Teacher: need for individual exercises for each student
The need is to provide different exercises for each student, particularly in online exams. Ways of implementing this can include
- using one exercise including variables in e.g. calculations or formula, and randomizing the variables for each student
- using multiple exercises and randomizing the whole exercises for each student
For example, if the student should transform a logical formula, each student should receive their own formula (depending on the focus of the randomization needs, e.g. STACK might already provide some solutions). The randomization could be e.g. generated synchronously by using the student ID (user ID) as the random seed.
Tomi did not want to try the existing personalized exercises feature of the MOOC-Grader because it is clunky and requires that the server admin runs the exercise instance generator in the server before the exercises are published to the students. Tomi is more interested in synchronous "on-the-fly" generation, but this requires that even opening the exercise description includes some custom, exercise-specific computation in the MOOC-Grader server.
Computation for the exercise GET request affects the server's performance negatively and it is a challenge to execute the teacher's custom code safely. Launching a container for safe code execution at that time might be way too slow. Thas is, per request it would not be a good idea, instead we should look into using serverless technologies with prewarming.
As a long term solution, we could use serverless code for form generation (see grader v2 ideas). In addition, the A+ protocol should be updated to support initial seed, which would be stored in A+ and returned to grader later on.
For now, the seed part can be hacked using signed data in the form (e.g. JWT). Though, every time server secret changes, the old forms can not be submitted or regraded. It would be good to find a teacher who needs the feature, and ask their course assistant to implement the exercise.
For now, the seed part can be hacked using signed data in the form (e.g. JWT). Though, every time server secret changes, the old forms can not be submitted or regraded. It would be good to find a teacher who needs the feature, and ask their course assistant to implement the exercise.
Looking for a course to prototype this and to find out if above concept solves the usecase for them.
How is this solved in TRAK-Y @arikorhonen ? Can the solution be used by others?
As far as I can see, this thread is related to a feature already implemented in A+. See A+-manual https://plus.cs.aalto.fi/aplus-manual/master/programming_exercises/personalized_exercises/ for more info. However, if that is not feasible solution, there is workaround, which @teemulehtinen implemented for TTS where the student gets one of the two alternative exercises (see Tehtävä 1: Ensimmäinen a-kirjaimella alkava sana https://plus.cs.aalto.fi/tietotekniikka-sovelluksissa/2024/bonus0/kertaustehtavat/#chapter-exercise-1), which is either Laki or Runo.
This is where the variations are implemented in that exercise:
https://version.aalto.fi/gitlab/course/cs-a1130/-/blob/2024/python1/a_sanan_paikka/accept_files.html
The accept-files view has access to the UID of the student which is then used to render a different page for different students