mou3az commited on
Commit
d467c6f
·
verified ·
1 Parent(s): c5d80ea

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -1,4 +1,4 @@
1
- from flask import Flask, render_template, request, jsonify
2
  from huggingface_hub import InferenceClient
3
  from requests.exceptions import RequestException
4
 
@@ -52,7 +52,7 @@ def generate_quiz_page():
52
  response = generate_quiz(context)
53
 
54
  if request.headers.get('Content-Type') == 'application/json':
55
- return jsonify(response)
56
 
57
 
58
  quiz_html = f"""
 
1
+ from flask import Flask, request, jsonify
2
  from huggingface_hub import InferenceClient
3
  from requests.exceptions import RequestException
4
 
 
52
  response = generate_quiz(context)
53
 
54
  if request.headers.get('Content-Type') == 'application/json':
55
+ return jsonify({"quiz": response})
56
 
57
 
58
  quiz_html = f"""