Quiz Mode
Quiz mode generates standalone assessments to test the user's knowledge on a topic.
Agents
QuizAgent
generate_quiz(topic, user_background, count=10)
Generates a full quiz with multiple-choice questions.
- Adaptive Count: If
countis set to 'auto', it estimates the appropriate number of questions based on topic complexity usingget_quiz_count_for_topic. - Validation: Uses
validate_quiz_structureto ensure the LLM output is a valid JSON object withquestion,options, andcorrect_answerfields. - Output: JSON dictionary containing the list of questions.
get_quiz_count_for_topic(topic, user_background)
Consults the LLM to determine the complexity of the topic and suggests a question count (clamped between 5 and 30).