Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
|
@@ -87,9 +87,10 @@ RAW NOTE:
|
|
| 87 |
with torch.no_grad():
|
| 88 |
outputs = model.generate(
|
| 89 |
**inputs,
|
| 90 |
-
max_new_tokens=
|
| 91 |
temperature=0.1,
|
| 92 |
-
do_sample=True
|
|
|
|
| 93 |
)
|
| 94 |
|
| 95 |
text = tokenizer.batch_decode(outputs)[0]
|
|
@@ -143,10 +144,11 @@ PRIVATE_DB:
|
|
| 143 |
with torch.no_grad():
|
| 144 |
outputs = model.generate(
|
| 145 |
**inputs,
|
| 146 |
-
max_new_tokens=
|
| 147 |
temperature=0.1,
|
| 148 |
repetition_penalty=1.05,
|
| 149 |
-
do_sample=True
|
|
|
|
| 150 |
)
|
| 151 |
|
| 152 |
text = tokenizer.batch_decode(outputs)[0]
|
|
|
|
| 87 |
with torch.no_grad():
|
| 88 |
outputs = model.generate(
|
| 89 |
**inputs,
|
| 90 |
+
max_new_tokens=64,
|
| 91 |
temperature=0.1,
|
| 92 |
+
do_sample=True,
|
| 93 |
+
use_cache=False
|
| 94 |
)
|
| 95 |
|
| 96 |
text = tokenizer.batch_decode(outputs)[0]
|
|
|
|
| 144 |
with torch.no_grad():
|
| 145 |
outputs = model.generate(
|
| 146 |
**inputs,
|
| 147 |
+
max_new_tokens=256,
|
| 148 |
temperature=0.1,
|
| 149 |
repetition_penalty=1.05,
|
| 150 |
+
do_sample=True,
|
| 151 |
+
use_cache=False
|
| 152 |
)
|
| 153 |
|
| 154 |
text = tokenizer.batch_decode(outputs)[0]
|