wp-patterns

wp-patterns is a skill for Claude Code from dr-robert-li/cowork-wordpress-expert. It costs 39 tokens per session (1,320 once invoked), scanned A, original, MIT.

A review guide for WordPress themes and plugins, including their file structure, data design, and connections to other systems.

In plain words
What is it for?
It is for checking theme and plugin organization, database choices, settings, security, reusable templates, and external integrations.
Why use it?
It helps spot architectural problems before they make a WordPress project harder to maintain or extend.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the wordpress-expert plugin — 54 skills shipped together

Good fit It is for checking theme and plugin organization, database choices, settings, security, reusable templates, and external integrations.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/dr-robert-li/cowork-wordpress-expert/wp-patterns
Install

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.

Any agent
npx skills add dr-robert-li/cowork-wordpress-expert --skill wp-patterns
Clone the repo
git clone --depth 1 https://github.com/dr-robert-li/cowork-wordpress-expert

Made for: Claude Code.

Or install wordpress-expert, the plugin that ships this one along with the rest of its 54 skills.

Wrote 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.

agentmods badge for wp-patterns

README.md
[![agentmods](https://agentmods.dev/badge/skills/dr-robert-li/cowork-wordpress-expert/wp-patterns.svg)](https://agentmods.dev/skills/dr-robert-li/cowork-wordpress-expert/wp-patterns)
Your own site
<a href="https://agentmods.dev/skills/dr-robert-li/cowork-wordpress-expert/wp-patterns"><img src="https://agentmods.dev/badge/skills/dr-robert-li/cowork-wordpress-expert/wp-patterns.svg" alt="Measured on agentmods" height="20"></a>
Per session 39 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,320 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00039 $0.01320
Opus 5 $0.00019 $0.00660
Sonnet 5 $0.00008 $0.00264
Haiku 4.5 $0.00004 $0.00132

Measured 7d ago against content hash 537f1f06b19a, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade A, and why

wp-patterns 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 7d 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.

skills/wp-patterns/SKILL.md · 192 lines

How it starts

The opening of the file, as written. The whole thing — 192 lines — stays where its author put it; the contents beside it link to each section on GitHub.

WordPress Architecture Review

Theme Architecture

Child Theme Configuration

  • Child theme properly configured (if extending a parent theme)
  • Template hierarchy followed correctly
  • functions.php not bloated — heavy logic moved to includes/classes
  • Template parts used for reusable components
  • Custom page templates registered properly
  • Theme support declarations (add_theme_support()) appropriate
  • Widget areas defined sensibly
  • Navigation menus registered and used correctly
  • Customizer settings sanitized and validated

Plugin Architecture

Main Plugin Structure

  • Main plugin file structure follows WordPress conventions
  • Activation/deactivation/uninstall hooks implemented
  • Database tables created with dbDelta() and proper versioning
  • Upgrade routines handle schema migrations gracefully
  • Admin menu pages registered with appropriate capabilities
  • Settings API used for options pages (not raw form handling)
  • Plugin properly cleans up after itself on uninstall
  • AJAX handlers properly registered and secured
  • REST API endpoints follow WordPress conventions
  • Shortcodes registered with proper escaping

Data Architecture

Data Model Choices

  • Custom Post Types vs custom tables — appropriate choice for data model
  • Post meta vs custom tables for high-volume structured data
  • Taxonomies used correctly (not abused for arbitrary data)
  • Options API not used for per-user or per-post data
  • User meta appropriately scoped
  • Multisite considerations for data isolation

Database Schema Best Practices

  • Custom tables use dbDelta() for creation and updates
  • Proper indexing on frequently queried columns
  • Foreign key relationships documented (even if not enforced)
  • Column types appropriate for data (not everything as TEXT)
  • Charset and collation match WordPress standards (utf8mb4)

Integration Architecture

External API Integration

  • External API calls use WordPress HTTP API (wp_remote_get(), wp_remote_post())
  • API responses cached with transients (with appropriate expiry)
  • Webhook handlers properly secured and idempotent
  • Background processing uses WP-Cron or Action Scheduler appropriately
  • Email sending uses wp_mail() with proper hooks for SMTP configuration
  • Timeout values set for all HTTP requests
  • Error handling for failed API calls (network issues, rate limits)
  • API credentials stored securely (not in database, use constants or environment variables)

Read the full file on GitHub · 192 lines

Changes

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.

  1. 7d ago First seen · 192 lines · 39 tokens per session scan A 537f1f06b19a

Subscribe to this mod's changes

wp-patterns is a skill published in the GitHub repository dr-robert-li/cowork-wordpress-expert (28 stars, last pushed 6mo ago), licensed MIT. It adds 39 tokens to every session and 1,320 once invoked, about $0.0002 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-30.

Related

Other skills, from other repositories

platform-apex-generate

Primary Apex authoring skill for class generation, refactoring, and review. ALWAYS ACTIVATE when the user mentions Apex, .cls, triggers, or asks to create/refactor a class (service, selector, domain, batch, queueable, schedulable, invocable, DTO, utility, interface, abstract, exception, REST resource). Use this skill…

forcedotcom/sf-skills · 122 tokens

flow-next-impl-review

Carmack-level implementation review of changes via the configured backend. Use when asked to review code or a diff in a flow-next repo.

gmickel/flow-next · 34 tokens

flow-next-resolve-pr

Resolve PR review feedback. Fetches unresolved threads, triages, fixes, replies and resolves via GraphQL. Use when asked to address review comments.

gmickel/flow-next · 36 tokens

api-contract-review

Use when auditing CloudBase cloud API wrappers, MCP tools, generated action metadata, or related docs for outdated or incorrect action names, parameters, casing, request shapes, or missing contract tests, especially during periodic quality review or before preparing corrective PRs.

TencentCloudBase/CloudBase-AI-Toolkit · 54 tokens

principle-model-the-domain

Apply when writing stateful logic, or when code branches a lot or repeats a shape assumption across files. Encode the domain in a structure instead of scattered conditionals.

cursor/plugins · 39 tokens

code-review-nodejs

Applies Node.js-specific code review patterns for async I/O, streams, security, process management, and dependency hygiene. Use when reviewing Node.js server code, route handlers, middleware, or any JavaScript file alongside package.json without TypeScript. Triggers on sync I/O in request paths, missing stream…

Jamie-BitFlight/claude_skills · 100 tokens