Agent skill

Calculate The Perf Performance

by codsen in codsen/codsen

Run, audit, and interpret the Codsen monorepo performance benchmarks.

MITAuto-check passedDevelopment

Install Calculate The Perf Performance

skills CLI
$ npx skills add codsen/codsen --skill calculate-the-perf-performance -a claude-code

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

GitHub CLI
$ gh skill install codsen/codsen calculate-the-perf-performance --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/codsen/codsen.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/calculate-the-perf-performance .claude/skills/calculate-the-perf-performance && 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
calculate-the-perf-performance
GitHub stars
214
Token cost
~2.2k tokens
SKILL.md length
1,190 words
Files
3 (incl. scripts)
Skills in repo
3
Repo updated
First seen
Licence
MIT

At a glance

Run, audit, and interpret the Codsen monorepo performance benchmarks.

  • Works in 10 steps: Locate the repository root by walking… → Before benchmarking, record git status… → For a release-wide audit, inspect every… → …
  • The user says calculate the perf
  • SKILL.md covers Workflow, Normalization model, Reading historical.json by hand and Comparison semantics, plus 1 more section
  • Runs JavaScript scripts from its folder; calls npm, git and node

What it does

Calculate The Perf Performance is an agent skill from codsen/codsen. Run, audit, and interpret the Codsen monorepo performance benchmarks. Use when the user says "calculate the perf", asks to run or review package perf checks, audit testme() workloads, compare current performance with preceding released versions, or summarize whether this monorepo became faster or slower.

Its SKILL.md is about 2.2k tokens, which your agent loads only when the skill is triggered. The skill folder holds 4 other files, including scripts (for example `agents/openai.yaml`).

It sits in Development, covering Monorepo tooling. The repository describes itself as: a monorepo of npm packages. The licence is MIT.

When your agent uses it

  • The user says calculate the perf
  • Review package perf checks
  • Audit testme() workloads
  • Compare current performance with preceding released versions

Example prompts

  • “calculate the perf”
  • “/calculate-the-perf-performance”

Requirements

  • Node.js

Workflow steps

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

  1. Locate the repository root by walking upward from the current directory until finding a package.json whose name is codsen-mono. Stop and…
  2. Before benchmarking, record git status --short -- packages/*/perf/check.js packages/*/perf/historical.json. These files may already…
  3. For a release-wide audit, inspect every packages/*/perf/check.js; otherwise inspect every working-tree-modified check and each check…
  4. Before changing the measured workload, run the changelog reconciliation and preservation checks in step 9 against the existing history…
  5. If the user requested only an audit or workload repair, do not run perf merely to refill reset histories; leave them {}, complete…
  6. A valid slowdown is a reported result, not a failure of npm run perf. Its baseline remains intact and the score is stored in…
  7. Run
  8. Read the complete analyser output before drawing conclusions. Higher normalized operations per second is better.
  9. Run npm run perf:changelogs and npm run perf:changelogs:check to reconcile all retained version-keyed gains above the noise tolerance into…
  10. After benchmarking, run git status --short -- packages/*/perf/historical.json and mention that the benchmark updated performance history…

What it can do on your machine

Read from SKILL.md and the folder at commit e7e6df7. 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 1 file in scripts/ (JavaScript), which the agent can run.

    Shell commands in SKILL.md call:

    • npm
    • git
    • node

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

  • Network

    No URLs in SKILL.md. Its commands use npm and git, 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

Calculate The Perf Performance loads about 2.2k tokens when it runs. Until then it costs about 84 tokens; SKILL.md has 1,190 words of instructions outside code blocks.

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

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 codsen/codsen at commit e7e6df7, republished under its MIT licence (© codsen). 1,190 words, ~2,236 tokens.

Download SKILL.mdSave it as .claude/skills/calculate-the-perf-performance/SKILL.md (or your agent's skills folder). This skill also uses 2 other files; get the full folder from GitHub.
name
calculate-the-perf-performance
description
Run, audit, and interpret the Codsen monorepo performance benchmarks. Use when the user says "calculate the perf", asks to run or review package perf checks, audit testme() workloads, compare current performance with preceding released versions, or summarize whether this monorepo became faster or slower.

Calculate the Perf (Performance)

Run every package benchmark, compare normalized operations per second with each package's preceding version baseline, and summarize the monorepo-wide movement.

Read .agents/PERFORMANCE.md completely before auditing a workload, editing a perf check, resetting history, or interpreting results. It is the source of truth for benchmark intent, normalization, and history invalidation.

Workflow

  1. Locate the repository root by walking upward from the current directory until finding a package.json whose name is codsen-mono. Stop and explain if it cannot be found.

  2. Before benchmarking, record git status --short -- packages/*/perf/check.js packages/*/perf/historical.json. These files may already contain user changes; preserve them.

  3. For a release-wide audit, inspect every packages/*/perf/check.js; otherwise inspect every working-tree-modified check and each check relevant to the request. Confirm that testme() calls the current built public API with valid, meaningful, deterministic inputs and no mutable state that grows across iterations. Use source types, examples, and tests as evidence. If dist is missing or stale, treat source/types as the contract and rebuild before a runtime smoke test when the user has authorized builds.

  4. Before changing the measured workload, run the changelog reconciliation and preservation checks in step 9 against the existing history. Then reset that package's complete perf/historical.json to {} before the next run. This is mandatory for changes to the callable, arguments, options, fixture contents, callbacks, setup placement, or amount of work. Do not reset for imports, comments, or formatting alone. Record every reset; never compare the new workload with old records.

  5. If the user requested only an audit or workload repair, do not run perf merely to refill reset histories; leave them {}, complete static/smoke validation, and skip measurement and analysis in steps 6–8. Still complete the reconciliation checks in step 9. Otherwise, from the repository root, run npm run perf. It builds all packages before measuring one at a time; keep other substantial CPU work stopped during measurement. Allow the command to finish because each benchmark runs asynchronously and writes perf/historical.json when its own suite completes. A reset package will gain only a fresh baseline for its new workload.

  6. A valid slowdown is a reported result, not a failure of npm run perf. Its baseline remains intact and the score is stored in lastSlowerRun. Execution, abort, invalid-rate and write errors still fail the sweep; inspect package output and Turbo task counts before claiming a complete run. Use npm run perf:check for optional strict validation of the latest saved results without remeasurement. A correctness fix can legitimately cost performance because it now does previously skipped work; investigate avoidable overhead, then explain and retain the necessary cost instead of reverting the fix or promising an open-ended algorithm project.

  7. Run:

    sh
    node .agents/skills/calculate-the-perf-performance/scripts/analyze-perf.mjs

    Pass --root /absolute/path/to/repo only when running the script outside the repository root. Pass --all when the user asks for the full per-package comparison table.

  8. Read the complete analyser output before drawing conclusions. Higher normalized operations per second is better.

  9. Run npm run perf:changelogs and npm run perf:changelogs:check to reconcile all retained version-keyed gains above the noise tolerance into each package changelog, including release sections removed by cleaning. Use verified dates (or an explicitly undated historical record when Git and npm provide none), add ### Performance Improvements when needed, retain existing prose, and check that regeneration and cleaning preserve each gain exactly once. Use comma thousands separators for quantities such as scores and large percentages (1,234,567, 12,345.67); preserve fractional precision, version numbers and dates, and check the same formatting in generated notes. Do not advertise first baselines, bookkeeping duplicates or pending slowdowns as improvements. Do this before a workload reset too, preserving valid gains from the previous workload.

  10. After benchmarking, run git status --short -- packages/*/perf/historical.json and mention that the benchmark updated performance history files. Preserve those run results unless the user asks otherwise; the mandatory pre-run reset for a changed workload is the sole automatic reset rule.

Normalization model

Let R be the freshly measured perfRef() rate, T the freshly measured testme() rate, and C the canonical opsPerSec exported by perf-ref. Persist T * C / R, not raw T. The shared scale factor C / R makes the reference score equal C — 183, the canonical value exported by perf-ref — and scales the target equally. Compare this relative, normalized score across releases; do not compare raw machine throughput.

Show full SKILL.md (481 more words)Show less

Reading historical.json by hand

packages/*/perf/historical.json is JSON except that its numbers carry underscore separators (19_069_207), and anything above 100 is stored rounded to a whole number. JSON.parse() throws on those files. Use parseHistorical() / stringifyHistorical() from ops/scripts/historicalJson.js instead — the analyser script and ops/scripts/perf.js both go through them.

Keys are either a semver version, lastVersion, or lastSlowerRun. Only the first two are baselines; see the comparison semantics below.

Comparison semantics

  • Treat lastVersion as the latest accepted normalized baseline; a newer rejected measurement is stored in lastSlowerRun.
  • Ignore lastSlowerRun when picking a baseline. It records a run which lost against lastVersion by more than 2%, kept as evidence precisely so that it did not become the baseline. The analyser reads it for you: such a package is classified pendingRegression, its deltaPct is score against against rather than anything derived from lastVersion, and worstOpsPerSec / worstPct report the lowest score seen while that baseline has stood. Count these separately from slower in the report — a slower package has already absorbed the loss into its baseline, whereas a pending regression is one the harness measured and refused to adopt.
  • Compare the latest score with the last version-keyed numeric entry preceding it.
  • When that entry is the current package.json version and duplicates lastVersion, skip it and use the preceding version entry. The benchmark writes the current score to both places, so comparing those duplicate values would always produce a misleading 0% change.
  • Calculate (latest / baseline - 1) * 100. Positive values mean faster; negative values mean slower.
  • Classify absolute changes of 2% or less as noise/roughly unchanged, matching ops/scripts/perf.js.
  • Compare percentages across packages, not raw operations-per-second values, because package workloads differ greatly.
  • Prefer the median percentage and geometric-mean ratio for the overall direction. Treat the arithmetic mean as secondary because outliers can dominate it.
  • Call out a mixed result when the aggregate measures disagree or gains and regressions are broadly balanced.

Final report

Lead with one plain-language verdict: faster, slower, roughly unchanged, or mixed. Then include:

  • how many files were found and how many packages were compared;
  • counts of faster, roughly unchanged, and slower packages using the 2% threshold, plus pending regressions counted separately;
  • every entry in pendingRegressions, named individually rather than summarised: each is a slowdown the harness measured and deliberately did not absorb; distinguish warnings within the strict threshold from those which would fail npm run perf:check;
  • median and geometric-mean percentage changes;
  • the most important improvements and regressions, including package name, baseline version, and percentage;
  • skipped or malformed files and any partial benchmark failures;
  • pending reset histories and fresh baseline-only packages, listed separately from malformed or failed files;
  • the number of changelog gain entries added or refreshed and any unresolved release-date evidence;
  • a short caution that benchmark noise can affect small movements and a rerun is worthwhile for surprising large changes.

Keep the summary concise. Do not dump the full package table unless the user asks for it.

© codsen, MIT. 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 2 other files (scripts) in .agents/skills/calculate-the-perf-performance of codsen/codsen.

  • SKILL.md
  • agents/openai.yaml
  • scripts/analyze-perf.mjs

Open the folder on GitHubat commit e7e6df7

Compare with similar skills

Calculate The Perf Performance 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.

Calculate The Perf Performance compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Calculate The Perf Performance this skillcodsen/codsen214—~2.2kAutomated safety check: PassMIT
Nx Importnrwl/nx29k6 repos~3.5kAutomated safety check: PassMIT
Nx Workspacenomcopter/react-mosaic4.8k8 repos~1.9kAutomated safety check: PassCustom licence
Electron Multi-Process ArchitectureiOfficeAI/AionUi33k1 repos~1.8kAutomated safety check: PassApache-2.0
Nx Run Tasksnomcopter/react-mosaic4.8k8 repos~613Automated safety check: PassCustom licence
Astro Developerwithastro/astro63k1 repos~1.5kAutomated safety check: PassCustom licence

Similar skills

  • Nx Import

    nrwl/nx

    Import, merge, or combine repositories into an Nx workspace using nx import.

    29k GitHub starsUsed in 6 repos~3.5k tokens
    DevelopmentAuto-check passed
  • Nx Workspace

    nomcopter/react-mosaic

    Explore and understand Nx workspaces. An agent skill from nomcopter/react-mosaic.

    4.8k GitHub starsUsed in 8 repos~1.9k tokens
    DevelopmentAuto-check passed
  • Tells the agent where new code belongs in an Electron multi-process project and which APIs each process may use, with rules for new bridges, services, agents and workers.

    33k GitHub starsUsed in 1 repo~1.8k tokens
    DevelopmentAuto-check passed
  • Nx Run Tasks

    nomcopter/react-mosaic

    Helps with running tasks in an Nx workspace. An agent skill from nomcopter/react-mosaic.

    4.8k GitHub starsUsed in 8 repos~613 tokens
    DevelopmentAuto-check passed
  • Astro Developer

    withastro/astro

    Official

    Comprehensive guide for developing in the Astro monorepo. An agent skill from withastro/astro.

    63k GitHub starsUsed in 1 repo~1.5k tokens
    DevelopmentAuto-check passed
  • Moves a package from another TryGhost repository into Ghost as an internal workspace package while keeping its Git history, with checkpoints for the steps that need an administrator.

    55k GitHub stars~3.8k tokensUpdated today
    DevelopmentAuto-check passed

More from codsen/codsen

  • Keep the repository's linted Markdown passing npm run lint:markdown.

    214 GitHub stars~832 tokensUpdated 8 days ago
    Auto-check passed
  • Audit, lower, test, and preserve Codsen package Node.js engine floors.

    214 GitHub stars~938 tokensUpdated 8 days ago
    Auto-check passed

Categories

Questions about Calculate The Perf Performance

What does Calculate The Perf Performance do?

Run, audit, and interpret the Codsen monorepo performance benchmarks. Calculate The Perf Performance is an agent skill from codsen/codsen. Run, audit, and interpret the Codsen monorepo performance benchmarks.

When should I use Calculate The Perf Performance?

Calculate The Perf Performance fits situations like: the user says calculate the perf; review package perf checks; audit testme() workloads; compare current performance with preceding released versions.

How do I install Calculate The Perf Performance in Claude Code?

Run `npx skills add codsen/codsen --skill calculate-the-perf-performance -a claude-code`. Or copy the skill folder (.agents/skills/calculate-the-perf-performance in codsen/codsen) into .claude/skills/calculate-the-perf-performance in your project. Claude Code loads it when a task matches its description.

How do I install Calculate The Perf Performance in Codex?

Run `npx skills add codsen/codsen --skill calculate-the-perf-performance -a codex`. Or copy the skill folder (.agents/skills/calculate-the-perf-performance in codsen/codsen) into .agents/skills/calculate-the-perf-performance in your project. Codex loads it when a task matches its description.

Can I use Calculate The Perf Performance 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 codsen/codsen --skill calculate-the-perf-performance -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/calculate-the-perf-performance, .gemini/skills/calculate-the-perf-performance, .github/skills/calculate-the-perf-performance and .opencode/skills/calculate-the-perf-performance in your project.

What does Calculate The Perf Performance need to run?

Going by SKILL.md and its folder, Calculate The Perf Performance needs JavaScript for the scripts in its folder and the command-line tools its instructions call (npm, git and node). Our summary lists: Node.js.

Does Calculate The Perf Performance access the network?

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

Is Calculate The Perf Performance 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 Calculate The Perf Performance use?

Calculate The Perf Performance 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 Calculate The Perf Performance use?

About 2.2k tokens (SKILL.md is roughly 8.9k 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 Calculate The Perf Performance?

Skills that share tags, products or a category with Calculate The Perf Performance: Nx Import (nrwl/nx, 29k stars), Nx Workspace (nomcopter/react-mosaic, 4.8k stars), Electron Multi-Process Architecture (iOfficeAI/AionUi, 33k stars) and Nx Run Tasks (nomcopter/react-mosaic, 4.8k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Calculate The Perf Performance?

codsen (a GitHub organization) maintains it in codsen/codsen, which has 214 GitHub stars. The repository holds 3 skills in this directory. The repository was last updated on September 29, 2026.

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