# ayush488-glitch/genesis-kit architecture

> Architecture diagram of the GitHub repository ayush488-glitch/genesis-kit, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-06). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/ayush488-glitch/genesis-kit
- Repository: https://github.com/ayush488-glitch/genesis-kit

## Overview

Genesis is a local, repository-native harness for resumable agent-assisted development. The main workflow captures a human-approved specification and plan, authorizes bounded task execution, verifies work against acceptance checks, and records evidence so work can be resumed. Its CLI also manages durable project state, checkpoints, and evaluated learning. A separate code-indexing branch supports queries, agent access, and local visualizations. The CLI is a large implementation hub; unsampled lifecycle details are represented only where the README documents them.

Main entry points: [`tools/genesis.mjs`](https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/genesis.mjs) (Genesis CLI), [`tools/query.mjs`](https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/query.mjs) (Index queries), [`tools/serve.mjs`](https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/serve.mjs) (Live view server), [`tools/graphizer.mjs`](https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/graphizer.mjs) (Code indexer)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_lifecycle["Work lifecycle"]
  node_cli["Genesis CLI<br/>[genesis.mjs]"]
  node_discovery["Discovery<br/>[genesis.mjs]"]
  node_spec["Specification<br/>[genesis.mjs]"]
  node_planning["Planning<br/>[genesis.mjs]"]
  node_execution["Authorized execution<br/>[genesis.mjs]"]
  node_verification["Verification<br/>[genesis.mjs]"]
end

subgraph group_continuation["State and learning"]
  node_project[("Project record")]
  node_proof[("Evidence receipts")]
  node_context["Context and recovery<br/>[genesis.mjs]"]
  node_learning["Evaluated learning<br/>[genesis.mjs]"]
end

subgraph group_indexing["Code intelligence"]
  node_indexer["Code indexer<br/>[graphizer.mjs]"]
  node_graph[("Repository index")]
  node_query["Index queries<br/>[query.mjs]"]
end

subgraph group_interfaces["User interfaces"]
  node_mcp["MCP interface<br/>[mcp.mjs]"]
  node_dashboard["Static dashboard<br/>[dashboard.mjs]"]
  node_server["Live view server<br/>[serve.mjs]"]
  node_panel["Live control panel<br/>[control-panel.mjs]"]
end

node_human(("Human"))
node_agent(("Coding host"))

node_human -->|"guides"| node_discovery
node_discovery -->|"informs"| node_spec
node_human -->|"approves"| node_spec
node_spec -->|"defines work"| node_planning
node_planning -->|"authorizes tasks"| node_execution
node_agent -->|"performs work"| node_execution
node_execution -->|"submits for proof"| node_verification
node_verification -->|"records evidence"| node_proof
node_cli -->|"persists state"| node_project
node_cli -->|"builds context"| node_context
node_context -->|"supplies continuation"| node_agent
node_cli -->|"runs evaluations"| node_learning
node_human -->|"reviews promotion"| node_learning
node_cli -.->|"runs indexing"| node_indexer
node_indexer -->|"writes index"| node_graph
node_query -->|"reads index"| node_graph
node_mcp -->|"delegates queries"| node_query
node_cli -->|"serves queries"| node_query
node_cli -->|"generates snapshot"| node_dashboard
node_server -->|"serves page"| node_panel
node_server -->|"uses queries"| node_query
node_dashboard -->|"renders state"| node_project

click node_cli "https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/genesis.mjs"
click node_discovery "https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/genesis.mjs"
click node_spec "https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/genesis.mjs"
click node_planning "https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/genesis.mjs"
click node_execution "https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/genesis.mjs"
click node_verification "https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/genesis.mjs"
click node_context "https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/genesis.mjs"
click node_learning "https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/genesis.mjs"
click node_indexer "https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/graphizer.mjs"
click node_query "https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/query.mjs"
click node_mcp "https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/mcp.mjs"
click node_dashboard "https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/dashboard.mjs"
click node_server "https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/serve.mjs"
click node_panel "https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/control-panel.mjs"

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_cli,node_discovery,node_spec,node_planning,node_execution,node_verification toneBlue
class node_project,node_proof,node_context,node_learning toneAmber
class node_indexer,node_graph,node_query toneMint
class node_mcp,node_dashboard,node_server,node_panel toneRose
class node_human,node_agent toneIndigo
```

## Components

### Work lifecycle

- [Genesis CLI](https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/genesis.mjs): `tools/genesis.mjs`
- [Discovery](https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/genesis.mjs): `tools/genesis.mjs`
- [Specification](https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/genesis.mjs): `tools/genesis.mjs`
- [Planning](https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/genesis.mjs): `tools/genesis.mjs`
- [Authorized execution](https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/genesis.mjs): `tools/genesis.mjs`
- [Verification](https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/genesis.mjs): `tools/genesis.mjs`

### State and learning

- **Project record**
- **Evidence receipts**
- [Context and recovery](https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/genesis.mjs): `tools/genesis.mjs`
- [Evaluated learning](https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/genesis.mjs): `tools/genesis.mjs`

### Code intelligence

- [Code indexer](https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/graphizer.mjs): `tools/graphizer.mjs`
- **Repository index**
- [Index queries](https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/query.mjs): `tools/query.mjs`

### User interfaces

- [MCP interface](https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/mcp.mjs): `tools/mcp.mjs`
- [Static dashboard](https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/dashboard.mjs): `tools/dashboard.mjs`
- [Live view server](https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/serve.mjs): `tools/serve.mjs`
- [Live control panel](https://github.com/ayush488-glitch/genesis-kit/blob/main/tools/control-panel.mjs): `tools/control-panel.mjs`

### Other components

- **Human**
- **Coding host**

## Connections

- Human → Discovery: guides (evidence: `README.md`)
- Discovery → Specification: informs (evidence: `README.md`)
- Human → Specification: approves (evidence: `README.md`)
- Specification → Planning: defines work (evidence: `README.md`)
- Planning → Authorized execution: authorizes tasks (evidence: `README.md`)
- Coding host → Authorized execution: performs work (evidence: `README.md`)
- Authorized execution → Verification: submits for proof (evidence: `README.md`)
- Verification → Evidence receipts: records evidence (evidence: `README.md`)
- Genesis CLI → Project record: persists state (evidence: `README.md`)
- Genesis CLI → Context and recovery: builds context (evidence: `README.md`)
- Context and recovery → Coding host: supplies continuation (evidence: `README.md`)
- Genesis CLI → Evaluated learning: runs evaluations (evidence: `README.md`)
- Human → Evaluated learning: reviews promotion (evidence: `README.md`)
- Genesis CLI → Code indexer: runs indexing
- Code indexer → Repository index: writes index (evidence: `README.md`)
- Index queries → Repository index: reads index (evidence: `tools/query.mjs`)
- MCP interface → Index queries: delegates queries (evidence: `tools/mcp.mjs`)
- Genesis CLI → Index queries: serves queries (evidence: `tools/genesis.mjs`)
- Genesis CLI → Static dashboard: generates snapshot (evidence: `tools/genesis.mjs`)
- Live view server → Live control panel: serves page (evidence: `tools/serve.mjs`)
- Live view server → Index queries: uses queries (evidence: `tools/serve.mjs`)
- Static dashboard → Project record: renders state (evidence: `README.md`)
