Spaces:
Sleeping
Sleeping
Stardragon2099
commited on
Commit
·
1bbbb4e
1
Parent(s):
1896a77
ported to chatgpt api
Browse files
app.py
CHANGED
@@ -86,8 +86,7 @@ def predict(img, prompt):
|
|
86 |
try:
|
87 |
response = openai.ChatCompletion.create(
|
88 |
model="gpt-4o-mini",
|
89 |
-
messages=messages
|
90 |
-
files=[("file", file_id)]
|
91 |
)
|
92 |
return response['choices'][0]['message']['content']
|
93 |
except Exception as e:
|
|
|
86 |
try:
|
87 |
response = openai.ChatCompletion.create(
|
88 |
model="gpt-4o-mini",
|
89 |
+
messages=messages
|
|
|
90 |
)
|
91 |
return response['choices'][0]['message']['content']
|
92 |
except Exception as e:
|