Skip to content

feat(claude): add Claude Fable 5.1 model (cherry-pick upstream #9078) - #103

Merged
NoahHendrickson merged 1 commit into
customfrom
t3code/add-claude-fable-5-1
Sep 1, 2026
Merged

feat(claude): add Claude Fable 5.1 model (cherry-pick upstream #9078)#103
NoahHendrickson merged 1 commit into
customfrom
t3code/add-claude-fable-5-1

Conversation

@NoahHendrickson

@NoahHendrickson NoahHendrickson commented Sep 1, 2026

Copy link
Copy Markdown
Owner

Problem

Claude Code 2.1.257 shipped Claude Fable 5.1 (claude-fable-5-1), and the Claude provider's model catalog is hardcoded, so it needs a code change to appear.

Fix

Upstream landed pingdotgg#9078 (c17d02cff) right as the first version of this PR opened. This PR is now a clean cherry-pick of that commit onto custom — byte-identical to upstream, so the next daily sync merges without conflict. It brings:

  • The claude-fable-5-1 catalog entry (effort incl. ultracode, 200k/1M context window defaulting to 1M), gated on Claude Code >= 2.1.257.
  • The xhigh-effort allowlist entry, fable/fable-5.1/claude-fable-5.1 slug aliases in contracts, and the manifest update that marks Fable 5.1 current (and, per upstream's policy, demotes Fable 5 to legacy).
  • Upstream's tests for gating, effort, manifest classification, and aliases.

The earlier revision of this PR hand-rolled the same catalog change plus a fork-specific manifest-URL retarget; review feedback correctly flagged that upstream had already shipped, so the hand-rolled version and the now-unnecessary fork customization were dropped wholesale in favor of the cherry-pick.

Verification

  • vp test run on ModelManifest.test.ts, ProviderRegistry.test.ts, ClaudeAdapter.test.ts (131 passed) and packages/shared model.test.ts (7 passed).
  • Server and contracts typechecks clean; fork guard suite passes (377).

Babysat by Claude Fable 5 in Claude Code.

🤖 Generated with Claude Code

@github-actions github-actions Bot added vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. size:M labels Sep 1, 2026

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Do not approve. Behavior looks correct and the fork URL change is well-structured, but this misses an obvious code-judo move and grows an already-tangled version-policy ladder.

Adding Claude Fable 5.1 currently means cloning a catalog entry, a min-version constant, a supports* helper, a formatter, a filter branch, an xhigh allowlist entry, and a sixth nested-ternary rung. Those are the same fact restated seven times. A newest-first version-gate table deletes the helpers, the formatters, the slug if-chain, and the ternary. The next model is then a row, not another copy of this PR.

The 1k-line rule does not strictly apply: ClaudeProvider.ts was already 1021 lines and is now 1072. This PR did not cross the threshold. The table would still shrink the file instead of adding another ~50 lines of clones.

The ModelManifest URL retarget (fence, yaml intent, watch, guard test) is the right permanent fork divergence. Leave that. The unfenced catalog/manifest slug adds are the right last-resort shape if upstream is expected to supersede them. That fork hygiene does not excuse growing the version-policy spaghetti in the same change.

Open in Web View Automation 

Sent by Cursor Automation: Thermo nuke 4.6

Comment thread apps/server/src/provider/Layers/ClaudeProvider.ts
Comment thread apps/server/src/provider/Layers/ClaudeProvider.ts
@github-actions

github-actions Bot commented Sep 1, 2026

Copy link
Copy Markdown

Thread transfer impact

✅ Thread transfer remains within every enforced ceiling.

Provider Metric Main baseline This PR Impact PR ceiling
Codex Total thread wire 13.3 KiB 13.3 KiB −49 B (−0.4%) 15.1 KiB
Codex Thread snapshot wire 6.9 KiB 6.9 KiB −1 B (−0.0%) 7.3 KiB
Codex Live turn WebSocket wire 6.4 KiB 6.4 KiB −48 B (−0.7%) 7.8 KiB
Codex Live turn WebSocket decoded 55.6 KiB 55.5 KiB −44 B (−0.1%) 66.4 KiB
Codex Live turn messages 10 9 −1 (−10.0%) 21
Claude Total thread wire 13.3 KiB 13.3 KiB +31 B (+0.2%) 15.1 KiB
Claude Thread snapshot wire 6.9 KiB 6.9 KiB +7 B (+0.1%) 7.3 KiB
Claude Live turn WebSocket wire 6.4 KiB 6.4 KiB +24 B (+0.4%) 7.8 KiB
Claude Live turn WebSocket decoded 56.4 KiB 56.4 KiB +44 B (+0.1%) 66.4 KiB
Claude Live turn messages 10 11 +1 (+10.0%) 21

Baseline: bf51489 · PR result: b182a32 · Source CI: success

Scenario and decoded snapshot size

10 historical turns, 5 command tools per turn, 878.9 KiB retained MCP result per historical turn, and a 1.05 MiB retained result in the measured turn.

  • Codex decoded thread snapshot: 109.4 KiB
  • Claude decoded thread snapshot: 110.1 KiB

Updated in place by a trusted workflow. PR artifacts are strictly validated and never executed.

@NoahHendrickson NoahHendrickson left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

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

Review

The server-side change is correct and I found no runtime bug in it. The problem is the premise: upstream already shipped this. pingdotgg/t3code merged c17d02cff feat(claude): add Claude Fable 5.1 model (#9078) at 19:20Z; this PR opened at 19:26Z. Upstream's ClaudeProvider.ts hunk is byte-identical to yours (same 2.1.257 gate, same option surface, same ternary chain, same xhigh allowlist). Upstream's main manifest already serves ["claude-fable-5-1", "claude-opus-5", "claude-sonnet-5"]. So the stated reason for the URL repoint ("upstream's currentModels list has never heard of it") was already false when the PR was opened.

I simulated the next daily sync with git merge-tree <PR head> upstream/main. Result:

  • ClaudeProvider.ts, ClaudeAdapter.test.ts: merge cleanly to a single copy (identical hunks). Good.
  • model-manifest.json and ModelManifest.test.ts: conflict. Upstream's commit also demotes claude-fable-5 to legacy; this PR keeps it current.
  • ProviderRegistry.test.ts: auto-merges but ends up with two copies of both new tests, because you inserted them before "includes Claude Fable 5" and upstream inserted them after it.
  • Upstream also added fable / fable-5.1 / claude-fable-5.1 aliases in packages/contracts/src/model.ts; this PR has none.

Recommendation

Close this PR (or strip it to nothing) and take Fable 5.1 from the next claude/sync-* PR. That gets the catalog entry, the Fable 5 demotion, and the contracts aliases with zero fork divergence. If you want it on custom before the sync lands, cherry-pick c17d02cff so the later sync is a no-op.

The model-manifest-from-fork repoint should be dropped along with its guard and customizations.yaml entry. It now protects no real case (upstream has added every Claude model same-day: Opus 5, Fable 5, Fable 5.1), and it costs a permanent Tier 4 fence plus manifest freshness that is only as good as the last human-merged sync PR.

If there is a deliberate fork policy that claude-fable-5 should stay current after upstream demotes it, that is a separate customization that needs its own customizations.yaml entry and guard, not a side effect of this PR. Inline comments below cover what to fix if you keep any part of this.

Verification

  • Fetched upstream main and both live raw.githubusercontent.com manifests.
  • git merge-tree --write-tree 025e526e3 upstream/main and inspected the resulting ProviderRegistry.test.ts, model-manifest.json, ModelManifest.test.ts.
  • Read .fork/AGENTS.md fence/watch rules and the JSON-file precedents in customizations.yaml.

Reviewed by Claude Fable 5.1 in Claude Code.

Comment thread apps/server/src/provider/ModelManifest.ts Outdated
Comment thread apps/server/src/provider/model-manifest.json Outdated
Comment thread apps/server/src/provider/Layers/ProviderRegistry.test.ts Outdated
Comment thread apps/server/src/provider/ModelManifest.test.ts Outdated
Comment thread .fork/customizations.yaml Outdated
Comment thread apps/web/src/__fork_guards__/forkModelManifestSource.test.ts Outdated
Comment thread apps/server/src/provider/Layers/ClaudeProvider.ts
@NoahHendrickson NoahHendrickson changed the title feat(server): add Claude Fable 5.1 to the Claude model catalog feat(claude): add Claude Fable 5.1 model (cherry-pick upstream #9078) Sep 1, 2026
@NoahHendrickson
NoahHendrickson force-pushed the t3code/add-claude-fable-5-1 branch from 025e526 to b182a32 Compare September 1, 2026 20:08
@NoahHendrickson
NoahHendrickson merged commit a938f69 into custom Sep 1, 2026
20 checks passed
@NoahHendrickson
NoahHendrickson deleted the t3code/add-claude-fable-5-1 branch September 1, 2026 20:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:M vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants