diff options
author | abc <98614666+xtekky@users.noreply.github.com> | 2023-07-16 21:31:51 +0200 |
---|---|---|
committer | abc <98614666+xtekky@users.noreply.github.com> | 2023-07-16 21:31:51 +0200 |
commit | e9467297369dd4f429c084bd1d034f3b1b63e7c2 (patch) | |
tree | a8ef4184e60e226baf2dab207225ce8f52502c38 /g4f/Provider/Providers/H2o.py | |
parent | minor fixes (diff) | |
download | gpt4free-e9467297369dd4f429c084bd1d034f3b1b63e7c2.tar gpt4free-e9467297369dd4f429c084bd1d034f3b1b63e7c2.tar.gz gpt4free-e9467297369dd4f429c084bd1d034f3b1b63e7c2.tar.bz2 gpt4free-e9467297369dd4f429c084bd1d034f3b1b63e7c2.tar.lz gpt4free-e9467297369dd4f429c084bd1d034f3b1b63e7c2.tar.xz gpt4free-e9467297369dd4f429c084bd1d034f3b1b63e7c2.tar.zst gpt4free-e9467297369dd4f429c084bd1d034f3b1b63e7c2.zip |
Diffstat (limited to 'g4f/Provider/Providers/H2o.py')
-rw-r--r-- | g4f/Provider/Providers/H2o.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/g4f/Provider/Providers/H2o.py b/g4f/Provider/Providers/H2o.py index 4400f3a9..92043026 100644 --- a/g4f/Provider/Providers/H2o.py +++ b/g4f/Provider/Providers/H2o.py @@ -10,6 +10,7 @@ url = 'https://gpt-gm.h2o.ai' model = ['falcon-40b', 'falcon-7b', 'llama-13b']
supports_stream = True
needs_auth = False
+working = True
models = {
'falcon-7b': 'h2oai/h2ogpt-gm-oasst1-en-2048-falcon-7b-v3',
@@ -18,6 +19,7 @@ models = { }
def _create_completion(model: str, messages: list, stream: bool, **kwargs):
+
conversation = ''
for message in messages:
conversation += '%s: %s\n' % (message['role'], message['content'])
@@ -47,8 +49,6 @@ def _create_completion(model: str, messages: list, stream: bool, **kwargs): }
response = session.post("https://gpt-gm.h2o.ai/settings", headers=headers, data=data)
-
-
headers = {
"User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:109.0) Gecko/20100101 Firefox/115.0",
"Accept": "*/*",
|