Always remove logit bias and stop from vision

This commit is contained in:
Cohee 2023-12-24 20:01:59 +02:00
parent a9e074dae1
commit f8dece9d88
1 changed files with 3 additions and 2 deletions

View File

@ -1556,9 +1556,10 @@ async function sendOpenAIRequest(type, messages, signal) {
delete generate_data.stop;
}
// Vision models don't support logit bias
if (isImageInliningSupported()) {
// Remove logit bias and stop strings if it's not supported by the model
if (isOAI && oai_settings.openai_model.includes('vision') || isOpenRouter && oai_settings.openrouter_model.includes('vision')) {
delete generate_data.logit_bias;
delete generate_data.stop;
}
// Proxy is only supported for Claude and OpenAI