mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2025-06-05 21:59:27 +02:00
Add gpt-4.5-preview
This commit is contained in:
@ -2867,6 +2867,10 @@
|
||||
<option value="o3-mini">o3-mini</option>
|
||||
<option value="o3-mini-2025-01-31">o3-mini-2025-01-31</option>
|
||||
</optgroup>
|
||||
<optgroup label="GPT-4.5">
|
||||
<option value="gpt-4.5-preview">gpt-4.5-preview</option>
|
||||
<option value="gpt-4.5-preview-2025-02-27">gpt-4.5-preview-2025-02-27</option>
|
||||
</optgroup>
|
||||
<optgroup label="GPT-4 Turbo and GPT-4">
|
||||
<option value="gpt-4-turbo">gpt-4-turbo</option>
|
||||
<option value="gpt-4-turbo-2024-04-09">gpt-4-turbo-2024-04-09</option>
|
||||
|
@ -1945,7 +1945,7 @@ async function sendOpenAIRequest(type, messages, signal) {
|
||||
}
|
||||
|
||||
// Remove logit bias, logprobs 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')) {
|
||||
if (isOAI && oai_settings.openai_model.includes('vision') || isOpenRouter && oai_settings.openrouter_model.includes('vision') || isOAI && oai_settings.openai_model.includes('gpt-4.5-preview')) {
|
||||
delete generate_data.logit_bias;
|
||||
delete generate_data.stop;
|
||||
delete generate_data.logprobs;
|
||||
@ -4997,6 +4997,8 @@ export function isImageInliningSupported() {
|
||||
'gpt-4-turbo',
|
||||
'gpt-4o',
|
||||
'gpt-4o-mini',
|
||||
'gpt-4.5-preview',
|
||||
'gpt-4.5-preview-2025-02-27',
|
||||
'o1',
|
||||
'o1-2024-12-17',
|
||||
'chatgpt-4o-latest',
|
||||
|
@ -108,6 +108,7 @@ export function isHiddenReasoningModel() {
|
||||
|
||||
/** @type {{ name: string; func: MatchingFunc; }[]} */
|
||||
const hiddenReasoningModels = [
|
||||
{ name: 'gpt-4.5', func: FUNCS.startsWith },
|
||||
{ name: 'o1', func: FUNCS.startsWith },
|
||||
{ name: 'o3', func: FUNCS.startsWith },
|
||||
{ name: 'gemini-2.0-flash-thinking-exp', func: FUNCS.startsWith },
|
||||
|
@ -410,6 +410,10 @@ export function getTokenizerModel(requestModel) {
|
||||
return 'gpt-4o';
|
||||
}
|
||||
|
||||
if (requestModel.includes('gpt-4.5-preview')) {
|
||||
return 'gpt-4o';
|
||||
}
|
||||
|
||||
if (requestModel.includes('gpt-4-32k')) {
|
||||
return 'gpt-4-32k';
|
||||
}
|
||||
|
Reference in New Issue
Block a user