From 58a62405a52fb91b7d90b96d19630b395d208662 Mon Sep 17 00:00:00 2001 From: Jing Hua Date: Tue, 30 Jan 2024 09:41:36 +0800 Subject: [PATCH] support gpt-3.5-turbo-0125 --- src/constants/chat.ts | 8 +++++++- src/types/chat.ts | 9 ++++++++- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/src/constants/chat.ts b/src/constants/chat.ts index fdfd1d568..6867aa9d3 100644 --- a/src/constants/chat.ts +++ b/src/constants/chat.ts @@ -21,9 +21,10 @@ export const modelOptions: ModelOptions[] = [ 'gpt-3.5-turbo', 'gpt-3.5-turbo-16k', 'gpt-3.5-turbo-1106', + 'gpt-3.5-turbo-0125', 'gpt-4', 'gpt-4-32k', - 'gpt-4-1106-preview' + 'gpt-4-1106-preview', // 'gpt-3.5-turbo-0301', // 'gpt-4-0314', // 'gpt-4-32k-0314', @@ -38,6 +39,7 @@ export const modelMaxToken = { 'gpt-3.5-turbo-16k': 16384, 'gpt-3.5-turbo-16k-0613': 16384, 'gpt-3.5-turbo-1106': 16384, + 'gpt-3.5-turbo-0125': 16384, 'gpt-4': 8192, 'gpt-4-0314': 8192, 'gpt-4-0613': 8192, @@ -72,6 +74,10 @@ export const modelCost = { prompt: { price: 0.001, unit: 1000 }, completion: { price: 0.0015, unit: 1000 }, }, + 'gpt-3.5-turbo-0125': { + prompt: { price: 0.0005, unit: 1000 }, + completion: { price: 0.0015, unit: 1000 }, + }, 'gpt-4': { prompt: { price: 0.03, unit: 1000 }, completion: { price: 0.06, unit: 1000 }, diff --git a/src/types/chat.ts b/src/types/chat.ts index ea37d8e2c..8f5aaa790 100644 --- a/src/types/chat.ts +++ b/src/types/chat.ts @@ -49,7 +49,14 @@ export interface Folder { color?: string; } -export type ModelOptions = 'gpt-4' | 'gpt-4-32k' | 'gpt-4-1106-preview' | 'gpt-3.5-turbo' | 'gpt-3.5-turbo-16k' | 'gpt-3.5-turbo-1106' ; +export type ModelOptions = + | 'gpt-4' + | 'gpt-4-32k' + | 'gpt-4-1106-preview' + | 'gpt-3.5-turbo' + | 'gpt-3.5-turbo-16k' + | 'gpt-3.5-turbo-1106' + | 'gpt-3.5-turbo-0125'; // | 'gpt-3.5-turbo-0301'; // | 'gpt-4-0314' // | 'gpt-4-32k-0314'