Agent skill

Format Code

by ROCm in ROCm/FlyDSL

Format, clean up, and style-check changed files, matching the project's CI style gate.

Custom licenceAuto-check: notesDevelopment

Install Format Code

skills CLI
$ npx skills add ROCm/FlyDSL --skill format-code -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install ROCm/FlyDSL format-code --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/ROCm/FlyDSL.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/format-code .claude/skills/format-code && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
format-code
GitHub stars
287
Token cost
~1.9k tokens
SKILL.md length
833 words
Files
1
Skills in repo
19
Repo updated
First seen
Licence
Custom licence

At a glance

Format, clean up, and style-check changed files, matching the project's CI style gate.

  • Works in 6 steps: Prefer the project wrapper → Ensure generic tools are installed → Collect changed files → …
  • The user says format code
  • SKILL.md covers Pipeline, Steps, Check only (reproduce the CI… and Notes
  • Calls bash, git and ruff

What it does

Format Code is an agent skill from ROCm/FlyDSL. Format, clean up, and style-check changed files, matching the project's CI style gate. Formats Python with black + ruff and C/C++ with clang-format using the repository's .clang-format, and can also run check-only to reproduce the CI gate locally without editing files. Use when the user says "format code", "clean up code", "lint", "format before commit", "/format-code", wants to reproduce the "Check Python Code Style" or "Check C++ Code Style" CI jobs locally, is fixing a CI style failure, is about to push Python…

Its SKILL.md is about 1.9k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Development, covering Linting and formatting and Refactoring. It works with C++, Python and Ruff. The repository describes itself as: FlyDSL is the Python front‑end of the project: a Flexible Layout Python DSL for expressing tiling, partitioning, data movement, and kernel structure at a high level.

When your agent uses it

  • The user says format code
  • Format before commit
  • Wants to reproduce the Check Python Code Style
  • Check C++ Code Style CI jobs locally

Example prompts

  • “format code”
  • “clean up code”
  • “format before commit”
  • “/format-code”

Requirements

  • Python 3
  • Pre-approved tools (allowed-tools): Bash, Read, Edit, Grep, Glob

Workflow steps

6 steps, taken from the step headings in SKILL.md.

  1. Prefer the project wrapper
  2. Ensure generic tools are installed
  3. Collect changed files
  4. Format Python files
  5. Format C/C++ files
  6. Inspect diff and report summary

What it can do on your machine

Read from SKILL.md and the folder at commit 1941889. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves these tools, so the agent can use them without asking each time:

    • Bash
    • Read
    • Edit
    • Grep
    • Glob

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • bash
    • git
    • ruff
    • pip
    • black
    • apt-get

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use git and pip, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Format Code loads about 1.9k tokens when it runs. Until then it costs about 148 tokens; SKILL.md has 833 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~148
When it runs · the whole SKILL.md, loaded when a task matches
~1.9k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check: notes

The automated check noted patterns worth knowing about, such as sudo or a known installer.

  • NoteRuns commands with sudoSKILL.md:81
    sudo apt-get install -y clang-format-18 2>/dev/null || pip install clang-format
  • NotePre-approves every shell command (allowed-tools: Bash)SKILL.md
    allowed-tools: Bash, Read, Edit, Grep, Glob

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

Its licence (Custom licence) doesn't allow us to republish the file, so here is its outline and opening line. It has 833 words (~1,903 tokens).

“Format and clean up changed files before committing. Prefer repository-provided style wrappers when they exist, because they encode the same file selection and tool flags as CI. For FlyDSL, use bash scripts/check_python_style.sh --fix for Python style fixes.”

— opening of SKILL.md by ROCm, Custom licence
name
format-code
allowed-tools
Bash, Read, Edit, Grep, Glob

Read the full SKILL.md on GitHub

Files

Just SKILL.md in .claude/skills/format-code of ROCm/FlyDSL.

Open the folder on GitHubat commit 1941889

Compare with similar skills

Format Code next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Format Code compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Format Code this skillROCm/FlyDSL287—~1.9kAutomated safety check: NotesCustom licence
Bump Depsayutaz/piper-plus218—~1.2kAutomated safety check: PassMIT
ONNX Runtime Lintmicrosoft/onnxruntime22k—~392Automated safety check: PassMIT
Tilelang Reviewtile-ai/tilelang-ascend400—~2.8kAutomated safety check: NotesMIT
Python Idiomsirahardianto/awesome-agv157—~4.4kAutomated safety check: PassMIT
LintMicrock/ordinary-claude-skills401—~2.2kAutomated safety check: NotesCustom licence

Similar skills

  • Bump Deps

    ayutaz/piper-plus

    ORT / openjtalk / ruff のような cross-runtime に canonical sync が必要な依存関係を 1 コマンドで bump する read-mostly skill。

    218 GitHub stars~1.2k tokensUpdated yesterday
    DevelopmentAuto-check passed
  • ONNX Runtime Lint

    microsoft/onnxruntime

    Official

    Lints and formats C++ and Python code in the ONNX Runtime repository with lintrunner, clang-format and ruff, preferring a pass over only the changed files.

    22k GitHub stars~392 tokensUpdated yesterday
    DevelopmentAuto-check passed
  • Tilelang Review

    tile-ai/tilelang-ascend

    检查代码格式是否符合 CI 规则。自动检测并安装缺失工具(ruff、clang-format),先运行检查生成报告,使用醒目方式询问用户后,仅在用户同意时执行修复。工作流程:检测环境→自动安装缺失工具→运行检查→生成报告→醒目询问→用户确认→执行修复。使用此技能当:用户要求"格式检查"、"格式化代码"、"代码格式化"、"检查代码格式"、"代码…

    400 GitHub stars~2.8k tokensUpdated 8 days ago
    DevelopmentAuto-check: notes
  • Python Idioms

    irahardianto/awesome-agv

    Modern Python (3.11+) idioms: type annotations, typing Protocols, Pydantic models, asyncio, pytest fixtures, and Ruff/Mypy strict compliance.

    157 GitHub stars~4.4k tokensUpdated 3 days ago
    DevelopmentAuto-check passed
  • Lint

    Microck/ordinary-claude-skills

    Run targeted linting, formatting, and code quality checks on modified files.

    401 GitHub stars~2.2k tokensUpdated 1 mo ago
    DevelopmentAuto-check: notes
  • Kedro Babysit

    kedro-org/kedro

    Run Kedro's local lint / format / type-check / tests on changed files (uses the project's pre-commit hooks, ruff, mypy, pytest, lint-imports, detect-secrets, Make targets — in the right venv), or…

    11k GitHub stars~4k tokensUpdated yesterday
    DevelopmentAuto-check passed

More from ROCm/FlyDSL

All 19 skills in this repo
  • Llvm

    ROCm/FlyDSL

    Tune and analyse a FlyDSL kernel at the LLVM level: pick a compile hint, function attribute, or AMDGPU backend flag, then PROVE it reached codegen.

    287 GitHub stars~4.9k tokensUpdated today
    Auto-check: notes
  • Detect per-kernel GPU resource regressions (VGPR, SGPR, register spills, scratch, static LDS) by diffing the final ISA before and after a change, using its isaresourcetable.py helper.

    287 GitHub stars~2.7k tokensUpdated today
    Auto-check: notes
  • API Stability

    ROCm/FlyDSL

    Review a FlyDSL PR, commit, branch, kernel, or consuming module for API-stability compliance.

    287 GitHub stars~3.2k tokensUpdated today
    Auto-check: notes
  • Build Rocm Image

    ROCm/FlyDSL

    Connect to a remote host via SSH and build a Docker image with rocprofv3, aiter, and FlyDSL.

    287 GitHub stars~1.2k tokensUpdated today
    Auto-check: notes
  • Debug FlyDSL GPU kernels that produce NaN, inf, wrong results, or crash.

    287 GitHub stars~2.6k tokensUpdated today
    Auto-check: notes
  • Guided step-by-step wizard for producing a new FlyDSL GPU kernel from a requirement: classify the kernel type, pick a skeleton, fill in compute, add control flow / sync / LDS, then test on GPU.

    287 GitHub stars~4.6k tokensUpdated today
    Auto-check: notes

Works with

Categories

Questions about Format Code

What does Format Code do?

Format, clean up, and style-check changed files, matching the project's CI style gate. Format Code is an agent skill from ROCm/FlyDSL. Format, clean up, and style-check changed files, matching the project's CI style gate.

When should I use Format Code?

Format Code fits situations like: the user says format code; format before commit; wants to reproduce the Check Python Code Style; check C++ Code Style CI jobs locally.

How do I install Format Code in Claude Code?

Run `npx skills add ROCm/FlyDSL --skill format-code -a claude-code`. Or copy the skill folder (.claude/skills/format-code in ROCm/FlyDSL) into .claude/skills/format-code in your project. Claude Code loads it when a task matches its description.

How do I install Format Code in Codex?

Run `npx skills add ROCm/FlyDSL --skill format-code -a codex`. Or copy the skill folder (.claude/skills/format-code in ROCm/FlyDSL) into .agents/skills/format-code in your project. Codex loads it when a task matches its description.

Can I use Format Code in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add ROCm/FlyDSL --skill format-code -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/format-code, .gemini/skills/format-code, .github/skills/format-code and .opencode/skills/format-code in your project.

What does Format Code need to run?

Going by SKILL.md and its folder, Format Code needs the command-line tools its instructions call (bash, git, ruff, pip, black and apt-get). Our summary lists: Python 3. Its frontmatter pre-approves these tools: Bash, Read, Edit, Grep, Glob.

Does Format Code access the network?

SKILL.md contains no URLs. Its commands use git and pip, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Format Code safe to install?

Our automated static check of SKILL.md found notes only (runs commands with sudo; pre-approves every shell command (allowed-tools: bash)), nothing it rates as a warning. It is not a guarantee. Review the folder before installing.

What licence does Format Code use?

Format Code has a licence file (the repository's licence) that doesn't match a standard licence. Read it on GitHub before reusing the skill.

How many tokens does Format Code use?

About 1.9k tokens (SKILL.md is roughly 7.6k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Format Code?

Skills that share tags, products or a category with Format Code: Bump Deps (ayutaz/piper-plus, 218 stars), ONNX Runtime Lint (microsoft/onnxruntime, 22k stars), Tilelang Review (tile-ai/tilelang-ascend, 400 stars) and Python Idioms (irahardianto/awesome-agv, 157 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Format Code?

ROCm (a GitHub organization) maintains it in ROCm/FlyDSL, which has 287 GitHub stars. The repository holds 19 skills in this directory. The repository was last updated on October 7, 2026.

Source: ROCm/FlyDSL on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.