Skip to content

fix: phase 0 host/provider consistency hygiene (F-07…F-22) - #142

Merged
pacphi merged 6 commits into
mainfrom
feat/phase-0-consistency-hygiene
Aug 15, 2026
Merged

fix: phase 0 host/provider consistency hygiene (F-07…F-22)#142
pacphi merged 6 commits into
mainfrom
feat/phase-0-consistency-hygiene

Conversation

@pacphi

@pacphi pacphi commented Aug 15, 2026

Copy link
Copy Markdown
Owner

Phase 0 of the host/provider consistency roadmap: the hygiene owed regardless of the
extensibility decision in #131. Every item bites built-in hosts today; each is
independently shippable. No new surfaces beyond one ak host status warning line.

What changed

Commit Findings Change
9ca97c7 F-07, F-20, F-22 Drop the dead statuslineSupported consumer (the registry's commandStatusline capability is the surviving vocabulary); guard npmRoot for hosts without an npm package; add createPlainTextSummaryCapture beside the JSONL capture; replace gemini unknown-host test sentinels with a synthetic id that can never register.
8e79790 F-15, F-16, F-12 Host adapters carry a required enabledByDefault; defaultHostMap() replaces the enabled-host literal that was triplicated across config, providers, and host-off reset (byte-identical output). The previously dead non-throwing validateBinding is wired: ak host status (human output only) names each malformed kit.json binding instead of ignoring it. The observability axis is documented as terminal validation metadata.
938bc5b F-08 The usage index never mis-files unknown-host records as claude: explicit parser dispatch, cache-hit path returns only known providers, scan roots fold into the single-flight key as sorted entries. Excluded and labeled, never mis-filed.
4eaee67 F-11, F-13 vendorOf tags unrecognized providers unregistered:<id>; validatePanel applies the can't-prove-independence rule to both checks — unregistered vendors never satisfy minVendors, and unregistered writer + unregistered jury is treated as could-be-colluding. Verified against ~280k synthetic panels that the new verdicts are a superset of the old shared-'unknown' model (never looser). The integrations migrator derives native default providers from the registry's host-login entries and infers nothing for hosts without one — unknown-via-<host> stamping is gone.
e70f0f9 F-09 Live events resolve hosts through one policy: known ids pass, safely-shaped novel ids pass verbatim, everything else lands in an explicit unknown-host bucket — never the retired internal label. Declared actor/target hosts get the same policy and inherit the session host only when absent.
99bb609 docs Citation re-anchors, one current-state sentence in PROVIDERS.md, decision history recorded in ADR-0015/ADR-0016 update notes.

Verification

  • Full gate (pnpm run check) green: typecheck, eslint, markdownlint, build, 1,526 tests passing, 0 failures (5 win32-only skips).
  • Each work package was built test-first with disjoint file ownership, then independently reviewed; the reviews caught and fixed two real regressions before merge (a fail-open inversion of the court's collusion check, and actor-host inheritance that misattributed novel actor hosts to the session host).

Relates to #131: this is the in-tree consistency pass promised there, sequenced ahead of any
extensibility decision so a future adapter lands against a coherent seam.

🤖 Generated with Claude Code

pacphi added 6 commits August 14, 2026 18:46
…in-text capture, retire gemini sentinels

Phase 0 consistency hygiene (F-07, F-20, F-22 + the plain-text capture):
statuslineSupported had zero call sites — the registry's commandStatusline
capability is the surviving vocabulary (ADR-0015 update note). npmRoot no
longer throws for a host without an npm package. createPlainTextSummaryCapture
mirrors the JSONL capture's contract for hosts whose oneshot mode emits plain
text. Negative tests stop using 'gemini' as the unknown-host sentinel so they
cannot silently invert if that id ever registers.
…nding warnings in host status

Phase 0 consistency hygiene (F-15, F-16, F-12): host adapters carry a required
enabledByDefault boolean and defaultHostMap() replaces the map literal that was
triplicated across config, providers, and host-off reset — output is
byte-identical for the shipped registry. The previously dead non-throwing
validateBinding is wired as bindingWarnings(): ak host status (human output
only) names each kit.json binding with an unknown host, unknown provider, or
unsupported transport instead of ignoring it silently. The observability axis
is documented as terminal validation metadata (ADR-0016 update note).
Phase 0 consistency hygiene (F-08): parseFile dispatches explicitly on the
three known providers and declines anything else instead of falling through to
parseClaude; locate()'s cache-hit path returns only claude/codex hits instead
of coercing every non-codex provider to claude; scanKey folds the scan roots
in as sorted entries so distinct root sets can never share a single-flight
promise. Records keep their real provider string — unknown hosts are excluded
and labeled, never mis-filed.
… registry-known native providers

Phase 0 consistency hygiene (F-11, F-13): vendorOf tags an unrecognized
provider id as unregistered:<id> instead of collapsing every unknown into one
shared vendor. validatePanel applies the can't-prove-independence rule
symmetrically — unregistered vendors never satisfy minVendors, and an
unregistered writer with an unregistered jury is treated as could-be-colluding
— so ak is never looser than the old shared-'unknown' model (verified against
~280k synthetic panels). The integrations migrator derives each host's native
default provider from the provider registry's host-login entries, guarded
against ambiguity, and infers no binding at all for hosts without one — the
unknown-via-<host> stamping is gone.
…em to internal

Phase 0 consistency hygiene (F-09): createLiveEvent resolves hosts through one
policy — a known host passes, a safely-shaped novel id passes verbatim, and
anything else becomes the explicit unknown-host bucket, never the retired
'internal' label. Declared actor/target hosts run through the same policy and
inherit the session host only when absent, so an actor on a novel host is
never silently attributed to the session's host. The structured adapter stops
pre-filtering hosts through its own allowlists and passes raw values to the
schema, the single resolver.
Re-anchor eight usage-index.mjs line citations that drifted past the
doc-citation gate's tolerance; note in PROVIDERS.md that ak host status warns
on malformed kit.json bindings (current-state phrasing only — history stays in
the ADRs); ADR-0015 records the statuslineSupported removal and ADR-0016
records the Phase 0 registry-level changes (enabledByDefault, terminal
observability axis, validateBinding wiring, registry-derived migrator
defaults).
@pacphi
pacphi merged commit 18427bc into main Aug 15, 2026
14 checks passed
@pacphi
pacphi deleted the feat/phase-0-consistency-hygiene branch August 15, 2026 02:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant