Jintonic92 commited on
Commit
8704ed6
ยท
verified ยท
1 Parent(s): 7af4be2

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -38
app.py CHANGED
@@ -401,7 +401,7 @@ def main():
401
  new_question = generate_similar_question(wrong_q, misconception_id, generator)
402
  if new_question:
403
  st.write("### ๐ŸŽฏ ์œ ์‚ฌ ๋ฌธ์ œ")
404
- display_math_content(new_question['question']) # ํ•จ์ˆ˜ ๊ต์ฒด
405
 
406
  # ๋‹ต๋ณ€ ์ƒํƒœ ํ™•์ธ
407
  answered = st.session_state.get(f"similar_question_answered_{i}", False)
@@ -417,43 +417,7 @@ def main():
417
  else:
418
  st.session_state[f"is_correct_{i}"] = False
419
  st.rerun()
420
- # ๋ณด๊ธฐ ํ‘œ์‹œ
421
- #st.write("**๋ณด๊ธฐ:**")
422
- #col1, col2 = st.columns(2)
423
-
424
-
425
- # ๋‹ต๋ณ€ํ•˜์ง€ ์•Š์€ ๊ฒฝ์šฐ์—๋งŒ ๋ฒ„ํŠผ ํ™œ์„ฑํ™”
426
- # if not answered:
427
- # with col1:
428
- # for option in ['A', 'C']:
429
- # if st.button(
430
- # f"{option}) {LatexNodes2Text().latex_to_text(new_question['choices'][option])}",
431
- # key=f"similar_{option}_{i}"
432
- # ):
433
- # st.session_state[f"similar_question_answered_{i}"] = True
434
- # st.session_state[f"selected_answer_{i}"] = option
435
- # correct_answer = st.session_state.get('current_similar_question_answer')
436
- # if option == correct_answer:
437
- # st.session_state[f"is_correct_{i}"] = True
438
- # else:
439
- # st.session_state[f"is_correct_{i}"] = False
440
- # st.rerun()
441
-
442
- # with col2:
443
- # for option in ['B', 'D']:
444
- # if st.button(
445
- # f"{option}) {LatexNodes2Text().latex_to_text(new_question['choices'][option])}",
446
- # key=f"similar_{option}_{i}"
447
- # ):
448
- # st.session_state[f"similar_question_answered_{i}"] = True
449
- # st.session_state[f"selected_answer_{i}"] = option
450
- # correct_answer = st.session_state.get('current_similar_question_answer')
451
- # if option == correct_answer:
452
- # st.session_state[f"is_correct_{i}"] = True
453
- # else:
454
- # st.session_state[f"is_correct_{i}"] = False
455
- # st.rerun()
456
-
457
  # ๋‹ต๋ณ€ํ•œ ๊ฒฝ์šฐ ๊ฒฐ๊ณผ ํ‘œ์‹œ
458
  if answered:
459
  is_correct = st.session_state.get(f"is_correct_{i}", False)
 
401
  new_question = generate_similar_question(wrong_q, misconception_id, generator)
402
  if new_question:
403
  st.write("### ๐ŸŽฏ ์œ ์‚ฌ ๋ฌธ์ œ")
404
+ #display_math_content(new_question['question']) # ํ•จ์ˆ˜ ๊ต์ฒด
405
 
406
  # ๋‹ต๋ณ€ ์ƒํƒœ ํ™•์ธ
407
  answered = st.session_state.get(f"similar_question_answered_{i}", False)
 
417
  else:
418
  st.session_state[f"is_correct_{i}"] = False
419
  st.rerun()
420
+
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
421
  # ๋‹ต๋ณ€ํ•œ ๊ฒฝ์šฐ ๊ฒฐ๊ณผ ํ‘œ์‹œ
422
  if answered:
423
  is_correct = st.session_state.get(f"is_correct_{i}", False)