Borrowing it
Nothing to install: this file belongs to eddiesanjuan/markupr. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/eddiesanjuan/markupr/main/.claude/commands/perf.mdgit clone --depth 1 https://github.com/eddiesanjuan/markuprWrote 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/commands/eddiesanjuan/markupr/perf)<a href="https://agentmods.dev/commands/eddiesanjuan/markupr/perf"><img src="https://agentmods.dev/badge/commands/eddiesanjuan/markupr/perf/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/commands/eddiesanjuan/markupr/perf"><img src="https://agentmods.dev/badge/commands/eddiesanjuan/markupr/perf.svg" alt="Reviewed on agentmods" width="80" 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.1 | $0.00000 | $0.01516 |
| Opus 5.5 | $0.00000 | $0.00606 |
| Sonnet 5.5 | $0.00000 | $0.00303 |
| Haiku 4.5 | $0.00000 | $0.00152 |
Grade A, and why
perf 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.
How it starts
The opening of the file, as written. The whole thing — 140 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Perf -- Performance Optimization Audit
Analyze markupr's performance characteristics across its three runtimes: Electron desktop app, CLI tool, and MCP server. Identify bottlenecks, heavy dependencies, and anti-patterns with prioritized recommendations.
Instructions
1. Bundle Size Analysis
Build all targets and measure output sizes:
cd ~/Projects/markupr && npm run build 2>&1
# Measure each build output
du -sh dist/main/
du -sh dist/renderer/
du -sh dist/cli/
du -sh dist/mcp/
du -sh dist/preload/
# Find the largest individual files
find dist/ -type f -name "*.mjs" -o -name "*.js" -o -name "*.css" | xargs ls -lhS | head -20
Report the size of each build target. For the renderer bundle specifically, check if source maps are included in production (they should not be).
2. Dependency Weight Analysis
Assess the heaviest dependencies and whether lighter alternatives exist:
| Dependency | Purpose | Risk Area |
|---|---|---|
sharp |
Image optimization for AI pipeline (src/main/ai/ImageOptimizer.ts) |
Native module, large binary (~30MB). Check if it's tree-shaken or fully bundled. For CLI/MCP, could canvas or jimp be lighter? |
@anthropic-ai/sdk |
Claude API calls (src/main/ai/ClaudeAnalyzer.ts) |
Large SDK. Check if markupr uses enough of it to justify full import vs. raw fetch |
electron-store |
Settings persistence (src/main/settings/) |
Pulls in conf, atomically, etc. Check if electron's built-in safeStorage + JSON would suffice |
whisper-node |
Local transcription (src/main/transcription/WhisperService.ts) |
Native module with binary download. Check startup impact |
keytar |
Secure API key storage (src/main/settings/) |
Native module. Check if Electron safeStorage could replace it |
zod |
Schema validation (src/shared/) |
Check v4 bundle size. v4 is significantly larger than v3 |
For each dependency:
- Read the actual import sites to see how much of the package is used
- Check if it's properly externalized in
electron.vite.config.ts(main process deps should be external) - Check if CLI/MCP builds in
scripts/build-cli.mjsandscripts/build-mcp.mjsproperly externalize or bundle
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.
- 1mo ago First seen · 140 lines · 0 tokens per session scan A ed0176d5587f
perf is a command published in the GitHub repository eddiesanjuan/markupr (18 stars, last pushed 6mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,516 tokens. 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-30.
Other commands, from other repositories
bug
Turn one screen recording of a bug into an evidence-backed GitHub issue draft (quote, frames, OCR identifiers, wall-clock; silent recordings work too).
triage-recording
Turn a narrated screencast into precise, evidence-backed findings JSON (bug / feature / question routing with frame evidence).
correlate-with-logs
Walk a recording's remarks against system logs using wall-clock timestamps.
voxpip
Watch any video and get a transcript — even without an API key. Extends /watch with a local speech-to-text fallback.
qa-changes
This skill should be used when the user asks to "QA a pull request", "test PR changes", "verify a PR works", "functionally test changes", or when an automated workflow triggers QA validation of code changes. Provides a structured methodology for setting up the environment, exercising changed behavior, and reporting…
http-service
Build, review or debug a Bun HTTP service. Loads the http-service skill, then works the task through its workflow.