# navywakura/echoai architecture

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

- Interactive diagram: https://gitdiagram.com/navywakura/echoai
- Repository: https://github.com/navywakura/echoai

## Overview

ECHO-AI is a research workspace for deterministic cognitive agents, interaction-based learning, ARC program solving, and controlled evaluation, with separate terminal and development tools. A typical research workflow develops an agent or solver, runs it against environments or task cases, and examines evidence and results; the README also documents an optional language adviser and an ECHO-5 runtime with a local viewer. The repository contains many historical experiment families, so this map emphasizes live top-level subsystems and the sampled ECHO-5, ARC, GUI, and composition components. Relationships are limited to README claims and SOURCE INDEX references; unsampled modules are not presumed to be wired together.

Main entry points: [`echo_arc/s6b22_search.py`](https://github.com/navywakura/echoai/blob/main/echo_arc/s6b22_search.py) (S6B22 Search), [`nexus0`](https://github.com/navywakura/echoai/tree/main/nexus0) (NEXUS Agent), [`echo_arc/guard_search.py`](https://github.com/navywakura/echoai/blob/main/echo_arc/guard_search.py) (Guard Search), [`echo_arc/s6b24_search.py`](https://github.com/navywakura/echoai/blob/main/echo_arc/s6b24_search.py) (S6B24 Search)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_core["Cognitive Core"]
  node_mathcore["Core Memory<br/>[cam.py]"]
end

subgraph group_agents["Agent Research"]
  node_nexus["NEXUS Agent"]
  node_compose["Composition Controller<br/>[controller.py]"]
  node_echo4["ECHO-4 Agents"]
  node_seed["Seed Controllers"]
end

subgraph group_arc["ARC Solving"]
  node_arcsearch["ARC Search"]
  node_contrastive["Contrastive Evidence"]
  node_feasible["Feasible Grammar"]
  node_guard["Guard Search<br/>[guard_search.py]"]
  node_search22["S6B22 Search<br/>[s6b22_search.py]"]
  node_search24["S6B24 Search<br/>[s6b24_search.py]"]
end

subgraph group_interfaces["User Interfaces"]
  node_terminal["Terminal CLI<br/>[cli.py]"]
  node_gui["GUI Observer<br/>[app.py]"]
  node_gui_evidence["GUI Evidence<br/>[evidence.py]"]
  node_gui_neural["Neural View<br/>[neural.py]"]
  node_echo_nexus["Terminal Workspace<br/>[app.py]"]
end

subgraph group_echo5["ECHO-5 Runtime"]
  node_echo5["ECHO-5 Research Runtime"]
  node_trace["Trace Recorder<br/>[trace.py]"]
  node_legacy["Legacy Adapter<br/>[legacy.py]"]
  node_viewer["Local Decision Viewer<br/>[app.js]"]
end

node_researcher(("Researcher"))

node_researcher -->|"invokes"| node_terminal
node_researcher -->|"interacts through"| node_echo_nexus
node_terminal -.->|"launches research commands"| node_nexus
node_nexus -->|"uses core representations"| node_mathcore
node_compose -.->|"implements composition"| node_nexus
node_echo4 -.->|"uses core helpers"| node_mathcore
node_seed -->|"requests search"| node_arcsearch
node_search22 -->|"uses evidence"| node_contrastive
node_search22 -->|"uses grammar"| node_feasible
node_guard -->|"uses evidence"| node_contrastive
node_guard -->|"uses grammar"| node_feasible
node_search24 -->|"reuses search"| node_search22
node_search24 -->|"reuses ARC search"| node_arcsearch
node_gui -->|"reads evidence"| node_gui_evidence
node_gui -->|"renders neural view"| node_gui_neural
node_trace -->|"imports"| node_legacy
node_researcher -->|"uses research runtime"| node_echo5
node_echo5 -->|"provides local viewer"| node_viewer

click node_terminal "https://github.com/navywakura/echoai/blob/main/cli.py"
click node_mathcore "https://github.com/navywakura/echoai/blob/main/core/cam.py"
click node_nexus "https://github.com/navywakura/echoai/tree/main/nexus0"
click node_compose "https://github.com/navywakura/echoai/blob/main/nexus0/compose1/controller.py"
click node_echo4 "https://github.com/navywakura/echoai/tree/main/echo4"
click node_seed "https://github.com/navywakura/echoai/tree/main/seed"
click node_arcsearch "https://github.com/navywakura/echoai/tree/main/echo_arc"
click node_contrastive "https://github.com/navywakura/echoai/blob/main/echo_arc/contrastive_evidence.py"
click node_feasible "https://github.com/navywakura/echoai/blob/main/echo_arc/feasible_grammar.py"
click node_guard "https://github.com/navywakura/echoai/blob/main/echo_arc/guard_search.py"
click node_search22 "https://github.com/navywakura/echoai/blob/main/echo_arc/s6b22_search.py"
click node_search24 "https://github.com/navywakura/echoai/blob/main/echo_arc/s6b24_search.py"
click node_gui "https://github.com/navywakura/echoai/blob/main/gui4/app.py"
click node_gui_evidence "https://github.com/navywakura/echoai/blob/main/gui4/evidence.py"
click node_gui_neural "https://github.com/navywakura/echoai/blob/main/gui4/neural.py"
click node_echo_nexus "https://github.com/navywakura/echoai/blob/main/harness/echo-nexus/src/echo_nexus/app.py"
click node_echo5 "https://github.com/navywakura/echoai/tree/main/ECHO-5/src/echo5"
click node_trace "https://github.com/navywakura/echoai/blob/main/ECHO-5/src/echo5/trace.py"
click node_legacy "https://github.com/navywakura/echoai/blob/main/ECHO-5/src/echo5/legacy.py"
click node_viewer "https://github.com/navywakura/echoai/blob/main/ECHO-5/src/echo5/web/app.js"

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_mathcore toneBlue
class node_nexus,node_compose,node_echo4,node_seed toneAmber
class node_arcsearch,node_contrastive,node_feasible,node_guard,node_search22,node_search24 toneMint
class node_terminal,node_gui,node_gui_evidence,node_gui_neural,node_echo_nexus toneRose
class node_echo5,node_trace,node_legacy,node_viewer,node_researcher toneIndigo
```

## Components

### Cognitive Core

- [Core Memory](https://github.com/navywakura/echoai/blob/main/core/cam.py): `core/cam.py`

### Agent Research

- [NEXUS Agent](https://github.com/navywakura/echoai/tree/main/nexus0): `nexus0`
- [Composition Controller](https://github.com/navywakura/echoai/blob/main/nexus0/compose1/controller.py): `nexus0/compose1/controller.py`
- [ECHO-4 Agents](https://github.com/navywakura/echoai/tree/main/echo4): `echo4`
- [Seed Controllers](https://github.com/navywakura/echoai/tree/main/seed): `seed`

### ARC Solving

- [ARC Search](https://github.com/navywakura/echoai/tree/main/echo_arc): `echo_arc`
- [Contrastive Evidence](https://github.com/navywakura/echoai/blob/main/echo_arc/contrastive_evidence.py): `echo_arc/contrastive_evidence.py`
- [Feasible Grammar](https://github.com/navywakura/echoai/blob/main/echo_arc/feasible_grammar.py): `echo_arc/feasible_grammar.py`
- [Guard Search](https://github.com/navywakura/echoai/blob/main/echo_arc/guard_search.py): `echo_arc/guard_search.py`
- [S6B22 Search](https://github.com/navywakura/echoai/blob/main/echo_arc/s6b22_search.py): `echo_arc/s6b22_search.py`
- [S6B24 Search](https://github.com/navywakura/echoai/blob/main/echo_arc/s6b24_search.py): `echo_arc/s6b24_search.py`

### User Interfaces

- [Terminal CLI](https://github.com/navywakura/echoai/blob/main/cli.py): `cli.py`
- [GUI Observer](https://github.com/navywakura/echoai/blob/main/gui4/app.py): `gui4/app.py`
- [GUI Evidence](https://github.com/navywakura/echoai/blob/main/gui4/evidence.py): `gui4/evidence.py`
- [Neural View](https://github.com/navywakura/echoai/blob/main/gui4/neural.py): `gui4/neural.py`
- [Terminal Workspace](https://github.com/navywakura/echoai/blob/main/harness/echo-nexus/src/echo_nexus/app.py): `harness/echo-nexus/src/echo_nexus/app.py`

### ECHO-5 Runtime

- [ECHO-5 Research Runtime](https://github.com/navywakura/echoai/tree/main/ECHO-5/src/echo5): `ECHO-5/src/echo5`
- [Trace Recorder](https://github.com/navywakura/echoai/blob/main/ECHO-5/src/echo5/trace.py): `ECHO-5/src/echo5/trace.py`
- [Legacy Adapter](https://github.com/navywakura/echoai/blob/main/ECHO-5/src/echo5/legacy.py): `ECHO-5/src/echo5/legacy.py`
- [Local Decision Viewer](https://github.com/navywakura/echoai/blob/main/ECHO-5/src/echo5/web/app.js): `ECHO-5/src/echo5/web/app.js`

### Other components

- **Researcher**

## Connections

- Researcher → Terminal CLI: invokes (evidence: `README.md`)
- Researcher → Terminal Workspace: interacts through (evidence: `README.md`)
- Terminal CLI → NEXUS Agent: launches research commands
- NEXUS Agent → Core Memory: uses core representations (evidence: `README.md`)
- Composition Controller → NEXUS Agent: implements composition (evidence: `nexus0/compose1/controller.py`)
- ECHO-4 Agents → Core Memory: uses core helpers
- Seed Controllers → ARC Search: requests search (evidence: `seed/s6b22.py`)
- S6B22 Search → Contrastive Evidence: uses evidence (evidence: `echo_arc/s6b22_search.py`)
- S6B22 Search → Feasible Grammar: uses grammar (evidence: `echo_arc/s6b22_search.py`)
- Guard Search → Contrastive Evidence: uses evidence (evidence: `echo_arc/guard_search.py`)
- Guard Search → Feasible Grammar: uses grammar (evidence: `echo_arc/guard_search.py`)
- S6B24 Search → S6B22 Search: reuses search (evidence: `echo_arc/s6b24_search.py`)
- S6B24 Search → ARC Search: reuses ARC search (evidence: `echo_arc/s6b24_search.py`)
- GUI Observer → GUI Evidence: reads evidence (evidence: `gui4/app.py`)
- GUI Observer → Neural View: renders neural view (evidence: `gui4/app.py`)
- Trace Recorder → Legacy Adapter: imports (evidence: `ECHO-5/src/echo5/trace.py`)
- Researcher → ECHO-5 Research Runtime: uses research runtime (evidence: `README.md`)
- ECHO-5 Research Runtime → Local Decision Viewer: provides local viewer (evidence: `README.md`)
