# raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis- architecture

> Architecture diagram of the GitHub repository raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-25). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-
- Repository: https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-

## Overview

This is an autonomous AIOps root-cause and remediation system. A telemetry collector detects real service-health transitions and raises alerts; the API starts a LangGraph workflow that localises the deepest unhealthy dependency, retrieves graph-vetted SOP candidates, asks an LLM to select safely, executes the SOP in a Docker sandbox, and re-probes for recovery, using fallback SOPs when needed. Neo4j holds infrastructure and skill graphs plus observed status. The dashboard exposes live incidents, graphs, audit history, and evaluations. Core runtime wiring is supported by sampled source; several documented subsystem links are shown at directory level because their implementations were not sampled.

Main entry points: [`agent/graph.py`](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/agent/graph.py) (LangGraph workflow), [`dashboard/app.py`](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/dashboard/app.py) (Streamlit dashboard), [`simulation/telemetry_collector.py`](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/simulation/telemetry_collector.py) (Telemetry collector), [`agent/main.py`](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/agent/main.py) (Alert API)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_observe["Detection"]
  node_collector["Telemetry collector"]
  node_injector["Fault injector<br/>[fault_injector.py]"]
end

subgraph group_agent["RCA agent"]
  node_webhook["Alert API<br/>[main.py]"]
  node_workflow["LangGraph workflow<br/>[graph.py]"]
  node_ingest["Alert ingestion<br/>[ingest.py]"]
  node_retriever["Graph retriever<br/>[retriever.py]"]
  node_reasoner["LLM reasoner<br/>[reasoner.py]"]
  node_evaluator["Recovery evaluator<br/>[evaluator.py]"]
  node_executor["SOP executor<br/>[executor.py]"]
end

subgraph group_knowledge["Graph knowledge"]
  node_graphclient["Graph client<br/>[graph_client.py]"]
  node_neo4j[("Neo4j graph")]
  node_populator["Graph population<br/>[graph_populator.py]"]
  node_schemas["Graph schema"]
end

subgraph group_ops["Remediation"]
  node_sandbox["Docker sandbox<br/>[sandbox_tools.py]"]
end

subgraph group_surface["Product surface"]
  node_dashboard["Streamlit dashboard<br/>[app.py]"]
  node_views["RCA views<br/>[rca_report.py]"]
  node_history["Incident audit<br/>[agent_log.py]"]
  node_visuals["Graph visualizations<br/>[graph_viz.py]"]
  node_baselines["RAG baselines"]
  node_evaluation["Benchmarking<br/>[benchmark_full.py]"]
end

node_boutique(("Microservice stack"))
node_llm{{"LLM provider"}}
node_docker{{"Docker engine"}}
node_redis["Redis health"]

node_boutique -->|"reports state"| node_collector
node_collector -->|"probes containers"| node_docker
node_collector -->|"checks health"| node_redis
node_collector -->|"syncs status"| node_neo4j
node_collector -->|"posts alerts"| node_webhook
node_injector -->|"injects faults"| node_docker
node_injector -->|"records status"| node_neo4j
node_webhook -->|"invokes"| node_workflow
node_workflow -->|"dispatches"| node_ingest
node_workflow -->|"dispatches"| node_retriever
node_workflow -->|"dispatches"| node_reasoner
node_workflow -->|"dispatches"| node_executor
node_workflow -->|"dispatches"| node_evaluator
node_retriever -->|"queries"| node_graphclient
node_graphclient -->|"reads graph"| node_neo4j
node_graphclient -->|"writes status"| node_neo4j
node_reasoner -->|"requests decision"| node_llm
node_executor -->|"runs SOP"| node_sandbox
node_sandbox -->|"runs container"| node_docker
node_evaluator -->|"re-probes"| node_docker
node_evaluator -->|"verifies health"| node_redis
node_executor -->|"requests fallback"| node_retriever
node_dashboard -->|"submits alerts"| node_webhook
node_dashboard -->|"renders reports"| node_views
node_dashboard -->|"shows history"| node_history
node_dashboard -->|"renders graphs"| node_visuals
node_dashboard -->|"reads live state"| node_neo4j
node_populator -->|"loads graph data"| node_neo4j
node_schemas -->|"defines graph"| node_populator
node_evaluation -->|"compares systems"| node_baselines
node_evaluation -->|"runs agent alerts"| node_webhook

click node_collector "https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/simulation/telemetry_collector.py"
click node_injector "https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/simulation/fault_injector.py"
click node_webhook "https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/agent/main.py"
click node_workflow "https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/agent/graph.py"
click node_ingest "https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/agent/nodes/ingest.py"
click node_retriever "https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/agent/nodes/retriever.py"
click node_reasoner "https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/agent/nodes/reasoner.py"
click node_evaluator "https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/agent/nodes/evaluator.py"
click node_executor "https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/agent/nodes/executor.py"
click node_sandbox "https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/agent/tools/sandbox_tools.py"
click node_graphclient "https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/graph/graph_client.py"
click node_populator "https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/graph/graph_populator.py"
click node_schemas "https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/graph/schema_definitions.py"
click node_dashboard "https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/dashboard/app.py"
click node_views "https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/dashboard/components/rca_report.py"
click node_history "https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/dashboard/components/agent_log.py"
click node_visuals "https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/dashboard/components/graph_viz.py"
click node_baselines "https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/tree/main/eval/baselines"
click node_evaluation "https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/eval/benchmark_full.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_collector,node_injector toneBlue
class node_webhook,node_workflow,node_ingest,node_retriever,node_reasoner,node_evaluator,node_executor,node_redis toneAmber
class node_graphclient,node_neo4j,node_populator,node_schemas toneMint
class node_sandbox toneRose
class node_dashboard,node_views,node_history,node_visuals,node_baselines,node_evaluation,node_boutique,node_llm,node_docker toneIndigo
```

## Components

### Detection

- [Telemetry collector](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/simulation/telemetry_collector.py): `simulation/telemetry_collector.py`
- [Fault injector](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/simulation/fault_injector.py): `simulation/fault_injector.py`

### RCA agent

- [Alert API](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/agent/main.py): `agent/main.py`
- [LangGraph workflow](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/agent/graph.py): `agent/graph.py`
- [Alert ingestion](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/agent/nodes/ingest.py): `agent/nodes/ingest.py`
- [Graph retriever](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/agent/nodes/retriever.py): `agent/nodes/retriever.py`
- [LLM reasoner](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/agent/nodes/reasoner.py): `agent/nodes/reasoner.py`
- [Recovery evaluator](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/agent/nodes/evaluator.py): `agent/nodes/evaluator.py`
- [SOP executor](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/agent/nodes/executor.py): `agent/nodes/executor.py`

### Graph knowledge

- [Graph client](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/graph/graph_client.py): `graph/graph_client.py`
- **Neo4j graph**
- [Graph population](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/graph/graph_populator.py): `graph/graph_populator.py`
- [Graph schema](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/graph/schema_definitions.py): `graph/schema_definitions.py`

### Remediation

- [Docker sandbox](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/agent/tools/sandbox_tools.py): `agent/tools/sandbox_tools.py`

### Product surface

- [Streamlit dashboard](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/dashboard/app.py): `dashboard/app.py`
- [RCA views](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/dashboard/components/rca_report.py): `dashboard/components/rca_report.py`
- [Incident audit](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/dashboard/components/agent_log.py): `dashboard/components/agent_log.py`
- [Graph visualizations](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/dashboard/components/graph_viz.py): `dashboard/components/graph_viz.py`
- [RAG baselines](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/tree/main/eval/baselines): `eval/baselines`
- [Benchmarking](https://github.com/raghavnimbalkar1/agentic-graphrag-for-root-cause-analysis-/blob/main/eval/benchmark_full.py): `eval/benchmark_full.py`

### Other components

- **Microservice stack**
- **LLM provider**
- **Docker engine**
- **Redis health**

## Connections

- Microservice stack → Telemetry collector: reports state
- Telemetry collector → Docker engine: probes containers
- Telemetry collector → Redis health: checks health
- Telemetry collector → Neo4j graph: syncs status
- Telemetry collector → Alert API: posts alerts
- Fault injector → Docker engine: injects faults
- Fault injector → Neo4j graph: records status
- Alert API → LangGraph workflow: invokes
- LangGraph workflow → Alert ingestion: dispatches
- LangGraph workflow → Graph retriever: dispatches
- LangGraph workflow → LLM reasoner: dispatches
- LangGraph workflow → SOP executor: dispatches
- LangGraph workflow → Recovery evaluator: dispatches
- Graph retriever → Graph client: queries
- Graph client → Neo4j graph: reads graph
- Graph client → Neo4j graph: writes status
- LLM reasoner → LLM provider: requests decision
- SOP executor → Docker sandbox: runs SOP
- Docker sandbox → Docker engine: runs container
- Recovery evaluator → Docker engine: re-probes
- Recovery evaluator → Redis health: verifies health
- SOP executor → Graph retriever: requests fallback
- Streamlit dashboard → Alert API: submits alerts
- Streamlit dashboard → RCA views: renders reports
- Streamlit dashboard → Incident audit: shows history
- Streamlit dashboard → Graph visualizations: renders graphs
- Streamlit dashboard → Neo4j graph: reads live state
- Graph population → Neo4j graph: loads graph data
- Graph schema → Graph population: defines graph
- Benchmarking → RAG baselines: compares systems
- Benchmarking → Alert API: runs agent alerts
