Spaces:
Runtime error
Runtime error
added more advanced params to request
Browse files
app.py
CHANGED
|
@@ -43,7 +43,10 @@ def predict(message, chatbot):
|
|
| 43 |
|
| 44 |
data = {
|
| 45 |
"inputs": input_prompt,
|
| 46 |
-
"parameters": {"max_new_tokens":256
|
|
|
|
|
|
|
|
|
|
| 47 |
}
|
| 48 |
|
| 49 |
response = requests.post(api_url, headers=headers, data=json.dumps(data), auth=('hf', hf_token), stream=True)
|
|
|
|
| 43 |
|
| 44 |
data = {
|
| 45 |
"inputs": input_prompt,
|
| 46 |
+
"parameters": {"max_new_tokens":256,
|
| 47 |
+
"do_sample":True,
|
| 48 |
+
"top_p":0.6,
|
| 49 |
+
"temperature":0.9,}
|
| 50 |
}
|
| 51 |
|
| 52 |
response = requests.post(api_url, headers=headers, data=json.dumps(data), auth=('hf', hf_token), stream=True)
|