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 skills add tolgakisaogullari/SumelaOS --skill performance-optimizationgit clone --depth 1 https://github.com/tolgakisaogullari/SumelaOSWrote 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/tolgakisaogullari/sumelaos/performance-optimization)<a href="https://agentmods.dev/skills/tolgakisaogullari/sumelaos/performance-optimization"><img src="https://agentmods.dev/badge/skills/tolgakisaogullari/sumelaos/performance-optimization.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.1 | $0.00025 | $0.01779 |
| Opus 5 | $0.00013 | $0.00890 |
| Sonnet 5 | $0.00005 | $0.00356 |
| Haiku 4.5 | $0.00003 | $0.00178 |
Grade A, and why
performance-optimization 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 8d 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 — 139 lines — stays where its author put it; the contents beside it link to each section on GitHub.
<optimization_workflow> Execute in this exact order. Do NOT skip to Step 3 before completing Steps 1 and 2.
-
MEASURE — Establish a baseline with real, reproducible data.
- Synthetic (controlled conditions, reproducible): DevTools Performance tab, Lighthouse, APM dashboards, load testing tools (k6, JMeter, etc.).
- Real User Monitoring (actual conditions): web-vitals (frontend), production APM traces (backend).
- Both are required. Synthetic finds the bottleneck. RUM validates the fix actually helped real users.
- Stack-specific tooling lives in project rules. Examples: .NET →
dotnet-trace, BenchmarkDotNet, EF Core query logging; Node → clinic.js, 0x; Python → cProfile, py-spy.
-
IDENTIFY — Find the actual bottleneck using symptoms as a guide:
What is slow?
First page load ├── Large bundle? → Measure bundle size, check code splitting / lazy loading ├── Slow server response? → Measure TTFB; profile backend queries and caching └── Render-blocking? → Check network waterfall for CSS/JS blocking API / Backend ├── Single endpoint slow? → Profile DB queries, check for N+1, missing indexes ├── All endpoints slow? → Check connection pool, memory pressure, CPU saturation └── Intermittent slowness? → Check lock contention, GC pauses, external dependency latency UI Interaction ├── Freezes on click? → Profile main thread for long tasks (>50ms) ├── Input lag? → Check re-renders, controlled component overhead └── Animation jank? → Check layout thrashing, forced reflowsBackend bottleneck table:
Symptom Likely Cause Investigation Slow API responses N+1 queries, missing indexes Enable DB query logging, review LINQ execution plans Memory growth Unbounded caches, large payloads, missing .AsNoTracking()Heap snapshot, memory profiler CPU spikes Sync I/O blocking async threads, regex backtracking CPU profiler, check for .Result/.Wait()High latency spikes Lock contention, cold starts, GC pressure APM traces, check Gen2 GC frequency Frontend bottleneck table:
Symptom Likely Cause Investigation Slow LCP Large images, render-blocking resources, slow TTFB Network waterfall, image sizes High CLS Images without dimensions, late-loading content Layout shift attribution in DevTools Poor INP Heavy JS on main thread, large DOM updates Long Tasks in Performance trace Slow navigation N+1 API fetches per route, no caching Network tab, API waterfall -
FIX — Address ONLY the specific bottleneck identified in Step 2. Do NOT bundle unrelated optimizations.
N+1 Query Pattern (most common backend bottleneck):
- ORM: Use the framework's eager-loading mechanism (
.Include()in EF Core,include:in Prisma,joinedloadin SQLAlchemy) to fetch related data in a single query. - Raw SQL: Use JOINs or batched queries instead of queries inside loops.
Missing Indexes:
- Analyze slow-query logs. Add indexes on columns used in WHERE, ORDER BY, and JOIN clauses.
Read-Heavy Queries Without Tracking:
- Disable change tracking on read-only queries when the ORM supports it (EF Core:
.AsNoTracking(); SQLAlchemy:Session(expire_on_commit=False)+ detached objects). Eliminates change-tracking overhead.
Unbounded Data Fetching:
- Always paginate list endpoints. Never fetch all rows.
- Apply pagination at the query level, not in memory.
Missing Caching:
- Cache frequently-read, rarely-changed data (e.g., config, reference data) with explicit TTL.
- Use in-process cache for single-instance state, distributed cache (Redis, Memcached, etc.) for shared state.
- Set
Cache-Controlheaders on API responses that can be cached by clients.
- ORM: Use the framework's eager-loading mechanism (
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.
- 8d ago First seen · 139 lines · 25 tokens per session scan A 17334969693f
performance-optimization is a skill published in the GitHub repository tolgakisaogullari/SumelaOS (4 stars, last pushed 13d ago), licensed MIT. It adds 25 tokens to every session and 1,779 once invoked, about $0.0001 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
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.