Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -111,8 +111,15 @@ def save_choice(choice_index):
|
|
| 111 |
sample = dataset.iloc[st.session_state.index]
|
| 112 |
|
| 113 |
# Display content
|
| 114 |
-
st.
|
| 115 |
-
st.write(f"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 116 |
st.write(f"**Question Category:** {sample.get('question_category', 'No category available')}")
|
| 117 |
st.video(sample["video_url"])
|
| 118 |
|
|
@@ -120,5 +127,5 @@ st.video(sample["video_url"])
|
|
| 120 |
not_enough_info = st.checkbox("The frame does not provide enough information to answer the question.", key='checkbox')
|
| 121 |
|
| 122 |
# Buttons
|
| 123 |
-
st.button(f"
|
| 124 |
-
st.button(f"
|
|
|
|
| 111 |
sample = dataset.iloc[st.session_state.index]
|
| 112 |
|
| 113 |
# Display content
|
| 114 |
+
st.markdown("<h1 style='text-align: center; font-size: 50px;'>MAIA Sample</h1>", unsafe_allow_html=True)
|
| 115 |
+
st.write(f"### User: {st.session_state.username}")
|
| 116 |
+
st.write("\n\n\n") # Add empty space
|
| 117 |
+
st.markdown("""
|
| 118 |
+
### Instructions:
|
| 119 |
+
- Look at the video thumbnail, do not play it!
|
| 120 |
+
- Select the checkbox if you think so.
|
| 121 |
+
- Then choose one of the two answers.
|
| 122 |
+
""")
|
| 123 |
st.write(f"**Question Category:** {sample.get('question_category', 'No category available')}")
|
| 124 |
st.video(sample["video_url"])
|
| 125 |
|
|
|
|
| 127 |
not_enough_info = st.checkbox("The frame does not provide enough information to answer the question.", key='checkbox')
|
| 128 |
|
| 129 |
# Buttons
|
| 130 |
+
st.button(f"Answer 1: {sample.get('answer1', 'No answer1 available')}", on_click=lambda: save_choice(0))
|
| 131 |
+
st.button(f"Answer 2: {sample.get('answer2', 'No answer2 available')}", on_click=lambda: save_choice(1))
|