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

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -5,7 +5,7 @@ from requests.exceptions import RequestException
5
  app = Flask(__name__)
6
 
7
 
8
- client = InferenceClient("mistralai/Mixtral-8x7B-Instruct-v0.1")
9
 
10
  def system_instructions(context):
11
  return f"""<s> [INST] Your are a great teacher and your task is to create 6 questions with answer and 4 choices based on the following context:\n\n{context}\n\n. Each example should be like this
@@ -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({"quiz": response})
56
 
57
 
58
  quiz_html = f"""
 
5
  app = Flask(__name__)
6
 
7
 
8
+ client = InferenceClient("HuggingFaceH4/zephyr-7b-beta")
9
 
10
  def system_instructions(context):
11
  return f"""<s> [INST] Your are a great teacher and your task is to create 6 questions with answer and 4 choices based on the following context:\n\n{context}\n\n. Each example should be like this
 
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"""