diff options
author | H Lohaus <hlohaus@users.noreply.github.com> | 2024-02-24 21:06:46 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-02-24 21:06:46 +0100 |
commit | 369ea621143b870626c2b5d7e1abb1a5007785db (patch) | |
tree | d2dffb31047dc2e12ee70e51f6ebe8f2afa69131 /g4f/Provider | |
parent | Merge pull request #1622 from hlohaus/gem (diff) | |
parent | DeepInfra: Add max_tokens and stop (diff) | |
download | gpt4free-369ea621143b870626c2b5d7e1abb1a5007785db.tar gpt4free-369ea621143b870626c2b5d7e1abb1a5007785db.tar.gz gpt4free-369ea621143b870626c2b5d7e1abb1a5007785db.tar.bz2 gpt4free-369ea621143b870626c2b5d7e1abb1a5007785db.tar.lz gpt4free-369ea621143b870626c2b5d7e1abb1a5007785db.tar.xz gpt4free-369ea621143b870626c2b5d7e1abb1a5007785db.tar.zst gpt4free-369ea621143b870626c2b5d7e1abb1a5007785db.zip |
Diffstat (limited to '')
-rw-r--r-- | g4f/Provider/DeepInfra.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/g4f/Provider/DeepInfra.py b/g4f/Provider/DeepInfra.py index 183f00ea..f44679ff 100644 --- a/g4f/Provider/DeepInfra.py +++ b/g4f/Provider/DeepInfra.py @@ -61,6 +61,8 @@ class DeepInfra(AsyncGeneratorProvider, ProviderModelMixin): 'model' : cls.get_model(model), 'messages': messages, 'temperature': kwargs.get("temperature", 0.7), + 'max_tokens': kwargs.get("max_tokens", 512), + 'stop': kwargs.get("stop", []), 'stream' : True } async with session.post('https://api.deepinfra.com/v1/openai/chat/completions', |