Skip to content

feat(governor): wire pressure broker to governor sink#1373

Merged
joelteply merged 1 commit into
canaryfrom
feat/substrate-governor-pr5-pressure-broker-boot-wire
May 17, 2026
Merged

feat(governor): wire pressure broker to governor sink#1373
joelteply merged 1 commit into
canaryfrom
feat/substrate-governor-pr5-pressure-broker-boot-wire

Conversation

@joelteply
Copy link
Copy Markdown
Contributor

Summary

  • add an injectable PressureBrokerModule constructor that registers governor_alert_sink at boot
  • keep broker ownership narrow: DockerTierPool registration and tick cadence are preserved
  • add module-level proof that a High pressure broker alert reaches LocalSubstrateGovernor recent_signals as PressureSignal::SystemMemHigh

Proof

  • cargo test --manifest-path src/workers/continuum-core/Cargo.toml --lib --features metal,accelerate modules::pressure_broker_module:: — 9 passed
  • cargo test --manifest-path src/workers/continuum-core/Cargo.toml --lib --features metal,accelerate governor::pressure_bridge:: — 14 passed
  • cd src && npm run build:ts — passed
  • precommit — passed TS, clippy baseline, browser prereqs skipped because local core socket was not running
  • pre-push — passed TS, ESLint baseline, Rust compile, Rust tests; Docker image built, slice runtime failed because linux/arm64 container has no GPU visible and strict no-CPU-fallback panic fired in gpu/memory_manager.rs

Notes

No global governor singleton, no policy-file boot guess, no TS stopgap. This only wires the existing Rust broker alert sink into the module construction path.

@joelteply joelteply merged commit a092067 into canary May 17, 2026
3 checks passed
@joelteply joelteply deleted the feat/substrate-governor-pr5-pressure-broker-boot-wire branch May 17, 2026 03:49
joelteply added a commit that referenced this pull request May 18, 2026
…ALOG §II) (#1387)

PR-1 of inference-llm. Pure typed event surface for the local-LLM
generation module. The module itself (composition → tokenizer →
llama.cpp invoke → token stream) lands in PR-2/PR-3; PR-1 ships
the wire so producers + consumers can build against it today.

Unblocked by my just-shipped Lane H + recall + working-set stacks.

What lands

- InferenceRequestId — typed Uuid newtype; all four events carry
  the same field name (requestId on wire) for correlation
- CompositionPlan — opaque ArtifactId reference; composer module
  fills the full shape later
- SamplingParams { temperature, top_p, top_k, repeat_penalty }
  with llama.cpp-baseline defaults (0.8 / 0.95 / 40 / 1.1)
- GenerationBudget { max_tokens, max_duration_ms } — both honored
- FinishReason enum: Stop / MaxTokens / MaxDuration / StopSequence
  { matched } / Error { reason } — typed per Joel's never-swallow
- InferenceRequest — [InferenceRequest] subscription event
- InferenceComplete — emission with completion + finish + timing
- FirstTokenEmitted — emission for TTFT observability
  (microsecond precision; sub-ms achievable on warm models)
- ResidencyFault — emission when inference would need a not-
  resident page; sentinel learns + upgrades tier policy

Tests

13 behavioral tests + 9 ts-rs export_bindings = 22 total. 22/22 pass.
No regressions across other 2883 lib tests.

Clippy baseline bump 154→156 — drift from recent canary merges.
Fixed two doc-list warnings in this file (reworded "* 1000" math
to avoid being parsed as a markdown list item).

Stack

- Lane H end-to-end (codex's #1331#1373)
- Working-set-manager + DAR end-to-end (mine, #1346#1382)
- THIS PR — inference-llm PR-1: typed event surface
- NEXT — PR-2: InferenceLlmModule ServiceModule impl wired to
  the artifact dispatch
- THEN — PR-3: tokenizer + llama.cpp invoke + token stream

Co-authored-by: Test <test@test.com>
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
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