How chittaranjanp51/enterprise-it-support-agentic-rag-copilot works
This is an enterprise IT support copilot: users submit questions through the chat API and receive a direct, knowledge-base, web-grounded, or explicitly unverified fallback answer, with source and trace metadata. Its main runtime is a LangGraph workflow that routes and grades evidence before choosing an answer path. A separate ingestion workflow loads policy files, chunks and embeds them, and writes them to Pinecone. The graph wiring and service calls are excerpted; web UI behavior and other unsampled details are not inferred.
Main entry points: services.py LLM provider · graph.py Question router · ingest.py Document ingestion · config.py Runtime settings
Components 21
Chat API
- Chat endpoint
app/main.py - Answer metadata
app/main.py
Answer Workflow
- LangGraph workflow
app/graph.py - Question router
app/graph.py - Direct answer
app/graph.py - KB retrieval
app/graph.py - KB evidence grading
app/graph.py - KB answer
app/graph.py - Web search
app/graph.py - Web evidence grading
app/graph.py - Web answer
app/graph.py - Fallback answer
app/graph.py
Knowledge Ingestion
- Policy files
data/kb - Document ingestion
app/ingest.py - Text chunking
app/ingest.py
External Services
- LLM provider
app/services.py - Text embeddings
app/services.py - Pinecone index
app/services.py - Tavily search
app/services.py - Runtime settings
app/config.py
Other components
- Questioner
Connections 29
- Questioner → Chat endpoint: submits question
README.md - Chat endpoint → LangGraph workflow: invokes
app/main.py - LangGraph workflow → Answer metadata: returns answer
app/main.py - LangGraph workflow → Question router: dispatches
app/graph.py - Question router → Direct answer: routes direct
app/graph.py - Question router → KB retrieval: routes lookup
app/graph.py - KB retrieval → KB evidence grading: passes matches
app/graph.py - KB evidence grading → KB answer: accepts evidence
app/graph.py - KB evidence grading → Web search: rejects evidence
app/graph.py - Web search → Web evidence grading: passes results
app/graph.py - Web evidence grading → Web answer: accepts evidence
app/graph.py - Web evidence grading → Fallback answer: rejects evidence
app/graph.py - Question router → LLM provider: asks
app/graph.py - Direct answer → LLM provider: asks
app/graph.py - KB evidence grading → LLM provider: grades with
app/graph.py - KB answer → LLM provider: generates with
app/graph.py - Web search → Tavily search: searches
app/graph.py - Web evidence grading → LLM provider: grades with
app/graph.py - Web answer → LLM provider: generates with
app/graph.py - Fallback answer → LLM provider: generates with
app/graph.py - KB retrieval → Text embeddings: embeds query
app/graph.py - KB retrieval → Pinecone index: queries
app/graph.py - Policy files → Document ingestion: loads files
README.md - Document ingestion → Text chunking: splits text
app/ingest.py - Document ingestion → Text embeddings: embeds chunks
app/ingest.py - Document ingestion → Pinecone index: upserts vectors
app/ingest.py - LLM provider → Runtime settings: reads provider config
app/services.py - Text embeddings → Runtime settings: reads model config
app/services.py - Pinecone index → Runtime settings: reads index config
app/services.py