How sanhith30/opspilot-ai-powered-it-operations-incident-response-copilot works
OpsPilot is an AI-assisted incident response copilot: operators use the web console or chat to investigate incidents, gather operational and knowledge evidence, assess risk, and review proposed remediation. The README documents tool-based investigation, grounded RAG, ticket workflows, human approval, RBAC, and auditing; those capabilities are represented where their source paths are supported. Excerpts show the API/frontend entry points, knowledge ingestion and retrieval, investigation persistence, and safe adapter dispatch, but not the full graph/tool orchestration or all service wiring, so uncertain links are omitted.
Main entry points: main.py REST API · App.jsx OpsPilot console · investigation_service.py Investigation workflow · service.py Access-aware retrieval
Components 24
Operator experience
- OpsPilot console
frontend/src/App.jsx - Persona authentication
frontend/src/context/AuthContext.jsx - Incident workspace
frontend/src/pages/IncidentDetailPage.jsx - Remediation portal
frontend/src/pages/RemediationsPage.jsx
API and workflows
- REST API
backend/app/main.py - Investigation endpoints
backend/app/api/v1/investigations.py - Incident endpoints
backend/app/api/v1/incidents.py - Investigation workflow
backend/app/services/investigation_service.py
Investigation intelligence
- Chat orchestration
backend/app/ai/graph/chat_graph.py - Investigation graph
backend/app/ai/graph/investigation_graph.py - Approved tool registry
backend/app/ai/tools/registry.py - Incident risk prediction
backend/app/ai/risk/predictor.py
Knowledge retrieval
- Knowledge document API
backend/app/api/v1/knowledge_documents.py - Document ingestion
backend/app/ai/rag/ingestion/service.py - Access-aware retrieval
backend/app/ai/rag/retrieval/service.py - Result reranking
backend/app/ai/rag/reranking/service.py - Vector index
backend/app/ai/rag/vectorstore/pinecone.py - Knowledge metadata
backend/app/repositories/knowledge_document_repository.py
Governed operations
- Remediation endpoints
backend/app/api/v1/remediations.py - Approval workflow
backend/app/services/remediation_service.py - Safe action engine
backend/app/remediation/engine.py - Action adapters
backend/app/remediation/adapters/restart.py - Immutable audit trail
backend/app/services/audit_log_service.py
Other components
- Operations engineer
Connections 26
- Operations engineer → OpsPilot console: uses
README.md - OpsPilot console → Persona authentication: provides context
frontend/src/App.jsx - OpsPilot console → Incident workspace: opens
frontend/src/App.jsx - OpsPilot console → Remediation portal: opens
frontend/src/App.jsx - Persona authentication → REST API: authenticates
frontend/src/context/AuthContext.jsx - OpsPilot console → REST API: requests data
- REST API → Investigation endpoints: routes
backend/app/main.py - REST API → Incident endpoints: routes
backend/app/main.py - REST API → Knowledge document API: routes
backend/app/main.py - REST API → Remediation endpoints: routes
backend/app/main.py - Investigation endpoints → Investigation workflow: delegates
- Investigation workflow → Investigation graph: runs analysis
- Investigation graph → Approved tool registry: dispatches tools
- Investigation graph → Incident risk prediction: assesses risk
- Investigation workflow → Access-aware retrieval: uses knowledge
- Knowledge document API → Document ingestion: ingests documents
- Document ingestion → Knowledge metadata: writes metadata
backend/app/ai/rag/ingestion/service.py - Document ingestion → Vector index: writes chunks
backend/app/ai/rag/ingestion/service.py - Access-aware retrieval → Knowledge metadata: checks versions
backend/app/ai/rag/retrieval/service.py - Access-aware retrieval → Result reranking: ranks candidates
- Access-aware retrieval → Vector index: searches vectors
backend/app/ai/rag/retrieval/service.py - Remediation endpoints → Approval workflow: delegates
- Approval workflow → Safe action engine: executes approved action
- Safe action engine → Action adapters: dispatches action
backend/app/remediation/engine.py - Approval workflow → Immutable audit trail: records decisions
- Investigation workflow → Immutable audit trail: records investigation
backend/app/services/investigation_service.py