Implement nested question remediation and review content

This commit is contained in:
hz
2026-07-16 21:46:56 -05:00
parent 0f5a1122d4
commit c8bfc26645
14 changed files with 1339 additions and 245 deletions
+11
View File
@@ -15,6 +15,9 @@ public class Question
public List<QuestionChoice> Choices { get; set; } = [];
public string CorrectChoiceId { get; set; } = "";
public string Explanation { get; set; } = "";
public string KeyTakeaway { get; set; } = "";
public string UsmlePearl { get; set; } = "";
public List<QuestionReviewFollowup> ReviewFollowups { get; set; } = [];
public Dictionary<string, string> ChoiceExplanations { get; set; } = [];
public Dictionary<string, WrongAnswerFollowup> WrongAnswerFollowups { get; set; } = [];
public Dictionary<string, int> ChoiceSelectionPercentages { get; set; } = [];
@@ -53,6 +56,14 @@ public class WrongAnswerFollowup
public string TeachingPoint { get; set; } = "";
}
public class QuestionReviewFollowup
{
public string Prompt { get; set; } = "";
public List<QuestionChoice> Choices { get; set; } = [];
public string CorrectChoiceId { get; set; } = "";
public string TeachingPoint { get; set; } = "";
}
public class QuestionReference
{
public string Title { get; set; } = "";
@@ -59,6 +59,9 @@ public class QuestionReportSnapshot
public List<QuestionChoice> Choices { get; set; } = [];
public string CorrectChoiceId { get; set; } = "";
public string Explanation { get; set; } = "";
public string KeyTakeaway { get; set; } = "";
public string UsmlePearl { get; set; } = "";
public List<QuestionReviewFollowup> ReviewFollowups { get; set; } = [];
public Dictionary<string, string> ChoiceExplanations { get; set; } = [];
public Dictionary<string, WrongAnswerFollowup> WrongAnswerFollowups { get; set; } = [];
public List<QuestionLab> Labs { get; set; } = [];
@@ -21,6 +21,9 @@ public class UpsertQuestionRequest
public List<QuestionChoice> Choices { get; set; } = [];
public string CorrectChoiceId { get; set; } = "";
public string Explanation { get; set; } = "";
public string KeyTakeaway { get; set; } = "";
public string UsmlePearl { get; set; } = "";
public List<QuestionReviewFollowup> ReviewFollowups { get; set; } = [];
public Dictionary<string, string> ChoiceExplanations { get; set; } = [];
public Dictionary<string, WrongAnswerFollowup> WrongAnswerFollowups { get; set; } = [];
public Dictionary<string, int> ChoiceSelectionPercentages { get; set; } = [];
@@ -9,6 +9,9 @@ public class QuestionResponse
public List<QuestionChoice> Choices { get; set; } = [];
public string CorrectChoiceId { get; set; } = "";
public string Explanation { get; set; } = "";
public string KeyTakeaway { get; set; } = "";
public string UsmlePearl { get; set; } = "";
public List<QuestionReviewFollowup> ReviewFollowups { get; set; } = [];
public Dictionary<string, string> ChoiceExplanations { get; set; } = [];
public Dictionary<string, WrongAnswerFollowup> WrongAnswerFollowups { get; set; } = [];
public Dictionary<string, int> ChoiceSelectionPercentages { get; set; } = [];
@@ -41,6 +44,9 @@ public class QuestionResponse
Choices = choices,
CorrectChoiceId = question.CorrectChoiceId,
Explanation = question.Explanation,
KeyTakeaway = question.KeyTakeaway,
UsmlePearl = question.UsmlePearl,
ReviewFollowups = question.ReviewFollowups,
ChoiceExplanations = question.ChoiceExplanations
.Where(entry => choiceIds.Contains(entry.Key))
.ToDictionary(),