Spaces:
Sleeping
Sleeping
n lo
Browse files
README.md
CHANGED
|
@@ -13,8 +13,20 @@ An AI-powered tool that creates learning objectives and multiple-choice quiz que
|
|
| 13 |
- **Generate from course materials** β Upload course files and let the AI extract and generate learning objectives automatically through a multi-run, multi-stage pipeline.
|
| 14 |
- **Use my own learning objectives** β Enter your own learning objectives in a text field (one per line). The app searches the uploaded course materials for relevant source references, generates a correct answer for each objective, and produces incorrect answer options β the same full pipeline as automatic generation.
|
| 15 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 16 |
**Shared capabilities (both modes):**
|
| 17 |
-
- Configurable AI model and temperature for both generation and incorrect answer suggestion steps
|
| 18 |
- All output in the same JSON format, ready to feed directly into Tab 2
|
| 19 |
- "Generate all" button runs the full end-to-end pipeline (learning objectives β quiz questions) in a single click, in either mode
|
| 20 |
|
|
@@ -22,13 +34,22 @@ An AI-powered tool that creates learning objectives and multiple-choice quiz que
|
|
| 22 |
|
| 23 |
- Takes the learning objectives JSON produced in Tab 1 as input
|
| 24 |
- Generates multiple-choice questions with 4 options, per-option feedback, and source references
|
| 25 |
-
- Configurable number of questions and generation runs
|
| 26 |
- Automatic ranking and grouping of generated questions by quality
|
| 27 |
- Outputs: ranked best-in-group questions, all grouped questions, and a human-readable formatted quiz
|
| 28 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 29 |
### Tab 3 β Propose / Edit Question
|
| 30 |
|
| 31 |
-
- Load the formatted quiz from Tab 2 or upload a `.md` / `.yml` quiz file
|
| 32 |
- Review and edit questions one at a time with Previous / Accept & Next navigation
|
| 33 |
- Download the final edited quiz
|
| 34 |
|
|
|
|
| 13 |
- **Generate from course materials** β Upload course files and let the AI extract and generate learning objectives automatically through a multi-run, multi-stage pipeline.
|
| 14 |
- **Use my own learning objectives** β Enter your own learning objectives in a text field (one per line). The app searches the uploaded course materials for relevant source references, generates a correct answer for each objective, and produces incorrect answer options β the same full pipeline as automatic generation.
|
| 15 |
|
| 16 |
+
**Always-visible controls:**
|
| 17 |
+
- Mode selector (Generate / Use my own)
|
| 18 |
+
- Upload Course Materials
|
| 19 |
+
- Number of Learning Objectives per Run *(generate mode)* / Learning Objectives text field *(manual mode)*
|
| 20 |
+
- Generate Learning Objectives / Process Learning Objectives button
|
| 21 |
+
- Generate all button *(works in both modes)*
|
| 22 |
+
|
| 23 |
+
**Advanced Options** *(collapsible, closed by default):*
|
| 24 |
+
- Number of Generation Runs
|
| 25 |
+
- Model
|
| 26 |
+
- Model for Incorrect Answer Suggestions
|
| 27 |
+
- Temperature
|
| 28 |
+
|
| 29 |
**Shared capabilities (both modes):**
|
|
|
|
| 30 |
- All output in the same JSON format, ready to feed directly into Tab 2
|
| 31 |
- "Generate all" button runs the full end-to-end pipeline (learning objectives β quiz questions) in a single click, in either mode
|
| 32 |
|
|
|
|
| 34 |
|
| 35 |
- Takes the learning objectives JSON produced in Tab 1 as input
|
| 36 |
- Generates multiple-choice questions with 4 options, per-option feedback, and source references
|
|
|
|
| 37 |
- Automatic ranking and grouping of generated questions by quality
|
| 38 |
- Outputs: ranked best-in-group questions, all grouped questions, and a human-readable formatted quiz
|
| 39 |
|
| 40 |
+
**Always-visible controls:**
|
| 41 |
+
- Learning Objectives JSON input
|
| 42 |
+
- Number of questions
|
| 43 |
+
- Generate Questions button
|
| 44 |
+
|
| 45 |
+
**Advanced Options** *(collapsible, closed by default):*
|
| 46 |
+
- Model
|
| 47 |
+
- Temperature
|
| 48 |
+
- Number of Question Generation Runs
|
| 49 |
+
|
| 50 |
### Tab 3 β Propose / Edit Question
|
| 51 |
|
| 52 |
+
- Load the formatted quiz from Tab 2 or upload a `.md` / `.yml` quiz file *(file upload is inside a collapsible section)*
|
| 53 |
- Review and edit questions one at a time with Previous / Accept & Next navigation
|
| 54 |
- Download the final edited quiz
|
| 55 |
|
ui/app.py
CHANGED
|
@@ -42,11 +42,6 @@ def create_ui():
|
|
| 42 |
)
|
| 43 |
# Generate-mode controls
|
| 44 |
num_objectives = gr.Slider(minimum=1, maximum=20, value=4, step=1, label="Number of Learning Objectives per Run")
|
| 45 |
-
num_runs = gr.Dropdown(
|
| 46 |
-
choices=["1", "2", "3", "4", "5"],
|
| 47 |
-
value="2",
|
| 48 |
-
label="Number of Generation Runs"
|
| 49 |
-
)
|
| 50 |
# Manual-mode input (hidden by default)
|
| 51 |
user_objectives_input = gr.Textbox(
|
| 52 |
label="Enter Learning Objectives (one per line)",
|
|
@@ -61,22 +56,27 @@ def create_ui():
|
|
| 61 |
),
|
| 62 |
visible=False
|
| 63 |
)
|
| 64 |
-
|
| 65 |
-
|
| 66 |
-
|
| 67 |
-
|
| 68 |
-
|
| 69 |
-
|
| 70 |
-
|
| 71 |
-
|
| 72 |
-
|
| 73 |
-
|
| 74 |
-
|
| 75 |
-
|
| 76 |
-
|
| 77 |
-
|
| 78 |
-
|
| 79 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 80 |
# Buttons β generate_button / process_user_obj_button toggle by mode;
|
| 81 |
# generate_all_button is always visible
|
| 82 |
generate_button = gr.Button("Generate Learning Objectives")
|
|
@@ -93,18 +93,19 @@ def create_ui():
|
|
| 93 |
with gr.Row():
|
| 94 |
with gr.Column():
|
| 95 |
objectives_input = gr.Textbox(label="Learning Objectives JSON", lines=10, max_lines=10)
|
| 96 |
-
model_dropdown_q = gr.Dropdown(
|
| 97 |
-
choices=MODELS,
|
| 98 |
-
value="gpt-5.2",
|
| 99 |
-
label="Model"
|
| 100 |
-
)
|
| 101 |
-
temperature_dropdown_q = gr.Dropdown(
|
| 102 |
-
choices=["0.0", "0.1", "0.2", "0.3", "0.4", "0.5", "0.6", "0.7", "0.8", "0.9", "1.0"],
|
| 103 |
-
value="1.0",
|
| 104 |
-
label="Temperature (0.0: Deterministic, 1.0: Creative)"
|
| 105 |
-
)
|
| 106 |
num_questions_slider = gr.Slider(minimum=1, maximum=10, value=10, step=1, label="Number of questions")
|
| 107 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 108 |
generate_q_button = gr.Button("Generate Questions")
|
| 109 |
|
| 110 |
with gr.Column():
|
|
|
|
| 42 |
)
|
| 43 |
# Generate-mode controls
|
| 44 |
num_objectives = gr.Slider(minimum=1, maximum=20, value=4, step=1, label="Number of Learning Objectives per Run")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 45 |
# Manual-mode input (hidden by default)
|
| 46 |
user_objectives_input = gr.Textbox(
|
| 47 |
label="Enter Learning Objectives (one per line)",
|
|
|
|
| 56 |
),
|
| 57 |
visible=False
|
| 58 |
)
|
| 59 |
+
with gr.Accordion("Advanced Options", open=False):
|
| 60 |
+
num_runs = gr.Dropdown(
|
| 61 |
+
choices=["1", "2", "3", "4", "5"],
|
| 62 |
+
value="2",
|
| 63 |
+
label="Number of Generation Runs"
|
| 64 |
+
)
|
| 65 |
+
model_dropdown = gr.Dropdown(
|
| 66 |
+
choices=MODELS,
|
| 67 |
+
value="gpt-5.2",
|
| 68 |
+
label="Model"
|
| 69 |
+
)
|
| 70 |
+
incorrect_answer_model_dropdown = gr.Dropdown(
|
| 71 |
+
choices=MODELS,
|
| 72 |
+
value="gpt-5.2",
|
| 73 |
+
label="Model for Incorrect Answer Suggestions"
|
| 74 |
+
)
|
| 75 |
+
temperature_dropdown = gr.Dropdown(
|
| 76 |
+
choices=["0.0", "0.1", "0.2", "0.3", "0.4", "0.5", "0.6", "0.7", "0.8", "0.9", "1.0"],
|
| 77 |
+
value="1.0",
|
| 78 |
+
label="Temperature (0.0: Deterministic, 1.0: Creative)"
|
| 79 |
+
)
|
| 80 |
# Buttons β generate_button / process_user_obj_button toggle by mode;
|
| 81 |
# generate_all_button is always visible
|
| 82 |
generate_button = gr.Button("Generate Learning Objectives")
|
|
|
|
| 93 |
with gr.Row():
|
| 94 |
with gr.Column():
|
| 95 |
objectives_input = gr.Textbox(label="Learning Objectives JSON", lines=10, max_lines=10)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 96 |
num_questions_slider = gr.Slider(minimum=1, maximum=10, value=10, step=1, label="Number of questions")
|
| 97 |
+
with gr.Accordion("Advanced Options", open=False):
|
| 98 |
+
model_dropdown_q = gr.Dropdown(
|
| 99 |
+
choices=MODELS,
|
| 100 |
+
value="gpt-5.2",
|
| 101 |
+
label="Model"
|
| 102 |
+
)
|
| 103 |
+
temperature_dropdown_q = gr.Dropdown(
|
| 104 |
+
choices=["0.0", "0.1", "0.2", "0.3", "0.4", "0.5", "0.6", "0.7", "0.8", "0.9", "1.0"],
|
| 105 |
+
value="1.0",
|
| 106 |
+
label="Temperature (0.0: Deterministic, 1.0: Creative)"
|
| 107 |
+
)
|
| 108 |
+
num_runs_q = gr.Slider(minimum=1, maximum=5, value=2, step=1, label="Number of Question Generation Runs")
|
| 109 |
generate_q_button = gr.Button("Generate Questions")
|
| 110 |
|
| 111 |
with gr.Column():
|