openedx / openedx-demo-course

A demonstration course that can be imported into an Open edX instance
GNU Affero General Public License v3.0
46 stars 68 forks source link

Advanced example with Text Input Problem #19

Closed pyrog closed 7 months ago

pyrog commented 7 years ago

Could you provide an example of case sensitivity and/or regular expressions please?

I'am a french user of several moocs that don't use theses options. The user experience is downgraded, students write a lot of posts to complain.

Part of a real example (the real list is longer 😉) :

<problem>
    <stringresponse answer="obstacle" type="cs">
        <label>Citez les 5 risques ferroviaires</label>
        <description>Sous la forme article défini + nom du risque</description>
        <additional_answer answer="Obstacle"></additional_answer>
        <additional_answer answer="Obstacles"></additional_answer>
        <additional_answer answer="obstacles sur voie"></additional_answer>
        <additional_answer answer="un obstacle sur la voie"></additional_answer>
        <additional_answer answer="des obstacles sur la voie"></additional_answer>
        <additional_answer answer="obstacles"></additional_answer>
        <additional_answer answer="Obstacle"></additional_answer>
        <additional_answer answer="Obstacles"></additional_answer>
        <additional_answer answer="l'obstacle"></additional_answer>
        <additional_answer answer="les obstacles"></additional_answer>
        <additional_answer answer="L'obstacle"></additional_answer>
        <additional_answer answer="Les obstacles"></additional_answer>
        <additional_answer answer="La rencontre d'obstacle"></additional_answer>
        <additional_answer answer="la rencontre d'obstacle"></additional_answer>
        <additional_answer answer="La rencontre d'obstacles"></additional_answer>
        <additional_answer answer="la rencontre d'obstacles"></additional_answer>
        <additional_answer answer="La rencontre d'un obstacle"></additional_answer>
        <additional_answer answer="la rencontre d'un obstacle"></additional_answer>
        <additional_answer answer="percuter un obstacle"></additional_answer>
        <additional_answer answer="Percuter un obstacle"></additional_answer>
        <additional_answer answer="obstacles sur voie"></additional_answer>
        <additional_answer answer="un obstacle sur la voie"></additional_answer>
        <additional_answer answer="des obstacles sur la voie"></additional_answer>
        <additional_answer answer="obsatcles sur la voie "></additional_answer>
        <additional_answer answer="obstacles sur les voies"></additional_answer>
        <additional_answer answer="des obstacles sur les voies"></additional_answer>
        <additional_answer answer="un obstacle sur les voies"></additional_answer>
    </stringresponse>
</problem>

I guess that we could rewrite it simply like this:

<problem>
    <stringresponse answer="obstacle" type="ci regexp">
        <label>Citez les 5 risques ferroviaires</label>
        <description>Sous la forme article défini + nom du risque</description>
        <additional_answer answer=".*obstacle.*"></additional_answer>
    </stringresponse>
</problem>

I think that the answer "un obstacle sur les voies" is not valid so I used an additional answer containing a "real" regexp. Does this additional answer is valid?

jswope00 commented 7 months ago

The original DemoX course has been replaced with an updated DemoX, which does include regex examples! Check the Text Input problem type in the new course. Here is a link to review it: https://training.openedx.org/courses/course-v1:Axim+DemoX+Demo_Course/courseware/d6780558bc3042c7ab6dd441a06d3478/276a277f5a784f53a7525e28b96e9a1b/?activate_block_id=block-v1%3AAxim%2BDemoX%2BDemo_Course%2Btype%40sequential%2Bblock%40276a277f5a784f53a7525e28b96e9a1b