How saiphanindar2007/voyagegenie works
VoyageGenie is a conversational travel copilot that turns traveller preferences into a priced, multi-product itinerary, validates availability and price, and supports booking and post-booking actions. The frontend provides account access, a dashboard and trip conversation; the backend authenticates and persists trip state, then coordinates intent, itinerary, pricing and booking agents. Supplier adapters distinguish live Amadeus flight searches from simulated products and operations. The graph includes documented cancellation, modification and voucher capabilities; their detailed implementations were not all sampled, so some links are intentionally unverified.
Main entry points: orchestrator.py Turn orchestrator · supplier_adapter.py Supplier adapter · models.py Trip and booking records · main.py FastAPI application
Components 25
Traveller experience
- Login and register
frontend/app/login/page.tsx - Trip dashboard
frontend/app/dashboard/page.tsx - Trip conversation
frontend/app/components/ChatWindow.tsx - Itinerary panel
frontend/app/components/ItineraryPanel.tsx - API client
frontend/app/lib/api.ts - Session management
frontend/app/lib/auth.ts
API and identity
- FastAPI application
backend/app/main.py - Auth endpoints
backend/app/routers/auth.py - Trip endpoints
backend/app/routers/trips.py - Chat endpoint
backend/app/routers/chat.py - Trip ownership
backend/app/dependencies.py
Travel workflow
- Turn orchestrator
backend/app/agents/orchestrator.py - Intent extraction
backend/app/services/llm_client.py - Itinerary generation
backend/app/agents/itinerary_agent.py - Price validation
backend/app/agents/pricing_agent.py - Booking
backend/app/agents/booking_agent.py - Trip aftercare
backend/app/agents/support_agent.py - Trip modification
backend/app/agents/modification_agent.py
Suppliers and records
- Supplier adapter
backend/app/services/supplier_adapter.py - Mock travel supplier
backend/app/services/mock_travel_api.py - PDF vouchers
backend/app/services/voucher_service.py - Trip and booking records
backend/app/models.py - SQL database
backend/app/database.py
Other components
- Traveller
- Amadeus flights
Connections 33
- Traveller → Login and register: registers or logs in
- Traveller → Trip dashboard: manages trips
- Trip dashboard → Trip conversation: opens trip
- Trip conversation → API client: sends requests
frontend/app/components/ChatWindow.tsx - Trip dashboard → API client: loads trips
frontend/app/dashboard/page.tsx - API client → Session management: uses tokens
frontend/app/lib/api.ts - API client → FastAPI application: calls API
- FastAPI application → Auth endpoints: registers routes
backend/app/main.py - FastAPI application → Chat endpoint: registers routes
backend/app/main.py - FastAPI application → Trip endpoints: registers routes
backend/app/main.py - Auth endpoints → Trip ownership: uses authentication
backend/app/routers/auth.py - Chat endpoint → Trip ownership: checks ownership
backend/app/routers/chat.py - Trip endpoints → Trip ownership: checks ownership
backend/app/routers/trips.py - Chat endpoint → Turn orchestrator: handles turns
backend/app/routers/chat.py - Turn orchestrator → Intent extraction: extracts intent
backend/app/agents/orchestrator.py - Turn orchestrator → Itinerary generation: builds itinerary
backend/app/agents/orchestrator.py - Turn orchestrator → Price validation: revalidates prices
backend/app/agents/orchestrator.py - Turn orchestrator → Booking: confirms booking
backend/app/agents/orchestrator.py - Turn orchestrator → Trip aftercare: dispatches support
backend/app/agents/orchestrator.py - Trip aftercare → Trip modification: delegates changes
backend/app/agents/support_agent.py - Itinerary generation → Supplier adapter: searches products
backend/app/agents/itinerary_agent.py - Price validation → Supplier adapter: checks availability
backend/app/agents/pricing_agent.py - Booking → Supplier adapter: books products
backend/app/agents/booking_agent.py - Supplier adapter → Mock travel supplier: delegates searches
backend/app/services/supplier_adapter.py - Supplier adapter → Amadeus flights: searches flights
- Booking → PDF vouchers: generates vouchers
backend/app/agents/booking_agent.py - Trip endpoints → PDF vouchers: serves downloads
backend/app/routers/trips.py - Itinerary generation → Trip and booking records: updates trip items
backend/app/agents/itinerary_agent.py - Booking → Trip and booking records: records bookings
backend/app/agents/booking_agent.py - Chat endpoint → Trip and booking records: persists conversation
backend/app/routers/chat.py - Trip endpoints → Trip and booking records: updates trip state
backend/app/routers/trips.py - Trip and booking records → SQL database: stores records
backend/app/models.py - Trip modification → Supplier adapter: modifies bookings