Commit Graph

1 Commits

Author SHA1 Message Date
Edward Cheng-I Wu 48bde6a0b1 feat(tiering): #517 model tiering — judgment/execution split, two opt-in directions, default untouched (#520)
* feat(tiering): #517 model tiering — judgment/execution split, two opt-in directions, default untouched

One tiering mechanism per the frozen #517 design (Lance Martin, "Cost
effective harnesses with Fable", 2026-07-10):

- Default (ARS_MODEL_TIERING unset): byte-equivalent — every agent stays
  model: inherit. Same opt-in philosophy as terminal_policies.
- economy (frontier session): 13 execution-type agents dispatch one tier
  below the session model, floor Opus-class, never Sonnet; draft_writer
  flagged as the highest-savings / most quality-sensitive downgrade.
- quality-boost (below-frontier session): judgment-type agents at the
  Stage 2.5/4.5 gates + final-review surfaces step up to the frontier
  tier; nothing is ever downgraded.
- Both directions carry explicit no-op announcements; unknown values
  warn once and behave as unset. Tiers are relative positions, never
  hard-pinned model ids (v3.7.0 opus-floor lesson).

Classification: 39 agents (26 judgment / 13 execution; issue header's
25/12 arithmetic corrected, membership unchanged) in
scripts/model_tiering_manifest.json + the canonical table in
shared/model_tiering.md, pinned to each other and to the *_agent.md
files on disk by scripts/check_model_tiering.py (11 mutation tests;
wired into spec-consistency.yml + local pytest manifest, 60 -> 61).

Consumers: compact "## Model Tiering (#517, optional)" block in the four
SKILL.md files; SETUP en/zh-TW env-table rows; prompt-caching guidance
(same-stage calls reuse the same worker) in the canonical doc.

No agent-file edits (sha256-locked bibliography_agent.md untouched),
no schema change, no hook.

Spec: docs/design/2026-07-12-517-model-tiering-spec.md
All CI lints + 61-entry pytest manifest green locally.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FczvB1WJjfumdJTg9YyL3X

* fix(tiering): #517 round-1 codex fixes — dispatch-as-subagent mechanism, exact-set lint, caching scope, wording unification

Addresses the round-1 codex review (2 P1 + 6 P2; 2 no-change with reasons):

- P1 routing reality: canonical doc now states the mechanism honestly —
  a tier is selectable only at subagent dispatch; when a direction
  applies to an inline role, the session dispatches it as a subagent
  pinned to the target tier (that IS the mechanism); impossible-dispatch
  falls open to inline-on-session-model with a one-line announcement.
  PERFORMANCE.md en/zh "no separate model routing layer" reconciled.
- P2 caching-vs-default: same-worker guidance scoped to active
  directions; unset default byte-equivalent incl. dispatch shapes.
- P2 semantics drift: quality-boost = jump TO the frontier (not one
  increment); warn-once wording unified; SETUP rows name the
  final-review surfaces.
- P2 lint subset-only + hardcoded dirs: exact per-(tier,skill)
  token-set comparison (missing/extra/duplicate tokens, per-row counts,
  duplicate rows) + repo-wide stray sweep; tests 11 -> 15.
- P2 stale verification record: 60 -> 61 manifest entries in the spec.
- No-change (documented): the PR-body session link is the repo's
  established harness attribution convention (48 occurrences in recent
  main history); Lance Martin/Anthropic is published-source author
  attribution consistent with the repo's citation norm.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FczvB1WJjfumdJTg9YyL3X

* fix(tiering): #517 round-2 codex fixes — dispatch-time tier resolver, claim-ref audit surface, Stage 3' roster, PERFORMANCE cost qualification

- P1 tier resolver: new "Resolving a tier at dispatch time" section — the
  no-hard-pinning rule governs repo files; the dispatch call resolves the
  relative target from the runtime's own model information (alias or
  current-generation id, ephemeral only); unresolvable -> announced no-op.
- P1 claim_ref_alignment_audit: quality-boost surface corrected to its
  real dispatch slot (opt-in Stage 4->5, ARS_CLAIM_AUDIT=1), removed from
  the 2.5/4.5 gate list; SKILL blocks + SETUP rows updated.
- P2 Stage 3' roster: canonical text now matches ARCHITECTURE (narrow
  re-review team; judgment roles there = eic + editorial_synthesizer);
  caching example rewritten accordingly.
- P2 PERFORMANCE en/zh: plugin-agent cost-unchanged claim qualified with
  the unset condition + economy behavior for plugin-exposed execution
  agents (report_compiler).
- P2 PR body refreshed (dispatch-as-subagent wording, 15 tests).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FczvB1WJjfumdJTg9YyL3X

* fix(tiering): #517 round-3 P2 residuals — caching example covers the full 3' narrow team; PR body audit surface

- Caching example names the authoritative Stage 3' re-review roster
  (field_analyst + eic + editorial_synthesizer) and states the reuse
  rule is tier-independent — field_analyst is the economy-affected role.
- PR body quality-boost bullet gains the opt-in Stage 4→5 claim-ref
  audit surface (was omitted after the round-2 canonical correction).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FczvB1WJjfumdJTg9YyL3X

---------

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
2026-07-12 03:51:12 +08:00