Skip to content
zpoorvPublic

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

YatraFind

YatraFind is a database-grounded travel-planning application. Its Vite frontend sends conversations to a FastAPI backend, which retrieves verified travel records from PostgreSQL and asks OpenRouter for the final answer.

Project structure

frontend/                 Browser client (Vite, static single-page app)
backend/
  ai/                     OpenRouter client and grounded chat orchestration
  routers/                FastAPI HTTP routes
  database.py             PostgreSQL connection setup
  models.py               ORM models matching db/YatraFindd.sql
  main.py                 FastAPI application entry point
db/YatraFindd.sql         Verified travel-data database dump
YatraFind Main Backend/   Legacy prototype; not part of the runnable app

Configure

  1. Create and import a PostgreSQL database named yatrafind using db/YatraFindd.sql.
  2. Copy backend/.env.example to backend/.env.
  3. Set DATABASE_URL and OPENROUTER_API_KEY in backend/.env. Keep this file private; it is ignored by Git.

All model-generated replies use GPT-4o mini (openai/gpt-4o-mini) through OpenRouter. The model is intentionally pinned in the backend and cannot be changed by browser input or an environment variable.

Run

In one terminal:

cd backend
.\venv\Scripts\Activate.ps1
pip install -r requirements.txt
uvicorn main:app --host 127.0.0.1 --port 8000

In another terminal:

cd frontend
npm install
npm run dev

Open http://localhost:5173.

API

  • GET / — health check
  • GET /api/chat/cities — verified city catalog
  • GET /api/chat/cities/{city_name} — city guide from PostgreSQL
  • GET /api/chat/recommendations?interests=culture,food — deterministic recommendations
  • POST /api/chat/ — database-grounded OpenRouter chat

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages