README.md
August 26, 2026 Β· View on GitHub
TravelBrain
A multi-agent AI travel planner. Describe the trip you want in
plain English and get back flights, hotels, weather and a day-by-day
itinerary β researched for you in about a minute.
π Table of Contents
π§ About
Planning a trip usually means juggling half a dozen browser tabs β one for flights, another for hotels, a third for the weather, and a notes app where you try to fit it all into a sensible order. TravelBrain collapses that into a single conversation. You describe the trip you want in your own words, the way you'd describe it to a friend β "Plan a 10 day Europe trip from India in April, mid-range budget" β and a team of AI specialists goes and researches it. One looks into flights, another finds places to stay, another checks what the weather will be doing while you're there. Their findings are then pulled together into a single plan you can actually act on, complete with a day-by-day schedule and a cost estimate. The result is a trip plan in about a minute, rather than an afternoon of research. Each part of the trip gets its own attention:
| βοΈ Flights | Likely airports, airlines on the route, typical duration and fare range |
| π¨ Hotels | Accommodation options matched to your destination and budget |
| π€οΈ Weather | Current conditions and the forecast, with travel advice |
| πΊοΈ Itinerary | A realistic day-by-day plan you can actually follow |
| π° Budget | An estimated breakdown of what the trip will cost |
Plans are saved as you go, so you can reopen a trip later and ask follow-up questions without starting over.
π Getting Started
These instructions will get you a copy of the project up and running on your local machine.
Prerequisites
You'll need the following before you start:
- Python 3.11
- uv β used to install dependencies
- A PostgreSQL database β a free Render instance works fine
- API keys from the services below. All of them have free tiers:
Installing
Clone the repository and move into it:
git clone https://github.com/KalyanM45/TravelBrain-Multi-Agent-AI-Travel-Planner.git
cd TravelBrain-Multi-Agent-AI-Travel-Planner
Install the dependencies:
uv sync
Create a file named .env in the project root and add your keys:
# Required
GROQ_API_KEY=your_groq_key
DATABASE_URL=postgresql://user:password@host:5432/dbname
# Service keys
TAVILY_API_KEY=your_tavily_key
AVIATIONSTACK_API_KEY=your_aviationstack_key
OPENWEATHER_API_KEY=your_openweather_key
# Optional
GROQ_MODEL=openai/gpt-oss-20b
Here's what each one is for:
| Variable | Required | What it's for |
|---|---|---|
GROQ_API_KEY | β | Powers the AI planning |
DATABASE_URL | β | Saves your trips so you can return to them |
TAVILY_API_KEY | β | Hotel search |
AVIATIONSTACK_API_KEY | β | Airport and airline information |
OPENWEATHER_API_KEY | β | Weather and forecasts |
GROQ_MODEL | β | Switch the AI model without editing any code |
Your .env file is ignored by Git. Never commit real keys.
Now start the app:
uv run python app.py
Open http://127.0.0.1:8000 in your browser. If you see the planner with a green API connected dot at the bottom of the sidebar, you're ready to go.
π Usage
Planning a trip
Type your request into the box at the bottom of the screen and press Enter. Anything conversational works:
Plan a 10 day Europe trip from India in April, mid-range budget
I want a relaxed 5 day trip to Rome and Florence in September for two people
Not sure where to start? Click one of the suggestion cards on the home screen.
A plan takes 30β90 seconds to build, and you'll see each stage as it progresses.
Using the trip builder
If you'd rather fill in fields than write a sentence, click the sliders icon to the left of the message box. Enter your origin, destination, dates, duration, number of travellers and budget, pick the things you're interested in, then hit Write my prompt. Your request is composed for you, ready to send or edit.
Reading your plan
Your results are split into tabs so you can jump straight to what you need:
Plan Β· Itinerary Β· Flights Β· Hotels Β· Weather
Saving, exporting and revisiting
- Every trip is saved to the sidebar automatically β click any one to reopen it
- Ask follow-up questions on an open trip and it remembers the context
- Use the icons at the top of a result to copy, download as Markdown or print
- Click New trip to start fresh
- Switch between light and dark mode with the sun/moon icon at the bottom of the sidebar
π€ Troubleshooting
The page loads but planning fails
Check the status indicator at the bottom of the sidebar. If it says API
unreachable, the app has stopped β restart it with uv run python app.py.
Otherwise, check the terminal you started the app in for the error.
An error says the model does not exist
AI providers retire models over time. List the ones your key can use:
curl -s https://api.groq.com/openai/v1/models \
-H "Authorization: Bearer $GROQ_API_KEY"
Pick one from the list and set it as GROQ_MODEL in your .env file.
An error says DATABASE_URL is missing
The app needs a PostgreSQL database to save your trips. Add a connection string
to your .env file β see Installing.
Plans take a long time
This is expected. Several specialists research your trip in turn, and each step involves live data and AI calls. 30β90 seconds is normal.
π€ Contributing
Contributions are welcome. This project is actively being developed, so there's plenty to pick up.
Getting set up
- Fork the repository and clone your fork
- Follow Getting Started to install everything
- Create a branch for your work:
git checkout -b feature/your-feature-name
Making your changes
- Keep each pull request focused on one thing
- Match the style of the code around you
- Check the app still runs end to end before you open a pull request
- Never commit your
.envfile or any API keys
Submitting your work
Commit with a message that says what changed and why:
git commit -m "Add support for multi-city trips"
Push to your fork:
git push origin feature/your-feature-name
Then open a pull request against main describing what you changed, why,
and how you tested it.
Reporting bugs and suggesting ideas
Open an issue. For bugs, include what you did, what you expected, what happened instead, and any error output from the terminal.
π Acknowledgements
- Groq for fast AI inference
- Tavily, AviationStack and OpenWeather for the live travel data
Licensed under the GNU General Public License v3.0. See LICENSE.