This commit is contained in:
RaymondVerhoef
2026-05-25 19:18:24 +02:00
parent 8291a52ba9
commit 9ba9ec94ad

View File

@@ -38,7 +38,7 @@ function dominantCorrectIndex(questions) {
const counts = [0, 0, 0, 0];
for (const q of questions) counts[q.correctIndex] = (counts[q.correctIndex] || 0) + 1;
const max = Math.max(...counts);
return max / questions.length > 0.5 ? { index: counts.indexOf(max), ratio: max / questions.length } : null;
return max / questions.length > 0.8 ? { index: counts.indexOf(max), ratio: max / questions.length } : null;
}
function validateBatchQuality(questions) {
@@ -66,7 +66,7 @@ Topic: ${topic.label}
Type: ${topic.type}
Description: ${topic.description}
Options must be prefixed "A) ", "B) ", "C) ", "D) ". Make questions specific and practical, not trivial. Example: a question whose correct answer is option C uses "correctIndex": 2.`;
Options must be prefixed "A) ", "B) ", "C) ", "D) ". Make questions specific and practical, not trivial. Ensure correct answers are evenly distributed.`;
const result = await callLLM({
task: 'quiz.generate',