返回提交历史
Modified
g4f/Provider/Blackbox.py
+1
-2
Modified
g4f/Provider/HuggingChat.py
+2
-0
Modified
g4f/models.py
+1
-1
XFEstudio/gpt4free
feat(g4f/Provider/HuggingChat.): add Qwen2.5-72B model and alias
a6099ba4
代码差异
3 个文件
+4
-3
@@ -154,7 +154,6 @@ class Blackbox(AsyncGeneratorProvider, ProviderModelMixin):
154
154
async for chunk in response.content.iter_any():
155
155
if chunk:
156
156
decoded_chunk = chunk.decode()
157
# Видаляємо префікс $@$v=v1.10-rv1$@$ та інші подібні
158
157
decoded_chunk = re.sub(r'\$@\$v=[^$]+\$@\$', '', decoded_chunk)
159
if decoded_chunk.strip(): # Перевіряємо, чи залишився якийсь текст після видалення префікса
158
if decoded_chunk.strip():
160
159
yield decoded_chunk
@@ -16,6 +16,7 @@ class HuggingChat(AbstractProvider, ProviderModelMixin):
16
16
models = [
17
17
'meta-llama/Meta-Llama-3.1-70B-Instruct',
18
18
'CohereForAI/c4ai-command-r-plus-08-2024',
19
'Qwen/Qwen2.5-72B-Instruct',
19
20
'mistralai/Mixtral-8x7B-Instruct-v0.1',
20
21
'NousResearch/Nous-Hermes-2-Mixtral-8x7B-DPO',
21
22
'mistralai/Mistral-7B-Instruct-v0.3',
@@ -25,6 +26,7 @@ class HuggingChat(AbstractProvider, ProviderModelMixin):
25
26
model_aliases = {
26
27
"llama-3.1-70b": "meta-llama/Meta-Llama-3.1-70B-Instruct",
27
28
"command-r-plus": "CohereForAI/c4ai-command-r-plus-08-2024",
29
"qwen-2-72b": "Qwen/Qwen2.5-72B-Instruct",
28
30
"mixtral-8x7b": "mistralai/Mixtral-8x7B-Instruct-v0.1",
29
31
"mixtral-8x7b-dpo": "NousResearch/Nous-Hermes-2-Mixtral-8x7B-DPO",
30
32
"mistral-7b": "mistralai/Mistral-7B-Instruct-v0.3",
@@ -443,7 +443,7 @@ qwen_1_5_110b = Model(
443
443
qwen_2_72b = Model(
444
444
name = 'qwen-2-72b',
445
445
base_provider = 'Qwen',
446
best_provider = IterListProvider([DeepInfraChat, Airforce])
446
best_provider = IterListProvider([DeepInfraChat, HuggingChat, Airforce, HuggingFace])
447
447
)
448
448
449
449
qwen_turbo = Model(