Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -73,11 +73,13 @@ def ai_judge(sentence1: str, sentence2: str) -> float:
|
|
73 |
|
74 |
data = helper({
|
75 |
"source_sentence": sentence1,
|
76 |
-
"sentences": [sentence2],
|
77 |
"parameters": {}
|
78 |
})
|
79 |
|
80 |
-
|
|
|
|
|
81 |
|
82 |
|
83 |
def query(payload: Dict[str, Any]) -> Dict[str, Any]:
|
|
|
73 |
|
74 |
data = helper({
|
75 |
"source_sentence": sentence1,
|
76 |
+
"sentences": [sentence2, sentence2],
|
77 |
"parameters": {}
|
78 |
})
|
79 |
|
80 |
+
result = data['similarities'][0]
|
81 |
+
|
82 |
+
return result
|
83 |
|
84 |
|
85 |
def query(payload: Dict[str, Any]) -> Dict[str, Any]:
|