MATLAB Hands-On Exercise Builder & Grader
A MATLAB tutoring skill that builds runnable exercises, executes them in MATLAB, compares actual vs. expected output, and gives style feedback.
EducationIntermediate★ 178⑂ 32AI score 8/10Last updated: Sep 10, 2026
What it does
- Runs a full practice loop: one-sentence goal → explicit expected outputs and assessment criteria → complete runnable script scaffold with a marked learner section.
- Bans grading by visual inspection: saves a temporary
.mfile, applies an execution-safety preflight, then runscheck_matlab_codeandrun_matlab_fileand inspects real MATLAB output. - Delivers MATLAB Grader–style formative assessment without Grader: variable existence, class/size/value checks, tolerance-based numeric comparison, required/forbidden functions, custom checks for plots, tables, errors and edge cases.
- Offers seven exercise types — Trace, Edit, Debug, Refactor, Test (matlab.unittest), Analyze, Visualize — favoring the shortest exercise that exposes the misconception.
- Treats learner code as untrusted: avoids file I/O, network calls,
delete,rmdir, shell commands and long simulations unless explicitly required and scoped.
Who it's for
- MATLAB instructors and TAs running courses or lab sections
- Educators who want automated formative feedback without a MATLAB Grader license
- Engineering/science students self-studying MATLAB who want execution-based feedback
Examples
- "Create a 5-line exercise on row vs. column vectors" → goal, expected output, scaffold; after the learner fills it in, the script is executed and the size mismatch is pinpointed.
- "Grade this student script" → safety preflight, MATLAB run, tolerance-based comparison of expected variables, pass/fail list plus Code Analyzer warnings.
- "Give me a matlab.unittest writing drill for this function" → drill assigned, tests executed, missing edge cases identified, one extension prompt offered.
· · · Install guide · · ·
Try it now, no install
Paste this into Claude to use the skill without installing anything.
Read the instructions in this file and follow them to help me: https://raw.githubusercontent.com/matlab/agent-skills-playground/HEAD/demos/ai-tutoring/skills/matlab-create-hands-on-exercises/SKILL.md What I want: (describe your task here)
If Claude can't open the link, open it yourself and paste the contents instead.
↓ If it works for you, download the ZIP below and install it. Then it runs on its own — no pasting each time.
Install in the Claude app (no terminal)
- Download the ZIP with the button below.
- In Claude, open Settings → Capabilities and turn on 'Code execution and file creation'. (one time)
- Go to Customize → Skills → + → 'Upload a skill' and upload the ZIP.
Install in Claude Code
Let Claude do it — paste this into Claude Code
Install the skill I found on Claude Skill Mart. Copy the demos/ai-tutoring/skills/matlab-create-hands-on-exercises folder from the GitHub repo matlab/agent-skills-playground into my ~/.claude/skills/matlab-create-hands-on-exercises/. When it's done, tell me in one line what this skill can do.
Install with a command instead
git clone https://github.com/matlab/agent-skills-playground.git && mkdir -p ~/.claude/skills && cp -r agent-skills-playground/demos/ai-tutoring/skills/matlab-create-hands-on-exercises ~/.claude/skills/⚠ This is a third-party skill. Check the source repository before installing.
- Open a terminal.
- Clone the repository:
git clone https://github.com/matlab/agent-skills-playground.git - Create the skills directory:
mkdir -p ~/.claude/skills - Copy the skill:
cp -r agent-skills-playground/demos/ai-tutoring/skills/matlab-create-hands-on-exercises ~/.claude/skills/ - Verify the
references/folder (execution-safety.md, exercise-patterns.md, script-assessment-patterns.md) came along. - Configure MATLAB tooling / an MCP server so Claude can call
run_matlab_fileandcheck_matlab_code. - Restart Claude Code and try: "Create a hands-on MATLAB exercise on indexing."
View source on GitHub ↗License: NOASSERTION