Skip to content

docs(arch): modular decomposition blueprint — composable service profiles - #1682

Merged
joelteply merged 2 commits into
canaryfrom
docs/modular-decomposition
Jun 19, 2026
Merged

joelteply merged 2 commits into
canaryfrom
docs/modular-decomposition

Conversation

@joelteply

Copy link
Copy Markdown
Contributor

The modular architecture worked out — refinement, not rewrite. The monolith isn't a design flaw in the modules; it's that one process registers all ~40. This builds on the EXISTING seam (BootMode + ModuleCategory + required_modules + route_command + the ServiceModule registry).

"A good AWS template": declare which service-groups a node runs; each independently health-checked, restartable, and testable; composed over the bus.

  • Refined ModuleCategory taxonomy — 7 service groups (RuntimeShell, ResourceGov, Inference, Cognition, Forge, GridTransport, Live) replacing the coarse Core/PersonaHosting blob (today Core lumps ~38 modules, so the smallest bootable process is ~the whole substrate — the live finding).
  • Co-location constraints (placement groups): Bevy render + LiveKit SFU + GPU MUST share a VM — avatar frames are a GPU-readback → framebuffer → WebRTC transfer; a process/network split would force a frame copy off-GPU every frame. Not everything is its own container.
  • Per-service health / supervised restart / independent test — reuses ServiceModule health + the 3-strike quarantine; the direct testability win (no more booting the monolith per test).
  • Container layout mirrors the profiles — light citizen nodes + shared GPU engine/live/forge nodes; cross-process routing over the existing bus.
  • 6-slice build plan; guardrails per CONCURRENCY-STYLE-GUIDE (no parallel orchestrator; FullCitizen still hosts everything in one process — decomposition is optional placement, not forced fragmentation).

Consolidates live findings #25/#26/#27. Docs-only; frames the implementation slices (first: refine ModuleCategory, test-covered by required_modules).

🤖 Generated with Claude Code

…iles

The modular architecture worked out, grounded in the EXISTING seam (BootMode +
ModuleCategory + required_modules + route_command + ServiceModule registry) so
it's refinement, not rewrite — the monolith is just one process registering all
~40 modules. "A good AWS template": declare which service-groups a node runs;
each independently health-checked, restartable, testable; composed over the bus.

Captures:
- Refined ModuleCategory taxonomy (7 service groups: RuntimeShell, ResourceGov,
  Inference, Cognition, Forge, GridTransport, Live) replacing the coarse
  Core/PersonaHosting blob.
- CO-LOCATION CONSTRAINTS (placement groups): Bevy render + LiveKit SFU + GPU
  MUST share a VM — avatar frames are a GPU-readback→framebuffer→WebRTC transfer
  that a process/network boundary would force off-GPU every frame. ResourceGov
  co-resides with its hardware; Inference's boundary is unsloth's /v1 wire.
- Per-service health / supervised restart / independent test (the testability
  win; reuses ServiceModule health + the 3-strike quarantine).
- Container layout mirrors the profiles (light citizen nodes + shared GPU
  engine/live/forge nodes), cross-process routing via the existing bus.
- 6-slice build plan; guardrails per CONCURRENCY-STYLE-GUIDE (no parallel
  orchestrator; FullCitizen still hosts all in one process — decomposition is
  optional placement, not forced fragmentation).

Consolidates live findings #25 (decompose), #26 (degrade-not-panic), #27
(intra-machine addressing). Referenced from ARCHITECTURE-INDEX quick-nav.

Co-Authored-By: Claude Opus 4.8 <[email protected]>
The profiles ARE grid roles (same binary, different service composition);
compute-leasing = a service group on another node over route_command;
per-service healing; independent scaling. The grid is the module graph placed
across machines — not a layer bolted on. Captures Joel's framing.

Co-Authored-By: Claude Opus 4.8 <[email protected]>
@joelteply
joelteply merged commit a829c24 into canary Jun 19, 2026
2 checks passed
@joelteply
joelteply deleted the docs/modular-decomposition branch June 19, 2026 22:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant