The AI Travel Planner is a revolutionary platform that crafts personalized travel itineraries using the power of Google Gemini 2.5. Input your budget, travel dates, and interests, and our multi-agent system delivers tailored destination suggestions, detailed daily plans, and seamless booking optionsβall within a sleek, accessible interface. Built with Flask, SQLAlchemy, and Bootstrap 5, this tool redefines travel planning with AI-driven insights and a user-friendly design. This publication details the systemβs architecture, agent collaboration, setup instructions, and support status, with all resources available in our public GitHub repository and a video demo.
Planning a trip can be dauntingβbalancing budgets, destinations, and activities is no easy task. The AI Travel Planner simplifies it all with artificial intelligence, offering personalized recommendations, comprehensive itineraries, and booking management in one intuitive platform. Certified under AAIDC-M2 standards, this publication provides a clear, engaging overview of the systemβs design, implementation, and usage.
The AI Travel Planner is modular, scalable, and designed for ease of use, leveraging a multi-agent system and a robust tech stack.
The platform comprises four core components:
Project Structure:
ai-travel-planner/
βββ Core Application
β βββ app.py # Flask app setup
β βββ main.py # Application entry point
β βββ routes.py # API routes
βββ AI & Services
β βββ gemini.py # AI recommendation logic
β βββ travel_service.py # Mock booking services
βββ Data Layer
β βββ models.py # Database models
β βββ instance/ # Database files
βββ Frontend
β βββ templates/ # Jinja2 HTML templates
β βββ static/css/ # Custom CSS
β βββ static/js/ # JavaScript for interactivity
βββ Documentation
βββ README.md # Project guide
βββ docs/ # Architecture diagrams
Component | Technology | Purpose |
---|---|---|
Backend | Flask 2.3.3 | Lightweight web framework |
AI Engine | Google Gemini 2.5 | Intelligent recommendations |
Database | SQLAlchemy + SQLite/PostgreSQL | Persistent data storage |
Frontend | Bootstrap 5 + Vanilla JS | Responsive, accessible UI |
Deployment | Gunicorn + Replit | Scalable hosting |
Four specialized agents collaborate seamlessly to plan your perfect trip.
routes.py
) manages agent interactions:
/preferences
./destinations
./itinerary
./book/<type>
.The chart below visualizes the data flow between agents, showing the number of API calls per request cycle (sample data).
app.py
, routes.py
): Handles user sessions and API routing.models.py
):
TravelPreference
: Stores budget, dates, and interests.Itinerary
: Saves trip plans with activities and budgets.gemini.py
): Custom prompts for Gemini 2.5 to generate recommendations.templates/
): Jinja2 for dynamic HTML rendering.static/css/style.css
): Bootstrap 5 with a dark theme and WCAG compliance.static/js/
): Vanilla JavaScript for form validation and dynamic features.Endpoint | Method | Description |
---|---|---|
/ | GET | Welcome page |
/preferences | GET/POST | Submit travel preferences |
/destinations | GET | View AI-recommended destinations |
/itinerary | GET | Access detailed itinerary |
/book/<type> | GET | Book flights, hotels, or activities |
/my_bookings | GET | View booking history |
Follow these steps to set up the AI Travel Planner locally.
git clone https://github.com/AishwaryaChandel27/AI-Travel-Planner.git cd AI-Travel-Planner
pip install -r requirements.txt
export GEMINI_API_KEY="your-gemini-api-key" export DATABASE_URL="sqlite:///travel_planner.db" # Or PostgreSQL URL
python -c "from app import db; db.create_all()"
python main.py
http://localhost:5000
in your browser.docker build -t ai-travel-planner .
docker run -p 5000:5000 -e GEMINI_API_KEY="your-gemini-api-key" ai-travel-planner
http://localhost:5000
./preferences
to input your budget, dates, and interests./destinations
for three AI-curated suggestions./itinerary
for a detailed plan./book/<type>
to reserve flights, hotels, or activities./my_bookings
.The AI Travel Planner is licensed under the MIT License, allowing free use, modification, and distribution. See the LICENSE
file in the repository for full details. This open-source license ensures transparency and encourages community contributions while protecting user rights.
docs/
folder of the repository.We welcome contributions! To get started:
git checkout -b feature/your-feature
).git commit -m "Add your feature"
).git push origin feature/your-feature
).Please follow PEP 8 guidelines and include tests for new features.
Have questions or ideas? Check the repositoryβs Wiki, report issues on GitHub, or join our Discussions community. Letβs make travel planning unforgettable together!