Summary
A c4-gen summary --scope <scope> subcommand that emits a short prose markdown fragment suitable for direct CLAUDE.md inclusion. Different from c4-gen views --format=mermaid, which is human-targeted; this is agent-targeted.
Why
Mermaid renders great for human readers but agents work better with prose at spawn time. The full model.json is too heavy to inline (20KB+ for pocketpaw); the Mermaid rendering is good for "what does the architecture look like" but not for "what should I know before changing this Container."
A prose summary at the Container + key-Component level (~30 lines per scope) is the right granularity to put in CLAUDE.md so every spawned agent sees it.
Proposed output shape
## pocketpaw architecture (auto-generated by c4-gen summary)
**Containers:** pocketpaw (FastAPI service), ollama (local LLM), qdrant (vector store)
**Key components:**
- Pockets — workspace entities; chokepoint for widgets, chat, ripple integration
- Sessions — chat threads + agent run state
- Agents — backend wrappers (ClaudeSDK, OpenAI, Ollama, etc.)
- Channels — channel adapter protocol; multiple implementations
- ee/cloud — multi-tenant cloud module (MongoDB-backed, separate scope)
**External dependencies:** Anthropic API, MongoDB (ee/cloud only), Soul Protocol, Ollama, Qdrant
**Cross-project consumers:** paw-enterprise frontend (REST + WebSocket)
Source: <project>/docs/c4/model.json. Update via make c4-pocketpaw.
Proposed shape
c4-gen summary --scope <scope> [--format=claude-md]
--format=claude-md (default) emits markdown suitable for direct paste into CLAUDE.md. Future formats could include --format=plain (no markdown), --format=json (structured), etc.
Length budget: ~30 lines per scope. The summary names Containers, key Components (top 5-8 by inbound or outbound relationships), external dependencies, and cross-project consumers.
Reference
Integration plan in the OCEAN workspace: docs/roadmap/future-upgrades/c4-integration.md (qbtrix/paw-workspace). Will be auto-injected into per-project CLAUDE.md once this lands.
Acceptance
c4-gen summary --scope pocketpaw produces a ~30-line markdown fragment
- Output is stable across runs (same model = same summary)
- Smoke test on a refined model produces useful output (won't be useful on bare-bones heuristic-only models — works best after refinement pass)
Summary
A
c4-gen summary --scope <scope>subcommand that emits a short prose markdown fragment suitable for direct CLAUDE.md inclusion. Different fromc4-gen views --format=mermaid, which is human-targeted; this is agent-targeted.Why
Mermaid renders great for human readers but agents work better with prose at spawn time. The full
model.jsonis too heavy to inline (20KB+ for pocketpaw); the Mermaid rendering is good for "what does the architecture look like" but not for "what should I know before changing this Container."A prose summary at the Container + key-Component level (~30 lines per scope) is the right granularity to put in CLAUDE.md so every spawned agent sees it.
Proposed output shape
Proposed shape
--format=claude-md(default) emits markdown suitable for direct paste into CLAUDE.md. Future formats could include--format=plain(no markdown),--format=json(structured), etc.Length budget: ~30 lines per scope. The summary names Containers, key Components (top 5-8 by inbound or outbound relationships), external dependencies, and cross-project consumers.
Reference
Integration plan in the OCEAN workspace:
docs/roadmap/future-upgrades/c4-integration.md(qbtrix/paw-workspace). Will be auto-injected into per-project CLAUDE.md once this lands.Acceptance
c4-gen summary --scope pocketpawproduces a ~30-line markdown fragment