Update app.py
Browse files
app.py
CHANGED
@@ -15,8 +15,8 @@ print (pipe(messages1) )
|
|
15 |
"""
|
16 |
For more information on `huggingface_hub` Inference API support, please check the docs: https://huggingface.co/docs/huggingface_hub/v0.22.2/en/guides/inference
|
17 |
"""
|
18 |
-
client = InferenceClient(model="google/recurrentgemma-2b-it")
|
19 |
-
|
20 |
|
21 |
def respond(
|
22 |
message,
|
@@ -38,7 +38,7 @@ def respond(
|
|
38 |
|
39 |
response = ""
|
40 |
|
41 |
-
for message in client
|
42 |
messages,
|
43 |
max_tokens=max_tokens,
|
44 |
stream=False,
|
|
|
15 |
"""
|
16 |
For more information on `huggingface_hub` Inference API support, please check the docs: https://huggingface.co/docs/huggingface_hub/v0.22.2/en/guides/inference
|
17 |
"""
|
18 |
+
#client = InferenceClient(model="google/recurrentgemma-2b-it")
|
19 |
+
client = pipeline("text-generation", model="google/recurrentgemma-2b-it")
|
20 |
|
21 |
def respond(
|
22 |
message,
|
|
|
38 |
|
39 |
response = ""
|
40 |
|
41 |
+
for message in client(
|
42 |
messages,
|
43 |
max_tokens=max_tokens,
|
44 |
stream=False,
|