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 Lonsdale201/wp-agent-skills --skill bd-source-adaptergit clone --depth 1 https://github.com/Lonsdale201/wp-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/lonsdale201/wp-agent-skills/bd-source-adapter)<a href="https://agentmods.dev/skills/lonsdale201/wp-agent-skills/bd-source-adapter"><img src="https://agentmods.dev/badge/skills/lonsdale201/wp-agent-skills/bd-source-adapter/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/skills/lonsdale201/wp-agent-skills/bd-source-adapter"><img src="https://agentmods.dev/badge/skills/lonsdale201/wp-agent-skills/bd-source-adapter.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
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.00207 | $0.03274 |
| Opus 5 | $0.00103 | $0.01637 |
| Sonnet 5 | $0.00041 | $0.00655 |
| Haiku 4.5 | $0.00021 | $0.00327 |
Grade A, and why
bd-source-adapter 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 10d 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 — 285 lines — stays where its author put it; the contents beside it link to each section on GitHub.
better-data: Adding a source adapter
For library maintainers integrating a new WordPress data store with better-data — comments, attachments, transients, custom tables, taxonomy hierarchies. Sources hydrate stored data into typed DataObjects via AttributeDrivenHydrator; the work is wiring up the bridge between WP's storage idioms and the hydrator's closure contract.
Misconception this skill corrects
"I'll call
get_post_meta($id, $key, true)directly — empty string means 'not set'."
Wrong. WordPress get_meta($key, true) returns '' (empty string) for both "key does not exist" AND "key exists with empty-string value". The AttributeDrivenHydrator distinguishes these because the default-value fallback at src/Internal/AttributeDrivenHydrator.php:90-95 needs to know "missing → use the parameter's default" vs "present-but-empty → coerce as empty string". Without the distinction, every nullable meta-backed field with a non-null default falls back incorrectly.
The contract: the closure you pass to the hydrator returns:
null→ key does not exist (hydrator falls back to parameter default / parameter nullable)- the stored value (including
'') → key exists, hydrator coerces
Verified pattern from src/Source/PostSource.php:91-93:
if (\function_exists('metadata_exists')
&& !\metadata_exists('post', $postId, $key)) {
return null; // key does not exist
}
return \get_post_meta($postId, $key, true); // exists; could be ''
Other AI-prone misconceptions:
- "I'll instantiate
WP_Userdirectly withnew WP_User($id)in a hot loop." Wrong — bypasses object cache. Useget_user_by('id', $id)so the per-request cache participates. - "Bulk hydration is just
array_map($id => hydrate($id))." Wrong — without prewarming, that's N+1 queries. Always callupdate_meta_cache(...)(and_prime_post_cachesfor posts) first. - "I'll write the WP-touching code in
src/Internal/." Wrong —src/Internal/is the WP-free engine zone (so it's unit-testable without a WP runtime). Source adapters live insrc/Source/and CAN call WP functions.
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.
- 10d ago First seen · 285 lines · 207 tokens per session scan A eabdf027bc71
bd-source-adapter is a skill published in the GitHub repository Lonsdale201/wp-agent-skills (22 stars, last pushed 11d ago), licensed MIT. It adds 207 tokens to every session and 3,274 once invoked, about $0.0010 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.
Other skills, from other repositories
mvc-expert
Expert guidelines to refactor legacy PHP codebases into clean, modern, and scalable MVC-structured projects / Pedoman ahli untuk merefaktor codebase PHP lama menjadi proyek terstruktur MVC yang bersih, modern, dan skalabel.
php-laravel
Modern PHP 8.4 and Laravel patterns: architecture, Eloquent, migrations, queues, testing. Use when working with Laravel, Eloquent, Blade, artisan, or building/testing a framework-based PHP app. Not for php-src internals, standalone PHP libraries, or general PHP language discussion.
laravel-engineering
Laravel implementation discipline for tracing context, reusing present contracts, keeping code simple, preserving failures, and verifying the changed critical path. Use when implementing, refactoring, debugging or reviewing Laravel code where callers, configuration, data flow or proof of correctness may be unclear.
webman
Expert skill for the webman framework (a long-lived, in-memory PHP framework based on workerman). Covers routing, controllers, middleware, database/Redis, custom processes, timers, coroutines (v2), plugin development, and guarding against memory leaks and cross-request state pollution under the resident process model.…
php-codeigniter-patterns
Guides CodeIgniter 4 application architecture — Controllers, Models (Query Builder, not an ORM), Entities, the Validation library, Filters (CI4's middleware equivalent), and Services. Use when building a CI4 controller or route, working with a CI4 Model or Entity, wiring a Filter to a route group, or adding a custom…
laravel-patterns
Guides Laravel application architecture — controllers, Eloquent, service/action layers, queues, and API resources. Use when building Laravel controllers or routes, working with Eloquent models and relationships, designing API resources, or adding queued jobs, events, or caching to a Laravel app.