0xmiden/agent-tools/masm-inline-comments
Claude Code and agent skill by 0xmiden/agent-tools
- community
Checking that the SKILL.md file is still in the repository.
Enforce inline commenting conventions for Miden Assembly (.masm) files. Use when editing, reviewing, or creating .masm files.
Install
npx vskill@latest install 0xmiden/agent-tools/masm-inline-commentsSKILL.md
MASM Inline Commenting Conventions
Rules
1. Inline comments start lowercase
Inline comments (single #) should begin with a lowercase letter.
2. Don't over-comment obvious operations
Only add comments that provide value. Skip comments for self-explanatory operations. Only apply this rule to new code you write. Do not remove comments that are present in the code.
Skip comments for:
- Simple arithmetic:
add,sub,mul,div - Basic stack ops when context is clear:
drop,swap,dup - Standard control flow:
if.true,while.true,end
Do comment:
- Stack state after complex operations:
# => [ptr, ASSET_ID, ASSET_VALUE, end_ptr] - Purpose of a code block:
# compute the pointer at which we should stop iterating - Non-obvious logic or business rules
- TODO items and references to external specs
3. Blank line after # => [...] trackers
Insert a blank line after a # => [...] stack-state tracker, except when the next non-blank line is one of:
end(proc /while.true/if.true/repeat.Nclosing).- A control-flow keyword such as
else,else.true, orelse.false. - Another
# =>line that continues the same multi-line stack state. - A
#continuation comment that explains the tracker.
This pairs each stack state visually with the operation that produced it and lets the eye skim from one labeled state to the next.
Good:
Also OK (no blank line before `end` or control flow):
4. Match the doc block
An inline # => [...] tracker uses the same item names, capitalization, and (N) span notation as the #! doc block for the enclosing procedure (see masm-doc-comments skill):
- Single-felt names stay lowercase:
note_idx,final_nonce. - Word names stay UPPERCASE:
ASSET_ID,ASSET_VALUE,RECIPIENT. (N)spans stay lowercase:pad(12),foreign_procedure_inputs(15).
Composite names like account_id_{suffix,prefix} are a doc-block shorthand for a group of felts. In inline trackers they decompose into their individual felts since each felt occupies one stack slot:
5. Reuse existing terminology
Use the vocabulary already established in the surrounding code and doc comments. Do not coin new terms or colloquialisms for a concept that already has a name — a value written to a local is "stored", not "stashed". This applies to inline comments and to constant-header comments.
6. Comment the code, not the change or the design
Inline comments explain what the code does for a future reader, not why a particular PR made a change. Avoid PR narrative and framing such as "this is the X that prevents Y"; describe the operation and its purpose as the code stands.
An inline comment states, in one line, what the next instruction block does or which invariant it relies on. It does not:
- explain why the design is the way it is, or which alternatives were rejected
- restate reasoning from a PR review or from the procedure's
#!doc comment - justify the ordering of steps with rationale; that belongs in the doc comment (see masm-doc-comments skill)
Avoid (implementation detail and rationale in an inline comment):
Good:
7. Accessing a word's individual elements
When accessing individual elements of a word, show the word destructured into elements, grouped with brackets, e.g.:
Examples
Good:
Avoid:
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/masm-inline-comments/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/0xmiden/agent-tools/masm-inline-comments)