D4: fold the four F2 flat_decision adapters onto the engine - #98
Merged
Conversation
…r data The four F2 vendors' data/vendors entries gain the G1 renderer tables (words, degrade notes, reason defaults) via tools/recount, and the engine gains the table-driven devices those dialects need: an escalate word path in _g1, the hook_specific_tool_input and top_level_updated_input transform bodies, template degrade notes, per-gate reason defaults, allow-body context, allow-silent events, a reverse-map fallback for payloads with no wire event name, a tool-input envelope chain, write-gated content, and literal hook-entry extras. All opt-in config keys absent from every F1 entry; full suite green with golden fixtures byte-identical. Signed-off-by: Open Coder AI <250249270+open-coder-ai@users.noreply.github.com>
…ion engine The four F2 modules are deleted; adapters.get() binds each to the D3 engine over its data/vendors entry, and bundle() composes engine + inlined VENDOR literal for them. Golden fixtures byte-for-byte unchanged; the 12-agent bundler subprocess replay is green. The tabnine source-grep vocabulary test is retired per design §5, its intent already re-homed as test_vocabulary_basis_is_unverified_only_for_tabnine. junie's PermissionRequest alias gate joins _EXTRA_GATE_NAMES; the transitional gemini fields override in tools/recount is removed now that the entry is the source. Signed-off-by: Open Coder AI <250249270+open-coder-ai@users.noreply.github.com>
open-coder-ai
marked this pull request as ready for review
September 1, 2026 13:23
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this changes
gemini_cli,tabnine,junieandgrokare no longer hand-written adapter modules: the D3 engine executes theirdata/vendors/<agent>.jsonentries (dialect-families.md §6, wave D4), andbundle()composes engine + inlinedVENDORliteral for them. Wire output through the dispatcher is unchanged — the golden fixture suite passes byte-for-byte with zero fixture edits.Claim check
MATRIXrow changes; every new config gate (junie'sPermissionRequest) was recounted by replaying the real dispatcher against the frozen D1 payload, andtest_config_gates_are_a_subset_of_matrix_block_capable_eventsstill gates itMATRIXrow carries averifiedrecord — no matrix rows touchedtests/fixtures/golden/<agent>.jsonChecks
pytest -qpasses (1348 passed, 4 skipped; includes the golden replay and the 12-agenttest_bundler_subprocess.pyreplay)ruff check .andruff format --check .pass (ruff check --select I --fixwas a no-op)PYTHONNOUSERSITE=1 python tests/check_stdlib_only.pyclean;examples/generate.py --checkanddocs/assets/gen_brand_assets.py --checkalso run clean)git commit -s)Notes for the reviewer
Two-stage history, each commit green. Stage 1 adds the schema fields, engine devices and
tools/recounttables and regenerates the four entries viarecount_vendor_config.py --write(modules still bound, so the enrichment is derived, not hand-typed — F1 and singleton entries regenerate byte-identical). Stage 2 flips_CONFIG_DRIVEN, deletes the four modules (465 lines), and removes the transitional gemini fields override.Every engine device is an opt-in config key, absent from all F1 entries (checked: every F1 G1 gate has
honours_escalate: false, no F1 entry carries the new keys), so F1 wire cannot move: escalate word path in_g1;hook_specific_tool_input(gemini, emitstool_input: nullon a rewrite with no input, as the fixture pins) andtop_level_updated_input(junie) transform bodies; template degrade notes filling(reason-or-default, wire event)(gemini's "cannot prompt from a hook");gate_reason_defaults(junie's Stop "not finished");allow_context_key/allow_silent_events(junie'sadditionalContextand silent Stop-allow);missing_wire: reverse_map(tabnine answers hand-built events, and a hand-built UNKNOWN event stays silent); afields.tool_inputenvelope chain (grok'stoolInput, derived by the recount walker from the deleted module's ownti =assignment);content_only_for_write_tools(gemini); literalentry_extravalues (tabnine'sname: agentseam).One designed test retirement.
test_the_unverified_vocabulary_is_still_only_tabninegrepped per-vendor source files that no longer exist; dialect-families.md §5's table names it as dying at this wave with its intent re-homed — the re-homed derivation (test_vendor_config.py::test_vocabulary_basis_is_unverified_only_for_tabnine) already exists and passes.Two respond()-direct behaviours did not survive, both unreachable through
handle()(called out in the CHANGELOG): tabnine no longer answers the undocumentedBeforeModel/AfterModelwire names (they map to no canonical event, sohandle()short-circuited beforerespond(), and a config gate for them would fail the matrix-subset test), and gemini_cli no longer honours a rewrite at gates the recount classified deny-only (through the dispatcher,degrade()already converted those to escalates). W38's handback note also asked for aflat_entrieshook-entry style for tabnine — tabnine's wrapper is actuallyhooks_mapwith anameextra, so only the literal-extra device was needed;flat_entriesrendering stays for the wave that folds its real users (vscode_copilot/windsurf, D5).Bundle sizes (design §7 updated with the same numbers): gemini_cli 458→690, tabnine 409→664, junie 429→664, grok 439→664 (+51–62%, above the §4 estimate of 470–500 because an engine bundle inlines the whole shared engine, G2 included — the trade D3 already made; D6 owns bundle composition). Source tree: −465 adapter lines, +~40 engine lines, no new modules.
Generated by Claude Code