How rm-ramasamy/sre_agent_intermediate works
SRE Agent Intermediate is a full-stack incident-response platform. Target workloads produce failures and observability signals; edge MCP servers expose infrastructure, logs, metrics, code history, and runbooks; the agent investigates alerts and follow-up questions; the control plane manages identity and persisted incident state; and the dashboard lets operators inspect and steer investigations. The README documents the overall request/evidence flow. Several internal runtime and API links are supported by the source index; unsampled modules are represented at their exact tree paths, without inferring unshown calls.
Main entry points: agent_runtime.py Agent API and runtime · agent_runtime_tasks.py Investigation tasks · auth.py Auth routes · crud.py Persistence operations
Components 34
Demo workload
- Traffic generator
Target_Client/load-generator/load_gen.py - Demo services
Target_Client/services
Evidence integrations
- Prometheus tools
edge_mcp_servers/mcp_servers/prometheus_real/server.py - Loki tools
edge_mcp_servers/mcp_servers/loki_real/server.py - Kubernetes tools
edge_mcp_servers/mcp_servers/k8s_real/server.py - GitHub tools
edge_mcp_servers/mcp_servers/github_real/server.py - Runbook tools
edge_mcp_servers/mcp_servers/runbooks_local/server.py
Agent runtime
- Agent API and runtime
sre_agent/agent_runtime.py - Investigation tasks
sre_agent/agent_runtime_tasks.py - Specialist agent graph
sre_agent/multi_agent_langgraph.py - Investigation supervisor
sre_agent/supervisor.py - Agent state
sre_agent/agent_state.py - LLM providers
sre_agent/llm_utils.py - Incident memory
sre_agent/memory_store.py - Live execution state
sre_agent/redis_state_store.py - Live log callbacks
sre_agent/callbacks.py
Control plane
- Mission control API
sre_agent/api/v1/mission_control.py - Incident timeline
sre_agent/incident_timeline.py - Versioned API routes
sre_agent/api/v1 - Auth routes
backend/routers/auth.py - Request authentication
sre_agent/api/v1/auth_deps.py - Token security
backend/auth.py - Persistence operations
backend/crud.py - Platform data models
backend/models.py - API schemas
backend/schemas.py - PostgreSQL access
backend/database.py
Operator dashboard
- Operator dashboard
dashboard/app/(dashboard) - Incident command center
dashboard/components/dashboard/IncidentCommandCenter.tsx - Dashboard authentication
dashboard/lib/auth-context.tsx
Other components
- SRE operator
- Demo workload
- PostgreSQL
- Redis
- Qdrant
Connections 41
- Demo workload → Traffic generator: drives traffic
README.md - Traffic generator → Demo services: exercises services
- Demo services → Prometheus tools: emits signals
README.md - Demo services → Loki tools: emits logs
README.md - Prometheus tools → Agent API and runtime: provides evidence
README.md - Loki tools → Agent API and runtime: provides evidence
README.md - Kubernetes tools → Agent API and runtime: provides evidence
README.md - GitHub tools → Agent API and runtime: provides evidence
README.md - Runbook tools → Agent API and runtime: provides evidence
README.md - SRE operator → Operator dashboard: uses
README.md - Operator dashboard → Versioned API routes: requests API
README.md - Dashboard authentication → Auth routes: authenticates
- Incident command center → Mission control API: sends follow-up
- Agent API and runtime → Versioned API routes: mounts routes
sre_agent/agent_runtime.py - Agent API and runtime → Auth routes: mounts router
sre_agent/agent_runtime.py - Mission control API → Agent API and runtime: starts investigation
sre_agent/api/v1/mission_control.py - Agent API and runtime → Specialist agent graph: orchestrates agents
sre_agent/agent_runtime.py - Agent API and runtime → Agent state: uses state
sre_agent/agent_runtime.py - Agent API and runtime → Investigation tasks: runs background tasks
sre_agent/agent_runtime.py - Investigation tasks → Incident memory: stores findings
sre_agent/agent_runtime_tasks.py - Agent API and runtime → Live execution state: stores live state
sre_agent/agent_runtime.py - Agent API and runtime → Live log callbacks: registers callbacks
sre_agent/agent_runtime.py - Live log callbacks → Live execution state: writes logs
sre_agent/callbacks.py - Mission control API → Incident timeline: loads context
sre_agent/api/v1/mission_control.py - Mission control API → Investigation tasks: dispatches follow-up
sre_agent/api/v1/mission_control.py - Auth routes → Request authentication: checks identity
backend/routers/auth.py - Auth routes → Persistence operations: reads and creates users
backend/routers/auth.py - Auth routes → Token security: verifies and signs
backend/routers/auth.py - Request authentication → Token security: decodes token
sre_agent/api/v1/auth_deps.py - Request authentication → Persistence operations: loads user
sre_agent/api/v1/auth_deps.py - Persistence operations → Platform data models: queries records
backend/crud.py - Persistence operations → API schemas: uses schemas
backend/crud.py - Auth routes → PostgreSQL access: opens session
backend/routers/auth.py - Persistence operations → PostgreSQL access: persists records
- PostgreSQL access → PostgreSQL: connects
backend/database.py - Investigation tasks → PostgreSQL access: updates incidents and jobs
sre_agent/agent_runtime_tasks.py - Investigation tasks → Platform data models: updates records
sre_agent/agent_runtime_tasks.py - Agent API and runtime → LLM providers: selects model
sre_agent/agent_runtime.py - Agent API and runtime → Investigation supervisor: coordinates investigation
README.md - Investigation tasks → Redis: uses state store
- Investigation tasks → Qdrant: stores incident memory