Install
$ agentstack add skill-wzyn20051216-matlab-agent-skills-matlab-runner ✓ scanned · ✓ verified — works with Claude Code, Cursor, and more.
Security review
✓ PassedNo issues found. Passed automated security review. · v0.1.0 How review works →
- ✓ Prompt-injection patterns
- ✓ Secret / credential exfiltration
- ✓ Dangerous shell & filesystem operations
- ✓ Untrusted network calls
- ✓ Known-malicious package signatures
What it can access
- ✓ Network access No
- ✓ Filesystem access No
- ✓ Shell / process execution No
- ✓ Environment & secrets No
- ✓ Dynamic code execution No
From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.
About
MATLAB Runner
Use this skill to execute MATLAB work safely and repeatably through the official MATLAB MCP server, preferably in auto mode, and only use terminal batch workflows when the user explicitly asks for them. It is the foundation skill for all other MATLAB skills.
Execution Rules
- Prefer the official MATLAB MCP auto mode for MATLAB work on this machine.
- Do not silently fall back to
matlab -batchwhen MCP is expected. - Capture logs, version info, working directory, and artifact paths where applicable.
- Run from a project root, not from a random temporary folder, unless isolation is required.
- Put generated files under
artifacts/or a user-specified output folder. - Keep scripts deterministic: seed random generators and record data sources.
MCP Required By Default
When using this repository on this machine, use this decision rule:
- Prefer official MATLAB MCP auto mode, so the server can reuse an existing shared session or start MATLAB automatically.
- If the task requires repeated model edits, parameter sweeps with live inspection, or user-visible desktop interaction, stay on MCP.
- Batch mode is reserved for explicit user requests such as CI, headless smoke tests, or reproducible one-shot runs.
- If MCP is unavailable, report the blocker instead of silently changing execution mode.
Preferred Wrapper
If the user explicitly requests batch execution in this repository, prefer:
powershell -ExecutionPolicy Bypass -File .\scripts\Invoke-MatlabBatch.ps1 -Script .\path\to\script.m
For official MCP auto-mode setup and validation in this repository, prefer:
powershell -ExecutionPolicy Bypass -File .\scripts\Setup-MatlabMcpExistingSession.ps1
powershell -ExecutionPolicy Bypass -File .\scripts\Test-MatlabMcpExistingSession.ps1
For a full local smoke test:
powershell -ExecutionPolicy Bypass -File .\scripts\Test-MatlabSkills.ps1
If the wrapper is not available, call MATLAB directly:
matlab -batch "disp(version); v=ver; disp({v.Name}')"
MATLAB Discovery
Use this order to find MATLAB:
- Official MATLAB MCP auto configuration
- Existing official MATLAB shared session metadata when present
$env:MATLAB_EXE,Get-Command matlab, and known install paths only for setup/verification of the MCP environment
Verify before running expensive work:
disp(version)
v = ver;
{v.Name}'
Error Handling
When MATLAB fails:
- Read the first error and the deepest stack frame.
- Check missing toolbox with
license('test', product)andver. - Check path ambiguity with
which functionName -all. - Re-run a minimal reproduction before editing large code.
- Save the failing command and log path.
- If the failure was on MCP, report the exact MCP blocker and stop hiding it behind a batch rerun.
Acceptance Checks
Choose at least one:
- Unit test passes with
runtestsandassertSuccess. - Numerical tolerance check passes.
- Simulink model simulates to stop time and logged signals are nonempty.
- Figure, data file, report, or generated code exists and has nonzero size.
- Static checks such as
checkcodereturn no critical issues for touched files.
Paper Reproduction Mode
For open-source paper projects:
- Record paper URL, commit hash, dataset URL, MATLAB release, toolbox list.
- Run the smallest official example first.
- Reproduce one figure or table before scaling to the whole paper.
- Save
manifest.json, raw logs, processed data, and generated figures. - Mark differences from the paper explicitly instead of smoothing them over.
Source & license
This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.
- Author: wzyn20051216
- Source: wzyn20051216/matlab-agent-skills
- License: MIT
- Homepage: https://github.com/wzyn20051216/matlab-agent-skills
Install and usage instructions live in the source repository linked above.
Reviews
No reviews yet — be the first.
Write a review
Versions
- v0.1.0 Imported from the upstream source.