diff options
| author | sigoden <sigoden@gmail.com> | 2024-02-13 13:07:23 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-02-13 13:07:23 +0800 |
| commit | 3bf0c371e407c8c6d03840cac6662ddfbbea484c (patch) | |
| tree | bd1ce7fd10debd910d6170c0dea9ace6ffb84511 /src/client | |
| parent | 25b27c148abd1fe0473304947c9b3a2194347326 (diff) | |
| download | aichat-3bf0c371e407c8c6d03840cac6662ddfbbea484c.tar.gz | |
feat: update openai/qianwen/gemini models (#306)
Diffstat (limited to 'src/client')
| -rw-r--r-- | src/client/gemini.rs | 3 | ||||
| -rw-r--r-- | src/client/openai.rs | 4 | ||||
| -rw-r--r-- | src/client/qianwen.rs | 3 |
3 files changed, 5 insertions, 5 deletions
diff --git a/src/client/gemini.rs b/src/client/gemini.rs index 6ff3f95..6f3141c 100644 --- a/src/client/gemini.rs +++ b/src/client/gemini.rs @@ -14,10 +14,9 @@ use serde_json::{json, Value}; const API_BASE: &str = "https://generativelanguage.googleapis.com/v1beta/models/"; -const MODELS: [(&str, usize, &str); 3] = [ +const MODELS: [(&str, usize, &str); 2] = [ ("gemini-pro", 32768, "text"), ("gemini-pro-vision", 16384, "vision"), - ("gemini-ultra", 32768, "text"), ]; const TOKENS_COUNT_FACTORS: TokensCountFactors = (5, 2); diff --git a/src/client/openai.rs b/src/client/openai.rs index cf6cc89..9c28473 100644 --- a/src/client/openai.rs +++ b/src/client/openai.rs @@ -13,12 +13,12 @@ use serde_json::{json, Value}; const API_BASE: &str = "https://api.openai.com/v1"; const MODELS: [(&str, usize, &str); 7] = [ - ("gpt-3.5-turbo", 4096, "text"), - ("gpt-3.5-turbo-16k", 16385, "text"), + ("gpt-3.5-turbo", 16385, "text"), ("gpt-3.5-turbo-1106", 16385, "text"), ("gpt-4", 8192, "text"), ("gpt-4-32k", 32768, "text"), ("gpt-4-1106-preview", 128000, "text"), + ("gpt-4-turbo-preview", 128000, "text"), ("gpt-4-vision-preview", 128000, "text,vision"), ]; diff --git a/src/client/qianwen.rs b/src/client/qianwen.rs index b9254ff..70c251a 100644 --- a/src/client/qianwen.rs +++ b/src/client/qianwen.rs @@ -24,12 +24,13 @@ const API_URL: &str = const API_URL_VL: &str = "https://dashscope.aliyuncs.com/api/v1/services/aigc/multimodal-generation/generation"; -const MODELS: [(&str, usize, &str); 5] = [ +const MODELS: [(&str, usize, &str); 6] = [ ("qwen-turbo", 8192, "text"), ("qwen-plus", 32768, "text"), ("qwen-max", 8192, "text"), ("qwen-max-longcontext", 30720, "text"), ("qwen-vl-plus", 0, "text,vision"), + ("qwen-vl-max", 0, "text,vision"), ]; #[derive(Debug, Clone, Deserialize, Default)] |
