Airline policy information is scattered, inconsistent, and hard to access when you actually need it. Phone support averages 2-12 hours. 80% of travelers say standard chatbots can't answer simple policy questions. And when you're rushing between gates or driving to the airport, typing through FAQ pages isn't practical.
A voice-enabled assistant that understands natural language and compares policies across multiple airlines. Semantic search interprets intent—not just keywords. Response time under 3 seconds. Voice support in Turkish and English for hands-free use.
demo.mp4
Speech services run as separate streams—TTS failure doesn't block query processing. Dual-LLM setup enables quality comparison and prevents vendor lock-in.
graph TD
A[User] <--> B[Frontend React]
B --> C[FastAPI Backend]
B --> I[Audio Input]
I --> J[AssemblyAI STT]
J --> C
C <--> D[PostgreSQL + pgvector]
E[Web Scraper] --> D
C <--> F[OpenAI/Claude APIs]
C --> K[AWS Polly TTS]
K --> L[Audio Output]
L --> B
G[Prometheus] --> H[Grafana]
C --> G
classDef userPath fill:#e1f5fe
classDef audioPath fill:#f3e5f5
classDef backend fill:#e8f5e8
classDef monitoring fill:#fff3e0
class A,B userPath
class I,J,K,L audioPath
class C,D,E,F backend
class G,H monitoring
| Technology | Purpose | Trade-off Reasoning |
|---|---|---|
| pgvector | Vector Search | Reduced overhead vs Pinecone/Weaviate. Sufficient for policy-scale datasets. |
| gte-multilingual-base | Embeddings | Open-source, no per-query cost. Native Turkish/English support. |
| FastAPI | Backend | Async handles concurrent LLM + STT + TTS calls. |
| BeautifulSoup | Scraping | Sufficient for general-purpose scraping needs. |
| OpenAI + Claude | LLM | Dual-provider prevents lock-in. Enables quality comparison. |
| AssemblyAI | STT | Strong Turkish accuracy. Handles background noise well. |
RAG Pipeline: Semantic search with source attribution. Reduces hallucination risk.
Voice Interface: Real-time STT/TTS in Turkish and English.
Production Monitoring: Prometheus + Grafana for latency, errors, and API costs.
Multi-LLM Support: Switch providers without code changes.
Intelligent Caching: Multi-layer LRU cache for repeated queries.
Metadata-Aware Routing: Airline-level metadata prefiltering combined with query routing to the correct policy domain.
git clone <repository-url>
cd multi-airline-rag-systemcp .env.example .envEdit the .env file and add your API keys:
OPENAI_API_KEY=your_openai_api_key_here
AWS_ACCESS_KEY_ID=your_aws_access_key_here
AWS_SECRET_ACCESS_KEY=your_aws_secret_key_here
# ... other required keysdocker-compose up -dNote: Initial startup may take 3-5 minutes as Docker builds the images and downloads ML models.
docker-compose run scraper python scraper_only.pycurl http://localhost:8000/health| Service | URL |
|---|---|
| Frontend | http://localhost:8501 |
| API | http://localhost:8000 |
| Grafana | http://localhost:3000 |