adlnet / xAPI-Spec

The xAPI Specification describes communication about learner activity and experiences between technologies.
https://adlnet.gov/projects/xapi/
899 stars 405 forks source link

Allow for an 'OR' operator in the correctResponsesPattern #1074

Open nieve opened 6 years ago

nieve commented 6 years ago

While the 'or' functionality is available in the guise of an array (of possibilities), this solution can become very quickly difficult to maintain when you need to work with a question that necessitates multiple answers and on for each answer there are multiple possibilities. Take for example a fill-in text where each blank can receive multiple correct possibilities. You can see how the correctResponsesPattern could exponentially grow and become rather cumbersome. A syntax using an OR operator such as [|] could be highly profitable in such an occasion, something like: optionA1[|]optionA2[.]target1[,]optionB1[|]optionB2[.]target2...

brianjmiller commented 6 years ago

Always open to interpretation, but I would suggest it is not "just an array of strings". It could depend on whether the interaction type is being specified. In the case that the type is specified I think the requirements to conform to the existing formats becomes more strict. The spec does indicate:

It is expected that Communities of Practice requiring richer interactions definitions will do so through the use of Activity types and Activity Definition Extensions.

But short of that, if the interactionType is specified you get into territory which includes:

From the spec on the response pattern:

The table below outlines the format of the strings within "correctResponsesPattern" property for each interaction type. This format is also used to represent the learner's response within the Result Object. These formats were originally based on the requirements relating to "cmi.interactions.n.correct_responses.n.pattern" as defined in the SCORM 2004 4th Edition Run-Time Environment.

Which is then extended to the correctResponsesPattern to match against the format listed above.

The table below outlines the format of the strings within "correctResponsesPattern" property for each interaction type. This format is also used to represent the learner's response within the Result Object. These formats were originally based on the requirements relating to "cmi.interactions.n.correct_responses.n.pattern" as defined in the SCORM 2004 4th Edition Run-Time Environment.

Also note, while the xAPI spec referenced the SCORM 2004, 4th ed. the formats of these values actually reference an IEEE standard which was the basis of the SCORM2004 values, see IEEE 1484.11. Adhering to them as a standard, particularly with the effort to standardize xAPI is probably wise.

Note any value can be recorded via extensions. If a better format is to be written, it might make sense to include it there and publicize that extension. Having said that, there is a lot of thought (not by me) that has gone into these formats.

Other things to consider: https://github.com/adlnet/xAPI-Spec/issues/628 https://github.com/adlnet/xAPI-Spec/issues/630

garemoko commented 6 years ago

The correctResponsesPattern doesn't have to be exhaustive so you don't have to include every possible combination. If there really are a huge number of possible correct combinations then I would question how useful that data is anyway; how is a reporting tool going to represent that?

Also consider that what you're representing as a single question may be more simply represented as multiple questions. Do you have a real example?