# anwar-genai/rag-architecture architecture

> Architecture diagram of the GitHub repository anwar-genai/rag-architecture, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-16). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/anwar-genai/rag-architecture
- Repository: https://github.com/anwar-genai/rag-architecture

## Overview

RAG Architecture Canvas is a single-file interactive explainer, not a RAG processing service. Its user workflow is to explore the zoomable canvas, click a pipeline block for its details, and inspect the latency waterfall; users can also switch themes. The diagram documents ingestion, retrieval, generation, and evaluation feedback as a conceptual production pipeline. The README is the only available evidence, so the arrows describe documented interactions and conceptual flow, not inspected implementation calls.

Main entry points: [`index.html`](https://github.com/anwar-genai/rag-architecture/blob/main/index.html) (Eval feedback)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_canvas["Interactive canvas"]
  node_canvas_view["Zoomable canvas<br/>[index.html]"]
  node_pipeline_blocks["Pipeline blocks<br/>[index.html]"]
  node_block_details["Block details<br/>[index.html]"]
  node_latency["Latency waterfall<br/>[index.html]"]
  node_theme["Theme toggle<br/>[index.html]"]
end

subgraph group_rag["RAG pipeline"]
  node_ingestion["Ingestion<br/>[index.html]"]
  node_chunking["Chunking<br/>[index.html]"]
  node_embedding_config["Embedding config<br/>[index.html]"]
  node_hybrid_retrieval["Hybrid retrieval<br/>[index.html]"]
  node_retrieval_config["Retrieval config<br/>[index.html]"]
  node_reranking["Reranking<br/>[index.html]"]
  node_generation["Generation<br/>[index.html]"]
end

subgraph group_evaluation["Evaluation loop"]
  node_eval_loop["Eval feedback<br/>[index.html]"]
end

node_user(("User"))

node_user -->|"explores"| node_canvas_view
node_user -->|"clicks blocks"| node_pipeline_blocks
node_pipeline_blocks -->|"shows details"| node_block_details
node_user -->|"inspects timings"| node_latency
node_user -->|"switches theme"| node_theme
node_canvas_view -->|"displays"| node_pipeline_blocks
node_ingestion -->|"feeds"| node_chunking
node_chunking -->|"uses config"| node_embedding_config
node_embedding_config -->|"supports"| node_hybrid_retrieval
node_hybrid_retrieval -->|"feeds"| node_reranking
node_reranking -->|"feeds"| node_generation
node_generation -->|"evaluated by"| node_eval_loop
node_eval_loop -->|"retunes"| node_chunking
node_eval_loop -->|"retunes"| node_embedding_config
node_eval_loop -->|"retunes"| node_retrieval_config
node_retrieval_config -->|"configures"| node_hybrid_retrieval

click node_canvas_view "https://github.com/anwar-genai/rag-architecture/blob/main/index.html"
click node_pipeline_blocks "https://github.com/anwar-genai/rag-architecture/blob/main/index.html"
click node_block_details "https://github.com/anwar-genai/rag-architecture/blob/main/index.html"
click node_latency "https://github.com/anwar-genai/rag-architecture/blob/main/index.html"
click node_theme "https://github.com/anwar-genai/rag-architecture/blob/main/index.html"
click node_ingestion "https://github.com/anwar-genai/rag-architecture/blob/main/index.html"
click node_chunking "https://github.com/anwar-genai/rag-architecture/blob/main/index.html"
click node_embedding_config "https://github.com/anwar-genai/rag-architecture/blob/main/index.html"
click node_hybrid_retrieval "https://github.com/anwar-genai/rag-architecture/blob/main/index.html"
click node_retrieval_config "https://github.com/anwar-genai/rag-architecture/blob/main/index.html"
click node_reranking "https://github.com/anwar-genai/rag-architecture/blob/main/index.html"
click node_generation "https://github.com/anwar-genai/rag-architecture/blob/main/index.html"
click node_eval_loop "https://github.com/anwar-genai/rag-architecture/blob/main/index.html"

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_canvas_view,node_pipeline_blocks,node_block_details,node_latency,node_theme,node_user toneBlue
class node_ingestion,node_chunking,node_embedding_config,node_hybrid_retrieval,node_retrieval_config,node_reranking,node_generation toneAmber
class node_eval_loop toneMint
```

## Components

### Interactive canvas

- [Zoomable canvas](https://github.com/anwar-genai/rag-architecture/blob/main/index.html): `index.html`
- [Pipeline blocks](https://github.com/anwar-genai/rag-architecture/blob/main/index.html): `index.html`
- [Block details](https://github.com/anwar-genai/rag-architecture/blob/main/index.html): `index.html`
- [Latency waterfall](https://github.com/anwar-genai/rag-architecture/blob/main/index.html): `index.html`
- [Theme toggle](https://github.com/anwar-genai/rag-architecture/blob/main/index.html): `index.html`

### RAG pipeline

- [Ingestion](https://github.com/anwar-genai/rag-architecture/blob/main/index.html): `index.html`
- [Chunking](https://github.com/anwar-genai/rag-architecture/blob/main/index.html): `index.html`
- [Embedding config](https://github.com/anwar-genai/rag-architecture/blob/main/index.html): `index.html`
- [Hybrid retrieval](https://github.com/anwar-genai/rag-architecture/blob/main/index.html): `index.html`
- [Retrieval config](https://github.com/anwar-genai/rag-architecture/blob/main/index.html): `index.html`
- [Reranking](https://github.com/anwar-genai/rag-architecture/blob/main/index.html): `index.html`
- [Generation](https://github.com/anwar-genai/rag-architecture/blob/main/index.html): `index.html`

### Evaluation loop

- [Eval feedback](https://github.com/anwar-genai/rag-architecture/blob/main/index.html): `index.html`

### Other components

- **User**

## Connections

- User → Zoomable canvas: explores (evidence: `README.md`)
- User → Pipeline blocks: clicks blocks (evidence: `README.md`)
- Pipeline blocks → Block details: shows details (evidence: `README.md`)
- User → Latency waterfall: inspects timings (evidence: `README.md`)
- User → Theme toggle: switches theme (evidence: `README.md`)
- Zoomable canvas → Pipeline blocks: displays (evidence: `README.md`)
- Ingestion → Chunking: feeds (evidence: `README.md`)
- Chunking → Embedding config: uses config (evidence: `README.md`)
- Embedding config → Hybrid retrieval: supports (evidence: `README.md`)
- Hybrid retrieval → Reranking: feeds (evidence: `README.md`)
- Reranking → Generation: feeds (evidence: `README.md`)
- Generation → Eval feedback: evaluated by (evidence: `README.md`)
- Eval feedback → Chunking: retunes (evidence: `README.md`)
- Eval feedback → Embedding config: retunes (evidence: `README.md`)
- Eval feedback → Retrieval config: retunes (evidence: `README.md`)
- Retrieval config → Hybrid retrieval: configures (evidence: `README.md`)
