dindizz commited on
Commit
3700671
1 Parent(s): cc4df6b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -61,7 +61,7 @@ def analyze_ad(image):
61
  )
62
 
63
  # Extract the response text from the API output
64
- result = response['choices'][0]['message']['content']
65
 
66
  # Return the result for display
67
  return result
 
61
  )
62
 
63
  # Extract the response text from the API output
64
+ result = response.choices[0].message.content.strip()
65
 
66
  # Return the result for display
67
  return result