Skip to content

docs(alpha): refresh ALPHA-GAP against 2026-05-16 canary; restructure document map; lane status truth-up - #1316

Merged
joelteply merged 3 commits into
canaryfrom
joel/docs-alpha-refresh
May 16, 2026
Merged

joelteply merged 3 commits into
canaryfrom
joel/docs-alpha-refresh

Conversation

@joelteply

Copy link
Copy Markdown
Contributor

What

Two-commit refresh of docs/planning/ALPHA-GAP-ANALYSIS.md against the actual state of canary on 2026-05-16. The doc had drifted to 2026-05-11 framing while this week landed the PressureBroker bootstrap stack, ~2500 LOC of TS cognition deletion, Docker tier Phase 1, SQLite-first config, and the inference-grpc fail-closed gate.

Why

ALPHA-GAP is the beacon-of-truth doc for what alpha needs. When it lags reality it stops being a planning tool and starts being a planning museum:

  1. New agents picking up work read the lane table and don't know what's claimed, in flight, or unstarted.
  2. Lane D being silently the highest-leverage open lane is the kind of fact that only surfaces when the table is honest. With the prior table everyone could believe "all lanes are claimed, just executing."
  3. Concrete deletion targets (e.g. inference-grpc/main.rs::get_num_workers() reading INFERENCE_WORKERS from ~/.continuum/config.env and otherwise picking a worker count from system memory at startup) don't get found by people who didn't write them. Calling them out by file name in the doc makes them claimable Lane E follow-ups instead of "someday cleanup."

Changes

Commit 1 — bf2937902 header / cross-links / Current Snapshot

  • Header date 2026-05-13 → 2026-05-16.
  • Added an explicit cross-link to docs/architecture/CBAR-SUBSTRATE-ARCHITECTURE.md as the runtime substrate spec.
  • Restructured the Document Map from a flat list into categorized references (Runtime substrate / Cognition migration / Memory paging / Model registry / Grid).
  • Added the precedence rule: if any supporting doc disagrees with ALPHA-GAP on the substrate contract (concurrency, scheduling, memory, pressure, telemetry, artifact handles), defer to CBAR-SUBSTRATE-ARCHITECTURE.md.
  • Current Snapshot table replaced with the actual canary state per area (Rust core / Node-TS / Docker / Config-secrets / Tests / AIRC / UI). Each row cites the PRs that moved it.

Commit 2 — 587c301ab lane status + immediate next actions

Lane status table now reflects state @ 2026-05-16, not aspiration:

Lane State
A. Rust model registry & admission In progress; model_registry/ exists with admission resolver.
B. Installer model seeding + GPU profiles Phase 1 landed (#1297); #1238 / #1239 still open.
C. VDD telemetry substrate In progress; vdd-report-command not yet bound.
D. CBAR persona runtime frame Unstarted — highest-leverage open lane.
E. Pressure broker & paging gate Bootstrap landed (#1307 / #1308 / #1310 / #1313); paging + pre-broker concurrency-hack deletion remain.
F. TS cognition deletion ratchet ~2500 LOC manually deleted; mechanical CI gate not yet landed (deletion reversible until it is).
G. Canary PR hygiene In progress on this branch.

Added an "adjacent active workstream" entry for GRID-INFERENCE-ROUTING (airc-8a5e, in flight on feat/grid-inference-routing-pr2-announcer) as the grid-side counterpart to Lane A.

Immediate Next Actions reordered by alpha leverage, not by who is online:

  1. Claim Lane D (the substrate-frame lane).
  2. Land the universal-trait "for free" triplet (RuntimeModule base trait + derive macro + scaffold generator) per CBAR-SUBSTRATE-ARCHITECTURE.md.
  3. Delete get_num_workers() in inference-grpc/main.rs and replace with PressureBroker leases.
  4. Claim Lane F mechanical ratchet PR.
  5. Bind Lane C vdd-report-command.
  6. Widen no_cpu_fallback_contract.rs to cover the Candle paths.
  7. Lane B follow-ups (feat(resources): implement DockerTierPool eviction via docker system prune planning #1238 / feat(resources): surface Docker tier pressure in status, alerts, and scheduler decisions #1239).
  8. Review GRID-INFERENCE-ROUTING PR-1 when it lands.
  9. Doc refresh follow-ups (CBAR-SUBSTRATE engram-analyzer worked example; CONTINUUM-ARCHITECTURE stale TS pseudocode; CONTINUUM-VISION interface-type audit; CLAUDE.md substrate pointer).

Out of scope

No code changes. Doc-only. The deletion targets and follow-up lanes called out above are each their own PR.

Validation

  • Local precommit passed both commits (TypeScript compile clean; no Rust/TS files staged).
  • Internal cross-links resolved against actual file paths under docs/architecture/, docs/planning/, and docs/.

Follow-ups (this manager will pick up after this lands)

  • CBAR-SUBSTRATE-ARCHITECTURE.md: tighten RuntimeModule trait sketch; add engram-analyzer worked example so the "for free" inheritance pattern is concrete reference, not slogan.
  • CONTINUUM-ARCHITECTURE.md: strip stale TS pseudocode.
  • CONTINUUM-VISION.md: audit TS-shaped interface types.
  • CLAUDE.md: point at CBAR-SUBSTRATE as the canonical substrate spec.
  • UNIVERSAL-SENSORY-ARCHITECTURE / UNIVERSAL-LEARNING-ARCHITECTURE / QUEUE-DRIVEN-COGNITION: mark stale sections DEPRECATED with pointer to canonical replacement.

Each refinement will cross-link back into ALPHA-GAP's Document Map.

Test added 2 commits May 16, 2026 10:51
Three changes to ALPHA-GAP-ANALYSIS.md:

1. Header date 2026-05-13 -> 2026-05-16. Add explicit cross-link to
   CBAR-SUBSTRATE-ARCHITECTURE.md as the runtime substrate spec.

2. Restructure the Document Map (was a flat list) into categorized
   references (Runtime substrate / Cognition migration / Memory paging /
   Model registry / Grid), and add the precedence rule: if any supporting
   doc disagrees with ALPHA-GAP on the substrate contract (concurrency,
   scheduling, memory, pressure, telemetry, artifact handles), defer to
   CBAR-SUBSTRATE-ARCHITECTURE.md.

3. Refresh the Current Snapshot table against canary @ 2026-05-16:
   - Rust core row reflects the PressureBroker bootstrap stack
     (#1307 / #1308 / #1310), runtime lease broker (#1313), cognition
     oxidization (#1284 / #1290 / #1291 / #1293 / #1298 / #1301 / #1303
     / #1292), dead-Candle deletes (#1277 / #1279 / #1281 / #1288), and
     the inference-grpc fail-closed (#1314). GRID-INFERENCE-ROUTING
     PR-1 announcer in flight on feat/grid-inference-routing-pr2-announcer.
   - Node/TS row notes net-negative trend (~2500 LOC TS deleted via the
     8-PR cognition stacks).
   - Docker row records Docker tier Phase 1 (#1297).
   - Config row records SQLite-first default (#1271).
   - Tests row records the no-CPU-fallback contract gap: the existing
     regression test in workers/continuum-core covers llama.cpp / ORT
     only, not the Candle-side paths where the orpheus + inference-grpc
     fallbacks lived before #1314.
Two updates to ALPHA-GAP-ANALYSIS.md:

1. Lane status table now reflects actual state @ 2026-05-16, not aspiration:
   - Lane A: in progress, model_registry/ exists with admission resolver.
   - Lane B: Phase 1 landed (#1297 docker-tier-stats); GPU profile +
     tier-pool eviction (#1238 / #1239) still open.
   - Lane C: structured RuntimeMetric emits from inference paths;
     vdd-report-command not yet bound.
   - Lane D: UNSTARTED — flagged as the highest-leverage open lane because
     Lane E (PressureBroker) and the inbox coalescing pattern both
     presuppose RuntimeFrame / CognitionTurnFrame.
   - Lane E: bootstrap landed (#1307 / #1308 / #1310 / #1313); paging and
     pre-broker concurrency-hack deletion remain. Concrete deletion target
     called out: get_num_workers() in inference-grpc/main.rs, which reads
     INFERENCE_WORKERS from config.env and otherwise picks worker count
     from system memory at startup — both branches violate the
     "we do not hard code" / "dynamic, broker-owned concurrency" rule.
   - Lane F: ~2500 LOC TS deleted manually this session; mechanical CI
     ratchet still not landed (deletion is reversible until it is).
   - Lane G: refresh in flight on joel/docs-alpha-refresh.

   Adds an "adjacent active workstream" note for GRID-INFERENCE-ROUTING
   (PR-1 announcer + probe + registry in flight on
   feat/grid-inference-routing-pr2-announcer) as the grid-side counterpart
   to Lane A.

2. Immediate Next Actions reordered by alpha leverage, not by who is
   online. Top three items are Lane D claim, the universal-trait "for free"
   triplet (RuntimeModule base trait + derive macro + scaffold generator
   from CBAR-SUBSTRATE-ARCHITECTURE.md), and the
   get_num_workers() deletion. Adds the Lane C VDD report command and the
   widening of no_cpu_fallback_contract.rs to cover Candle paths. Adds
   doc-refresh follow-ups so each supporting doc gets cross-linked back
   into the Document Map.
Three updates to ALPHA-GAP-ANALYSIS.md following continuum#1327:

1. Lane H added to the lane status table: Substrate governor + tiered
   genome cache. Sibling to Lane E (broker owns admission; governor
   owns sizing). 7-PR implementation sequence detailed in
   GENOME-FOUNDRY-SENTINEL.md Part 13. Currently Proposed, needs owner
   claim.

2. Lane claim update at end of the lane discussion: Lane H proposed
   via continuum#1327 with full design pinned to that doc; sibling to
   Lane E with the boundary stated explicitly.

3. Document Map gets GENOME-FOUNDRY-SENTINEL entry under "Runtime
   substrate (load-bearing)" — the artifact-sharing economy on top of
   the CBAR substrate. Tiered genome cache, page faults, foundry as JIT,
   sentinel-AI as profile-guided optimizer, demand-aligned recall,
   composer + speculator, SubstrateGovernor (DVFS).

4. Immediate Next Actions step 9 added: claim Lane H. Step 10 (formerly
   step 9) updated to reflect what's landed in this doc batch
   (CBAR-SUBSTRATE refinement via #1324, CONTINUUM-ARCHITECTURE refresh
   via #1317, CONTINUUM-VISION refresh via #1320, GENOME-FOUNDRY-SENTINEL
   via #1327) and what's next (CLAUDE.md substrate pointer; stale-section
   deprecations in UNIVERSAL-SENSORY / LEARNING / QUEUE-DRIVEN-COGNITION).
@github-actions github-actions Bot added size: L and removed size: M labels May 16, 2026
@joelteply
joelteply merged commit d80bc6f into canary May 16, 2026
2 checks passed
@joelteply
joelteply deleted the joel/docs-alpha-refresh branch May 16, 2026 21:19
joelteply added a commit that referenced this pull request May 16, 2026
…ngs + magic constants (#1340)

CBAR-PIECE-8 (vhsm-d1f4 audit pass 1, surfaced again in #1316 ALPHA-GAP):
get_num_workers() in inference-grpc/main.rs had three anti-patterns
that violate the dynamic / broker-owned-concurrency rule:

(a) clamp(1, 8) ceiling on the env-var path
(b) clamp(1, 4) ceiling on the autodetect path + magic 2GB-per-worker
    constant that's wrong for every model that isn't a 7B Q4_K_M
(c) silent fallback to "2 workers" when sys-info fails

All three deleted. New resolve_num_workers():

1. INFERENCE_WORKERS env var is the channel a supervising continuum-core
   sets at process spawn (broker-derived). Value passes through
   verbatim — no clamping. Supervisor knows the live hardware + memory
   pressure; this binary doesn't second-guess.

2. INFERENCE_WORKERS unset → num_cpus::get_physical().max(1). Hardware-
   derived, never zero, one info log so operator sees the fallback.
   Documents that continuum-core supervisor SHOULD set INFERENCE_WORKERS
   based on its PressureBroker lease (the broker integration is the
   next PR in this chain).

3. INFERENCE_WORKERS=0 or invalid → Err with bad value named, main()
   propagates the error to abort startup. No silent default. Surfaces
   the config bug at the source.

Deleted:
- ~/.continuum/config.env file reading (static-config violates
  dynamic rule; env var is the cross-process channel now)
- sys-info crate dep (was only used for the deleted auto-detect path)
- magic 2GB-per-worker constant
- clamp(1, 4) / clamp(1, 8) ceilings
- 'Default: 2 workers' silent fallback

Added: num_cpus crate dep (replaces sys-info; was already in
continuum-core's deps via the workspace).

Tests: 14 passing on cargo test --no-default-features
  -- --test-threads=1 (env-mutating tests must run serial):

- env var passes through verbatim (8)
- env var=64 not capped (was clamp(1,8) → 8 before; pins no-ceiling)
- env var=0 → Err
- env var=not-a-number → Err with value named
- env var unset → num_cpus::get_physical() fallback
- env var empty → Err (empty != unset; refuse rather than fallback)
- env var=1 (lower boundary) → passes
- env var=-1 (negative) → Err (defensive against shell underflow)

What this enables (CBAR-SUBSTRATE alignment): one less hardcoded
ceiling between the supervisor's PressureBroker and the actual
inference pool size. Once a future PR wires continuum-core to spawn
inference-grpc with INFERENCE_WORKERS=<broker-lease>, the concurrency
budget is dynamic + supervisor-controlled end-to-end. The deletion
landed here unblocks that wiring without further refactoring.

Closes one of the three deletion targets listed in #1316 ALPHA-GAP's
'Concrete deletion target' callout.

Co-authored-by: Test <[email protected]>
joelteply pushed a commit that referenced this pull request May 16, 2026
…ning; navigate to MODULE-CATALOG queue

Second refresh of ALPHA-GAP Immediate Next Actions to reflect work
landed since #1316 merged. Six items closed; navigation into
MODULE-CATALOG queue made explicit.

Closed: #6 contract widening (#1341), #8 GRID-INFERENCE-ROUTING PR-1
(#1315), CBAR-PIECE-5 end-to-end (#1331/#1333/#1335/#1338),
PIECE-8 inference-grpc hardcoded-clamps (#1340), doc family
architecture surface (#1324/#1327/#1332/#1336/#1337 open;
#1316/#1317/#1320/#1329 merged).

Item #9 reorganized to point at MODULE-CATALOG's 'Next Modules To
Build' queue (audit-recorder → threat-detector → working-set-manager
→ demand-aligned-recall → substrate-governor).

Adds closeout summary section listing what's done, what's open
(5 architecture-doc PRs ready for review + 2 airc PRs), and what's
queued (5 modules with dependency state + LoC + acceptance criteria
in MODULE-CATALOG).

Doc-driven development cycle is working: doc spec → implementing
agent picks up → ships PR → next spec referenced.
joelteply added a commit that referenced this pull request May 16, 2026
…ning; navigate to MODULE-CATALOG queue (#1342)

Second refresh of ALPHA-GAP Immediate Next Actions to reflect work
landed since #1316 merged. Six items closed; navigation into
MODULE-CATALOG queue made explicit.

Closed: #6 contract widening (#1341), #8 GRID-INFERENCE-ROUTING PR-1
(#1315), CBAR-PIECE-5 end-to-end (#1331/#1333/#1335/#1338),
PIECE-8 inference-grpc hardcoded-clamps (#1340), doc family
architecture surface (#1324/#1327/#1332/#1336/#1337 open;
#1316/#1317/#1320/#1329 merged).

Item #9 reorganized to point at MODULE-CATALOG's 'Next Modules To
Build' queue (audit-recorder → threat-detector → working-set-manager
→ demand-aligned-recall → substrate-governor).

Adds closeout summary section listing what's done, what's open
(5 architecture-doc PRs ready for review + 2 airc PRs), and what's
queued (5 modules with dependency state + LoC + acceptance criteria
in MODULE-CATALOG).

Doc-driven development cycle is working: doc spec → implementing
agent picks up → ships PR → next spec referenced.

Co-authored-by: Test <[email protected]>
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