How vyshnavi536/laurus-agent works
Laurus is a pharmaceutical intelligence chat application. Users sign up or log in, then submit a drug question or two-drug interaction query; the backend identifies the drugs, retrieves FDA label data or checks interaction sources, and returns a formatted AI-assisted response. Authenticated chat history is presented in the UI and can be deleted or cleared. The README documents these capabilities; sampled source confirms the query and integration logic, while route implementation details and some frontend screens were not sampled, so uncertain internal wiring is omitted.
Main entry points: Chat.jsx Chat page · langchain_service.py Query processing · api.js API client · App.jsx App routing
Components 18
Web application
- App routing
frontend/src/App.jsx - Login and signup
frontend/src/pages/Login.jsx - Chat page
frontend/src/pages/Chat.jsx - Message display
frontend/src/components/ChatBox.jsx - History sidebar
frontend/src/components/Sidebar.jsx - API client
frontend/src/services/api.js
API and identity
- FastAPI app
backend/main.py - Auth routes
backend/routes/auth.py - Chat and history routes
backend/routes/chat.py - User and history models
backend/models.py
Drug intelligence
- Query processing
backend/services/langchain_service.py - Drug label lookup
backend/services/openfda_service.py - Interaction analysis
backend/services/interaction_service.py
Data and integrations
- SQLite database
backend/database.py - Kaggle DDI data
backend/kaggle_interactions.csv - Google Gemini
- OpenFDA service
Other components
- User
Connections 20
- User → App routing: uses
- App routing → Login and signup: routes
- App routing → Chat page: routes
- Chat page → Message display: displays
- Chat page → History sidebar: renders
- Login and signup → API client: submits credentials
- Chat page → API client: sends queries
- Chat page → API client: requests history
- API client → FastAPI app: HTTP requests
- FastAPI app → Auth routes: registers routes
- FastAPI app → Chat and history routes: registers routes
- Auth routes → SQLite database: reads and writes users
- Chat and history routes → SQLite database: stores history
- Chat and history routes → Query processing: processes query
- Query processing → Drug label lookup: looks up drug
- Query processing → Interaction analysis: checks pair
- Drug label lookup → Interaction analysis: normalizes names
- Drug label lookup → OpenFDA service: fetches label
- Interaction analysis → Kaggle DDI data: reads interactions
- Query processing → Google Gemini: extracts and summarizes