Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -10,8 +10,9 @@ headers = {
|
|
10 |
|
11 |
def rank(uri, options):
|
12 |
matches = []
|
13 |
-
for option in options
|
14 |
matches.append({"text": option})
|
|
|
15 |
payload = json.dumps({
|
16 |
"data": [
|
17 |
{
|
@@ -23,7 +24,6 @@ def rank(uri, options):
|
|
23 |
})
|
24 |
|
25 |
response = requests.request("POST", url, headers=headers, data=payload)
|
26 |
-
|
27 |
return response.text
|
28 |
|
29 |
examples = [["https://picsum.photos/id/102/300/300", "three berry, four berries, ten berries"]]
|
|
|
10 |
|
11 |
def rank(uri, options):
|
12 |
matches = []
|
13 |
+
for option in options:
|
14 |
matches.append({"text": option})
|
15 |
+
|
16 |
payload = json.dumps({
|
17 |
"data": [
|
18 |
{
|
|
|
24 |
})
|
25 |
|
26 |
response = requests.request("POST", url, headers=headers, data=payload)
|
|
|
27 |
return response.text
|
28 |
|
29 |
examples = [["https://picsum.photos/id/102/300/300", "three berry, four berries, ten berries"]]
|