instar 1.2.75 → 1.2.77
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +21 -1
- package/dist/commands/init.js.map +1 -1
- package/dist/commands/server.d.ts.map +1 -1
- package/dist/commands/server.js +43 -1
- package/dist/commands/server.js.map +1 -1
- package/dist/config/ConfigDefaults.d.ts.map +1 -1
- package/dist/config/ConfigDefaults.js +6 -0
- package/dist/config/ConfigDefaults.js.map +1 -1
- package/dist/core/Config.d.ts +2 -14
- package/dist/core/Config.d.ts.map +1 -1
- package/dist/core/Config.js +50 -1
- package/dist/core/Config.js.map +1 -1
- package/dist/core/PostUpdateMigrator.d.ts.map +1 -1
- package/dist/core/PostUpdateMigrator.js +64 -3
- package/dist/core/PostUpdateMigrator.js.map +1 -1
- package/dist/core/SessionManager.d.ts.map +1 -1
- package/dist/core/SessionManager.js +14 -2
- package/dist/core/SessionManager.js.map +1 -1
- package/dist/core/Usher.d.ts +57 -0
- package/dist/core/Usher.d.ts.map +1 -0
- package/dist/core/Usher.js +179 -0
- package/dist/core/Usher.js.map +1 -0
- package/dist/core/UsherSignalStore.d.ts +58 -0
- package/dist/core/UsherSignalStore.d.ts.map +1 -0
- package/dist/core/UsherSignalStore.js +113 -0
- package/dist/core/UsherSignalStore.js.map +1 -0
- package/dist/core/codexHookArm.d.ts +81 -0
- package/dist/core/codexHookArm.d.ts.map +1 -0
- package/dist/core/codexHookArm.js +191 -0
- package/dist/core/codexHookArm.js.map +1 -0
- package/dist/core/codexHookTrust.d.ts +52 -0
- package/dist/core/codexHookTrust.d.ts.map +1 -0
- package/dist/core/codexHookTrust.js +114 -0
- package/dist/core/codexHookTrust.js.map +1 -0
- package/dist/core/installCodexHooks.d.ts.map +1 -1
- package/dist/core/installCodexHooks.js +19 -12
- package/dist/core/installCodexHooks.js.map +1 -1
- package/dist/core/types.d.ts +12 -0
- package/dist/core/types.d.ts.map +1 -1
- package/dist/core/types.js.map +1 -1
- package/dist/providers/adapters/openai-codex/canary/codexHookContractCanary.d.ts +1 -0
- package/dist/providers/adapters/openai-codex/canary/codexHookContractCanary.d.ts.map +1 -1
- package/dist/providers/adapters/openai-codex/canary/codexHookContractCanary.js +17 -3
- package/dist/providers/adapters/openai-codex/canary/codexHookContractCanary.js.map +1 -1
- package/dist/server/AgentServer.d.ts +2 -0
- package/dist/server/AgentServer.d.ts.map +1 -1
- package/dist/server/AgentServer.js +5 -0
- package/dist/server/AgentServer.js.map +1 -1
- package/dist/server/CapabilityIndex.d.ts.map +1 -1
- package/dist/server/CapabilityIndex.js +1 -0
- package/dist/server/CapabilityIndex.js.map +1 -1
- package/dist/server/usherRoutes.d.ts +16 -0
- package/dist/server/usherRoutes.d.ts.map +1 -0
- package/dist/server/usherRoutes.js +40 -0
- package/dist/server/usherRoutes.js.map +1 -0
- package/package.json +1 -1
- package/src/data/builtin-manifest.json +19 -19
- package/upgrades/1.2.76.md +64 -0
- package/upgrades/1.2.77.md +99 -0
- package/upgrades/side-effects/codex-full-parity-bundle.md +46 -0
- package/upgrades/side-effects/codex-parity-arm-model-literal.md +24 -0
- package/upgrades/side-effects/codex-parity-arm-vitest-guard.md +31 -0
- package/upgrades/side-effects/codex-parity-asdf-and-model-badge.md +41 -0
- package/upgrades/side-effects/codex-parity-asdf-convergence-fixes.md +44 -0
- package/upgrades/side-effects/codex-parity-c3-scope-coherence-reentry.md +34 -0
- package/upgrades/side-effects/codex-parity-p0-arm-realpath-liveproof.md +35 -0
- package/upgrades/side-effects/codex-parity-p0-arm-wiring.md +40 -0
- package/upgrades/side-effects/codex-parity-p0-hook-arm.md +50 -0
- package/upgrades/side-effects/codex-parity-p0-hook-trust-core.md +43 -0
- package/upgrades/side-effects/codex-parity-stop-trio-and-deferral.md +76 -0
- package/upgrades/side-effects/cwa-usher.md +82 -0
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
# Side-effects review — the Usher (rung 4, signal-only)
|
|
2
|
+
|
|
3
|
+
**Scope**: A signal-only mid-task watcher that re-surfaces faded-but-now-relevant
|
|
4
|
+
context. Per the ratified spec (`docs/specs/cwa-usher.md`): on each substantive
|
|
5
|
+
inbound turn, query the faded tail of the topic-intent store, ask a cheap LLM
|
|
6
|
+
whether the turn re-activates any, and emit re-surface SIGNALS to a read-only pull
|
|
7
|
+
surface. It NEVER injects (rung 5, gated on the Usher's measured precision).
|
|
8
|
+
|
|
9
|
+
**Files touched**:
|
|
10
|
+
- `src/core/UsherSignalStore.ts` — NEW. File-backed per-topic store of signals +
|
|
11
|
+
precision metrics (fired/acted); atomic writes; best-effort (never throws);
|
|
12
|
+
capped at 50 signals/topic.
|
|
13
|
+
- `src/core/Usher.ts` — NEW. `buildUsherPrompt`/`parseUsherResponse` (anti-injection,
|
|
14
|
+
refId-validated), `createUsherCheckFn` (injected provider, degrade-safe),
|
|
15
|
+
`usherCheckTurn`/`createUsherLoop` (pre-filter reuse, shed/rate gates, faded-tail
|
|
16
|
+
= observation-tier refs, fire-and-forget, never-throws). Reacts to USER turns only.
|
|
17
|
+
- `src/server/usherRoutes.ts` — NEW. `GET /usher/signals` + `GET /usher/metrics`
|
|
18
|
+
(with precision = acted/fired). 503-stub when the store is absent.
|
|
19
|
+
- `src/server/AgentServer.ts` — new optional `usherSignalStore`; mount the routes.
|
|
20
|
+
- `src/commands/server.ts` — construct `UsherSignalStore` (unless disabled); chain
|
|
21
|
+
the Usher loop onto `onMessageLogged` AFTER the capture chain (reusing the
|
|
22
|
+
queued subscription provider + LlmQueue); pass the store to AgentServer.
|
|
23
|
+
- `src/server/CapabilityIndex.ts` — `usher` → `INTERNAL_PREFIXES`.
|
|
24
|
+
- `src/config/ConfigDefaults.ts` + `src/core/types.ts` — `usher.enabled` default true.
|
|
25
|
+
- Tests: unit (Usher + store) + boot-path route tests + the discoverability scan
|
|
26
|
+
now includes `usherRoutes.ts`.
|
|
27
|
+
|
|
28
|
+
**Under-block**: The Usher only *emits suggestions to a pull surface* — it blocks
|
|
29
|
+
nothing. Its checks are gated (pre-filter, shed, rate ceiling) and every gate
|
|
30
|
+
fails toward "no signal", so it can't suppress anything either. RefIds are
|
|
31
|
+
validated against the candidate set (a poisoned/hallucinated id is dropped).
|
|
32
|
+
|
|
33
|
+
**Over-block**: None possible — there is no `block`/`inject` path in the code.
|
|
34
|
+
A false signal costs one line on a side board the consumer pulls.
|
|
35
|
+
|
|
36
|
+
**Level-of-abstraction fit**: The Usher reuses the established seam
|
|
37
|
+
(`onMessageLogged`), the topic-intent store's faded tail (observation-tier refs),
|
|
38
|
+
the queued subscription provider (never a raw client), and the capture loop's
|
|
39
|
+
pre-filter — it adds a watcher + a pull surface, not a new subsystem. "Faded" is
|
|
40
|
+
defined precisely as below-briefing-tier (observation), the genuine re-warm case.
|
|
41
|
+
|
|
42
|
+
**Signal vs authority (defining constraint)**: The Usher is a pure signal
|
|
43
|
+
producer. Authority to act on a signal (mid-task injection) is withheld for rung
|
|
44
|
+
5, which the spec makes conditional on the Usher's measured precision. The surface
|
|
45
|
+
is PULL (endpoint/dashboard), never a chat push — so even a noisy Usher can't
|
|
46
|
+
train anyone to tune it out (Near-Silent).
|
|
47
|
+
|
|
48
|
+
**Interactions**:
|
|
49
|
+
- Chained AFTER the capture loop on the single-assignment `onMessageLogged`
|
|
50
|
+
property (prior callback preserved — verified by the wiring-integrity source
|
|
51
|
+
guard). Fire-and-forget (`void usherLoop(...)`) so Usher latency never reaches
|
|
52
|
+
the delivery path.
|
|
53
|
+
- One fast-tier LLM call per substantive USER turn, background lane on the shared
|
|
54
|
+
LlmQueue, rate-limited (20/60s/topic), skipped under QuotaTracker pressure, and
|
|
55
|
+
skipped entirely when the topic has no faded candidates — same cost envelope as
|
|
56
|
+
capture. Agent turns are skipped (capture handles those).
|
|
57
|
+
- `precision = acted/fired` on `/usher/metrics` is the read that rung 5's spec
|
|
58
|
+
will cite as its precondition; pairs with the human-as-detector miss-map.
|
|
59
|
+
- Construction broadened nothing — the assembler/capture wiring is unchanged; the
|
|
60
|
+
Usher is purely additive within the existing `sharedIntelligence` block.
|
|
61
|
+
|
|
62
|
+
**External surfaces**: `GET /usher/signals`, `GET /usher/metrics` (INTERNAL
|
|
63
|
+
prefix). New config `usher.enabled` (default true). New modules `Usher.ts`,
|
|
64
|
+
`UsherSignalStore.ts`. No injection, no chat push, no change to existing routes.
|
|
65
|
+
|
|
66
|
+
**Deferred (tracked)**: mid-task injection (`cwa-injection`, gated on this
|
|
67
|
+
rung's precision), per-tool-call seam (`cwa-usher-tool-seam`), capability/standards
|
|
68
|
+
descriptors as candidates (`cwa-capability-index-context`).
|
|
69
|
+
|
|
70
|
+
**Rollback cost**: Low, strictly additive. Remove the watcher wiring + routes +
|
|
71
|
+
store; nothing depends on it (rung 5 isn't built). Kill-switch `usher.enabled:
|
|
72
|
+
false` stops the watcher (routes 503). No data migration.
|
|
73
|
+
|
|
74
|
+
**Migration parity**: Additive watcher wiring + routes + config default
|
|
75
|
+
(existence-checked) + INTERNAL prefix — all server-side (every agent on update).
|
|
76
|
+
The signal store is created lazily; no schema migration. No hook/template/skill change.
|
|
77
|
+
|
|
78
|
+
**Convergence honesty**: Claude-authored + manual review; multi-model tooling
|
|
79
|
+
absent on host. The Usher is deliberately the safe half (signal-only, pull
|
|
80
|
+
surface, precision-measured before rung 5 earns authority), but a fuller review —
|
|
81
|
+
especially of the `acted` precision definition that gates rung 5 — remains
|
|
82
|
+
advisable before relying on it.
|