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.
npx agentmods add skills/mthines/agent-skills/profile-optimizernpx skills add mthines/agent-skills --skill profile-optimizergit clone --depth 1 https://github.com/mthines/agent-skillsWrote 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/mthines/agent-skills/profile-optimizer)<a href="https://agentmods.dev/skills/mthines/agent-skills/profile-optimizer"><img src="https://agentmods.dev/badge/skills/mthines/agent-skills/profile-optimizer.svg" alt="Measured on agentmods" height="20"></a>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 | $0.00218 | $0.02550 |
| Opus 5 | $0.00109 | $0.01275 |
| Sonnet 5 | $0.00044 | $0.00510 |
| Haiku 4.5 | $0.00022 | $0.00255 |
Grade A, and why
profile-optimizer 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 5d 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.
How it starts
The opening of the file, as written. The whole thing — 212 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Profile Optimizer
Turn a profile file into a ranked, evidence-backed optimisation plan.
Index file. Detailed analysis rules, optimisation patterns, and report templates live under
rules/,references/, andtemplates/. Load only what the current phase needs — the body ofSKILL.mdis a thin orchestrator.
Inputs
The user passes one or more profile files. Accept any of:
| Format | Extension | Detection signal |
|---|---|---|
| React DevTools Profiler | .json (often .reactprofile) |
Top-level keys include dataForRoots and rendererID / version |
| Chrome Performance trace | .json / .json.gz |
Top-level traceEvents array (or NDJSON with ph, ts, cat) |
| Chrome CPU profile (legacy) | .cpuprofile |
Top-level nodes, samples, timeDeltas |
| Chrome heap snapshot | .heapsnapshot |
Top-level snapshot.meta.node_fields + nodes/edges/strings |
| Chrome heap timeline | .heaptimeline |
Heap snapshot shape + samples array |
| Chrome heap profile (sampled allocations) | .heapprofile |
Top-level head + samples (V8 sampling-allocation profile) |
If the file is gzipped, decompress with gunzip -k before parsing.
If multiple formats are passed, treat them as complementary evidence:
- React profile + Chrome trace → correlate by wall-clock timestamp (React shows component cost, Chrome shows where the main thread actually spent time).
- Two or three heap snapshots → diff them to find what grew (leak detection).
- Chrome trace + heap timeline of the same interaction → CPU + memory cost of one action correlated.
See rules/input-detection.md for the precise
detection logic.
What ships with it
12 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- references/chrome-optimization-patterns.md 4.8 KB
- references/react-optimization-patterns.md 5.5 KB
- rules/chrome-trace-analysis.md 7.2 KB
- rules/confidence-loop.md 3.7 KB
- rules/heap-snapshot-analysis.md 13 KB
- rules/input-detection.md 7.7 KB
- rules/measurement-methodology.md 5.2 KB
- rules/optimization-playbook.md 7.9 KB
- rules/react-profile-analysis.md 6.9 KB
- scripts/heap-diff.mjs 3.9 KB runs code
- scripts/heap-summary.mjs 2.8 KB runs code
- templates/analysis-report.md 2.9 KB
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.
- 5d ago First seen · 212 lines · 218 tokens per session scan A f2976e90c36b
profile-optimizer is a skill published in the GitHub repository mthines/agent-skills (12 stars, last pushed today), licensed MIT. It adds 218 tokens to every session and 2,550 once invoked, about $0.0011 per session on Opus 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-08-31.
Other skills, from other repositories
ego-browser
Skill "ego-browser" from citrolabs/ego-lite, covering ego-browser, quick start, common helpers, task spaces and control handoff.
temporal-developer
Develop, debug, and manage Temporal applications across Python, TypeScript, Go, Java, .NET, Ruby, and Rust. Use when the user is building workflows, activities, or workers with a Temporal SDK, debugging issues like non-determinism errors, stuck workflows, or activity retries, using Temporal CLI, Temporal Server, or…
x-algorithm
Write X (Twitter) posts that the For You algorithm actually rewards. Grounded in the open-sourced X recommendation system — the Grok-based transformer ranker, Phoenix retrieval, Thunder in-network store, and Grox content-understanding pipeline. Use when the user wants to write a post, thread, reply, or quote; plan a…
opencode-memory
Browse local OpenCode history: sessions, messages, plans, prompt history, and prior decisions. Use when the user says history, previous session, last time, remember, recall, plans, prior work, or when resuming/debugging repeated work where earlier OpenCode context may help. Do not use for fresh tasks or when current…
creating-explainers
Use when creating an interactive explainer - a single self-contained HTML page with hand-built Canvas figures. Handles source-file explainers, topic-driven research explainers, and mixed intake where files provide the spine and research adds support. Trigger phrases include "make an explainer", "turn this paper into…
custom-icons
Create or refine custom icon assets as native or traced SVGs and transparent PNG/WebP files. Use when the user asks for a bespoke icon or cohesive icon set, wants an image traced into a clean vector, or needs a detailed or 3D icon with transparency.