diff options
author | Tekky <98614666+xtekky@users.noreply.github.com> | 2024-09-16 00:37:30 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-09-16 00:37:30 +0200 |
commit | cc80f2d3159ca0b6f6bfa2c36c4be87bc96209b2 (patch) | |
tree | 25ef52b8c5496ca22ce8eaa82bc885313962ba29 /g4f/Provider/HuggingChat.py | |
parent | Merge pull request #2207 from kqlio67/main (diff) | |
parent | refactor(ReplicateHome): update model handling and API interaction (diff) | |
download | gpt4free-cc80f2d3159ca0b6f6bfa2c36c4be87bc96209b2.tar gpt4free-cc80f2d3159ca0b6f6bfa2c36c4be87bc96209b2.tar.gz gpt4free-cc80f2d3159ca0b6f6bfa2c36c4be87bc96209b2.tar.bz2 gpt4free-cc80f2d3159ca0b6f6bfa2c36c4be87bc96209b2.tar.lz gpt4free-cc80f2d3159ca0b6f6bfa2c36c4be87bc96209b2.tar.xz gpt4free-cc80f2d3159ca0b6f6bfa2c36c4be87bc96209b2.tar.zst gpt4free-cc80f2d3159ca0b6f6bfa2c36c4be87bc96209b2.zip |
Diffstat (limited to 'g4f/Provider/HuggingChat.py')
-rw-r--r-- | g4f/Provider/HuggingChat.py | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/g4f/Provider/HuggingChat.py b/g4f/Provider/HuggingChat.py index 76c76a35..06216ade 100644 --- a/g4f/Provider/HuggingChat.py +++ b/g4f/Provider/HuggingChat.py @@ -12,24 +12,21 @@ class HuggingChat(AbstractProvider, ProviderModelMixin): working = True supports_stream = True default_model = "meta-llama/Meta-Llama-3.1-70B-Instruct" + models = [ 'meta-llama/Meta-Llama-3.1-70B-Instruct', - 'meta-llama/Meta-Llama-3.1-405B-Instruct-FP8', - 'CohereForAI/c4ai-command-r-plus', + 'CohereForAI/c4ai-command-r-plus-08-2024', 'mistralai/Mixtral-8x7B-Instruct-v0.1', 'NousResearch/Nous-Hermes-2-Mixtral-8x7B-DPO', - '01-ai/Yi-1.5-34B-Chat', 'mistralai/Mistral-7B-Instruct-v0.3', 'microsoft/Phi-3-mini-4k-instruct', ] model_aliases = { "llama-3.1-70b": "meta-llama/Meta-Llama-3.1-70B-Instruct", - "llama-3.1-405b": "meta-llama/Meta-Llama-3.1-405B-Instruct-FP8", - "command-r-plus": "CohereForAI/c4ai-command-r-plus", + "command-r-plus": "CohereForAI/c4ai-command-r-plus-08-2024", "mixtral-8x7b": "mistralai/Mixtral-8x7B-Instruct-v0.1", - "mixtral-8x7b": "NousResearch/Nous-Hermes-2-Mixtral-8x7B-DPO", - "yi-1.5-34b": "01-ai/Yi-1.5-34B-Chat", + "mixtral-8x7b-dpo": "NousResearch/Nous-Hermes-2-Mixtral-8x7B-DPO", "mistral-7b": "mistralai/Mistral-7B-Instruct-v0.3", "phi-3-mini-4k": "microsoft/Phi-3-mini-4k-instruct", } @@ -80,7 +77,7 @@ class HuggingChat(AbstractProvider, ProviderModelMixin): response = session.post('https://huggingface.co/chat/conversation', json=json_data) conversationId = response.json()['conversationId'] - response = session.get(f'https://huggingface.co/chat/conversation/{conversationId}/__data.json?x-sveltekit-invalidated=01',) + response = session.get(f'https://huggingface.co/chat/conversation/{conversationId}/__data.json?x-sveltekit-invalidated=11',) data: list = (response.json())["nodes"][1]["data"] keys: list[int] = data[data[0]["messages"]] |