Agent skill

Profile Dart Code

by kevmoo in kevmoo/dash_skills

Profile Dart command-line applications using the VM Service protocol to capture CPU samples and identify performance bottlenecks.

Apache-2.0Auto-check passedMobile

Install Profile Dart Code

skills CLI
$ npx skills add kevmoo/dash_skills --skill profile-dart-code -a claude-code

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

GitHub CLI
$ gh skill install kevmoo/dash_skills profile-dart-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/kevmoo/dash_skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/profile-dart-code .claude/skills/profile-dart-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
profile-dart-code
GitHub stars
147
Token cost
~1.1k tokens
SKILL.md length
434 words
Files
5 (incl. scripts)
Skills in repo
12
Repo updated
First seen
Licence
Apache-2.0

At a glance

Profile Dart command-line applications using the VM Service protocol to capture CPU samples and identify performance bottlenecks.

  • Works in 3 steps: Ensure clean compilation: Make sure the… → Run Profiler Script: Use the automated… → Analyze & Optimize: Review the self and…
  • Tasks that involve Cross-platform mobile apps
  • SKILL.md covers When to use this skill, Workflow, Running the Profiler Helper… and Best Practices for…
  • Runs Dart scripts from its folder; calls dart

What it does

Profile Dart Code is an agent skill from kevmoo/dash_skills. Profile Dart command-line applications using the VM Service protocol to capture CPU samples and identify performance bottlenecks. Helps agents automate CPU profiling, generate function call breakdown summaries, and export JSON profiles without a browser or DevTools.

Its SKILL.md is about 1.1k tokens, which your agent loads only when the skill is triggered. The skill folder holds 8 other files, including scripts (for example `evals/evals.json` and `scripts/pubspec.yaml`).

It sits in Mobile, covering Cross-platform mobile apps and Performance optimization. It works with Dart and Flutter. The repository describes itself as: Agent Skills for Dart and Flutter ecosytem. The licence is Apache-2.0.

When your agent uses it

  • Tasks that involve Cross-platform mobile apps
  • Tasks that involve Performance optimization

Example prompts

  • “/profile-dart-code”

Workflow steps

3 steps, taken from the first numbered list in SKILL.md.

  1. Ensure clean compilation: Make sure the target Dart script runs cleanly
  2. Run Profiler Script: Use the automated profiling helper script inside
  3. Analyze & Optimize: Review the self and total sample percentages reported

What it can do on your machine

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

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Ships 3 files in scripts/ (Dart), which the agent can run.

    Shell commands in SKILL.md call:

    • dart

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

  • Network

    No URLs in SKILL.md.

    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

Profile Dart Code loads about 1.1k tokens when it runs. Until then it costs about 71 tokens; SKILL.md has 434 words of instructions outside code blocks.

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

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 passed

The automated check found no risky patterns in SKILL.md.

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); the scripts in this folder are not scanned.

SKILL.md

The full file from kevmoo/dash_skills at commit d3439fb, republished under its Apache-2.0 licence (© kevmoo). 434 words, ~1,079 tokens.

Download SKILL.mdSave it as .claude/skills/profile-dart-code/SKILL.md (or your agent's skills folder). This skill also uses 4 other files; get the full folder from GitHub.
name
profile-dart-code
description
Profile Dart command-line applications using the VM Service protocol to capture CPU samples and identify performance bottlenecks. Helps agents automate CPU profiling, generate function call breakdown summaries, and export JSON profiles without a browser or DevTools.
key_features
Automated VM Service WebSocket connection, CPU sampling and top-function call summary, JSON trace export for further analysis

Dart CPU Profiling

Guidelines and automated tools for capturing CPU profiles and identifying bottlenecks in Dart command-line applications.

When to use this skill

  • When asked to profile, optimize, or benchmark CPU execution of a Dart script or CLI tool.
  • When investigating hot loops, heavy function calls, or unexpected execution overhead.
When NOT to use (Abstention Guardrails)

Do NOT profile using this skill when:

  • Pure I/O-Bound Bottlenecks: The performance bottleneck is network latency, database queries, or disk I/O wait rather than CPU execution.
  • Flutter UI Applications: The target is a Flutter application requiring frame profiling, raster thread inspection, or widget rebuild tracking (use Flutter DevTools or widget_inspector).
  • Short-Lived Micro-Benchmarks: Micro-benchmarks running for only a few milliseconds where VM warmup and sampling overhead skew results (use package:benchmark_harness or package:bench_press instead).
  • Target Does Not Run Cleanly: If the target script fails to compile or crashes on startup, fix functional bugs before attempting CPU profiling.

Workflow

  1. Ensure clean compilation: Make sure the target Dart script runs cleanly (dart run <script.dart>).
  2. Run Profiler Script: Use the automated profiling helper script inside this skill directory to launch the target app with VM Service observability enabled, capture CPU samples, and output top-consuming functions.
  3. Analyze & Optimize: Review the self and total sample percentages reported by the tool to pinpoint bottlenecks (e.g., excessive object allocation, costly hashing, virtual dispatch overhead).

Running the Profiler Helper Script

This repository includes a zero-dependency (using only official vm_service) profiling script that launches any Dart file, connects to the VM Service, waits for execution to complete (--pause-isolates-on-exit), retrieves CPU samples, and prints a clean summary while exporting the full JSON profile.

Run it from any working directory:

bash
dart run <dash_skills_repo>/skills/profile-dart-code/scripts/bin/profile.dart --out=cpu_profile.json -- <path_to_target.dart> [target_arguments...]
Show full SKILL.md (158 more words)Show less
Script Arguments
  • -o, --out=<file>: Output file path to save the raw JSON CPU profile (default: cpu_profile.json).
  • -p, --period=<micros>: Sampling interval in microseconds (default: 1000µs = 1ms). Minimum 50µs.
  • -- <target.dart> [args...]: The Dart script to profile, followed by any arguments passed to main().

[!WARNING] Potential Hangs: When profiling or debugging Dart targets using VM services, target exceptions or connection issues can cause the process to hang indefinitely. Ensure your target script handles timeouts, and monitor the process output.

Example Output
Connecting to VM service at ws://127.0.0.1:8181/ws...
Target execution paused at exit. Retrieving CPU profile samples...

=== Top CPU Functions (Self Samples) ===
 1. _PuzzleSmart._shiftSlice (self: 34.2%, total: 41.0%)
 2. _countInversions (self: 18.5%, total: 18.5%)
 3. shortestPaths (self: 12.1%, total: 98.4%)

Saved complete JSON profile to: cpu_profile.json

Best Practices for Interpreting Profiles

  1. Focus on Self % vs. Total %: High self % indicates where CPU time is spent directly inside a function's own body (math, loop branching, array indexing). High total % with low self % indicates a dispatcher or outer orchestration loop.
  2. Look for Hidden Overhead: Watch out for implicit object allocations (_copyData, iterator wrappers, closure creation) inside tight loops.
  3. Verify Optimizations Empirically: Always record baseline sample counts and execution duration (time -v) before and after applying optimizations.

© kevmoo, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 4 other files (scripts) in skills/profile-dart-code of kevmoo/dash_skills.

  • SKILL.md
  • evals/evals.json
  • scripts/bin/profile.dart
  • scripts/pubspec.yaml
  • scripts/test/profile_test.dart

Open the folder on GitHubat commit d3439fb

Compare with similar skills

Profile Dart 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.

Profile Dart Code compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Profile Dart Code this skillkevmoo/dash_skills147—~1.1kAutomated safety check: PassApache-2.0
Engine Whats Newflutter/flutter179k—~978Automated safety check: PassBSD-3-Clause
Flutter Cherry Pickflutter/flutter179k—~1.8kAutomated safety check: PassBSD-3-Clause
Upgrade Browserflutter/flutter179k—~1.1kAutomated safety check: PassBSD-3-Clause
Bump Dartflutter/flutter179k—~1.2kAutomated safety check: PassBSD-3-Clause
Run Devicelab With Ledflutter/flutter179k—~786Automated safety check: PassBSD-3-Clause

Similar skills

  • Engine Whats New

    flutter/flutter

    Generates the "what's new" release summary and diff file for changes in the Flutter engine (//engine/src/flutter) between two releases (e.g., 3.47 vs 3.44).

    179k GitHub stars~978 tokensUpdated today
    MobileAuto-check passed
  • Flutter Cherry Pick

    flutter/flutter

    How to land a formal cherry-pick of a merged PR for the flutter/flutter repo stable or beta channel.

    179k GitHub stars~1.8k tokensUpdated today
    MobileAuto-check passed
  • Upgrade Browser

    flutter/flutter

    Upgrade browser versions (Chrome or Firefox) in the Flutter Web Engine and/or Framework tests.

    179k GitHub stars~1.1k tokensUpdated today
    MobileAuto-check passed
  • Bump Dart

    flutter/flutter

    Do not trigger automatically; only run when a user runs /bump-dart.

    179k GitHub stars~1.2k tokensUpdated today
    MobileAuto-check passed
  • Run Devicelab With Led

    flutter/flutter

    Run DeviceLab tests for Flutter PRs using LUCI's led CLI tool.

    179k GitHub stars~786 tokensUpdated today
    MobileAuto-check passed
  • Shepherd PRs

    flutter/flutter

    Automate shepherding, checking status, updating branches, and landing open PRs or approved third-party contributor PRs in the flutter/flutter repository using the gh CLI.

    179k GitHub stars~1.7k tokensUpdated today
    MobileAuto-check passed

More from kevmoo/dash_skills

All 12 skills in this repo
  • Dart Test Coverage

    kevmoo/dash_skills

    Understand and improve test coverage in a Dart package. An agent skill from kevmoo/dash_skills.

    147 GitHub stars~1.1k tokensUpdated today
    Auto-check passed
  • Dart Best Practices

    kevmoo/dash_skills

    General best practices for Dart development. An agent skill from kevmoo/dash_skills.

    147 GitHub stars~709 tokensUpdated today
    Auto-check passed
  • Dart Doc Validation

    kevmoo/dash_skills

    Best practices for validating Dart documentation comments. An agent skill from kevmoo/dash_skills.

    147 GitHub stars~822 tokensUpdated today
    Auto-check passed
  • Dart Long Lines

    kevmoo/dash_skills

    Guidelines for handling long lines in Dart code to adhere to the 80-column rule.

    147 GitHub stars~1k tokensUpdated today
    Auto-check passed
  • Dart Matcher Best Practices

    kevmoo/dash_skills

    Best practices for using expect and package:matcher. An agent skill from kevmoo/dash_skills.

    147 GitHub stars~1.6k tokensUpdated today
    Auto-check passed
  • Dart Modern Features

    kevmoo/dash_skills

    Guidelines for using modern Dart features (v3.0 - v3.10) such as Records, Extension Types, Class Modifiers, Wildcards, Digit Separators, Null-Aware Elements, and Dot Shorthands.

    147 GitHub stars~1.6k tokensUpdated today
    Auto-check passed

Works with

Categories

Questions about Profile Dart Code

What does Profile Dart Code do?

Profile Dart command-line applications using the VM Service protocol to capture CPU samples and identify performance bottlenecks. Profile Dart Code is an agent skill from kevmoo/dash_skills. Profile Dart command-line applications using the VM Service protocol to capture CPU samples and identify performance bottlenecks.

When should I use Profile Dart Code?

Profile Dart Code fits situations like: tasks that involve Cross-platform mobile apps; tasks that involve Performance optimization.

How do I install Profile Dart Code in Claude Code?

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

How do I install Profile Dart Code in Codex?

Run `npx skills add kevmoo/dash_skills --skill profile-dart-code -a codex`. Or copy the skill folder (skills/profile-dart-code in kevmoo/dash_skills) into .agents/skills/profile-dart-code in your project. Codex loads it when a task matches its description.

Can I use Profile Dart 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 kevmoo/dash_skills --skill profile-dart-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/profile-dart-code, .gemini/skills/profile-dart-code, .github/skills/profile-dart-code and .opencode/skills/profile-dart-code in your project.

What does Profile Dart Code need to run?

Going by SKILL.md and its folder, Profile Dart Code needs Dart for the scripts in its folder and the command-line tools its instructions call (dart).

Does Profile Dart Code access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Profile Dart Code safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.

What licence does Profile Dart Code use?

Profile Dart Code is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Profile Dart Code use?

About 1.1k tokens (SKILL.md is roughly 4.3k 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 Profile Dart Code?

Skills that share tags, products or a category with Profile Dart Code: Engine Whats New (flutter/flutter, 179k stars), Flutter Cherry Pick (flutter/flutter, 179k stars), Upgrade Browser (flutter/flutter, 179k stars) and Bump Dart (flutter/flutter, 179k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Profile Dart Code?

kevmoo (a GitHub user) maintains it in kevmoo/dash_skills, which has 147 GitHub stars. The repository holds 12 skills in this directory. The repository was last updated on October 8, 2026.

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