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/iwritec0de/wp-dev/wordpress-performancenpx skills add iwritec0de/wp-dev --skill wordpress-performancegit clone --depth 1 https://github.com/iwritec0de/wp-devWhat 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.00134 | $0.02353 |
| Opus 5 | $0.00067 | $0.01177 |
| Sonnet 5 | $0.00027 | $0.00471 |
| Haiku 4.5 | $0.00013 | $0.00235 |
Grade A, and why
wordpress-performance 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 yesterday.
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 — 253 lines — stays where its author put it; the contents beside it link to each section on GitHub.
WordPress Performance
Performance optimization patterns for WordPress plugins, themes, and live sites.
Critical Rules
- Never query without limits —
posts_per_page => -1and unbounded$wpdbqueries are the most common cause of memory exhaustion on production sites. - Cache expensive queries — any query that runs on every page load and doesn't change per-request must be cached with transients or the object cache.
- Use
no_found_rows— set'no_found_rows' => trueon anyWP_Querythat doesn't need pagination; this skipsSQL_CALC_FOUND_ROWSwhich is expensive on large tables. - Avoid meta queries on unindexed keys —
meta_queryonwp_postmetaperforms full table scans unless you add custom indexes. Consider a custom table for heavily queried data. - Defer heavy work — operations on
initrun on every request. Useadmin_initfor admin-only work,rest_api_initfor REST-only, andwp_loadedor later hooks when possible. - Prime caches, don't loop-query — use
update_post_meta_cache(),update_post_caches(), or_prime_post_caches()to batch-load metadata instead of callingget_post_meta()in a loop.
Query Performance Patterns
Efficient WP_Query
// Good — limited, cache-friendly, no unnecessary data:
$query = new WP_Query( [
'post_type' => 'product',
'posts_per_page' => 20,
'no_found_rows' => true, // Skip pagination count query.
'update_post_meta_cache' => false, // Skip if not reading meta.
'update_post_term_cache' => false, // Skip if not reading terms.
'fields' => 'ids', // Return only IDs when full objects aren't needed.
] );
// Bad — unbounded, forces full table scan:
$query = new WP_Query( [
'post_type' => 'product',
'posts_per_page' => -1, // Never do this.
] );
N+1 Query Prevention
// Bad — N+1 pattern (1 query per post in the loop):
foreach ( $posts as $post ) {
$price = get_post_meta( $post->ID, '_price', true ); // Query per iteration.
}
// Good — prime the cache first, then loop reads from cache:
$post_ids = wp_list_pluck( $posts, 'ID' );
update_meta_cache( 'post', $post_ids ); // Single query loads all meta.
foreach ( $posts as $post ) {
$price = get_post_meta( $post->ID, '_price', true ); // Reads from cache.
}
What ships with it
2 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.
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.
- yesterday First seen · 253 lines · 134 tokens per session scan A 79aeeed55047
wordpress-performance is a skill published in the GitHub repository iwritec0de/wp-dev (1 stars, last pushed 4mo ago), licensed MIT. It adds 134 tokens to every session and 2,353 once invoked, about $0.0007 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
systematic-debugging
Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.
next-cache-components-adoption
Turn on Cache Components in a Next.js app and resolve the blocking routes it surfaces. Use when the user wants to enable, adopt, or migrate to Cache Components, flip the cacheComponents flag, work through a flood of blocking-prerender / instant validation errors, run the cache-components-instant-false codemod, or…
babysit-pr
Babysit a GitHub pull request after creation by continuously polling review comments, CI checks/workflow runs, and mergeability state until the PR is merged/closed or user help is required. Diagnose failures, retry likely flaky failures up to 3 times, auto-fix/push branch-related issues when appropriate, and keep…
imagegen
Generate or edit raster images when the task benefits from AI-created bitmap visuals such as photos, illustrations, textures, sprites, mockups, or transparent-background cutouts. Use when Codex should create a brand-new image, transform an existing image, or derive visual variants from references, and the output…
cpu-profile-analysis
Analyze V8/Chrome CPU profiles (.cpuprofile) and DevTools trace files (Trace-.json). Use when: profiling performance, investigating slow functions, comparing code paths, finding bottlenecks, analyzing timeToRequest, understanding call trees from sampling profiler data, analyzing layout/paint/rendering, investigating…
next-cache-components-optimizer
Drive a Next.js route to instant navigation by setting up an agentic loop, under Cache Components / PPR, on initial load (hard navigation) and client-side navigation (soft navigation). Encode the goal as a failing @next/playwright instant() e2e and work it to green, one verified route at a time; the shipped test then…