feat(agents-orchestration): subagent tool-scoping + optional review gates - #6
Merged
Merged
Conversation
…al review gates (subagent_review flag) Add an always-on subagent tool-scoping resilience rule to agents-orchestration.md: the Anthropic tool-use API rejects top-level oneOf/allOf/anyOf in a tool's input_schema, and a subagent's init advertises its whole tool surface in one request, so a single bad tool kills every subagent type at once and silently. Read-only fan-out agents (explore / plan / review) must declare a least-privilege tools allowlist (Read, Grep, Glob, Bash; WebFetch/WebSearch only for docs) so no connector schema reaches their init request; for owned MCP servers, strip top-level combinators from the advertised schema while keeping call-time validation (the mcp-github pattern); disable third-party connectors you cannot edit. Add two OPT-IN parallel-subagent review gates, gated by a new feature flag subagent_review: Gate 1 offers a plan-review before a non-trivial plan is confirmed; Gate 2 offers a conformance-review of the built work against the plan at merge-prep. Both ask the user each time and use the scoped ctxr-* agents; the foreground-only polling discipline is unchanged. Cross-link parallel-validation.md as the issue-tree specialization, and reference the gates from pr-loop.md and plan-to-issues.md. Wire the new subagent_review flag everywhere the existing flags appear (12 -> 13): FEATURE_NAMES in scripts/lib/config.mjs, the schema + flag-table + preset matrix in local-config.md, templates/config.local.md, index.md, and README.md. The flag conceptually requires agents_orchestration (stated in the flag-table row); it is on for single-issue and full, off for pr-only. No frontmatter requires.config is added; agents-orchestration.md keeps feature: agents_orchestration and gates the new section with an inline Skip callout. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
4 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.
Summary
agents-orchestration.md: NEW "Subagent tool scoping (keep fan-out alive)" section (the top-level oneOf/allOf/anyOf failure mode that silently kills all fan-out, and the least-privilegetools:allowlist rule) + NEW "Optional review gates" section (inline-gated bysubagent_review): Gate 1 plan-review before confirmation, Gate 2 conformance-review at merge-prep, both opt-in and foreground.subagent_review(requiresagents_orchestration) wired throughscripts/lib/config.mjsFEATURE_NAMES, the Features tables, the preset matrix, and the 12 -> 13 counts.parallel-validation.md,pr-loop.md,plan-to-issues.md. Companion scoped agents ship in.claude/agents/.Closes #4. Supersedes #5 (GitHub auto-closed #5 when its stacked base branch was deleted on the #3 merge; this is the same commit rebased onto main).