Spaces:
Runtime error
Runtime error
Allen Park
commited on
Commit
·
8275a94
1
Parent(s):
60ffe71
get rid of .to(device)
Browse files
app.py
CHANGED
|
@@ -31,7 +31,7 @@ Your output should be in JSON FORMAT with the keys "REASONING" and "SCORE":
|
|
| 31 |
@spaces.GPU()
|
| 32 |
def model_call(question, document, answer):
|
| 33 |
NEW_FORMAT = PROMPT.format(question=question, document=document, answer=answer)
|
| 34 |
-
inputs = tokenizer(NEW_FORMAT, return_tensors="pt")
|
| 35 |
model.generate(inputs.input_ids)
|
| 36 |
generated_text = tokenizer.decode(inputs.input_ids[0])
|
| 37 |
print(generated_text)
|
|
|
|
| 31 |
@spaces.GPU()
|
| 32 |
def model_call(question, document, answer):
|
| 33 |
NEW_FORMAT = PROMPT.format(question=question, document=document, answer=answer)
|
| 34 |
+
inputs = tokenizer(NEW_FORMAT, return_tensors="pt")
|
| 35 |
model.generate(inputs.input_ids)
|
| 36 |
generated_text = tokenizer.decode(inputs.input_ids[0])
|
| 37 |
print(generated_text)
|