Skip to content

[QTI] Dual-publish Perseus zips for choice/text-entry (math input only) QTI items #6001

Description

@rtibbles

This issue is not open for contribution. Visit Contributing guidelines to learn about the contributing process and how to find suitable issues.

Overview

Derive a Perseus archive from QTI items whose interaction type Perseus can express (single/multiple choice, text/math input), published alongside the QTI package so older Kolibri still renders the content.

Complexity: High
Target branch: unstable

Context

  • Older Kolibri renders Perseus; newer renders QTI. The authored source of truth is QTI XML in raw_data.
  • PerseusExerciseGenerator builds Perseus from structured question/answers, which native QTI items no longer carry.
  • The pydantic models can read the choice/text-entry subset. Advanced interaction types have no Perseus equivalent.

The Change

  • For QTI items mapping to a Perseus question type, derive the structured form from the QTI XML and produce a Perseus archive in addition to the QTI package.
  • Publish QTI only for nodes containing any interaction with no Perseus equivalent — never a partial or invalid Perseus.

Acceptance Criteria

  • A node of choice/text-input QTI items publishes both a QTI package and a Perseus archive
  • The derived Perseus matches the QTI item: prompt, choices, correct answers
  • Hints in kolibri:hint catalog cards are derived back into Perseus hints ([QTI] Carry legacy hints into generated QTI items as dormant catalog content #6011 contract)
  • Nodes containing any non-Perseus-expressible interaction publish QTI only
  • Older Kolibri (Perseus) and newer Kolibri (QTI) each render the node
  • Tests cover single-choice derivation
  • Tests cover multiple-choice derivation
  • Tests cover text/math input derivation
  • Tests cover hint derivation
  • Tests cover the QTI-only fallback

References

  • contentcuration/contentcuration/utils/assessment/perseus.py

AI usage

Claude mapped the existing publish/validation/ricecooker code, proposed the issue breakdown, and drafted each issue; the maintainer steered every decision and reviewed throughout.

Metadata

Metadata

Assignees

No one assigned

    Type

    No fields configured for Task.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions