# nateherkai/roast-room architecture

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

- Interactive diagram: https://gitdiagram.com/nateherkai/roast-room
- Repository: https://github.com/nateherkai/roast-room
- Video tour (about a minute): https://gitdiagram.com/nateherkai/roast-room/video

## Overview

Roast Room turns a business decision into a scored, multi-advisor verdict, then saves and presents the council’s work. Its primary workflow is orchestrated by the Claude Code skill and seat agents; the local web app watches and replays those sessions. An optional API runner can run councils from the room itself. The graph preserves the documented debate, scoring, history, and PDF capabilities. Some app-to-server wiring and skill internals were not sampled, so those links rely on README statements rather than uninspected implementation claims.

Main entry points: [`app/server.mjs`](https://github.com/nateherkai/roast-room/blob/main/app/server.mjs) (Local web server), [`app/public/app.js`](https://github.com/nateherkai/roast-room/blob/main/app/public/app.js) (Room interface), [`.claude/skills/roast-room/SKILL.md`](https://github.com/nateherkai/roast-room/blob/main/.claude/skills/roast-room/SKILL.md) (Chair workflow), [`app/lib/anthropic.mjs`](https://github.com/nateherkai/roast-room/blob/main/app/lib/anthropic.mjs) (Anthropic client)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_council["Claude Code Council"]
  node_chair["Chair workflow<br/>[SKILL.md]"]
  node_seat_agents["Seat agents<br/>[agents]"]
  node_prompts["Round protocol<br/>[references]"]
end

subgraph group_knowledge["Advisor Knowledge"]
  node_brains["Advisor brains<br/>[brains]"]
end

subgraph group_runtime["Council Runtime"]
  node_council_engine["Council orchestration<br/>[council.mjs]"]
  node_seat_runtime["Seat and scoring logic<br/>[seats.mjs]"]
  node_api_client["Anthropic client<br/>[anthropic.mjs]"]
  node_env["Runtime configuration<br/>[env.mjs]"]
end

subgraph group_room["Live Room"]
  node_server["Local web server<br/>[server.mjs]"]
  node_web_ui["Room interface<br/>[app.js]"]
  node_pdf["Verdict PDF<br/>[pdf.js]"]
end

subgraph group_history["Session History"]
  node_watcher["Session watcher<br/>[watch.mjs]"]
  node_session_files[("Saved sessions")]
end

node_founder(("Decision maker"))
node_anthropic{{"Anthropic API"}}

node_founder -->|"submits decision"| node_chair
node_chair -->|"invokes advisors"| node_seat_agents
node_chair -->|"follows rounds"| node_prompts
node_seat_agents -->|"uses advisor knowledge"| node_brains
node_chair -->|"writes council steps"| node_session_files
node_session_files -->|"watches session files"| node_watcher
node_watcher -->|"parses and scores"| node_seat_runtime
node_server -->|"starts and queries"| node_watcher
node_server -->|"starts API councils"| node_council_engine
node_server -->|"serves seat data"| node_seat_runtime
node_server -->|"serves usage"| node_api_client
node_council_engine -->|"loads seats and parses cards"| node_seat_runtime
node_council_engine -->|"requests advisor responses"| node_api_client
node_api_client -->|"reads API key"| node_env
node_api_client -->|"streams model requests"| node_anthropic
node_seat_runtime -->|"locates agent files"| node_env
node_web_ui -->|"uses room service"| node_server
node_web_ui -->|"requests PDF download"| node_pdf
node_web_ui -->|"plays watched sessions"| node_watcher
node_web_ui -->|"replays saved councils"| node_session_files

click node_chair "https://github.com/nateherkai/roast-room/blob/main/.claude/skills/roast-room/SKILL.md"
click node_seat_agents "https://github.com/nateherkai/roast-room/tree/main/.claude/agents"
click node_prompts "https://github.com/nateherkai/roast-room/tree/main/.claude/skills/roast-room/references"
click node_brains "https://github.com/nateherkai/roast-room/tree/main/.claude/skills/roast-room/brains"
click node_server "https://github.com/nateherkai/roast-room/blob/main/app/server.mjs"
click node_web_ui "https://github.com/nateherkai/roast-room/blob/main/app/public/app.js"
click node_pdf "https://github.com/nateherkai/roast-room/blob/main/app/public/pdf.js"
click node_watcher "https://github.com/nateherkai/roast-room/blob/main/app/lib/watch.mjs"
click node_session_files "https://github.com/nateherkai/roast-room/tree/main/sessions"
click node_council_engine "https://github.com/nateherkai/roast-room/blob/main/app/lib/council.mjs"
click node_seat_runtime "https://github.com/nateherkai/roast-room/blob/main/app/lib/seats.mjs"
click node_api_client "https://github.com/nateherkai/roast-room/blob/main/app/lib/anthropic.mjs"
click node_env "https://github.com/nateherkai/roast-room/blob/main/app/lib/env.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_chair,node_seat_agents,node_prompts toneBlue
class node_brains toneAmber
class node_council_engine,node_seat_runtime,node_api_client,node_env,node_anthropic toneMint
class node_server,node_web_ui,node_pdf toneRose
class node_watcher,node_session_files,node_founder toneIndigo
```

## Components

### Claude Code Council

- [Chair workflow](https://github.com/nateherkai/roast-room/blob/main/.claude/skills/roast-room/SKILL.md): `.claude/skills/roast-room/SKILL.md`
- [Seat agents](https://github.com/nateherkai/roast-room/tree/main/.claude/agents): `.claude/agents`
- [Round protocol](https://github.com/nateherkai/roast-room/tree/main/.claude/skills/roast-room/references): `.claude/skills/roast-room/references`

### Advisor Knowledge

- [Advisor brains](https://github.com/nateherkai/roast-room/tree/main/.claude/skills/roast-room/brains): `.claude/skills/roast-room/brains`

### Council Runtime

- [Council orchestration](https://github.com/nateherkai/roast-room/blob/main/app/lib/council.mjs): `app/lib/council.mjs`
- [Seat and scoring logic](https://github.com/nateherkai/roast-room/blob/main/app/lib/seats.mjs): `app/lib/seats.mjs`
- [Anthropic client](https://github.com/nateherkai/roast-room/blob/main/app/lib/anthropic.mjs): `app/lib/anthropic.mjs`
- [Runtime configuration](https://github.com/nateherkai/roast-room/blob/main/app/lib/env.mjs): `app/lib/env.mjs`

### Live Room

- [Local web server](https://github.com/nateherkai/roast-room/blob/main/app/server.mjs): `app/server.mjs`
- [Room interface](https://github.com/nateherkai/roast-room/blob/main/app/public/app.js): `app/public/app.js`
- [Verdict PDF](https://github.com/nateherkai/roast-room/blob/main/app/public/pdf.js): `app/public/pdf.js`

### Session History

- [Session watcher](https://github.com/nateherkai/roast-room/blob/main/app/lib/watch.mjs): `app/lib/watch.mjs`
- [Saved sessions](https://github.com/nateherkai/roast-room/tree/main/sessions): `sessions`

### Other components

- **Decision maker**
- **Anthropic API**

## Connections

- Decision maker → Chair workflow: submits decision (evidence: `README.md`)
- Chair workflow → Seat agents: invokes advisors (evidence: `README.md`)
- Chair workflow → Round protocol: follows rounds (evidence: `README.md`)
- Seat agents → Advisor brains: uses advisor knowledge (evidence: `README.md`)
- Chair workflow → Saved sessions: writes council steps (evidence: `README.md`)
- Saved sessions → Session watcher: watches session files (evidence: `app/lib/watch.mjs`)
- Session watcher → Seat and scoring logic: parses and scores (evidence: `app/lib/watch.mjs`)
- Local web server → Session watcher: starts and queries (evidence: `app/server.mjs`)
- Local web server → Council orchestration: starts API councils (evidence: `app/server.mjs`)
- Local web server → Seat and scoring logic: serves seat data (evidence: `app/server.mjs`)
- Local web server → Anthropic client: serves usage (evidence: `app/server.mjs`)
- Council orchestration → Seat and scoring logic: loads seats and parses cards (evidence: `app/lib/council.mjs`)
- Council orchestration → Anthropic client: requests advisor responses (evidence: `app/lib/council.mjs`)
- Anthropic client → Runtime configuration: reads API key (evidence: `app/lib/anthropic.mjs`)
- Anthropic client → Anthropic API: streams model requests (evidence: `app/lib/anthropic.mjs`)
- Seat and scoring logic → Runtime configuration: locates agent files (evidence: `app/lib/seats.mjs`)
- Room interface → Local web server: uses room service (evidence: `README.md`)
- Room interface → Verdict PDF: requests PDF download (evidence: `app/public/app.js`)
- Room interface → Session watcher: plays watched sessions (evidence: `README.md`)
- Room interface → Saved sessions: replays saved councils (evidence: `README.md`)
