fix(ci): receipt the eager load_skill surface in the runtime-contract budget

`Lint` has been red on main since 91b5898a2, on both the push and the dispatched
runs, at "Check runtime-contract budget":

  identity changed for Plan active tool names
  [`tool_catalog.modes.plan.active.tool_names`] (added=['load_skill'] removed=[])

That commit made `load_skill` eager so the `## Skills` instruction in the base
prompt is actually callable — it had been deferred behind `tool_search`, so the
prompt told the model to call a tool that was not in the array it was printed
beside. The model-facing surface therefore grew on purpose and the baseline
never receipted it.

`--update` cannot absorb an identity change by design: compare() raises before
the update path, so the gate requires an explicit maintainer decision recorded
in scripts/runtime-contract-budget.json. This makes that decision and logs it in
the file's running decision comment (the canonical writer truncates that comment,
so it is restored and appended rather than replaced).

Measured from 6bafe6e72 on macOS aarch64 all-features:
- load_skill joins the ACTIVE sets of Plan, Act and Operate: 11 -> 12 tools,
  +816 schema bytes / +204 estimated tokens in every mode (ceilings 33786/8447)
- full catalogs move only by the defer_loading spelling plus that schema body:
  +245 bytes / +61-62 tokens
- representative stages re-hash and each move +149 bytes, total +37 tokens:
  dc32272f15's Bearing article and mandate-first scope law, plus 91b5898a2's
  rewritten Skills paragraph, which every stage renders

No other name-set identity, count, prompt or skill-discovery measurement moves,
and the file's prior decision log is preserved verbatim. bytes/4 remains an
estimate, not measured provider usage or billing.

Evidence: python3 scripts/check-runtime-contract-budget.py ->
"PASS: all 55 metrics are exactly at budget" (end to end, re-measured).
This commit is contained in:
CodeWhale Bot committed 2026-09-22 01:55:42 -07:00
1 parent 6bafe6e727
commit 3e8bf29946
1 file changed
+33 -30
+33 -30
View File
@@ -1,5 +1,5 @@
{
"_comment": "One-way numeric ceilings and exact structural identities for the provider-free runtime contract. Decreases pass; increases or identity changes fail. Lock in decreases with: python3 scripts/check-runtime-contract-budget.py --update The v0.9.8 child-receipt restore grew every production tool surface by 1496 schema bytes / 374 estimated tokens (agent tool). The v0.9.8 workshop read/tool-result byte fields then grew every production tool surface by 371 schema bytes / 93 estimated tokens. Both raises are explicit maintainer decisions; identities stay on the pre-raise digests only if the name set is unchanged \u2014 re-measure on Linux CI if Lint reports identity drift. The v0.9.8 pinned session prefix added the <context_update> sentence to the base prompt (5848 -> 6084 bytes, every representative stage re-hashed), and the host-side Workflow/Goal verbs plus honest child posture grew the tool catalog (active 16531 -> 16602 bytes, full 71473 -> 72371); both are explicit v0.9.8 maintainer decisions measured from the release train. The v0.9.9 configured-skills change hides only custom configured-root paths, preserves discoverable default-root paths, normalizes Windows prompt separators, and trims 50 redundant skills-prompt bytes. The skill/memory/goal/handoff identities were re-measured without raising any ceiling. Explicit maintainer decision for #5473/#5492. The v0.9.10 full surfaces intentionally add the safe read_media tool; their measured schemas remain below the prior byte/token ceilings. Representative prompt byte metrics now use the same host-independent normalized text as their identities; the normalized base is 6089 bytes. The v0.9.11 model-visible sub-agent surface intentionally retires six legacy agents/* tools in favor of the canonical agent tool; all affected schema and prompt metrics decrease. The v0.9.12 plugin prompt-match slice intentionally adds the request_plugin_install tool to the full tool surfaces (plan full: +518 schema bytes / +130 estimated tokens / 29 -> 30 tools) so a strong prompt match can surface the human review CTA; explicit maintainer decision for #5663/#5579. The v0.9.13 profile pins a non-executed bare bash shell so interpreter guidance is reproducible across hosts. The duplicate tts catalog entry is intentionally hidden; speech remains canonical and the alias remains available for saved-transcript dispatch. Explicit v0.9.13 maintainer decision (2026-09-08): after removing 1426 repeated guidance bytes and pinning the bash-v2 fixture, accept only the measured tool byte/token ceilings from all-features macOS source e27735bb63c897f88061c71567701fd971f5d396, verified libtest SHA-256 5e8cbe213f32c4ecdec63494c4de5e31857b4a40134edf7b21a55bca926b1b38: active 13274/3319 in every mode, Plan full 39885/9972, Act/Operate full 67603/16901, with no margin. Against the prior budget, active +390 bytes is agent -41 plus retained bash command syntax +431. Plan full also retains Git commit_plan +253, update_goal progress +583, github bounded local-report guidance +127, review complete-input refusal +35, and send_later dispatching status +14. Act/Operate full instead has github +2151 and additionally speech +230, hidden tts -2120, and tasks/automation exact model-route fields +274 each. The older budget predates v0.9.12: that tag had already removed 361 agent bytes and added the two 274-byte route fields; the retained initial increase versus the tag is 751 source-attributed bytes (agent +320, bash +431), not the +390 budget delta. Only the seven active definitions form the initial request; full catalogs include deferred tools. Estimated tokens use the existing bytes/4 heuristic, not provider usage or billing. Prompt, representative-context, skill-discovery and tool-name identities/ceilings are unchanged. Explicit v0.9.13 maintainer decision (2026-09-09): source ccc5dadfa2279545bf084d37cff3617e41ceaae2 intentionally exposes create_goal, get_goal and update_goal before continuation, so all three initial surfaces now contain ten tools. Measure exact source 4648d148eea64782be857eda6952af2c539cbfcc with the hosted macOS all-features libtest SHA-256 4485c88c7a8b66b8bb9a135807321e417a1e266457ecb74cffc7dfb92f850fc4: four exact provider-free metric tests pass. Active schemas are exactly 17847 bytes / 4462 estimated tokens (+4573 / +1143 for the three eager goal definitions); Plan full is 40597 / 10150 and Act/Operate full is 68315 / 17079, with no margin. The +712 full-catalog bytes are request_user_input guidance +358, update_goal state-change guidance +98, list_dir home-relative path guidance +56, explicit review max_passes schema +197, and three defer_loading true-to-false values +3. The three active name sets/digests, their counts, and measured active/full byte/token ceilings change; full name identities and all prompt, representative-context and skill-discovery measurements remain unchanged. This updates the earlier seven-tool initial-request receipt; bytes/4 remains an estimate, not measLine truncated
"_comment": "One-way numeric ceilings and exact structural identities for the provider-free runtime contract. Decreases pass; increases or identity changes fail. Lock in decreases with: python3 scripts/check-runtime-contract-budget.py --update The v0.9.8 child-receipt restore grew every production tool surface by 1496 schema bytes / 374 estimated tokens (agent tool). The v0.9.8 workshop read/tool-result byte fields then grew every production tool surface by 371 schema bytes / 93 estimated tokens. Both raises are explicit maintainer decisions; identities stay on the pre-raise digests only if the name set is unchanged \u2014 re-measure on Linux CI if Lint reports identity drift. The v0.9.8 pinned session prefix added the <context_update> sentence to the base prompt (5848 -> 6084 bytes, every representative stage re-hashed), and the host-side Workflow/Goal verbs plus honest child posture grew the tool catalog (active 16531 -> 16602 bytes, full 71473 -> 72371); both are explicit v0.9.8 maintainer decisions measured from the release train. The v0.9.9 configured-skills change hides only custom configured-root paths, preserves discoverable default-root paths, normalizes Windows prompt separators, and trims 50 redundant skills-prompt bytes. The skill/memory/goal/handoff identities were re-measured without raising any ceiling. Explicit maintainer decision for #5473/#5492. The v0.9.10 full surfaces intentionally add the safe read_media tool; their measured schemas remain below the prior byte/token ceilings. Representative prompt byte metrics now use the same host-independent normalized text as their identities; the normalized base is 6089 bytes. The v0.9.11 model-visible sub-agent surface intentionally retires six legacy agents/* tools in favor of the canonical agent tool; all affected schema and prompt metrics decrease. The v0.9.12 plugin prompt-match slice intentionally adds the request_plugin_install tool to the full tool surfaces (plan full: +518 schema bytes / +130 estimated tokens / 29 -> 30 tools) so a strong prompt match can surface the human review CTA; explicit maintainer decision for #5663/#5579. The v0.9.13 profile pins a non-executed bare bash shell so interpreter guidance is reproducible across hosts. The duplicate tts catalog entry is intentionally hidden; speech remains canonical and the alias remains available for saved-transcript dispatch. Explicit v0.9.13 maintainer decision (2026-09-08): after removing 1426 repeated guidance bytes and pinning the bash-v2 fixture, accept only the measured tool byte/token ceilings from all-features macOS source e27735bb63c897f88061c71567701fd971f5d396, verified libtest SHA-256 5e8cbe213f32c4ecdec63494c4de5e31857b4a40134edf7b21a55bca926b1b38: active 13274/3319 in every mode, Plan full 39885/9972, Act/Operate full 67603/16901, with no margin. Against the prior budget, active +390 bytes is agent -41 plus retained bash command syntax +431. Plan full also retains Git commit_plan +253, update_goal progress +583, github bounded local-report guidance +127, review complete-input refusal +35, and send_later dispatching status +14. Act/Operate full instead has github +2151 and additionally speech +230, hidden tts -2120, and tasks/automation exact model-route fields +274 each. The older budget predates v0.9.12: that tag had already removed 361 agent bytes and added the two 274-byte route fields; the retained initial increase versus the tag is 751 source-attributed bytes (agent +320, bash +431), not the +390 budget delta. Only the seven active definitions form the initial request; full catalogs include deferred tools. Estimated tokens use the existing bytes/4 heuristic, not provider usage or billing. Prompt, representative-context, skill-discovery and tool-name identities/ceilings are unchanged. Explicit v0.9.13 maintainer decision (2026-09-09): source ccc5dadfa2279545bf084d37cff3617e41ceaae2 intentionally exposes create_goal, get_goal and update_goal before continuation, so all three initial surfaces now contain ten tools. Measure exact source 4648d148eea64782be857eda6952af2c539cbfcc with the hosted macOS all-features libtest SHA-256 4485c88c7a8b66b8bb9a135807321e417a1e266457ecb74cffc7dfb92f850fc4: four exact provider-free metric tests pass. Active schemas are exactly 17847 bytes / 4462 estimated tokens (+4573 / +1143 for the three eager goal definitions); Plan full is 40597 / 10150 and Act/Operate full is 68315 / 17079, with no margin. The +712 full-catalog bytes are request_user_input guidance +358, update_goal state-change guidance +98, list_dir home-relative path guidance +56, explicit review max_passes schema +197, and three defer_loading true-to-false values +3. The three active name sets/digests, their counts, and measured active/full byte/token ceilings change; full name identities and all prompt, representative-context and skill-discovery measurements remain unchanged. This updates the earlier seven-tool initial-request receipt; bytes/4 remains an estimate, not measLine truncated
"document_kind": "codewhale.runtime_contract_budget",
"representative_context": {
"fixture_id": "representative-v1",
@@ -9,14 +9,14 @@
"identity_sha256": "47ec39be875d57bc86c0a490be4a7a31bee577011eb3707df51b706901d17b22"
},
"goal": {
"bytes": 8878,
"bytes": 9027,
"delta_bytes": 81,
"identity_sha256": "4e079faa30af095d903a630608174198ad72a00901900fd55a645e8d95b352b9"
"identity_sha256": "42b25f1398cdf49fe8e18c98264ecb5842f885bb8b1a5132b772a9d7b676a3ed"
},
"handoff": {
"bytes": 9266,
"bytes": 9415,
"delta_bytes": 388,
"identity_sha256": "05430757b2d2cd9627c6521c55706882261cb0d7bc33cbef1cca347ddd6a8276"
"identity_sha256": "79451002384ef3657a15e7dfc5bcd1aa1345dbf7d341a132f6ef238b7b0e6dfe"
},
"instructions": {
"bytes": 7217,
@@ -24,9 +24,9 @@
"identity_sha256": "c6f4d19bb203f82f85c7852ee31310fe426441371850126682cd86d03596289c"
},
"memory": {
"bytes": 8797,
"bytes": 8946,
"delta_bytes": 963,
"identity_sha256": "45284c41712d97cca11e13f90c12c757bcd3111f7421c67661a88f04dbaa9b23"
"identity_sha256": "79232e012821f5c1ff7ce4bf33908dd349f21d2ce92ff59e3f8e80b24c80d7f5"
},
"project": {
"bytes": 7086,
@@ -34,14 +34,14 @@
"identity_sha256": "7e2993b93e1dcadef95c70d3c502984423e9800ee037743ab6101c67831dd83e"
},
"skill": {
"bytes": 7834,
"delta_bytes": 617,
"identity_sha256": "28a1b91473b992440d0d2ffcd0db79cb9a7b5582c521e527bbb855b5fa506dbb"
"bytes": 7983,
"delta_bytes": 766,
"identity_sha256": "1cf103582df03012601b90e24b89c24b433409036a6c1b80f9aacc2d83b44422"
}
},
"system_prompt_blocks": 6,
"total_bytes": 9266,
"total_tokens_est": 2317
"total_bytes": 9415,
"total_tokens_est": 2354
},
"schema_version": 1,
"skill_discovery": {
@@ -86,15 +86,16 @@
"modes": {
"act": {
"active": {
"bytes": 32970,
"identity_sha256": "cf523fcd7528ab2e14efffd7fe6b0916a370d6a8b8426d15a159aa823a7b86ce",
"tokens_est": 8243,
"bytes": 33786,
"identity_sha256": "df6676989a677fb08fecc8bf7ae12caf4fa88e0cae3d143cea6a4da4382b746c",
"tokens_est": 8447,
"tool_names": [
"agent",
"bash",
"create_goal",
"edit",
"get_goal",
"load_skill",
"read",
"todo_write",
"tool_search",
@@ -102,12 +103,12 @@
"workflow",
"write"
],
"tools": 11
"tools": 12
},
"full": {
"bytes": 83079,
"bytes": 83324,
"identity_sha256": "45e989bbe5ac0bb1f2d9084361c021009f30a06539f132ebd4fd2331a1bb1954",
"tokens_est": 20770,
"tokens_est": 20831,
"tool_names": [
"Git",
"Run",
@@ -168,15 +169,16 @@
},
"operate": {
"active": {
"bytes": 32970,
"identity_sha256": "cf523fcd7528ab2e14efffd7fe6b0916a370d6a8b8426d15a159aa823a7b86ce",
"tokens_est": 8243,
"bytes": 33786,
"identity_sha256": "df6676989a677fb08fecc8bf7ae12caf4fa88e0cae3d143cea6a4da4382b746c",
"tokens_est": 8447,
"tool_names": [
"agent",
"bash",
"create_goal",
"edit",
"get_goal",
"load_skill",
"read",
"todo_write",
"tool_search",
@@ -184,12 +186,12 @@
"workflow",
"write"
],
"tools": 11
"tools": 12
},
"full": {
"bytes": 83079,
"bytes": 83324,
"identity_sha256": "45e989bbe5ac0bb1f2d9084361c021009f30a06539f132ebd4fd2331a1bb1954",
"tokens_est": 20770,
"tokens_est": 20831,
"tool_names": [
"Git",
"Run",
@@ -250,15 +252,16 @@
},
"plan": {
"active": {
"bytes": 32970,
"identity_sha256": "cf523fcd7528ab2e14efffd7fe6b0916a370d6a8b8426d15a159aa823a7b86ce",
"tokens_est": 8243,
"bytes": 33786,
"identity_sha256": "df6676989a677fb08fecc8bf7ae12caf4fa88e0cae3d143cea6a4da4382b746c",
"tokens_est": 8447,
"tool_names": [
"agent",
"bash",
"create_goal",
"edit",
"get_goal",
"load_skill",
"read",
"todo_write",
"tool_search",
@@ -266,12 +269,12 @@
"workflow",
"write"
],
"tools": 11
"tools": 12
},
"full": {
"bytes": 53200,
"bytes": 53445,
"identity_sha256": "ac8af1f4988199825be7b00b054c258724a44074b1d4e6de6c92ade7c1cffe63",
"tokens_est": 13300,
"tokens_est": 13362,
"tool_names": [
"Git",
"Web",