A mapping of question ID to grader.
A mapping of question ID to grader specification.
An exception including an adjusted score and an explanation of why the exception was applied.
A mapping from (uniqname, question id) to any exceptions applied for that student for that question. The question's display index (e.g. "3.2") may be used in place of the question ID. Only one exception may be specified per student/question pair.
Generated using TypeDoc
TODO this documentation is old and needs to be updated Grading Exams
To start, you'll want to define some graders and a mapping from question IDs for the questions you're using to those graders. You might put these in their own files, or in the same file as the question definitions, or somewhere else. Whatever organization you like is fine, as long as you can eventually import the graders you define into your grading script.
The association between a question ID and the grader that handles that question is done with a GraderMap.
src/rubric/tf.ts
src/rubric/s7_3.ts
and so on...
Then, set up a top-level grading script to create an ExamGrader, register your graders with it, load exams, grade the exams, and write out reports:
src/grade.ts
Note the import of
exam
in the example above. This comes from your exam specification that you've created in a separate file. TODO link to that documentation.You might also have some questions (e.g. open-ended code writing) that require people to manually grade. Calling
gradeAll()
won't fully grade those, but it will trigger the appropriate graders to create grading assignment files. Once those are filled in, just run the grading script again and it will pick up the human-generated results in those files.Several graders are currently supported:
FreebieGrader
- Gives points to everyone (or, optionally, to all non-blank submissions)SimpleMCGrader
- Grades an MC question with one right answerSummationMCGrader
- Grades a multiple-select MC question where each selection is worth positive or negative pointsFITBRegexGrader
- Uses regular expressions to grade each blank in an FITB question. Also comes with an interface for human review of unique answersStandardSLGrader
- Grades SL ("select-a-statement") questions based on which lines should/shouldn't be includedThe format for the graders looks like JSON, but it's actually typescript code defining an object literal, so autocomplete, etc. should be available in VS Code.
For the FITB Regex grader, you'll need to be familiar with javascript regular expression syntax.
^
and$
. For example, if you're looking to match any decimal number/[\d\.]+
will match6.2
andMy answer is 6.2
, whereas^[\d\.]+$
will only match6.2
. Essentially^
means "beginning of string" and$
means "end of string".For now, refer to examples of existing graders. More thorough documentation coming.