How lindsey5/healthcare-scheduling-system-ai works
This repository implements a healthcare-center chat API. A user submits a message to the chat route, which invokes a stateful agent; the agent can answer from the FAQ knowledge base or call external services for service listings and appointment details. The FAQ path retrieves and formats relevant answers from a persisted FAISS index built from the dataset. The README is empty, so capabilities and connections here are based on the sampled source and file tree; the external service API’s implementation is not present.
Main entry points: vectorstore.py Vector store · ai_agent_routes.py Chat endpoint · agent.py Chat agent · tools.py Chat tools
Components 15
Chat API
- FastAPI app
app.py - Chat endpoint
routes/ai_agent_routes.py
Agent and tools
- Chat agent
agent/agent.py - Chat tools
agent/tools.py
FAQ knowledge
- FAQ retrieval
rag/chain.py - Vector store
rag/vectorstore.py - FAQ ingestion
rag/ingest.py - FAQ dataset
data/datasets.json - FAISS index
faiss_db/index.faiss - Index metadata
faiss_db/index.pkl
Model providers
- Model factory
llm/model.py - OpenRouter chat model
- Embedding service
Other components
- Chat user
- Healthcare API
Connections 16
- Chat user → Chat endpoint: sends message
- FastAPI app → Chat endpoint: registers route
- FastAPI app → Chat agent: initializes
- Chat endpoint → Chat agent: invokes
- Chat agent → Chat tools: dispatches tools
- Chat agent → Model factory: selects model
- Model factory → OpenRouter chat model: creates client
- Chat tools → FAQ retrieval: asks questions
- FAQ retrieval → Vector store: retrieves matches
- Vector store → FAISS index: loads and searches
- Vector store → Index metadata: loads metadata
- Chat tools → Healthcare API: fetches services or appointments
- FAQ ingestion → FAQ dataset: reads FAQs
- FAQ ingestion → Vector store: builds index
- Vector store → Embedding service: requests embeddings
- Chat endpoint → Chat user: returns reply