fix(models): isModelError 识别「issue with the selected model」→ 触发回退链
线上实测:reviewer 用 fable-5 报「There's an issue with the selected model (claude-fable-5)」(该档未对当前账号开通),但 isModelError 未命中此措辞 → 不回退 → 复审失败(verdict=null)。补正则后 fable-5 不可用会自动回退 opus 重试,复审正常。 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -94,6 +94,8 @@ test('isModelError:模型不可用类错误才触发回退', () => {
|
||||
assert.ok(isModelError('404 model does not exist'));
|
||||
assert.ok(isModelError('The requested model is unavailable'));
|
||||
assert.ok(isModelError('unknown model "claude-fable-5"'));
|
||||
// Claude Code 的「未开通某档模型」报错(线上 fable-5 实测)
|
||||
assert.ok(isModelError("There's an issue with the selected model (claude-fable-5)"));
|
||||
// 不应触发
|
||||
assert.ok(!isModelError('执行超时'));
|
||||
assert.ok(!isModelError('network connection refused'));
|
||||
|
||||
Reference in New Issue
Block a user