Spaces:
Sleeping
Sleeping
mohammed3536
commited on
Commit
•
52aa91a
1
Parent(s):
e47b063
Update app.py
Browse files
app.py
CHANGED
@@ -33,9 +33,6 @@ def generate_mcqs_on_topic(text, topic, num_mcqs=5):
|
|
33 |
chatgpt_question = generate_question_with_chatgpt(sentence)
|
34 |
mcqs.append(chatgpt_question)
|
35 |
|
36 |
-
# Use LLM for nuanced language modeling
|
37 |
-
llm_question = generate_question_with_llm(sentence, topic)
|
38 |
-
mcqs.append(llm_question)
|
39 |
|
40 |
return mcqs
|
41 |
|
@@ -59,10 +56,6 @@ def generate_question_with_chatgpt(context):
|
|
59 |
|
60 |
return generated_question
|
61 |
|
62 |
-
|
63 |
-
response = requests.post(LLM_API_ENDPOINT, json=data, headers=headers)
|
64 |
-
result = response.json()
|
65 |
-
|
66 |
# Extract the generated question from the response
|
67 |
generated_question = result["generated_question"]
|
68 |
return generated_question
|
|
|
33 |
chatgpt_question = generate_question_with_chatgpt(sentence)
|
34 |
mcqs.append(chatgpt_question)
|
35 |
|
|
|
|
|
|
|
36 |
|
37 |
return mcqs
|
38 |
|
|
|
56 |
|
57 |
return generated_question
|
58 |
|
|
|
|
|
|
|
|
|
59 |
# Extract the generated question from the response
|
60 |
generated_question = result["generated_question"]
|
61 |
return generated_question
|