Getting it into your agent
It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.
git clone --depth 1 https://github.com/JakubMikolajek/codex-skills-collectionnpx agentmods add skills/jakubmikolajek/codex-skills-collection/performance-profilingWrote 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.
[](https://agentmods.dev/skills/jakubmikolajek/codex-skills-collection/performance-profiling)<a href="https://agentmods.dev/skills/jakubmikolajek/codex-skills-collection/performance-profiling"><img src="https://agentmods.dev/badge/skills/jakubmikolajek/codex-skills-collection/performance-profiling/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.
<a href="https://agentmods.dev/skills/jakubmikolajek/codex-skills-collection/performance-profiling"><img src="https://agentmods.dev/badge/skills/jakubmikolajek/codex-skills-collection/performance-profiling.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00096 | $0.03152 |
| Opus 5 | $0.00048 | $0.01576 |
| Sonnet 5 | $0.00019 | $0.00630 |
| Haiku 4.5 | $0.00010 | $0.00315 |
Grade A, and why
performance-profiling scanned grade A with 1 finding 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 10d 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.
Makes network callslowCapability
Not a fault in itself. Listed so you know the mod talks to something, and to what.
time curl -s http://localhost:3000/api/search?q=test > /dev/null How it starts
The opening of the file, as written. The whole thing — 357 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Performance Profiling
Measure first. Optimize second. Every optimization that is not preceded by a measurement is a guess dressed as an improvement.
When to Use
- A service is missing latency SLOs (p95/p99 thresholds)
- Memory usage grows over time (suspected leak)
- A specific operation is "slow" but the cause is unknown
- Before any optimization work — to establish a baseline and confirm the bottleneck
- After a deploy that introduced a performance regression
- IDE/developer-tooling features with latency requirements (LSP response, indexing, AST/tree traversal)
When NOT to Use
- Premature optimization before the feature is functionally correct
- Micro-benchmarking syntax choices without a production workload profile
- Tuning without a measurable target — always define the SLO before profiling
Core Principles
The Golden Rule: Never Optimize Without a Baseline
Before touching code, answer:
- What is the current measured performance? (p50, p95, p99 latency, or MB/s, or memory at t+1h)
- What is the target? (SLO, user expectation, or "2x faster than current")
- Which operation is the bottleneck? (profile first — the slow part is rarely where you expect)
Amdahl's Law in Practice
Optimizing a section that accounts for 5% of runtime cannot improve total time by more than 5%, no matter how fast you make it. Profile to find the part that accounts for 80%+ of runtime. That is the only part worth optimizing.
Performance Budget per Layer
Define budgets before profiling so you know when you are done:
| Layer | Target | Hard limit |
|---|---|---|
| API response (p99) | <200ms | <1s |
| Database query | <10ms | <100ms |
| Background job | <5s | <30s |
| LSP response (IDE) | <50ms | <200ms |
| Page interactive (LCP) | <2.5s | <4s |
| Memory growth per hour | 0 (stable) | <10MB/h |
Profiling Process
Profiling progress:
- [ ] Step 1: Define the target and establish the baseline measurement
- [ ] Step 2: Isolate the workload to profile
- [ ] Step 3: Run the profiler for your ecosystem
- [ ] Step 4: Read the flamegraph or profile output
- [ ] Step 5: Identify the bottleneck (not the symptom)
- [ ] Step 6: Make one change, re-measure
- [ ] Step 7: Document findings
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.
- 10d ago First seen · 357 lines · 96 tokens per session scan A 4d0429cb9c39
performance-profiling is a skill published in the GitHub repository JakubMikolajek/codex-skills-collection (5 stars, last pushed 5d ago), licensed MIT. It adds 96 tokens to every session and 3,152 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
debug-optimize-lcp
Guides debugging and optimizing Largest Contentful Paint (LCP) using Chrome DevTools MCP tools. Use this skill whenever the user asks about LCP performance, slow page loads, Core Web Vitals optimization, or wants to understand why their page's main content takes too long to appear. Also use when the user mentions…
systematic-debugging
Use when debugging a failing test, build error, or runtime issue that isn't immediately obvious. Guides a 4-phase root cause analysis instead of random fix attempts.
diagnose
Trace from a reproduced symptom to the source code that causes it. Pin the specific file and approximate line, rate confidence in the cause and clarity of the fix independently, and always propose a concrete fix.
repro-admin
Reproduce an EmDash admin UI bug. Attach a container, start the demo dev server, drive the admin with agent-browser using the dev-bypass session, and capture the reproduction as screenshots plus a replayable transcript.
log-error-digest
Analyze log files to troubleshoot errors, identify peak error periods, and produce error clustering, frequency statistics, and time distribution reports. Supports JSON, syslog, and Nginx formats with automatic detection. Use when a user uploads a .log file and asks to analyze errors, find patterns, debug issues, or…
byted-util-volcengine-detect-retry
An orchestration workflow for Volcengine Cloud Detect, a service that checks websites or network endpoints from test locations.