Skip to content

Commit 6a983fa

Browse files
committed
feat(caps): Fable 5 / 5.1 carry their 1M window under every id they arrive as
Fable reaches the composer two ways — through the gateway as the OpenRouter basename (dotted `claude-fable-5.1`) and BYOK-native as the dashed `claude-fable-5-1` — and neither had a row, so both fell to the claude-* heuristic's 200k: a fifth of the real window, and the meter sized every Fable conversation against it. Vision was already right by luck of the heuristic; the window was not. Three explicit rows, one per spelling. Matters more now that Fable 5 / 5.1 are Pro-tier on the gateway (thin.ly, 2026-09-08) rather than Max-only. Verified: catalog 15 tests (was 14); imageCost 9, imageAttach 30. Rows reverted -> the new test fails.
1 parent d44d6b3 commit 6a983fa

2 files changed

Lines changed: 12 additions & 0 deletions

File tree

extensions/levelcode-ai/providers/catalog.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,12 @@ const CAPS = {
2929
'claude-opus-4-8': { context: 200000, tools: true, vision: true, caching: true },
3030
'claude-sonnet-4-6': { context: 200000, tools: true, vision: true, caching: true },
3131
'claude-haiku-4-5-20251001': { context: 200000, tools: true, vision: true, fast: true },
32+
// Fable reaches the composer two ways: through the gateway as the OpenRouter basename (dotted
33+
// 5.1), and BYOK-native as the dashed id. Neither had a row, so both fell to the claude-*
34+
// heuristic's 200k — a fifth of the real window. Fable 5 / 5.1 are Pro-tier from 2026-09-08.
35+
'claude-fable-5': { context: 1000000, tools: true, vision: true, caching: true },
36+
'claude-fable-5.1': { context: 1000000, tools: true, vision: true, caching: true },
37+
'claude-fable-5-1': { context: 1000000, tools: true, vision: true, caching: true },
3238
// OpenAI
3339
'gpt-4o': { context: 128000, tools: true, vision: true },
3440
'gpt-4o-mini': { context: 128000, tools: true, vision: true, fast: true },

extensions/levelcode-ai/test/catalog.test.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,12 @@ test('modelCaps: gpt-6-astra is an explicit row, not the gpt-4/5 heuristic', ()
2727
assert.strictEqual(C.supportsVisionForModel('openai', 'gpt-6-astra'), true);
2828
assert.strictEqual(C.contextWindowFor('openai', 'gpt-6-astra'), 1050000);
2929
});
30+
test('modelCaps: Fable 5 / 5.1 carry the 1M window under every id they arrive as', () => {
31+
for (const id of ['anthropic/claude-fable-5', 'anthropic/claude-fable-5.1', 'claude-fable-5-1']) {
32+
assert.deepStrictEqual(C.modelCaps(id), { context: 1000000, tools: true, vision: true, caching: true }, id);
33+
assert.strictEqual(C.contextWindowFor('openai', id), 1000000, id);
34+
}
35+
});
3036
test('modelCaps: family heuristics for unknown ids', () => {
3137
assert.strictEqual(C.modelCaps('o4-mini').reasoning, true); // o-series
3238
assert.strictEqual(C.modelCaps('claude-3-5-haiku-latest').vision, true);

0 commit comments

Comments
 (0)