mangalathkedar commited on
Commit
9f3e8e6
·
verified ·
1 Parent(s): a07544d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -67,7 +67,7 @@ def analyze_image(image):
67
  base64_image = base64.b64encode(img_byte_arr).decode("utf-8")
68
 
69
  response = client.chat.completions.create(
70
- model="gpt-4o-mini",
71
  messages=[
72
  {
73
  "role": "user",
@@ -131,5 +131,5 @@ def main():
131
  result = analyze_image(image)
132
  st.markdown(format_response(result))
133
 
134
- if __name__ == "__main__":
135
- main()
 
67
  base64_image = base64.b64encode(img_byte_arr).decode("utf-8")
68
 
69
  response = client.chat.completions.create(
70
+ model="gpt-4o-mini", # Update to the correct model name
71
  messages=[
72
  {
73
  "role": "user",
 
131
  result = analyze_image(image)
132
  st.markdown(format_response(result))
133
 
134
+ # Call the main function directly (no need for __name__ == "__main__" in Hugging Face Spaces)
135
+ main()