Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
rajkumarrrk
commited on
Commit
•
b90ce03
1
Parent(s):
3a77309
Update app.py
Browse files
app.py
CHANGED
@@ -29,7 +29,7 @@ template = Template(
|
|
29 |
def judge_reliability(document: str, conversation: str):
|
30 |
with torch.no_grad():
|
31 |
conversation = json.loads(conversation)
|
32 |
-
text = template.render(
|
33 |
print(text)
|
34 |
encoded = tokenizer([text], padding=True)
|
35 |
input_ids = torch.tensor(encoded.input_ids).to(device)
|
|
|
29 |
def judge_reliability(document: str, conversation: str):
|
30 |
with torch.no_grad():
|
31 |
conversation = json.loads(conversation)
|
32 |
+
text = template.render(document=document, conversation=conversation)
|
33 |
print(text)
|
34 |
encoded = tokenizer([text], padding=True)
|
35 |
input_ids = torch.tensor(encoded.input_ids).to(device)
|