Skip to content

Default Subagents to Frontier and Refuse Untiered Explore and Plan - #4283

Merged
ptr727 merged 3 commits into
developfrom
feature/subagent-default-model
Nov 19, 2026
Merged

ptr727 merged 3 commits into
developfrom
feature/subagent-default-model

Conversation

@ptr727

@ptr727 ptr727 commented Nov 19, 2026 •

Copy link
Copy Markdown
Owner

Summary

A session launched on the maintainer-only tier passed that tier to every dispatch that named no model. This makes the kit set a default, refuses the dispatches that default cannot reach, and states the rule.

  • Installer default subagent model. host-setup/agent-safety/claude/install.py sets env.CLAUDE_CODE_SUBAGENT_MODEL in the Claude Code settings file to the model of the tier defaultTier names in spec/model-tiers.json, read through the tier guard's own reader. The stamp records the value the kit wrote (subagentModel). An absent value is written. A value equal to the default is current. The recorded value, with the default since changed, is updated. Any other value is the host's own, left and noted, naming the maintainer-only tier where it is that one. The kit never sets CLAUDE_CODE_SUBAGENT_MODEL_FORCE, and where the host sets it, it reports that and changes nothing. --report, which the bootstrap --agent-status step runs, reads each state. The installer has no removal path.
  • Guard refusal. model-tier-guard.py denies an Agent call naming no model whose subagent_type is listed under the tool's new inheritingAgentTypes (Explore, Plan), matched without regard to case. The deny text lists each tier and its model, the default marked and the maintainer-only tier left out. FLEET_ALLOW_HIGHEST=1 still allows everything. A mapping without the key lists no type. spec/validate.py checks the key's shape.
  • Rule text. AGENTS.md "Model Tiers" (the highest bullet and the orchestrating-seat bullet), a new "Delegation" bullet and brief-template line, and a new backlog-burndown "Away Mode" bullet. The include regions carrying "Model Tiers" are regenerated by scripts/build_dist.py.
  • Kit docs. The kit README describes the setting, its ownership, and what it does not reach (the Explore and Plan types, and a fork). The host-safety spec's requirement 10 states the default and the refusal.

Verification

The full local gate set in OPERATIONS.md passed: ruff check and format, mypy, the unittest suite with coverage, the audit helpers, workflow_reuse.py --selftest, every agent-safety self-test and suite, build_dist.py --check, canonical_review.py status, repo_gate.py, the prose gate, jq over the JSON, and spec/validate.py. scripts/docker_lint.py passed all its linters.

Local review

Three recorded local-strict-review passes at the frontier tier. The first two rounds' findings were fixed: the installer reads the mapping through the guard's load_tiers, the guard drops checks the validated mapping makes unreachable, requirement 10 names the no-model refusal, the verify line counts only the default-model key, an empty or null value is treated as absent, and the mapping note's long sentence is split. The edit budget is spent, so these introduced findings went to this pull request's review loop, which gives each its outcome below:

  • introduced, host-setup/agent-safety/claude/install.py, ownership of the default subagent model rests on the stamp's subagentModel record. A failed stamp write, or a run of an installer from before this change (which rewrites the stamp without the key), leaves the kit's own value unrecorded. At the next defaultTier model change that value reads as the host's own, the install leaves it, and --report prints a Note naming the mismatch rather than a STALE verdict. Outcome: declined. The stamp is the record the design names, and a value equal to the default with no record cannot be told apart from a host's own coincident value, which the kit must never overwrite. The mismatch stays visible in every --report and --agent-status.
  • introduced, AGENTS.md "Model Tiers" highest bullet, the decided text says the kit refuses a no-model Explore or Plan dispatch and that a no-model dispatch runs at the kit's default, without naming the launch allowance or a host's own value or force switch. Outcome: declined as out of scope here. The text is the decided rule wording this pull request carries, and a wording change of substance belongs to the dispatching session.

🤖 Generated with Claude Code

ptr727 and others added 3 commits November 19, 2026 07:55
A session launched on the maintainer-only tier passed that tier to every
dispatch that named no model. The agent-safety installer now sets the
default subagent model to the default tier's model, owned through a stamp
record so a host's own value is never overwritten. The model-tier guard
refuses a no-model dispatch of the built-in types that default does not
reach. AGENTS.md states the new default and when a session above the tier
its work calls for dispatches the execution, and backlog-burndown says an
away run gains nothing from a session on the maintainer-only tier.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
The installer reads the default and maintainer-only tiers through the
tier guard's own reader, so the two never read one mapping two ways. The
guard drops checks the validated mapping makes unreachable. Requirement 10
names the no-model refusal, and the verify line counts only the default
subagent model key.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
An empty or null CLAUDE_CODE_SUBAGENT_MODEL sets no default, so the
installer treats it as absent and fills it rather than reporting it as
the host's own model. The mapping note's new sentence is split to the
prose length cap.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Copilot AI lite review requested due to automatic review settings November 19, 2026 16:12
@ptr727

ptr727 commented Nov 19, 2026

Copy link
Copy Markdown
Owner Author

A recorded local strict-review pass covers head 2f064008dc7e9377fbd063875e442a59f9e14e31, the content this pull request carries at that commit against develop, and it recorded 2 findings.

@coderabbitai

coderabbitai Bot commented Nov 19, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 45 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 5a58f67 and 2f06400.

Files ignored due to path filters: 9

  • .claude-plugin/fleet-skills/.source-digests/backlog-burndown is excluded by !.claude-plugin/fleet-skills/**
  • .claude-plugin/fleet-skills/.source-digests/decision-triage is excluded by !.claude-plugin/fleet-skills/**
  • .claude-plugin/fleet-skills/.source-digests/local-strict-review is excluded by !.claude-plugin/fleet-skills/**
  • .claude-plugin/fleet-skills/skills/backlog-burndown/SKILL.md is excluded by !.claude-plugin/fleet-skills/**
  • .claude-plugin/fleet-skills/skills/decision-triage/SKILL.md is excluded by !.claude-plugin/fleet-skills/**
  • .claude-plugin/fleet-skills/skills/local-strict-review/SKILL.md is excluded by !.claude-plugin/fleet-skills/**
  • .github/skills/backlog-burndown/SKILL.md is excluded by !.github/skills/**
  • .github/skills/decision-triage/SKILL.md is excluded by !.github/skills/**
  • .github/skills/local-strict-review/SKILL.md is excluded by !.github/skills/**
Files selected for processing: 13

  • .agents/skills/backlog-burndown/SKILL.md
  • .agents/skills/decision-triage/SKILL.md
  • .agents/skills/local-strict-review/SKILL.md
  • AGENTS.md
  • host-setup/agent-safety/README.md
  • host-setup/agent-safety/claude/README.md
  • host-setup/agent-safety/claude/install.py
  • host-setup/agent-safety/claude/model-tier-guard.py
  • host-setup/agent-safety/claude/test_install.py
  • host-setup/agent-safety/claude/test_model_tier_guard.py
  • spec/model-tiers.json
  • spec/validate.py
  • tests/test_spec_validate.py
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Active critical defects leave the report incorrectly succeeding when the subagent model is missing or outdated and allow malformed agent-type mappings to bypass the safety guard.

3 open issues
What changed in this PR

This PR makes frontier the default Claude Code subagent tier and prevents untiered Explore and Plan dispatches from inheriting a maintainer-only session model. It updates the host-safety installer and guard, model-tier validation, tests, documentation, and generated fleet guidance. The review identified issues involving stale report verdicts, malformed deployed mappings, an incomplete diagnostic, and unexplained typing suppressions.

Changes:

  • Configure and stamp CLAUDE_CODE_SUBAGENT_MODEL from the default tier while preserving host-owned values and force-switch behavior.
  • Reject untiered built-in agent dispatches that bypass the configured default.
  • Extend model-tier validation, host-safety documentation, tests, fleet guidance, generated Skills, and source digests.
File Description
tests/​test_spec_validate.py Adds tests for validating optional inheriting agent types.
spec/​validate.py Validates the shape, uniqueness, and non-empty values of inheritingAgentTypes.
spec/​model-tiers.json Defines the default model tier and the inheriting Explore and Plan agent types.
host-setup/​agent-safety/​README.md Documents the expanded host-safety requirement for default models and untiered dispatches.
host-setup/​agent-safety/​claude/​test_model_tier_guard.py Tests refusal of untiered inheriting agent dispatches and tier messaging.
host-setup/​agent-safety/​claude/​test_install.py Tests default-model installation, ownership tracking, reporting, and force handling.
host-setup/​agent-safety/​claude/​README.md Documents the default subagent model setting, ownership rules, and guard behavior.
host-setup/​agent-safety/​claude/​model-tier-guard.py Loads inheriting agent types and refuses unsupported untiered dispatches.
host-setup/​agent-safety/​claude/​install.py Installs, records, reports, and preserves the configured default subagent model.
AGENTS.md Updates model-tier, delegation, and away-mode guidance.
.github/​skills/​local-strict-review/​SKILL.md Regenerates the carried Model Tiers guidance.
.github/​skills/​decision-triage/​SKILL.md Regenerates the carried Model Tiers guidance.
.github/​skills/​backlog-burndown/​SKILL.md Adds away-mode guidance and regenerates Model Tiers content.
.claude-plugin/​fleet-skills/​skills/​local-strict-review/​SKILL.md Updates the generated Claude Skill distribution for local strict review.
.claude-plugin/​fleet-skills/​skills/​decision-triage/​SKILL.md Updates the generated Claude Skill distribution for decision triage.
.claude-plugin/​fleet-skills/​skills/​backlog-burndown/​SKILL.md Updates the generated Claude Skill distribution for backlog burndown.
.claude-plugin/​fleet-skills/​.source-digests/​local-strict-review Updates the generated source digest for local strict review.
.claude-plugin/​fleet-skills/​.source-digests/​decision-triage Updates the generated source digest for decision triage.
.claude-plugin/​fleet-skills/​.source-digests/​backlog-burndown Updates the generated source digest for backlog burndown.
.agents/​skills/​local-strict-review/​SKILL.md Updates the authored local strict review guidance.
.agents/​skills/​decision-triage/​SKILL.md Updates the authored decision triage guidance.
.agents/​skills/​backlog-burndown/​SKILL.md Adds authored away-mode guidance and updates model-tier content.

Review effort: Lite

@codecov

codecov Bot commented Nov 19, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 18.60465% with 70 lines in your changes missing coverage. Please review.
✅ Project coverage is 78.89%. Comparing base (5d07823) to head (2f06400).
⚠️ Report is 2 commits behind head on develop.

Files with missing lines Patch % Lines
host-setup/agent-safety/claude/install.py 15.66% 70 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #4283      +/-   ##
===========================================
- Coverage    79.21%   78.89%   -0.32%     
===========================================
  Files           42       42              
  Lines        15502    15582      +80     
===========================================
+ Hits         12280    12294      +14     
- Misses        3222     3288      +66     
Flag Coverage Δ
python-3.13 78.89% <18.60%> (-0.32%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@ptr727

ptr727 commented Nov 19, 2026

Copy link
Copy Markdown
Owner Author

@coderabbitai review

@ptr727

ptr727 commented Nov 19, 2026

Copy link
Copy Markdown
Owner Author

/review

@coderabbitai

coderabbitai Bot commented Nov 19, 2026 •

Copy link
Copy Markdown
Action not completed

Review rate limited.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@ptr727
ptr727 merged commit f5cd85d into develop Nov 19, 2026
14 checks passed
@ptr727
ptr727 deleted the feature/subagent-default-model branch November 19, 2026 16:28
ptr727 added a commit that referenced this pull request Nov 19, 2026
…red-Path Edges (#4290)

## Summary

Promotes `develop` to `main`. It carries these changes:

- [#4283](#4283) defaults
subagents to the `frontier` tier and refuses an untiered `Explore` or
`Plan` dispatch.
- **Installer default.** The Claude Code safety kit sets the default
subagent model to the model of the default tier, records it in its
stamp, and leaves a host's own value alone.
- **Guard refusal.** The tier guard denies a no-model dispatch of an
agent type that inherits the session's model.
- [#4287](#4287) drops the
unreachable end-of-refill signal from the `backlog-burndown` lean
orchestrator.
- [#4286](#4286) closes
latent edges in the retired-path checks. The remaining edges are filed
as #4285.
- [#4288](#4288) reports
downstream copies when a whole tree declaration is dropped.

Closes #4278
Closes #4273
Closes #4272

🤖 Generated with [Claude Code](https://claude.com/claude-code)
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.

2 participants