Skip to main content

qudb: Question Database

Project description

Manage a database of questions and use it to generate assessments, e.g. assignments, quizzes, and exams.

qudb is a personal question bank for instructors that allows you to:

  1. Keep track of your collection of questions for a given course.

  2. Query your database for terms, assessment types, assessments, or questions. An assessment is a pair of a term and an assessment type.

    Example queries:

    • In which assessments has a given question been used?

    • What questions make up a given assessment?

    • What questions have been used in a given term?

    • What questions have been used in final exams across all terms?

  3. Use a template to render an assessment document using its questions.

  4. Distinguish between essay questions (default) and multiple-choice questions.

  5. Use arbitrary additional variables in your templates, so you can use the same templates across courses, and use a course name variable.

Getting Started

  1. Create a database:

    qm init  # creates ./qu.db

    Use the -D (or --database) option to specify the database file location.

  2. Add questions:

    qm add --term 151 --assessment-type quiz1 questions/chapter1/whats-your-name.tex
    qm add --term 151 --assessment-type quiz1 questions/chapter1/mcq/choose-a-month.tex

    Use the -Q (or --questions-directory) to specify where to look for the question files. You can also specify a question’s points, whether it’s a bonus question, and its order in the assessment if you want to insert it somewhere in the middle.

  3. Generate an assessment:

    qm render --term 151 --assessment-type quiz1 --pdflatex quiz-template.tex

    The --pdflatex option assumes that your template is a LaTeX file, requires the pdflatex program, and generates a PDF. Without it, you get a rendered template.

    The --config option allows specifying additional arbitrary template variables using an ini-style configuration file.

Assumptions

  • One SQLite database file per course.

  • Questions and templates are text files.

  • Templates are Jinja2 templates.

  • Multiple choice questions have an /mcq/ component in their paths.

  • Although it is not required, qudb works well with the exam LaTeX package.

License

BSD (2-clause).

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

qudb-0.5.tar.gz (8.7 kB view hashes)

Uploaded Source

Built Distribution

qudb-0.5-py3-none-any.whl (11.5 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page