Generate or improve MATLAB help text (documentation comments) for a function, class, or script file following MathWorks standards (H1 line, syntax paragraphs, See Also, 75-char lines). Read BEFORE writing MATLAB help — default patterns (Inputs:/Outputs: lists, block comments, uppercase See Also) produce non-conforming output.
SkillScore78Maintained
Automatic
◆Doc Ops pack
Last verified 8/16/2026
What it changes
Passed 16 of 20 test cases with the skill, and 10 of 20 without it.
Without skill52%
With skill78%
Checks it passed that the model alone missed
The See Also line does not end with a period.
Protected methods receive only an H1 summary line.
The response states that comment lines must not exceed 75 characters.
and 6 more in the full report
8 fixed10 passed either way3 still failing2 broke
Pass-rate lift
+26 pp
Tokens
+182%
Agent turns
0%
Response time
-56%
Model gemini-3.6-flashMeasured 8/16/2026v118 of 23 cases passed with skill · 20 comparable
Tokens, turns and time describe resource use, not a dollar price.
See it in action
One of 8 test cases the skill fixed. Same model, same prompt, with and without the skill.
1 of 8
Prompt
In a `classdef` file help header, what exact heading should precede the listing of public methods?
What was checked, without and with the skill
Checked
Without skill
With skill
The response specifies the heading format `CLASSNAME functions:` using the word functions.
Missed
Passed
case-13 · gemini-3.6-flash · 8/16/2026 · answers are capped and redacted
What's inside
The instructions your model reads when the skill loads.
SKILL.md478 linessingle file
When to Use
Writing help text for a new MATLAB function, class, or script
Rewriting or improving existing help text that is incomplete or non-conforming
Reviewing help text for standards compliance
Adding help to methods in a classdef file
Generating property comments for a class
When NOT to Use
Writing general documentation or README files (not help comments)
Generating code — this skill only produces help text
Working with non-MATLAB languages
Writing MATLAB Live Script markup (use plain-text-live-code guidelines instead)
Task
Resolve $file to an M-file path and generate complete, standards-compliant MATLAB help text for it. If the file already has help text, improve it to meet the standards below. Present the proposed help text to the user for review before modifying the file.
Standards for MATLAB Help Text
All rules below are mandatory. Violating any of them produces non-conforming help.
General Rules
Help begins on line 2 (after function or classdef line) for functions/classes
Help begins on line 1 for scripts or built-in sidecar files
Help comments must match the indentation of the body code.
Look at the first non-comment content after the help block to
determine the indentation level:
For classdef files: the body is properties/methods blocks,
which are always indented 4 spaces → class help at 4 spaces
For function files: look at the first executable statement.
If at column 1, help at column 1; if at 4 spaces, help at 4 spaces.
Example at 4-space indent:
function result = myFunc(x)
%myFunc - Brief description
% RESULT = myFunc(X) does something with X.
result = x + 1;