Agent skill

Codspeed Debug

by cometkim in cometkim/unicode-segmenter

Investigate CodSpeed CI performance reports on PRs — regressions or improbable improvements that don't reproduce locally.

MITAuto-check passed

Install Codspeed Debug

skills CLI
$ npx skills add cometkim/unicode-segmenter --skill codspeed-debug -a claude-code

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

GitHub CLI
$ gh skill install cometkim/unicode-segmenter codspeed-debug --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/cometkim/unicode-segmenter.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/codspeed-debug .claude/skills/codspeed-debug && 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
codspeed-debug
GitHub stars
112
Token cost
~814 tokens
SKILL.md length
426 words
Files
1
Skills in repo
4
Repo updated
First seen
Licence
MIT

At a glance

Investigate CodSpeed CI performance reports on PRs — regressions or improbable improvements that don't reproduce locally.

  • The CodSpeed check flags a delta and you need to replicate
  • SKILL.md covers How the instrumented…, Local replication recipe and Other V8 behaviors that have…
  • Calls node

What it does

Codspeed Debug is an agent skill from cometkim/unicode-segmenter. Investigate CodSpeed CI performance reports on PRs — regressions or improbable improvements that don't reproduce locally. Use when the CodSpeed check flags a delta and you need to replicate or explain it.

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

The repository describes itself as: A lightweight implementation of the Unicode Text Segmentation (UAX 29). The licence is MIT.

When your agent uses it

  • The CodSpeed check flags a delta and you need to replicate

Example prompts

  • “/codspeed-debug”

What it can do on your machine

Read from SKILL.md and the folder at commit 5d3c738. 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

    Shell commands in SKILL.md call:

    • node

    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

Codspeed Debug loads about 814 tokens when it runs. Until then it costs about 55 tokens; SKILL.md has 426 words of instructions outside code blocks.

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

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); files beside SKILL.md are not scanned.

SKILL.md

The full file from cometkim/unicode-segmenter at commit 5d3c738, republished under its MIT licence (© cometkim). 426 words, ~814 tokens.

Download SKILL.mdSave it as .claude/skills/codspeed-debug/SKILL.md (or your agent's skills folder).
name
codspeed-debug
description
Investigate CodSpeed CI performance reports on PRs — regressions or improbable improvements that don't reproduce locally. Use when the CodSpeed check flags a delta and you need to replicate or explain it.

Debugging CodSpeed results

CI (.github/workflows/codspeed.yml) runs node benchmark/grapheme/codspeed.js (tinybench + @codspeed/tinybench-plugin) under CodSpeedHQ/action in simulation mode: a valgrind-style instrumented VM counting simulated CPU work, not wall clock. Its numbers routinely disagree with mitata.

How the instrumented measurement differs from mitata

  • V8 runs with stability flags (e.g. --predictable --hash-seed=1) and the plugin measures roughly: a few warmup calls → forced gc() → one measured call.
  • Consequence 1: the measured call sees whatever tier the code reached during warmup. The repo defends with a 2000-iteration beforeAll warmup in codspeed.js — do not remove it.
  • Consequence 2 (the big trap): forced GC clears weak references embedded in optimized code (deopt reason: embedded weak objects cleared — e.g. hidden-class maps of objects with no live instances), so optimized code deopts right before the measured call, producing phantom regressions up to ~60%.
    • src/grapheme.js carried a defense against this from #133 to #145: a block stashing a live generator and its first result on PAIR._keep, so the segment-object hidden classes stayed strongly reachable across GC. It was removed after measuring it inert on the current (generator-based) code — the deopt it guarded was diagnosed on a class-iterator rewrite that never shipped. If you re-add anything like it, note that a module-scope const _keep = ... does NOT work: unreferenced module bindings don't survive module evaluation, so the pin has to hang off an object that stays reachable.
    • Before re-adding it, measure it properly: a single instrumented call cannot resolve this for graphemeSegments, which allocates ~120 objects per call, so whether a scavenge lands inside the measured call swings it ±30%. Run 50 { gc(); one call } cycles under callgrind and subtract a { gc() }-only run of the same shape; that showed 92,965 vs 92,915 instructions per call (0.05%), with the pin making each major GC ~26 k instructions more expensive.
Show full SKILL.md (131 more words)Show less

Local replication recipe

Write a scratch script that mimics the protocol per case: N warmup calls, globalThis.gc(), then time exactly one call. Run with:

node --expose-gc --predictable --hash-seed=1 scratch.mjs

Diagnose tiering with --trace-deopt, --trace-opt, and --trace-baseline; a deopt logged between the gc() and the measured call is the smoking gun.

Other V8 behaviors that have bitten this repo

  • Sparkplug (baseline) compiles in batches with a ~4 KiB source-length threshold: one huge function can be compiled alone or later than the same logic split into smaller functions, so pure source-size changes can shift tier-up timing and show up as CodSpeed deltas unrelated to algorithmic cost.
  • Deltas under ~5% in simulation mode are noise. Before reacting to anything, open the flame diff on codspeed.io and check whether the changed frames are in the segmenter or in the harness/GC.

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

Files

Just SKILL.md in .claude/skills/codspeed-debug of cometkim/unicode-segmenter.

Open the folder on GitHubat commit 5d3c738

Compare with similar skills

Codspeed Debug 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.

Codspeed Debug compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Codspeed Debug this skillcometkim/unicode-segmenter112—~814Automated safety check: PassMIT
Debugasgeirtj/system_prompts_leaks69k—~439Automated safety check: PassCC0-1.0
Root Cause Investigationgarrytan/gstack136k—~12kAutomated safety check: NotesMIT
Runtime Debugvercel/next.js143k1 repos~618Automated safety check: PassMIT
Openclaw Debuggingopenclaw/openclaw392k—~1.9kAutomated safety check: PassMIT
Debugging Executionsn8n-io/n8n207k—~2.6kAutomated safety check: PassCustom licence

Similar skills

  • Debug

    asgeirtj/system_prompts_leaks

    Enable debug logging for this session and help diagnose issues

    69k GitHub stars~439 tokensUpdated today
    Auto-check passed
  • Debugs in four phases (investigate, analyze, hypothesize, implement) under one rule: no fix is made until the root cause is found.

    136k GitHub stars~12k tokensUpdated today
    DevelopmentAuto-check: notes
  • Runtime Debug

    vercel/next.js

    Official

    Debug and verification workflow for runtime-bundle and module-resolution regressions.

    143k GitHub starsUsed in 1 repo~618 tokens
    DevelopmentAuto-check passed
  • Openclaw Debugging

    openclaw/openclaw

    Debug OpenClaw model, provider, tool-surface, code-mode, streaming, and live/Crabbox behavior by choosing the right logs, probes, and proof path before changing code, including fetching stored…

    392k GitHub stars~1.9k tokensUpdated today
    DevelopmentAuto-check passed
  • Official

    Debug failed or wrong-output workflow executions using executions tools.

    207k GitHub stars~2.6k tokensUpdated today
    DevelopmentAuto-check passed
  • Debugging Toolkit

    sickn33/agentic-awesome-skills

    A skill your agent uses when working with debugging toolkit smart debug (Alias for debugging-toolkit-smart-debug)

    47k GitHub starsUsed in 1 repo~344 tokens
    DevelopmentAuto-check passed

More from cometkim/unicode-segmenter

  • Bench Records

    cometkim/unicode-segmenter

    Archive benchmark runs into benchmark/grapheme/records and regenerate the HTML report.

    112 GitHub stars~723 tokensUpdated 2 mo ago
    Auto-check passed
  • Benchmark

    cometkim/unicode-segmenter

    Measure runtime perf, bundle size, and memory impact of unicode-segmenter changes.

    112 GitHub stars~1.3k tokensUpdated 2 mo ago
    Auto-check passed
  • Unicode Data

    cometkim/unicode-segmenter

    Regenerate the generated Unicode data modules (src/graphemedata.js, generaldata.js, emojidata.js, test/unicodetestdata.js) and verify correctness.

    112 GitHub stars~1.1k tokensUpdated 2 mo ago
    Auto-check passed

Questions about Codspeed Debug

What does Codspeed Debug do?

Investigate CodSpeed CI performance reports on PRs — regressions or improbable improvements that don't reproduce locally. Codspeed Debug is an agent skill from cometkim/unicode-segmenter. Investigate CodSpeed CI performance reports on PRs — regressions or improbable improvements that don't reproduce locally.

When should I use Codspeed Debug?

Codspeed Debug fits situations like: the CodSpeed check flags a delta and you need to replicate.

How do I install Codspeed Debug in Claude Code?

Run `npx skills add cometkim/unicode-segmenter --skill codspeed-debug -a claude-code`. Or copy the skill folder (.claude/skills/codspeed-debug in cometkim/unicode-segmenter) into .claude/skills/codspeed-debug in your project. Claude Code loads it when a task matches its description.

How do I install Codspeed Debug in Codex?

Run `npx skills add cometkim/unicode-segmenter --skill codspeed-debug -a codex`. Or copy the skill folder (.claude/skills/codspeed-debug in cometkim/unicode-segmenter) into .agents/skills/codspeed-debug in your project. Codex loads it when a task matches its description.

Can I use Codspeed Debug 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 cometkim/unicode-segmenter --skill codspeed-debug -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/codspeed-debug, .gemini/skills/codspeed-debug, .github/skills/codspeed-debug and .opencode/skills/codspeed-debug in your project.

What does Codspeed Debug need to run?

Going by SKILL.md and its folder, Codspeed Debug needs the command-line tools its instructions call (node).

Does Codspeed Debug 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 Codspeed Debug 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. Review the folder before installing.

What licence does Codspeed Debug use?

Codspeed Debug is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Codspeed Debug use?

About 814 tokens (SKILL.md is roughly 3.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 Codspeed Debug?

Skills that share tags, products or a category with Codspeed Debug: Debug (asgeirtj/system_prompts_leaks, 69k stars), Root Cause Investigation (garrytan/gstack, 136k stars), Runtime Debug (vercel/next.js, 143k stars) and Openclaw Debugging (openclaw/openclaw, 392k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Codspeed Debug?

cometkim (a GitHub user) maintains it in cometkim/unicode-segmenter, which has 112 GitHub stars. The repository holds 4 skills in this directory. The repository was last updated on July 29, 2026.

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