Update app.py
Browse files
app.py
CHANGED
@@ -205,17 +205,9 @@ if topic:
|
|
205 |
response = model.generate_content(prompt)
|
206 |
quiz_content = response.text
|
207 |
|
208 |
-
# --- DEBUGGING PRINTS ---
|
209 |
-
st.write("### Raw Quiz Content from Gemini:")
|
210 |
-
st.code(quiz_content) # Display raw content in a code block for readability
|
211 |
|
212 |
parsed_quiz_data, answer_key = parse_quiz_content(quiz_content)
|
213 |
|
214 |
-
st.write("### Parsed Quiz Data:")
|
215 |
-
st.write(parsed_quiz_data) # Display the parsed data structure
|
216 |
-
|
217 |
-
# --- END DEBUGGING PRINTS ---
|
218 |
-
|
219 |
|
220 |
if quiz_content: # Check if quiz_content was generated successfully (outer if)
|
221 |
if parsed_quiz_data: # Check if parsing was successful (inner if)
|
|
|
205 |
response = model.generate_content(prompt)
|
206 |
quiz_content = response.text
|
207 |
|
|
|
|
|
|
|
208 |
|
209 |
parsed_quiz_data, answer_key = parse_quiz_content(quiz_content)
|
210 |
|
|
|
|
|
|
|
|
|
|
|
211 |
|
212 |
if quiz_content: # Check if quiz_content was generated successfully (outer if)
|
213 |
if parsed_quiz_data: # Check if parsing was successful (inner if)
|