merge queue: checking #307 on main (104f21f) - #339
Closed
mergify[bot] wants to merge 3 commits into
Closed
Conversation
- Problem: principle-subagent-inherits-scope (previous slice) is prose, and the next fan-out skill someone writes will not remember it. A scope boundary that exists only in a principle nobody loads at spawn time is the tier-4-where-tier-3-applies failure that reflect/references/lenses.md's fix hierarchy warns about. - Trigger: landing that principle without a check would repeat the admin-bypass-sweep shape from PR #303 — prose asking for a behavior with nothing enforcing it. - Chose: a skill whose body instructs delegation must name principle-subagent-inherits-scope, or cite the scope contract in principle-prove-it/references/finding-shape.md. Two ways to satisfy it because the four investigation products already cite the reference and should not each repeat the principle's name. - Chose: grandfather the three pre-existing spawners in a shrink-only allowlist (scripts/subagent_scope_debt_allowlist.txt), mirroring scripts/skill_test_debt_allowlist.txt exactly. Rewriting reflect, independent-judge-swarm, and show-me-your-work to state the contract is a different review than adding the rule. - Rejected: a hardcoded list of known fan-out skills. Same objection as the trigger-policy gate — it needs someone to remember the next one. - Regex iteration, recorded because the first version was wrong in both directions. A loose pattern flagged three false positives: principle-build-the-lever says "don't fan out delegates", principle-trace-token-burn-loop prices "re-spawning the agent", and principle-guard-the-context-window costs out parallel Agent calls — all prose ABOUT delegation, not instructions to delegate. Tightening the verb to require an article ("spawn a|one|all ...") then went too far and lost why, alternatives-considered, and independent-judge-swarm, which are real spawners — false negatives are worse than false positives in a safety gate. The landed version keeps the broad verb patterns and adds a per-line negation guard, which drops all three false positives and keeps all seven real spawners. Both false positives are regression fixtures in the tests. - New: scripts/check_subagent_scope_contract.py, scripts/subagent_scope_debt_allowlist.txt, tests/test_subagent_scope_contract.py. - Modified: engine/skills/make-pr/scripts/preflight.py gains the gate (so future skill PRs run it) plus a colocated test for the gate list. - No skill prose changes, so no agent behavior changes from this slice alone. - Revertable with git revert. - Fail-before / pass-after with the allowlist emptied (the state before this slice), both outputs captured: fail engine/skills/reflect: instructs spawning subagents but names neither principle-subagent-inherits-scope nor the scope contract in finding-shape.md fail product/skills/independent-judge-swarm: ... same fail product/skills/show-me-your-work: ... same exit=1 with the allowlist restored: ok subagent scope contract exit=0 - python3 scripts/check_subagent_scope_contract.py --list -> 7 spawners, 4 ok (principle-prove-it, alternatives-considered, how, why), 3 grandfathered - python3 -m unittest tests.test_subagent_scope_contract -> Ran 9 tests, OK - python3 -m unittest discover -s engine/skills/make-pr/tests -> Ran 13, OK Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JQMWSLRArEfEm1psa7RKdD
check_no_new_comments.py rejected nine comment lines this branch added. Seven explained why SPAWNER_RE and NEGATED_RE are deliberately narrow; two named the corpus skills the test fixtures were copied from. The SPAWNER_RE/NEGATED_RE rationale moves into the module docstring, which the gate exempts. The two fixture-provenance lines are dropped: the test module docstring already names both skills and why they are there. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013mDsvDgGuwaBuyRtYgvktd
3 tasks
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.
🎉 This pull request has been checked successfully and will be merged soon. 🎉
#307 is queued for merge on branch main (104f21f).
This pull request has been created by Mergify to check the mergeability of #307.
You don't need to do anything. Mergify will close this pull request automatically when it is complete.
Required conditions of queue rule
admin-bypassfor merge:check-success = lintcheck-success = testRequired conditions to stay in the queue:
-draftbase=mainlabel=admin-bypass