Skip to main content

Overview

KnowledgeCheckr supports four distinct question types, each designed for different assessment needs. Every question includes core properties like points, category assignment, and accessibility controls.

Base Question Properties

All questions share these common fields:
{
  id: string,              // Unique identifier (UUID)
  points: number,          // Must be positive
  category: string,        // Assigned category (default: 'general')
  question: string,        // The question text (minimum 3 words)
  accessibility: 'all' | 'practice-only' | 'exam-only'
}
Use the accessibility field to control where questions appear. Set to practice-only for learning exercises or exam-only for formal assessments.

Question Types

Single Choice Questions

Single choice questions require selecting exactly one correct answer from multiple options. Perfect for testing clear-cut knowledge where only one answer is correct.

Structure

{
  type: 'single-choice',
  answers: [
    {
      id: string,        // Unique UUID
      answer: string,    // Answer text
      correct: boolean   // Exactly one must be true
    }
  ]
}

Example

{
  "id": "q1",
  "type": "single-choice",
  "question": "What is the capital of France?",
  "points": 5,
  "category": "geography",
  "accessibility": "all",
  "answers": [
    { "id": "a1", "answer": "London", "correct": false },
    { "id": "a2", "answer": "Paris", "correct": true },
    { "id": "a3", "answer": "Berlin", "correct": false },
    { "id": "a4", "answer": "Madrid", "correct": false }
  ]
}

Validation Rules

  • At least one answer must be provided
  • Exactly one answer must be marked as correct
  • All answers must have unique text (case-insensitive)
  • All answer IDs must be unique UUIDs
  • Answer text cannot be empty

What Users See

Users see a list of options with radio buttons, allowing them to select only one answer. The interface clearly indicates that exactly one option should be chosen.

Question Configuration

Point Values

Assign points based on question difficulty and importance:
points: number  // Must be positive
Consider assigning higher points to:
  • Multiple choice with many options
  • Drag-drop questions requiring precise ordering
  • Open-ended questions requiring detailed responses

Accessibility Control

Control where each question appears:

all

Appears in both practice and examination modes

practice-only

Only visible during practice sessions

exam-only

Only visible during formal examinations
accessibility: 'all' | 'practice-only' | 'exam-only'
Use this to:
  • Reserve harder questions for exams
  • Provide easier practice questions for learning
  • Create separate question pools for different contexts

Answer Ordering

You can configure how answers are displayed through the knowledge check settings:
settings: {
  examination: {
    answerOrder: 'create-order' | 'random'
  }
}
  • create-order: Displays answers in the order you created them
  • random: Shuffles answers for each user attempt
Randomizing answers helps prevent pattern memorization and reduces cheating.

Best Practices

Writing Quality Questions

  1. Be Clear and Concise: Questions must be at least 3 words but should clearly state what’s being asked
  2. Avoid Ambiguity: Ensure only the intended answers are correct
  3. Unique Answers: All answers within a question must be distinct
  4. Appropriate Length: Keep answers reasonably short for choice questions

Choosing Question Types

  • Facts with one correct answer
  • True/false questions
  • Definition matching
  • Simple recall

Common Pitfalls

  • Don’t use duplicate answer text (case-insensitive comparison)
  • Ensure drag-drop positions are continuous starting from 0
  • Single choice must have exactly one correct answer
  • Multiple choice must have at least one correct answer
  • Questions must be assigned to existing categories

Example: Mixed Question Set

[
  {
    "type": "single-choice",
    "question": "What does HTML stand for?",
    "points": 5,
    "category": "web-basics",
    "accessibility": "all",
    "answers": [
      { "answer": "Hyper Text Markup Language", "correct": true },
      { "answer": "High Tech Modern Language", "correct": false }
    ]
  },
  {
    "type": "multiple-choice",
    "question": "Which are JavaScript frameworks?",
    "points": 8,
    "category": "web-frameworks",
    "accessibility": "exam-only",
    "answers": [
      { "answer": "React", "correct": true },
      { "answer": "Angular", "correct": true },
      { "answer": "Django", "correct": false },
      { "answer": "Vue", "correct": true }
    ]
  },
  {
    "type": "drag-drop",
    "question": "Order the HTTP request lifecycle",
    "points": 12,
    "category": "networking",
    "accessibility": "exam-only",
    "answers": [
      { "answer": "DNS Resolution", "position": 0 },
      { "answer": "TCP Connection", "position": 1 },
      { "answer": "Send Request", "position": 2 },
      { "answer": "Receive Response", "position": 3 }
    ]
  },
  {
    "type": "open-question",
    "question": "Explain the difference between GET and POST requests",
    "points": 15,
    "category": "http-methods",
    "accessibility": "exam-only",
    "expectation": "Should discuss data transmission, idempotency, caching, and use cases"
  }
]

Next Steps

Practice Mode

Let users practice with instant feedback

Examination Mode

Set up formal timed assessments

Categories

Organize questions into categories

Knowledge Checks

Back to knowledge check overview

Build docs developers (and LLMs) love