Lab Notes
Appendix

Appendix E: Reference Architecture

A single, large, annotated diagram of the lab's architecture with all components, ports, paths, and communication flows. The single page to print.

Purpose

This appendix is the single annotated diagram of the lab's architecture. It complements the System Architecture page with a single, large, printable view.

The diagram is sanitized: real names, real paths, and real agent identifiers are replaced with placeholders. The places where the placeholders go are marked with {...}.

The diagram

Loading diagram…

Click any box to open its documentation page.

Annotated components

External services

ComponentProtocolPurpose
Model Provider AHTTPSThe Coordinator's primary model.
Model Provider BHTTPSThe Coordinator's fast variant.
Search Provider: TavilyHTTPSThe research framework's primary search adapter.
Search Provider: DuckDuckGoHTTPSThe fallback search adapter.
Search Provider: GoogleHTTPSThe optional Google Custom Search adapter.
Video: YouTubeHTTPSYouTube search and transcript.
Streaming: StremiomDNSStremio catalog and streaming.
Chromecast DevicesmDNSCast-capable displays on the LAN.
VLC Hosts on LANmDNSVLC instances with RC/HTTP enabled.

Gateway layer

ComponentPortPurpose
Coordinator18789The main gateway. The user's entry point.
Scout18790The specialized gateway for the Research Worker and the Media Agent.

Agent layer

ComponentPurpose
CoordinatorRoutes requests, manages memory and sessions, activates skills.
Coding AssistantReviews code from the sub-agent, integrates, tests.
Research WorkerRuns research missions end-to-end.
Media AgentHandles media search and playback to local and remote devices.
Web AgentDrives the browser through the accessibility tree.

Framework layer

ComponentPurpose
Research FrameworkOrchestrates the 8 phases; manages artifacts, state, and the request journal.
Coding Sub-agentThe sandboxed Codex CLI that the Coding Assistant delegates to.

Tool layer

ComponentPurpose
CLI toolsThe lab's deterministic CLI tools (torrent-finder, etc.).
chromecastDiscovers and controls Cast devices.
vlcSpawns and controls VLC locally and remotely.
media-playbackSelects the right backend for a given source.
media-lab-serverGenerates images and music through an HTTP API.
browserDrives a Chromium-based browser.

Adapter layer

ComponentPurpose
tavilySearch adapter for Tavily.
duckduckgoSearch adapter for DuckDuckGo.
google_searchSearch adapter for Google Custom Search.
youtube_transcriptTranscript adapter for YouTube.
yt-dlpFallback video metadata adapter.
perplexitySynthesis adapter with a token pool.

State layer

ComponentPurpose
MEMORY.mdThe lab's long-term memory.
Daily logsThe raw chronological record.
Session stateThe in-memory state of the current session.
SkillsThe agent's capabilities (SKILL.md, TOOL.md).
Mission artifactsThe research framework's typed outputs.
Request journalThe append-only log of external calls.
Token pool stateThe live state of the token pool.
Audit reportsThe weekly, monthly, quarterly, and ad-hoc audits.

How to read the diagram

  • User is the only external entity. The user communicates with the Coordinator through the Coordinator gateway.
  • Coordinator gateway is the entry point. The Coordinator itself runs inside the gateway process.
  • Scout gateway hosts the Research Worker and the Media Agent. The Coordinator talks to the Scout through HTTP.
  • Coding sub-agent is invoked by the Coding Assistant. The sub-agent runs in a sandbox.
  • Web Agent drives the browser through the OpenClaw browser tool on the CDP port.
  • Media Lab Server is a standalone HTTP server (:8765) that the Coordinator can call directly.
  • State layer is the foundation. Every other layer reads from and writes to the state layer.

What the diagram does not show

The diagram is a single view of the system. The details are in the other pages.

See also

On this page