Note:

If you want to create a new page for developers, you should create it on the Moodle Developer Resource site.

Shortanswer question development

From MoodleDocs
Revision as of 16:02, 12 November 2008 by Oleg Sychev (talk | contribs) (Page created)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Following discussion about regular expressions question types in Moodle Tim Hunt suggested a development of short answer question that allows the teacher to use a number of options (matches string, not matches string, contains the words, matches regexp an so on). The idea is good, though it needs further discussion.


Abilities

Initial list of options

Feel free to place suggestions there:

  • Exact match string
  • Partial match string
  • Contains the all/one of the words (substrings?)
  • Exact match regular expression
  • Partial match regular expression

Logical operations

Logical AND, OR, NOT - it is very useful to have more detailed way to describe an answer (for example contains some words AND not contains another). Should we stick to precedences and brackets there, or just evaluate this from left to right (as in search engines)?

I think that just using left associativity is better option since it is more obvious for teachers.--Oleg Sychev 10:02, 12 November 2008 (CST)

Interface

The actual problem is to get clever interface there, so the question creation would not be too cumbersome in simple cases.

Considering using AND/OR logical operation to group complex expressions in one answer I think that using simple formal language (as embedded question now) is better alternative than having many fields for each graded subasnwers.--Oleg Sychev 10:02, 12 November 2008 (CST)

Implementation

The options should be implemented as subclasses of abstract class to make adding new options easier. Does we need to have them as actual plugins (with versions, language packs, installation and so on) or more simple subplugins?

Does we need to store all options (with logical operators) with given subanswer as a whole, or create a new table with one entry per options? Right now I'm against new tables.--Oleg Sychev 10:02, 12 November 2008 (CST)