vectorvein 0.2.76__tar.gz → 0.2.77__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {vectorvein-0.2.76 → vectorvein-0.2.77}/PKG-INFO +1 -1
- {vectorvein-0.2.76 → vectorvein-0.2.77}/pyproject.toml +1 -1
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/utils.py +1 -1
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/types/defaults.py +142 -18
- {vectorvein-0.2.76 → vectorvein-0.2.77}/README.md +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/__init__.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/api/__init__.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/api/client.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/api/exceptions.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/api/models.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/__init__.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/anthropic_client.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/baichuan_client.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/base_client.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/deepseek_client.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/ernie_client.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/gemini_client.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/groq_client.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/local_client.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/minimax_client.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/mistral_client.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/moonshot_client.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/openai_client.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/openai_compatible_client.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/py.typed +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/qwen_client.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/stepfun_client.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/xai_client.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/yi_client.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/zhipuai_client.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/py.typed +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/server/token_server.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/settings/__init__.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/settings/py.typed +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/types/__init__.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/types/enums.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/types/exception.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/types/llm_parameters.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/types/py.typed +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/types/settings.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/utilities/media_processing.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/utilities/rate_limiter.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/utilities/retry.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/graph/edge.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/graph/node.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/graph/port.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/graph/workflow.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/nodes/__init__.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/nodes/audio_generation.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/nodes/control_flows.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/nodes/file_processing.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/nodes/image_generation.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/nodes/llms.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/nodes/media_editing.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/nodes/media_processing.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/nodes/output.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/nodes/relational_db.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/nodes/text_processing.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/nodes/tools.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/nodes/triggers.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/nodes/vector_db.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/nodes/video_generation.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/nodes/web_crawlers.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/utils/analyse.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/utils/check.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/utils/json_to_code.py +0 -0
- {vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/workflow/utils/layout.py +0 -0
@@ -158,7 +158,7 @@ def get_token_counts(text: str | dict, model: str = "", use_token_server_first:
|
|
158
158
|
return 1000
|
159
159
|
result = response.json()
|
160
160
|
return result["segments_num"]
|
161
|
-
elif model.startswith("moonshot"):
|
161
|
+
elif model.startswith(("moonshot", "kimi")):
|
162
162
|
backend_setting = settings.get_backend(BackendType.Moonshot).models[model]
|
163
163
|
if len(backend_setting.endpoints) == 0:
|
164
164
|
return len(get_gpt_35_encoding().encode(text))
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# @Author: Bi Ying
|
2
2
|
# @Date: 2024-07-27 00:02:34
|
3
|
-
from typing import Final, Dict,
|
3
|
+
from typing import Final, Dict, TypedDict, NotRequired
|
4
4
|
|
5
5
|
from .enums import ContextLengthControlType
|
6
6
|
|
@@ -12,26 +12,39 @@ ENDPOINT_TPM: Final[int] = 300000
|
|
12
12
|
|
13
13
|
MODEL_CONTEXT_LENGTH: Final[int] = 32768
|
14
14
|
|
15
|
+
|
16
|
+
class ModelSettingDict(TypedDict):
|
17
|
+
id: str
|
18
|
+
function_call_available: bool
|
19
|
+
response_format_available: bool
|
20
|
+
native_multimodal: bool
|
21
|
+
context_length: int
|
22
|
+
max_output_tokens: NotRequired[int]
|
23
|
+
|
24
|
+
|
15
25
|
# Moonshot models
|
16
|
-
MOONSHOT_DEFAULT_MODEL: Final[str] = "
|
17
|
-
MOONSHOT_MODELS: Final[Dict[str,
|
26
|
+
MOONSHOT_DEFAULT_MODEL: Final[str] = "kimi-latest"
|
27
|
+
MOONSHOT_MODELS: Final[Dict[str, ModelSettingDict]] = {
|
18
28
|
"moonshot-v1-8k": {
|
19
29
|
"id": "moonshot-v1-8k",
|
20
30
|
"context_length": 8192,
|
21
31
|
"function_call_available": True,
|
22
32
|
"response_format_available": True,
|
33
|
+
"native_multimodal": False,
|
23
34
|
},
|
24
35
|
"moonshot-v1-32k": {
|
25
36
|
"id": "moonshot-v1-32k",
|
26
37
|
"context_length": 32768,
|
27
38
|
"function_call_available": True,
|
28
39
|
"response_format_available": True,
|
40
|
+
"native_multimodal": False,
|
29
41
|
},
|
30
42
|
"moonshot-v1-128k": {
|
31
43
|
"id": "moonshot-v1-128k",
|
32
44
|
"context_length": 131072,
|
33
45
|
"function_call_available": True,
|
34
46
|
"response_format_available": True,
|
47
|
+
"native_multimodal": False,
|
35
48
|
},
|
36
49
|
"moonshot-v1-8k-vision-preview": {
|
37
50
|
"id": "moonshot-v1-8k-vision-preview",
|
@@ -55,17 +68,25 @@ MOONSHOT_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
55
68
|
"response_format_available": True,
|
56
69
|
"native_multimodal": True,
|
57
70
|
},
|
71
|
+
"kimi-latest": {
|
72
|
+
"id": "kimi-latest",
|
73
|
+
"context_length": 131072,
|
74
|
+
"function_call_available": True,
|
75
|
+
"response_format_available": True,
|
76
|
+
"native_multimodal": True,
|
77
|
+
},
|
58
78
|
}
|
59
79
|
|
60
80
|
# Deepseek models
|
61
81
|
DEEPSEEK_DEFAULT_MODEL: Final[str] = "deepseek-chat"
|
62
|
-
DEEPSEEK_MODELS: Final[Dict[str,
|
82
|
+
DEEPSEEK_MODELS: Final[Dict[str, ModelSettingDict]] = {
|
63
83
|
"deepseek-chat": {
|
64
84
|
"id": "deepseek-chat",
|
65
85
|
"context_length": 64000,
|
66
86
|
"max_output_tokens": 8192,
|
67
87
|
"function_call_available": True,
|
68
88
|
"response_format_available": True,
|
89
|
+
"native_multimodal": False,
|
69
90
|
},
|
70
91
|
"deepseek-reasoner": {
|
71
92
|
"id": "deepseek-reasoner",
|
@@ -73,18 +94,20 @@ DEEPSEEK_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
73
94
|
"max_output_tokens": 8192,
|
74
95
|
"function_call_available": False,
|
75
96
|
"response_format_available": False,
|
97
|
+
"native_multimodal": False,
|
76
98
|
},
|
77
99
|
}
|
78
100
|
|
79
101
|
# Baichuan models
|
80
102
|
BAICHUAN_DEFAULT_MODEL: Final[str] = "Baichuan3-Turbo"
|
81
|
-
BAICHUAN_MODELS: Final[Dict[str,
|
103
|
+
BAICHUAN_MODELS: Final[Dict[str, ModelSettingDict]] = {
|
82
104
|
"Baichuan4": {
|
83
105
|
"id": "Baichuan4",
|
84
106
|
"context_length": 32768,
|
85
107
|
"max_output_tokens": 2048,
|
86
108
|
"function_call_available": True,
|
87
109
|
"response_format_available": True,
|
110
|
+
"native_multimodal": False,
|
88
111
|
},
|
89
112
|
"Baichuan3-Turbo": {
|
90
113
|
"id": "Baichuan3-Turbo",
|
@@ -92,6 +115,7 @@ BAICHUAN_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
92
115
|
"max_output_tokens": 2048,
|
93
116
|
"function_call_available": True,
|
94
117
|
"response_format_available": True,
|
118
|
+
"native_multimodal": False,
|
95
119
|
},
|
96
120
|
"Baichuan3-Turbo-128k": {
|
97
121
|
"id": "Baichuan3-Turbo-128k",
|
@@ -99,6 +123,7 @@ BAICHUAN_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
99
123
|
"max_output_tokens": 2048,
|
100
124
|
"function_call_available": True,
|
101
125
|
"response_format_available": True,
|
126
|
+
"native_multimodal": False,
|
102
127
|
},
|
103
128
|
"Baichuan2-Turbo": {
|
104
129
|
"id": "Baichuan2-Turbo",
|
@@ -106,6 +131,7 @@ BAICHUAN_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
106
131
|
"max_output_tokens": 2048,
|
107
132
|
"function_call_available": True,
|
108
133
|
"response_format_available": False,
|
134
|
+
"native_multimodal": False,
|
109
135
|
},
|
110
136
|
"Baichuan2-53B": {
|
111
137
|
"id": "Baichuan2-53B",
|
@@ -113,75 +139,92 @@ BAICHUAN_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
113
139
|
"max_output_tokens": 2048,
|
114
140
|
"function_call_available": False,
|
115
141
|
"response_format_available": False,
|
142
|
+
"native_multimodal": False,
|
116
143
|
},
|
117
144
|
}
|
118
145
|
|
119
146
|
# Groq models
|
120
147
|
GROQ_DEFAULT_MODEL: Final[str] = "llama3-70b-8192"
|
121
|
-
GROQ_MODELS: Final[Dict[str,
|
148
|
+
GROQ_MODELS: Final[Dict[str, ModelSettingDict]] = {
|
122
149
|
"mixtral-8x7b-32768": {
|
123
150
|
"id": "mixtral-8x7b-32768",
|
124
151
|
"context_length": 32768,
|
125
152
|
"function_call_available": True,
|
126
153
|
"response_format_available": True,
|
154
|
+
"native_multimodal": False,
|
127
155
|
},
|
128
156
|
"llama3-70b-8192": {
|
129
157
|
"id": "llama3-70b-8192",
|
130
158
|
"context_length": 8192,
|
131
159
|
"function_call_available": True,
|
132
160
|
"response_format_available": True,
|
161
|
+
"native_multimodal": False,
|
133
162
|
},
|
134
163
|
"llama3-8b-8192": {
|
135
164
|
"id": "llama3-8b-8192",
|
136
165
|
"context_length": 8192,
|
137
166
|
"function_call_available": True,
|
138
167
|
"response_format_available": True,
|
168
|
+
"native_multimodal": False,
|
139
169
|
},
|
140
170
|
"gemma-7b-it": {
|
141
171
|
"id": "gemma-7b-it",
|
142
172
|
"context_length": 8192,
|
143
173
|
"function_call_available": True,
|
144
174
|
"response_format_available": True,
|
175
|
+
"native_multimodal": False,
|
145
176
|
},
|
146
177
|
"gemma2-9b-it": {
|
147
178
|
"id": "gemma2-9b-it",
|
148
179
|
"context_length": 8192,
|
180
|
+
"function_call_available": True,
|
181
|
+
"response_format_available": True,
|
182
|
+
"native_multimodal": False,
|
149
183
|
},
|
150
184
|
"llama3-groq-70b-8192-tool-use-preview": {
|
151
185
|
"id": "llama3-groq-70b-8192-tool-use-preview",
|
152
186
|
"context_length": 8192,
|
153
187
|
"function_call_available": True,
|
188
|
+
"response_format_available": True,
|
154
189
|
"max_output_tokens": 8000,
|
190
|
+
"native_multimodal": False,
|
155
191
|
},
|
156
192
|
"llama3-groq-8b-8192-tool-use-preview": {
|
157
193
|
"id": "llama3-groq-8b-8192-tool-use-preview",
|
158
194
|
"context_length": 8192,
|
159
195
|
"function_call_available": True,
|
196
|
+
"response_format_available": True,
|
160
197
|
"max_output_tokens": 8000,
|
198
|
+
"native_multimodal": False,
|
161
199
|
},
|
162
200
|
"llama-3.1-70b-versatile": {
|
163
201
|
"id": "llama-3.1-70b-versatile",
|
164
202
|
"context_length": 131072,
|
165
203
|
"function_call_available": True,
|
204
|
+
"response_format_available": True,
|
166
205
|
"max_output_tokens": 8000,
|
206
|
+
"native_multimodal": False,
|
167
207
|
},
|
168
208
|
"llama-3.1-8b-instant": {
|
169
209
|
"id": "llama-3.1-8b-instant",
|
170
210
|
"context_length": 131072,
|
171
211
|
"function_call_available": True,
|
212
|
+
"response_format_available": True,
|
172
213
|
"max_output_tokens": 8000,
|
214
|
+
"native_multimodal": False,
|
173
215
|
},
|
174
216
|
}
|
175
217
|
|
176
218
|
# Qwen models
|
177
219
|
QWEN_DEFAULT_MODEL: Final[str] = "qwen2.5-72b-instruct"
|
178
|
-
QWEN_MODELS: Final[Dict[str,
|
220
|
+
QWEN_MODELS: Final[Dict[str, ModelSettingDict]] = {
|
179
221
|
"qwen2.5-7b-instruct": {
|
180
222
|
"id": "qwen2.5-7b-instruct",
|
181
223
|
"context_length": 131072,
|
182
224
|
"max_output_tokens": 8192,
|
183
225
|
"function_call_available": True,
|
184
226
|
"response_format_available": True,
|
227
|
+
"native_multimodal": False,
|
185
228
|
},
|
186
229
|
"qwen2.5-14b-instruct": {
|
187
230
|
"id": "qwen2.5-14b-instruct",
|
@@ -189,6 +232,7 @@ QWEN_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
189
232
|
"max_output_tokens": 8192,
|
190
233
|
"function_call_available": True,
|
191
234
|
"response_format_available": True,
|
235
|
+
"native_multimodal": False,
|
192
236
|
},
|
193
237
|
"qwen2.5-32b-instruct": {
|
194
238
|
"id": "qwen2.5-32b-instruct",
|
@@ -196,6 +240,7 @@ QWEN_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
196
240
|
"max_output_tokens": 8192,
|
197
241
|
"function_call_available": True,
|
198
242
|
"response_format_available": True,
|
243
|
+
"native_multimodal": False,
|
199
244
|
},
|
200
245
|
"qwen2.5-coder-32b-instruct": {
|
201
246
|
"id": "qwen2.5-coder-32b-instruct",
|
@@ -203,6 +248,7 @@ QWEN_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
203
248
|
"max_output_tokens": 4096,
|
204
249
|
"function_call_available": False,
|
205
250
|
"response_format_available": False,
|
251
|
+
"native_multimodal": False,
|
206
252
|
},
|
207
253
|
"qwq-32b": {
|
208
254
|
"id": "qwq-32b",
|
@@ -210,6 +256,7 @@ QWEN_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
210
256
|
"max_output_tokens": 8192,
|
211
257
|
"function_call_available": False,
|
212
258
|
"response_format_available": False,
|
259
|
+
"native_multimodal": False,
|
213
260
|
},
|
214
261
|
"qwen2.5-72b-instruct": {
|
215
262
|
"id": "qwen2.5-72b-instruct",
|
@@ -217,6 +264,7 @@ QWEN_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
217
264
|
"max_output_tokens": 8192,
|
218
265
|
"function_call_available": True,
|
219
266
|
"response_format_available": True,
|
267
|
+
"native_multimodal": False,
|
220
268
|
},
|
221
269
|
"qwen2-vl-72b-instruct": {
|
222
270
|
"id": "qwen2-vl-72b-instruct",
|
@@ -256,6 +304,7 @@ QWEN_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
256
304
|
"max_output_tokens": 2048,
|
257
305
|
"function_call_available": True,
|
258
306
|
"response_format_available": True,
|
307
|
+
"native_multimodal": False,
|
259
308
|
},
|
260
309
|
"qwen-max-longcontext": {
|
261
310
|
"id": "qwen-max-longcontext",
|
@@ -263,6 +312,7 @@ QWEN_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
263
312
|
"max_output_tokens": 2048,
|
264
313
|
"function_call_available": True,
|
265
314
|
"response_format_available": True,
|
315
|
+
"native_multimodal": False,
|
266
316
|
},
|
267
317
|
"qwen-plus": {
|
268
318
|
"id": "qwen-plus",
|
@@ -270,6 +320,7 @@ QWEN_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
270
320
|
"max_output_tokens": 8096,
|
271
321
|
"function_call_available": True,
|
272
322
|
"response_format_available": True,
|
323
|
+
"native_multimodal": False,
|
273
324
|
},
|
274
325
|
"qwen-turbo": {
|
275
326
|
"id": "qwen-turbo",
|
@@ -277,6 +328,7 @@ QWEN_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
277
328
|
"max_output_tokens": 1500,
|
278
329
|
"function_call_available": True,
|
279
330
|
"response_format_available": True,
|
331
|
+
"native_multimodal": False,
|
280
332
|
},
|
281
333
|
"qvq-max": {
|
282
334
|
"id": "qvq-max",
|
@@ -290,13 +342,14 @@ QWEN_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
290
342
|
|
291
343
|
# Yi models
|
292
344
|
YI_DEFAULT_MODEL: Final[str] = "yi-lightning"
|
293
|
-
YI_MODELS: Final[Dict[str,
|
345
|
+
YI_MODELS: Final[Dict[str, ModelSettingDict]] = {
|
294
346
|
"yi-lightning": {
|
295
347
|
"id": "yi-lightning",
|
296
348
|
"context_length": 16000,
|
297
349
|
"max_output_tokens": 4096,
|
298
350
|
"function_call_available": False,
|
299
351
|
"response_format_available": False,
|
352
|
+
"native_multimodal": False,
|
300
353
|
},
|
301
354
|
"yi-vision-v2": {
|
302
355
|
"id": "yi-vision-v2",
|
@@ -310,13 +363,14 @@ YI_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
310
363
|
|
311
364
|
# ZhiPuAI models
|
312
365
|
ZHIPUAI_DEFAULT_MODEL: Final[str] = "glm-4-air"
|
313
|
-
ZHIPUAI_MODELS: Final[Dict[str,
|
366
|
+
ZHIPUAI_MODELS: Final[Dict[str, ModelSettingDict]] = {
|
314
367
|
"glm-3-turbo": {
|
315
368
|
"id": "glm-3-turbo",
|
316
369
|
"context_length": 128000,
|
317
370
|
"function_call_available": True,
|
318
371
|
"response_format_available": False,
|
319
372
|
"max_output_tokens": 4095,
|
373
|
+
"native_multimodal": False,
|
320
374
|
},
|
321
375
|
"glm-4": {
|
322
376
|
"id": "glm-4",
|
@@ -324,6 +378,7 @@ ZHIPUAI_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
324
378
|
"function_call_available": True,
|
325
379
|
"response_format_available": False,
|
326
380
|
"max_output_tokens": 4095,
|
381
|
+
"native_multimodal": False,
|
327
382
|
},
|
328
383
|
"glm-4-plus": {
|
329
384
|
"id": "glm-4-plus",
|
@@ -331,6 +386,7 @@ ZHIPUAI_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
331
386
|
"function_call_available": True,
|
332
387
|
"response_format_available": False,
|
333
388
|
"max_output_tokens": 4095,
|
389
|
+
"native_multimodal": False,
|
334
390
|
},
|
335
391
|
"glm-4-0520": {
|
336
392
|
"id": "glm-4-0520",
|
@@ -338,6 +394,7 @@ ZHIPUAI_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
338
394
|
"function_call_available": True,
|
339
395
|
"response_format_available": False,
|
340
396
|
"max_output_tokens": 4095,
|
397
|
+
"native_multimodal": False,
|
341
398
|
},
|
342
399
|
"glm-4-air": {
|
343
400
|
"id": "glm-4-air",
|
@@ -345,6 +402,7 @@ ZHIPUAI_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
345
402
|
"function_call_available": True,
|
346
403
|
"response_format_available": False,
|
347
404
|
"max_output_tokens": 4095,
|
405
|
+
"native_multimodal": False,
|
348
406
|
},
|
349
407
|
"glm-4-airx": {
|
350
408
|
"id": "glm-4-airx",
|
@@ -352,6 +410,7 @@ ZHIPUAI_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
352
410
|
"function_call_available": True,
|
353
411
|
"response_format_available": False,
|
354
412
|
"max_output_tokens": 4095,
|
413
|
+
"native_multimodal": False,
|
355
414
|
},
|
356
415
|
"glm-4-flash": {
|
357
416
|
"id": "glm-4-flash",
|
@@ -359,6 +418,7 @@ ZHIPUAI_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
359
418
|
"function_call_available": True,
|
360
419
|
"response_format_available": False,
|
361
420
|
"max_output_tokens": 4095,
|
421
|
+
"native_multimodal": False,
|
362
422
|
},
|
363
423
|
"glm-4-long": {
|
364
424
|
"id": "glm-4-long",
|
@@ -366,6 +426,7 @@ ZHIPUAI_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
366
426
|
"function_call_available": True,
|
367
427
|
"response_format_available": False,
|
368
428
|
"max_output_tokens": 4095,
|
429
|
+
"native_multimodal": False,
|
369
430
|
},
|
370
431
|
"glm-4v": {
|
371
432
|
"id": "glm-4v",
|
@@ -411,66 +472,75 @@ ZHIPUAI_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
411
472
|
|
412
473
|
# Mistral models
|
413
474
|
MISTRAL_DEFAULT_MODEL: Final[str] = "mistral-small"
|
414
|
-
MISTRAL_MODELS: Final[Dict[str,
|
475
|
+
MISTRAL_MODELS: Final[Dict[str, ModelSettingDict]] = {
|
415
476
|
"open-mistral-7b": {
|
416
477
|
"id": "open-mistral-7b",
|
417
478
|
"context_length": 32000,
|
418
479
|
"function_call_available": False,
|
419
480
|
"response_format_available": True,
|
481
|
+
"native_multimodal": False,
|
420
482
|
},
|
421
483
|
"open-mixtral-8x7b": {
|
422
484
|
"id": "open-mixtral-8x7b",
|
423
485
|
"context_length": 32000,
|
424
486
|
"function_call_available": False,
|
425
487
|
"response_format_available": True,
|
488
|
+
"native_multimodal": False,
|
426
489
|
},
|
427
490
|
"open-mixtral-8x22b": {
|
428
491
|
"id": "open-mixtral-8x22b",
|
429
492
|
"context_length": 64000,
|
430
493
|
"function_call_available": True,
|
431
494
|
"response_format_available": True,
|
495
|
+
"native_multimodal": False,
|
432
496
|
},
|
433
497
|
"open-mistral-nemo": {
|
434
498
|
"id": "open-mistral-nemo",
|
435
499
|
"context_length": 128000,
|
436
500
|
"function_call_available": False,
|
437
501
|
"response_format_available": True,
|
502
|
+
"native_multimodal": False,
|
438
503
|
},
|
439
504
|
"codestral-latest": {
|
440
505
|
"id": "codestral-latest",
|
441
506
|
"context_length": 32000,
|
442
507
|
"function_call_available": False,
|
443
508
|
"response_format_available": True,
|
509
|
+
"native_multimodal": False,
|
444
510
|
},
|
445
511
|
"mistral-small-latest": {
|
446
512
|
"id": "mistral-small-latest",
|
447
513
|
"context_length": 30000,
|
448
514
|
"function_call_available": True,
|
449
515
|
"response_format_available": True,
|
516
|
+
"native_multimodal": False,
|
450
517
|
},
|
451
518
|
"mistral-medium-latest": {
|
452
519
|
"id": "mistral-medium-latest",
|
453
520
|
"context_length": 30000,
|
454
521
|
"function_call_available": False,
|
455
522
|
"response_format_available": True,
|
523
|
+
"native_multimodal": False,
|
456
524
|
},
|
457
525
|
"mistral-large-latest": {
|
458
526
|
"id": "mistral-large-latest",
|
459
527
|
"context_length": 128000,
|
460
528
|
"function_call_available": True,
|
461
529
|
"response_format_available": True,
|
530
|
+
"native_multimodal": False,
|
462
531
|
},
|
463
532
|
}
|
464
533
|
|
465
534
|
# OpenAI models
|
466
535
|
OPENAI_DEFAULT_MODEL: Final[str] = "gpt-4o"
|
467
|
-
OPENAI_MODELS: Final[Dict[str,
|
536
|
+
OPENAI_MODELS: Final[Dict[str, ModelSettingDict]] = {
|
468
537
|
"gpt-35-turbo": {
|
469
538
|
"id": "gpt-35-turbo",
|
470
539
|
"context_length": 16385,
|
471
540
|
"function_call_available": True,
|
472
541
|
"response_format_available": True,
|
473
542
|
"max_output_tokens": 4096,
|
543
|
+
"native_multimodal": False,
|
474
544
|
},
|
475
545
|
"gpt-4-turbo": {
|
476
546
|
"id": "gpt-4-turbo",
|
@@ -478,6 +548,7 @@ OPENAI_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
478
548
|
"max_output_tokens": 4096,
|
479
549
|
"function_call_available": True,
|
480
550
|
"response_format_available": True,
|
551
|
+
"native_multimodal": False,
|
481
552
|
},
|
482
553
|
"gpt-4": {
|
483
554
|
"id": "gpt-4",
|
@@ -485,6 +556,7 @@ OPENAI_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
485
556
|
"max_output_tokens": 4096,
|
486
557
|
"function_call_available": True,
|
487
558
|
"response_format_available": True,
|
559
|
+
"native_multimodal": False,
|
488
560
|
},
|
489
561
|
"gpt-4o": {
|
490
562
|
"id": "gpt-4o",
|
@@ -508,6 +580,7 @@ OPENAI_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
508
580
|
"max_output_tokens": 4096,
|
509
581
|
"function_call_available": True,
|
510
582
|
"response_format_available": True,
|
583
|
+
"native_multimodal": True,
|
511
584
|
},
|
512
585
|
"o1-mini": {
|
513
586
|
"id": "o1-mini",
|
@@ -536,8 +609,8 @@ OPENAI_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
536
609
|
}
|
537
610
|
|
538
611
|
# Anthropic models
|
539
|
-
ANTHROPIC_DEFAULT_MODEL: Final[str] = "claude-3-
|
540
|
-
ANTHROPIC_MODELS: Final[Dict[str,
|
612
|
+
ANTHROPIC_DEFAULT_MODEL: Final[str] = "claude-3-7-sonnet-20250219"
|
613
|
+
ANTHROPIC_MODELS: Final[Dict[str, ModelSettingDict]] = {
|
541
614
|
"claude-3-opus-20240229": {
|
542
615
|
"id": "claude-3-opus-20240229",
|
543
616
|
"context_length": 200000,
|
@@ -598,13 +671,14 @@ ANTHROPIC_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
598
671
|
|
599
672
|
# Minimax models
|
600
673
|
MINIMAX_DEFAULT_MODEL: Final[str] = "MiniMax-Text-01"
|
601
|
-
MINIMAX_MODELS: Final[Dict[str,
|
674
|
+
MINIMAX_MODELS: Final[Dict[str, ModelSettingDict]] = {
|
602
675
|
"abab5-chat": {
|
603
676
|
"id": "abab5-chat",
|
604
677
|
"context_length": 6144,
|
605
678
|
"max_output_tokens": 6144,
|
606
679
|
"function_call_available": True,
|
607
680
|
"response_format_available": True,
|
681
|
+
"native_multimodal": False,
|
608
682
|
},
|
609
683
|
"abab5.5-chat": {
|
610
684
|
"id": "abab5.5-chat",
|
@@ -612,6 +686,7 @@ MINIMAX_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
612
686
|
"max_output_tokens": 16384,
|
613
687
|
"function_call_available": True,
|
614
688
|
"response_format_available": True,
|
689
|
+
"native_multimodal": False,
|
615
690
|
},
|
616
691
|
"abab6-chat": {
|
617
692
|
"id": "abab6-chat",
|
@@ -619,6 +694,7 @@ MINIMAX_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
619
694
|
"max_output_tokens": 32768,
|
620
695
|
"function_call_available": True,
|
621
696
|
"response_format_available": True,
|
697
|
+
"native_multimodal": False,
|
622
698
|
},
|
623
699
|
"abab6.5s-chat": {
|
624
700
|
"id": "abab6.5s-chat",
|
@@ -626,6 +702,7 @@ MINIMAX_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
626
702
|
"max_output_tokens": 245760,
|
627
703
|
"function_call_available": True,
|
628
704
|
"response_format_available": True,
|
705
|
+
"native_multimodal": False,
|
629
706
|
},
|
630
707
|
"abab7-preview": {
|
631
708
|
"id": "abab7-preview",
|
@@ -633,6 +710,7 @@ MINIMAX_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
633
710
|
"max_output_tokens": 245760,
|
634
711
|
"function_call_available": True,
|
635
712
|
"response_format_available": True,
|
713
|
+
"native_multimodal": False,
|
636
714
|
},
|
637
715
|
"MiniMax-Text-01": {
|
638
716
|
"id": "MiniMax-Text-01",
|
@@ -640,12 +718,13 @@ MINIMAX_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
640
718
|
"max_output_tokens": 1000192,
|
641
719
|
"function_call_available": True,
|
642
720
|
"response_format_available": True,
|
721
|
+
"native_multimodal": False,
|
643
722
|
},
|
644
723
|
}
|
645
724
|
|
646
725
|
# Gemini models
|
647
726
|
GEMINI_DEFAULT_MODEL: Final[str] = "gemini-2.0-flash"
|
648
|
-
GEMINI_MODELS: Final[Dict[str,
|
727
|
+
GEMINI_MODELS: Final[Dict[str, ModelSettingDict]] = {
|
649
728
|
"gemini-1.5-pro": {
|
650
729
|
"id": "gemini-1.5-pro",
|
651
730
|
"context_length": 2097152,
|
@@ -737,13 +816,14 @@ GEMINI_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
737
816
|
|
738
817
|
# 百度文心一言 ERNIE 模型
|
739
818
|
ERNIE_DEFAULT_MODEL: Final[str] = "ernie-lite"
|
740
|
-
ERNIE_MODELS: Final[Dict[str,
|
819
|
+
ERNIE_MODELS: Final[Dict[str, ModelSettingDict]] = {
|
741
820
|
"ernie-lite": {
|
742
821
|
"id": "ernie-lite",
|
743
822
|
"context_length": 6144,
|
744
823
|
"max_output_tokens": 2048,
|
745
824
|
"function_call_available": False,
|
746
825
|
"response_format_available": False,
|
826
|
+
"native_multimodal": False,
|
747
827
|
},
|
748
828
|
"ernie-speed": {
|
749
829
|
"id": "ernie-speed",
|
@@ -751,6 +831,7 @@ ERNIE_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
751
831
|
"max_output_tokens": 4096,
|
752
832
|
"function_call_available": False,
|
753
833
|
"response_format_available": False,
|
834
|
+
"native_multimodal": False,
|
754
835
|
},
|
755
836
|
"ernie-speed-pro-128k": {
|
756
837
|
"id": "ernie-speed-pro-128k",
|
@@ -758,6 +839,7 @@ ERNIE_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
758
839
|
"max_output_tokens": 4096,
|
759
840
|
"function_call_available": False,
|
760
841
|
"response_format_available": False,
|
842
|
+
"native_multimodal": False,
|
761
843
|
},
|
762
844
|
"ernie-3.5-8k": {
|
763
845
|
"id": "ernie-3.5-8k",
|
@@ -765,6 +847,7 @@ ERNIE_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
765
847
|
"max_output_tokens": 2048,
|
766
848
|
"function_call_available": True,
|
767
849
|
"response_format_available": True,
|
850
|
+
"native_multimodal": False,
|
768
851
|
},
|
769
852
|
"ernie-3.5-128k": {
|
770
853
|
"id": "ernie-3.5-128k",
|
@@ -772,6 +855,7 @@ ERNIE_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
772
855
|
"max_output_tokens": 8192,
|
773
856
|
"function_call_available": True,
|
774
857
|
"response_format_available": True,
|
858
|
+
"native_multimodal": False,
|
775
859
|
},
|
776
860
|
"ernie-4.0-8k-latest": {
|
777
861
|
"id": "ernie-4.0-8k-latest",
|
@@ -779,6 +863,7 @@ ERNIE_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
779
863
|
"max_output_tokens": 2048,
|
780
864
|
"function_call_available": True,
|
781
865
|
"response_format_available": True,
|
866
|
+
"native_multimodal": False,
|
782
867
|
},
|
783
868
|
"ernie-4.0-8k": {
|
784
869
|
"id": "ernie-4.0-8k",
|
@@ -786,6 +871,7 @@ ERNIE_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
786
871
|
"max_output_tokens": 2048,
|
787
872
|
"function_call_available": True,
|
788
873
|
"response_format_available": True,
|
874
|
+
"native_multimodal": False,
|
789
875
|
},
|
790
876
|
"ernie-4.0-turbo-8k": {
|
791
877
|
"id": "ernie-4.0-turbo-8k",
|
@@ -793,6 +879,7 @@ ERNIE_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
793
879
|
"max_output_tokens": 2048,
|
794
880
|
"function_call_available": False,
|
795
881
|
"response_format_available": True,
|
882
|
+
"native_multimodal": False,
|
796
883
|
},
|
797
884
|
"ernie-4.5-8k-preview": {
|
798
885
|
"id": "ernie-4.5-8k-preview",
|
@@ -800,47 +887,54 @@ ERNIE_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
800
887
|
"max_output_tokens": 2048,
|
801
888
|
"function_call_available": False,
|
802
889
|
"response_format_available": True,
|
890
|
+
"native_multimodal": False,
|
803
891
|
},
|
804
892
|
}
|
805
893
|
|
806
894
|
|
807
895
|
STEPFUN_DEFAULT_MODEL: Final[str] = "step-1-8k"
|
808
|
-
STEPFUN_MODELS: Final[Dict[str,
|
896
|
+
STEPFUN_MODELS: Final[Dict[str, ModelSettingDict]] = {
|
809
897
|
"step-1-8k": {
|
810
898
|
"id": "step-1-8k",
|
811
899
|
"context_length": 8192,
|
812
900
|
"function_call_available": True,
|
813
901
|
"response_format_available": True,
|
902
|
+
"native_multimodal": False,
|
814
903
|
},
|
815
904
|
"step-1-32k": {
|
816
905
|
"id": "step-1-32k",
|
817
906
|
"context_length": 32000,
|
818
907
|
"function_call_available": True,
|
819
908
|
"response_format_available": True,
|
909
|
+
"native_multimodal": False,
|
820
910
|
},
|
821
911
|
"step-1-128k": {
|
822
912
|
"id": "step-1-128k",
|
823
913
|
"context_length": 128000,
|
824
914
|
"function_call_available": True,
|
825
915
|
"response_format_available": True,
|
916
|
+
"native_multimodal": False,
|
826
917
|
},
|
827
918
|
"step-1-256k": {
|
828
919
|
"id": "step-1-256k",
|
829
920
|
"context_length": 256000,
|
830
921
|
"function_call_available": True,
|
831
922
|
"response_format_available": True,
|
923
|
+
"native_multimodal": False,
|
832
924
|
},
|
833
925
|
"step-2-16k": {
|
834
926
|
"id": "step-2-16k",
|
835
927
|
"context_length": 16384,
|
836
928
|
"function_call_available": True,
|
837
929
|
"response_format_available": True,
|
930
|
+
"native_multimodal": False,
|
838
931
|
},
|
839
932
|
"step-1-flash": {
|
840
933
|
"id": "step-1-flash",
|
841
934
|
"context_length": 8192,
|
842
935
|
"function_call_available": True,
|
843
936
|
"response_format_available": True,
|
937
|
+
"native_multimodal": False,
|
844
938
|
},
|
845
939
|
"step-1v-8k": {
|
846
940
|
"id": "step-1v-8k",
|
@@ -860,18 +954,20 @@ STEPFUN_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
860
954
|
|
861
955
|
|
862
956
|
XAI_DEFAULT_MODEL: Final[str] = "grok-2-latest"
|
863
|
-
XAI_MODELS: Final[Dict[str,
|
957
|
+
XAI_MODELS: Final[Dict[str, ModelSettingDict]] = {
|
864
958
|
"grok-beta": {
|
865
959
|
"id": "grok-beta",
|
866
960
|
"context_length": 131072,
|
867
961
|
"function_call_available": True,
|
868
962
|
"response_format_available": True,
|
963
|
+
"native_multimodal": False,
|
869
964
|
},
|
870
965
|
"grok-2-latest": {
|
871
966
|
"id": "grok-2-latest",
|
872
967
|
"context_length": 131072,
|
873
968
|
"function_call_available": True,
|
874
969
|
"response_format_available": True,
|
970
|
+
"native_multimodal": False,
|
875
971
|
},
|
876
972
|
"grok-2-vision-latest": {
|
877
973
|
"id": "grok-2-vision-latest",
|
@@ -880,4 +976,32 @@ XAI_MODELS: Final[Dict[str, Dict[str, Any]]] = {
|
|
880
976
|
"response_format_available": True,
|
881
977
|
"native_multimodal": True,
|
882
978
|
},
|
979
|
+
"grok-3-beta": {
|
980
|
+
"id": "grok-beta",
|
981
|
+
"context_length": 131072,
|
982
|
+
"function_call_available": True,
|
983
|
+
"response_format_available": True,
|
984
|
+
"native_multimodal": False,
|
985
|
+
},
|
986
|
+
"grok-3-fast-beta": {
|
987
|
+
"id": "grok-beta",
|
988
|
+
"context_length": 131072,
|
989
|
+
"function_call_available": True,
|
990
|
+
"response_format_available": True,
|
991
|
+
"native_multimodal": False,
|
992
|
+
},
|
993
|
+
"grok-3-mini-beta": {
|
994
|
+
"id": "grok-beta",
|
995
|
+
"context_length": 131072,
|
996
|
+
"function_call_available": True,
|
997
|
+
"response_format_available": True,
|
998
|
+
"native_multimodal": False,
|
999
|
+
},
|
1000
|
+
"grok-3-mini-fast-beta": {
|
1001
|
+
"id": "grok-beta",
|
1002
|
+
"context_length": 131072,
|
1003
|
+
"function_call_available": True,
|
1004
|
+
"response_format_available": True,
|
1005
|
+
"native_multimodal": False,
|
1006
|
+
},
|
883
1007
|
}
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{vectorvein-0.2.76 → vectorvein-0.2.77}/src/vectorvein/chat_clients/openai_compatible_client.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|