@learnosity/lib-qti-converter 0.10.4 → 0.12.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/docs/ROADMAP.md DELETED
@@ -1,232 +0,0 @@
1
- # Roadmap
2
-
3
- This document outlines planned features, known limitations, and completed work for the Learnosity QTI Converter.
4
-
5
- ## High Priority
6
-
7
- ### Support for responseProcessing-based Correct Responses
8
-
9
- **Status:** Not Started
10
- **Priority:** High
11
-
12
- **Issue:** Some QTI files define correct responses in `<responseProcessing>` blocks instead of `<responseDeclaration>/<correctResponse>/<value>`. This is a valid QTI pattern but not currently supported.
13
-
14
- **Example:**
15
-
16
- ```xml
17
- <responseDeclaration baseType="string" cardinality="single" identifier="RESPONSE1">
18
- <mapping defaultValue="0.00" upperBound="1.00">
19
- <mapEntry mappedValue="1"/> <!-- Missing mapKey attribute -->
20
- </mapping>
21
- </responseDeclaration>
22
-
23
- <!-- Correct responses defined here instead: -->
24
- <responseProcessing>
25
- <responseCondition>
26
- <responseIf>
27
- <equal>
28
- <variable identifier="RESPONSE1"/>
29
- <baseValue baseType="float">1</baseValue> <!-- Correct answer -->
30
- </equal>
31
- <setOutcomeValue identifier="SCORE1">
32
- <baseValue baseType="float">1</baseValue>
33
- </setOutcomeValue>
34
- </responseIf>
35
- </responseCondition>
36
- </responseProcessing>
37
- ```
38
-
39
- **Current Behavior:**
40
-
41
- - Parser throws error: `responseDeclaration found for "RESPONSE1" but no correctResponse values. This QTI file may define correct responses in <responseProcessing> which is not currently supported.`
42
-
43
- **Proposed Solution:**
44
-
45
- 1. Add `<responseProcessing>` parsing to extract correct responses from `<responseCondition>` blocks
46
- 2. Support both patterns:
47
- - Standard: `<responseDeclaration>/<correctResponse>/<value>`
48
- - Alternative: `<responseProcessing>/<responseCondition>/<baseValue>`
49
- 3. Update parsers for all interaction types
50
-
51
- ---
52
-
53
- ## Medium Priority
54
-
55
- ### Enhanced Metadata Support
56
-
57
- - [x] Support Common Cartridge curriculum standards metadata (`csm:labelledGUID`)
58
- - [ ] Support custom metadata fields beyond LOM classification/taxonPath
59
- - [ ] Preserve QTI metadata in round-trip conversions
60
-
61
- ### Improved Diagnostics
62
-
63
- - [ ] Add more detailed error messages with suggestions
64
- - [ ] Provide auto-fix suggestions for common issues
65
-
66
- ---
67
-
68
- ## Known Limitations
69
-
70
- ### Unsupported QTI Interaction Types
71
-
72
- The following QTI interaction types are not currently supported:
73
-
74
- - `associateInteraction`
75
- - `selectPointInteraction`
76
- - `graphicOrderInteraction`
77
- - `graphicAssociateInteraction`
78
- - `sliderInteraction`
79
- - `positionObjectInteraction`
80
- - `customInteraction`
81
-
82
- ### Unsupported Learnosity Features
83
-
84
- The following Learnosity features are not supported in QTI conversion:
85
-
86
- - `calculator` - No QTI equivalent
87
- - `ruler` - No QTI equivalent
88
- - `protractor` - No QTI equivalent
89
- - `linereader` - No QTI equivalent
90
-
91
- ---
92
-
93
- ## Completed
94
-
95
- ### v0.7.0 (Current Release)
96
-
97
- ### ✅ Learnosity Activity Sections Support
98
-
99
- - Full support for Learnosity activities with sections
100
- - Section-based activities → Multiple QTI `<assessmentSection>` elements
101
- - Flat activities → Single QTI `<assessmentSection>` with all items
102
- - Section-level navigation modes (linear/nonlinear) → `<testPart navigationMode>`
103
- - Section-level time limits (hard/soft) → `<timeLimits>` with `allowLateSubmission`
104
- - Section-level item shuffling → `<assessmentSection shuffle>`
105
- - Comprehensive documentation in `docs/LEARNOSITY_SECTIONS.md`
106
- - 8 new unit tests covering all section features
107
- - Support for both legacy (string array) and official (object array) item formats
108
-
109
- ### v0.4.0
110
-
111
- ### ✅ QTI Validation Tool
112
-
113
- - `bin/validateQti.py` script for validating QTI XML files against XSD schemas
114
- - Parallel validation using ProcessPoolExecutor for performance
115
- - Detailed error reporting with line numbers
116
- - Folder-based summary breakdown
117
-
118
- ### ✅ File Upload and Drawing Support
119
-
120
- - `fileupload` → `uploadInteraction` conversion
121
- - `drawing` → `drawingInteraction` conversion
122
- - MIME type mapping for file uploads
123
- - Background image support for drawing questions
124
-
125
- ### ✅ LOM Metadata Support
126
-
127
- - Bidirectional LOM ↔ Learnosity tags mapping
128
- - `lomParser.ts` extracts classification/taxonPath from LOM XML → Learnosity tags
129
- - `mapTagsToLom()` converts Learnosity tags → LOM classification metadata
130
- - Automatic LOM file discovery for QTI packages
131
-
132
- ### ✅ Common Cartridge Curriculum Standards Metadata Support
133
-
134
- - Parses `csm:labelledGUID` elements from Common Cartridge metadata in `imsmanifest.xml`
135
- - Maps `<csm:label>` to Learnosity tag type and `<csm:GUID>` to tag name
136
- - Namespace-aware parsing (works with any XML prefix)
137
- - Automatic deduplication and whitespace normalization
138
- - Merges with LOM metadata when both are present
139
- - Comprehensive test coverage (9 tests)
140
-
141
- ### v0.2.0
142
-
143
- ### ✅ Unified Versioning
144
-
145
- - Single source of truth in root package.json
146
- - CLI and Core packages use 0.0.0 as placeholder
147
- - Simpler version management
148
-
149
- ### ✅ Config File Improvements
150
-
151
- - Added `organisationId` and `mediaVault` to config schema
152
- - Renamed `defaultOutDir` to `output` for clarity
153
- - Removed unimplemented `strict` option
154
- - Removed redundant `writeDiagnosticsFile` option
155
- - Complete config documentation in all guides
156
-
157
- ### ✅ Asset URL Transformation Enhancements
158
-
159
- - UUID-based asset URLs (replaced MD5 hashing)
160
- - `--mediavault` flag for media-vault subdomain support
161
- - `--custom-asset-url` flag for custom CDN/asset server support
162
- - Fixed organisationId not being passed to conversion functions
163
- - Fixed duplicate asset URL transformations
164
-
165
- ### ✅ Comprehensive Documentation
166
-
167
- - Created SUPPORTED_INTERACTIONS.md with complete bidirectional mappings
168
- - Documented all 10 QTI → Learnosity interaction mappings
169
- - Documented all 16 Learnosity → QTI question type mappings
170
- - Documented supported Learnosity features (sharedpassage, audioplayer, videoplayer)
171
- - Enhanced config file documentation across all guides
172
-
173
- ### ✅ Bug Fixes
174
-
175
- - Fixed empty stimulus in MCQ, order, extendedText, match, graphicGapMatch parsers
176
- - Fixed duplicate/split break tags in HTML content
177
- - Fixed missing gapImg images in graphicGapMatch conversion
178
- - Fixed CLI display of organisationId and mediaVault options
179
-
180
- ### v0.1.0 and Earlier
181
-
182
- ### ✅ All 10 QTI Interaction Types
183
-
184
- - choiceInteraction → mcq
185
- - textEntryInteraction → clozetext/shorttext
186
- - extendedTextInteraction → longtextV2
187
- - matchInteraction → choicematrix
188
- - gapMatchInteraction → clozeassociation
189
- - inlineChoiceInteraction → clozedropdown
190
- - orderInteraction → orderlist
191
- - hotspotInteraction → hotspot
192
- - hottextInteraction → tokenhighlight
193
- - graphicGapMatchInteraction → imageclozeassociationV2
194
-
195
- ### ✅ Learnosity Features Support
196
-
197
- - sharedpassage → assessmentStimulus
198
- - audioplayer → HTML5 audio (QTI 2.2) or object (QTI 2.1)
199
- - videoplayer → HTML5 video (QTI 2.2) or object (QTI 2.1)
200
-
201
- ### ✅ QTI Package Support
202
-
203
- - Full IMS Content Package support
204
- - Manifest parsing and generation
205
- - Asset extraction and packaging
206
- - Multi-item test/activity conversion
207
-
208
- ### ✅ CLI Features
209
-
210
- - Interactive mode with prompts
211
- - Multiple output formats (dir, zip, stdout)
212
- - Flexible diagnostics output (stderr, file, both, none)
213
- - Config file support
214
- - Verbose mode for detailed diagnostics
215
- - Pretty-print JSON/XML output
216
-
217
- ### ✅ Core Features
218
-
219
- - Bidirectional conversion (QTI ↔ Learnosity)
220
- - QTI 2.1 and 2.2 support
221
- - Comprehensive diagnostic reporting
222
- - Source file tracking in diagnostics
223
- - Round-trip conversion support
224
-
225
- ### ✅ Library (Programmatic) API
226
-
227
- - Zero-dependency bundled output via tsdown (all dependencies inlined)
228
- - Dual usage: CLI (`lcon`) and library (`import { ... } from '@learnosity/lib-qti-converter'`)
229
- - Single-item conversion: `convertQtiToLearnosity()`, `convertLearnosityToQti()`
230
- - Package conversion: `convertQtiPackageToLearnosity()`, `convertLearnosityToQtiPackage()`
231
- - Full TypeScript type exports for all options and result types
232
- - Diagnostic utility functions: `hasErrors()`, `filterByLevel()`, `countByLevel()`, `formatDiagnosticsReport()`