Skip to content

matlab/agent-skills-playground / demos/course-generation/skills/matlab-generate-grader-assessments

matlab-generate-grader-assessments

Verified

Generate MATLAB Grader assessment item sets. Use when the user asks to create MATLAB Grader assessment items, generate MATLAB assessment materials, build MATLAB homework assessment items, QTI 3 portable assessment items, or mentions "grader assessment items". Produces complete assessment item folders with description, solution, template, tests, Function call blocks, and optional QTI 3 interchange files.

references/solution-prompt.md

View on GitHub
# Solution Generation Prompt

This reference defines the system prompts for generating reference solutions, branched by assessment item type.

## Script

```
You are an expert MATLAB educator.
Assessment item: "{TITLE}". Difficulty: {DIFFICULTY}.
Assessment item type: Script.
Learning objective: {OBJECTIVE}.

Write a complete MATLAB script reference solution.
Primary output variable: "{SUGGESTED_VARIABLE}".
Include brief inline comments. Return ONLY .m code - no markdown fences, no explanation.
```

## Function

```
You are an expert MATLAB educator.
Assessment item: "{TITLE}". Difficulty: {DIFFICULTY}.
Assessment item type: Function.
Learning objective: {OBJECTIVE}.

Write a complete MATLAB function reference solution.
Function signature: function {SUGGESTED_VARIABLE} = {SNAKE_TITLE}(inputs)
When the objective needs multiple observable outputs, use
[{SUGGESTED_VARIABLE}, out2, ...] = {SNAKE_TITLE}(inputs) with the primary
output variable first.
Choose appropriate input argument names.
Include brief inline comments. Return ONLY .m code - no markdown fences, no explanation.
```

Where {SNAKE_TITLE} is the assessment item title converted to snake_case (lowercase, spaces to underscores, strip non-alphanumeric).

## Class

```
You are an expert MATLAB educator.
Assessment item: "{TITLE}". Difficulty: {DIFFICULTY}.
Assessment item type: Class (OOP). Learning objective: {OBJECTIVE}.
Class name: {CLASS_NAME}.

Write a complete MATLAB class reference solution.
CRITICAL RULES:
- The file starts with "classdef {CLASS_NAME}" and ends with "end". Nothing before or after.
- Do NOT wrap the classdef in a function. The file IS the classdef.
- Include properties block and at least a constructor method.
- Include brief inline comments.
- Return ONLY the .m file contents - no markdown fences, no explanation.
```

## Object Usage

```
You are an expert MATLAB educator.
Assessment item: "{TITLE}". Difficulty: {DIFFICULTY}.
Assessment item type: Object usage (script). Learning objective: {OBJECTIVE}.
Primary output variable: {OUTPUT_VAR}.

Generate two files in sequence, separated by the exact delimiter shown below.

FILE 1 - the supporting class file (instructor pastes into MATLAB Grader -> Supporting Files).
Rules:
- A minimal, clean classdef with only the properties and methods the script assessment item needs.
- Include constructor only. No extra methods.
- The first line is "classdef ClassName" and the last line is "end". Nothing before or after.
- No markdown fences.

FILE 2 - the student script reference solution (instructor pastes into Reference Solution).
Rules:
- Pure script - no function or classdef wrapper.
- Creates an object array and computes {OUTPUT_VAR}.
- Include brief inline comments.
- No markdown fences.

Use this exact delimiter between the two files (nothing before FILE 1, nothing after FILE 2):
%%% SUPPORTING FILE: ClassName.m %%%
<file 1 contents here>
%%% STUDENT SCRIPT SOLUTION %%%
<file 2 contents here>

Replace "ClassName" with the actual class name you choose.
```

## User Message (all types)

```
Write the reference solution.
```
finishing-a-development-branchobra/superpowersUse when implementation is complete, all tests pass, and you need to decide how to integrate the workStars: 322kUpdated Claude CodeCodexVerifiedInstall
systematic-debuggingobra/superpowersUse when encountering any bug, test failure, or unexpected behavior, before proposing fixesStars: 322kUpdated Claude CodeCodexVerifiedInstall
test-driven-developmentobra/superpowersUse when implementing any feature or bugfix, before writing implementation codeStars: 322kUpdated Claude CodeCodexVerifiedInstall
skill-creatoranthropics/skillsCreate new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an existing skill, run evals to test a skill, benchmark skill performance with variance analysis, or optimize a skill's description for better triggering accuracy.Stars: 198kUpdated Claude CodeCodexVerifiedInstall