How m0h1tkumar/ai_sre works
RunbookMind is an SRE incident diagnosis and remediation-ranking application. An SRE submits or simulates an alert in the control-center UI; the API records it and dispatches diagnosis, which gathers similar incidents, log and deployment context, asks an LLM for hypotheses and fixes, and reranks fixes using remembered outcomes. SRE feedback updates metrics and is retained for future recall. The graph also preserves the documented metrics and scenario capabilities. Some tool and UI-client internals were not excerpted, so their behavior is represented only where README or indexed references support it.
Main entry points: orchestrator.py Diagnosis Orchestrator · api.ts API Client · alerts.py Alert Endpoint · feedback.py Feedback Endpoint
Components 20
Control Center
- Control Center UI
ui/src/App.tsx - API Client
ui/src/api.ts
Incident API
- FastAPI Application
app/main.py - Alert Endpoint
app/api/alerts.py - Feedback Endpoint
app/api/feedback.py - Metrics Endpoint
app/api/metrics.py - API Schemas
app/api/schemas.py
Diagnosis Agent
- Diagnosis Orchestrator
app/agent/orchestrator.py - Prompt Builder
app/agent/prompts.py - LLM Client
app/agent/llm.py - Fix Reranker
app/agent/ranking.py - Log Search
app/tools/search_logs.py - Deployment History
app/tools/deploy_history.py - Runbook Tool
app/tools/runbooks.py
Learning and Metrics
- Incident Memory Client
app/memory/client.py - Resolution Formatter
app/memory/schema.py - Metrics Database
app/db/metrics.py
Other components
- SRE
- Groq Inference
- Hindsight Cloud
Connections 23
- SRE → Control Center UI: uses
README.md - Control Center UI → API Client: calls
ui/src/App.tsx - API Client → Alert Endpoint: submits alerts
README.md - API Client → Feedback Endpoint: submits feedback
README.md - API Client → Metrics Endpoint: fetches metrics
README.md - FastAPI Application → Alert Endpoint: registers route
app/main.py - FastAPI Application → Feedback Endpoint: registers route
app/main.py - FastAPI Application → Metrics Endpoint: registers route
app/main.py - Alert Endpoint → Diagnosis Orchestrator: dispatches diagnosis
app/api/alerts.py - Alert Endpoint → Metrics Database: records alert
app/api/alerts.py - Diagnosis Orchestrator → Incident Memory Client: recalls incidents
app/agent/orchestrator.py - Diagnosis Orchestrator → Log Search: searches logs
app/agent/orchestrator.py - Diagnosis Orchestrator → Deployment History: gets deployments
app/agent/orchestrator.py - Diagnosis Orchestrator → Prompt Builder: builds prompt
app/agent/orchestrator.py - Diagnosis Orchestrator → LLM Client: requests diagnosis
app/agent/orchestrator.py - LLM Client → Groq Inference: requests inference
app/agent/llm.py - Diagnosis Orchestrator → Fix Reranker: reranks fixes
app/agent/orchestrator.py - Incident Memory Client → Hindsight Cloud: recalls and retains
app/memory/client.py - Incident Memory Client → Resolution Formatter: formats resolution
app/memory/client.py - Feedback Endpoint → Metrics Database: updates outcomes
app/api/feedback.py - Feedback Endpoint → Incident Memory Client: retains resolution
app/api/feedback.py - Metrics Endpoint → Metrics Database: reads metrics
app/api/metrics.py - Runbook Tool → Diagnosis Orchestrator