profiling-guide

profiling-guide is a skill for Claude Code from VersoXBT/claude-initial-setup. It costs 70 tokens per session (1,830 once invoked), scanned A, original, MIT.

A guide to measuring where web and backend applications spend time or memory, using tools such as browser profiling, cProfile, and flame graphs.

In plain words
What is it for?
Use it to investigate slow pages and endpoints, memory leaks, CPU-heavy code, and performance changes before and after optimization.
Why use it?
It helps locate the real cause of slow code or growing memory use before making changes.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the claude-initial-setup plugin — 75 skills, 15 commands, 14 agents, 2 hooks shipped together

Good fit Use it to investigate slow pages and endpoints, memory leaks, CPU-heavy code, and performance changes before and after optimization.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/versoxbt/claude-initial-setup/profiling-guide
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add VersoXBT/claude-initial-setup --skill profiling-guide
Clone the repo
git clone --depth 1 https://github.com/VersoXBT/claude-initial-setup

Made for: Claude Code.

Or install claude-initial-setup, the plugin that ships this one along with the rest of its 75 skills, 15 commands, 14 agents, 2 hooks.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for profiling-guide

README.md
[![agentmods](https://agentmods.dev/badge/skills/versoxbt/claude-initial-setup/profiling-guide/github.svg)](https://agentmods.dev/skills/versoxbt/claude-initial-setup/profiling-guide)
Your own site
<a href="https://agentmods.dev/skills/versoxbt/claude-initial-setup/profiling-guide"><img src="https://agentmods.dev/badge/skills/versoxbt/claude-initial-setup/profiling-guide/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for profiling-guide

Your own site · 80×15
<a href="https://agentmods.dev/skills/versoxbt/claude-initial-setup/profiling-guide"><img src="https://agentmods.dev/badge/skills/versoxbt/claude-initial-setup/profiling-guide.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 70 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,830 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00070 $0.01830
Opus 5.5 $0.00028 $0.00732
Sonnet 5.5 $0.00014 $0.00366
Haiku 4.5 $0.00007 $0.00183

Measured 1mo ago against content hash 1a9f63920f41, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

profiling-guide scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/performance/profiling-guide/SKILL.md · 250 lines

How it starts

The opening of the file, as written. The whole thing — 250 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Profiling Guide

Measure before optimizing. Use profiling tools to identify actual bottlenecks instead of guessing. This guide covers profiling for JavaScript/Node.js, Python, and Go.

When to Use

  • Application or endpoint is slow and you need to find the bottleneck
  • Investigating memory leaks or growing memory usage
  • Optimizing hot paths in CPU-intensive code
  • Generating flame graphs for visual performance analysis
  • Comparing performance before and after a change

Core Patterns

Chrome DevTools Profiling (Frontend)

Profile rendering, JavaScript execution, and memory in the browser.

## Performance Tab Workflow
1. Open DevTools (Cmd+Option+I / F12)
2. Go to Performance tab
3. Click Record, perform the slow action, click Stop
4. Analyze the flame chart:
   - Yellow = JavaScript execution
   - Purple = Rendering/layout
   - Green = Painting
   - Look for long tasks (>50ms, marked with red triangle)

## Key Metrics
- First Contentful Paint (FCP): < 1.8s
- Largest Contentful Paint (LCP): < 2.5s
- Total Blocking Time (TBT): < 200ms
- Cumulative Layout Shift (CLS): < 0.1

## Memory Tab Workflow
1. Go to Memory tab
2. Take Heap Snapshot
3. Perform suspected leaking action
4. Take another Heap Snapshot
5. Compare snapshots (select "Comparison" view)
6. Sort by "Delta" to find growing object counts

Programmatic performance measurement:

// Measure specific operations
performance.mark('fetch-start');
const data = await fetchLargeDataset();
performance.mark('fetch-end');
performance.measure('data-fetch', 'fetch-start', 'fetch-end');

const measure = performance.getEntriesByName('data-fetch')[0];
// measure.duration gives you milliseconds

// React component profiling
import { Profiler } from 'react';

function onRenderCallback(
  id: string,
  phase: 'mount' | 'update',
  actualDuration: number,
) {
  if (actualDuration > 16) { // Longer than one frame at 60fps
    console.warn(`Slow render: ${id} took ${actualDuration.toFixed(2)}ms`);
  }
}

<Profiler id="UserList" onRender={onRenderCallback}>
  <UserList users={users} />
</Profiler>

Read the full file on GitHub · 250 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 250 lines · 70 tokens per session scan A 1a9f63920f41

Subscribe to this mod's changes

profiling-guide is a skill published in the GitHub repository VersoXBT/claude-initial-setup (4 stars, last pushed 5mo ago), licensed MIT. It adds 70 tokens to every session and 1,830 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

learner

Post-debugging knowledge extraction — captures non-obvious, codebase-specific learnings that pass quality gates. Invoke after resolving tricky bugs or discovering surprising behavior.

XeldarAlz/everything-claude-unity · 34 tokens

git-advanced-workflows

Master advanced Git workflows including rebasing, cherry-picking, bisect, worktrees, and reflog to maintain clean history and recover from any situation. Use when managing complex Git histories, collaborating on feature branches, or troubleshooting repository issues.

wshobson/agents · 54 tokens

principle-attack-the-premise

Apply when two or more fixes that share one premise have failed the same gate. Write the premise down and test it directly before you write another fix that assumes it.

michael-denyer/pstack-claude · 41 tokens

vigil-instrument

Instrument a service with OpenTelemetry — RED metrics, structured logs, distributed tracing, and health checks. Outputs actual code and config, not a plan. Use when asked to "add monitoring", "instrument this", "add logging", "set up tracing", or "observability".

tonone-ai/tonone · 61 tokens

forge-diagnose

Diagnose runtime infrastructure issues — cold starts, timeouts, scaling problems, network failures. Use when asked about "infra is slow", "cold starts", "network issues", "why is this timing out", "scaling problem", "latency spikes", or "service is down".

tonone-ai/tonone · 63 tokens

decision-table

Use when the user wants a code-grounded decision table for current behavior, wants to compare current behavior against a plan or work item, or needs a control-flow artifact for recovery, retry, finalization, validation, state-machine, or review-heavy edge cases.

closedloop-ai/claude-plugins · 55 tokens