Files changed (1) hide show
  1. app.py +1 -3
app.py CHANGED
@@ -54,10 +54,8 @@ def generate_question_with_chatgpt():
54
  response = requests.post(CHATGPT_API_ENDPOINT, json=data, headers=headers)
55
  result = response.json()
56
 
57
- return generated_question
58
-
59
  # Extract the generated question from the response
60
- generated_question = result["generated_question"]
61
  return generated_question
62
 
63
  def main():
 
54
  response = requests.post(CHATGPT_API_ENDPOINT, json=data, headers=headers)
55
  result = response.json()
56
 
 
 
57
  # Extract the generated question from the response
58
+ generated_question = result["choices"][0]["message"]["content"]
59
  return generated_question
60
 
61
  def main():