From 5fd5eefbdb93fd0b9ff05e7463e15f5d48cb160e Mon Sep 17 00:00:00 2001 From: Vishnuvardhan Reddy Date: Thu, 26 Feb 2026 18:12:43 +0000 Subject: [PATCH] fix(provider): classify HTTP 404 as model error for fallback When a model returns 404 NOT_FOUND, treat it as FailoverModel so the fallback chain continues to the next model instead of failing completely. This fixes the issue where cerebras/gpt-oss-120b returning 404 was not triggering fallback to other models. --- pkg/providers/error_classifier.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pkg/providers/error_classifier.go b/pkg/providers/error_classifier.go index 96fa8675b..bc6aaee50 100644 --- a/pkg/providers/error_classifier.go +++ b/pkg/providers/error_classifier.go @@ -175,6 +175,8 @@ func classifyByStatus(status int) FailoverReason { return FailoverAuth case status == 402: return FailoverBilling + case status == 404: + return FailoverModel // Model not found case status == 408: return FailoverTimeout case status == 429: