Inspiration
I use AI as a tool for finding stuff to do when I travel, and I wanted a way to quickly generate structured itineraries without manually searching for activities. This tool makes the process faster, more convenient, and visually appealing with automatic AI-generated suggestions and destination images.
What it does
Takes user input (destination + number of days). Uses Cohere AI to generate a detailed travel itinerary with morning, afternoon, and evening plans. Fetches relevant images of the destination using the Unsplash API. Formats the itinerary in a beautiful, structured layout with Tailwind CSS. Allows users to download a styled PDF of the itinerary to use while traveling.
How I built it
Backend: Flask (Python) to handle user input and AI requests. AI Integration: Cohere API for AI-generated itineraries. Image Fetching: Unsplash API for fetching relevant images dynamically. Frontend Styling: Tailwind CSS for clean, responsive UI. PDF Generation: Playwright & Pyppeteer to convert styled HTML into a downloadable PDF while preserving design. Hosting: Running locally, but could be deployed using Render, Vercel, or Replit.
Challenges we ran into
Formatting AI responses properly: Markdown formatting wasn’t always consistent, leading to some UI glitches. GitHub issues: Had to reset the repository after large files (like venv) got included accidentally. PDF styling: Traditional PDF libraries (like xhtml2pdf) stripped styling, so we had to switch to Playwright/Pyppeteer. API Key Management: Ensuring secure API usage and preventing rate limits.
Accomplishments that we're proud of
✅ Successfully integrating Cohere AI to dynamically generate structured itineraries. ✅ Making the UI clean, dark-mode friendly, and fully responsive with Tailwind CSS. ✅ Keeping the PDF output fully styled, unlike most solutions that lose formatting. ✅ Using Unsplash to fetch relevant images automatically for a more immersive experience.
What we learned
How to use AI-generated content effectively while ensuring proper markdown conversion. The best ways to preserve Tailwind CSS styles when exporting to PDF. How to handle GitHub issues and reset repositories cleanly. The importance of caching API requests (to avoid unnecessary fetches & rate limits).
What's next for AI Travel Itinerary Creator
🚀 Deploy Online – Host it on Render, Vercel, or Replit so users don’t need to run it locally. 📍 Add More Customization – Let users select preferences (budget-friendly, adventure, luxury, food-focused). 🗺️ Interactive Map – Display itinerary locations visually on an embedded map. 📅 Calendar Sync – Export itineraries to Google Calendar for easy trip planning. 📲 Mobile-Friendly UI – Improve UX for mobile users who want to generate itineraries on the go.
Built With
- cohere
- python
- unsplash
Log in or sign up for Devpost to join the conversation.