fix(api): skip preflight for unknown model limits

This commit is contained in:
Yeachan-Heo
2026-05-25 03:32:56 +00:00
committed by YeonGyu-Kim
parent e7d5d08892
commit bd9102f851

View File

@@ -640,14 +640,7 @@ pub fn model_token_limit(model: &str) -> Option<ModelTokenLimit> {
max_output_tokens: 16_384, max_output_tokens: 16_384,
context_window_tokens: 256_000, context_window_tokens: 256_000,
}), }),
// Hotfix: Unknown models get conservative defaults to avoid crashes. _ => None,
// Uses the minimum of known supported models: max_output_tokens: 16_384,
// context_window_tokens: 131_072. This may under-utilize the model's
// actual capabilities but hopefully ensures safer operation.
_ => Some(ModelTokenLimit {
max_output_tokens: 16_384,
context_window_tokens: 131_072,
}),
} }
} }