wordpress-ai-image-optimizer

wordpress-ai-image-optimizer is a skill for Claude Code from respira-press/agent-skills-wordpress. It costs 68 tokens per session (2,160 once invoked), scanned A, original, MIT.

An image maintenance workflow for WordPress media libraries and content.

In plain words
What is it for?
Use it to audit images, compress and resize them, convert them to WebP, rename files locally, preserve originals, re-upload results, and update content references.
Why use it?
Large, poorly sized, or inefficiently named images can slow a site and leave duplicate references that need manual cleanup.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: mentions Claude Code.

Part of the respira-wordpress-skills plugin — 48 skills shipped together

Good fit Use it to audit images, compress and resize them, convert them to WebP, rename files locally, preserve originals, re-upload results, and update content references.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/respira-press/agent-skills-wordpress/wordpress-ai-image-optimizer
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 respira-press/agent-skills-wordpress --skill wordpress-ai-image-optimizer
Clone the repo
git clone --depth 1 https://github.com/respira-press/agent-skills-wordpress

Made for: Claude Code.

Or install respira-wordpress-skills, the plugin that ships this one along with the rest of its 48 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 wordpress-ai-image-optimizer

README.md
[![agentmods](https://agentmods.dev/badge/skills/respira-press/agent-skills-wordpress/wordpress-ai-image-optimizer.svg)](https://agentmods.dev/skills/respira-press/agent-skills-wordpress/wordpress-ai-image-optimizer)
Your own site
<a href="https://agentmods.dev/skills/respira-press/agent-skills-wordpress/wordpress-ai-image-optimizer"><img src="https://agentmods.dev/badge/skills/respira-press/agent-skills-wordpress/wordpress-ai-image-optimizer.svg" alt="Measured on agentmods" height="20"></a>
Per session 68 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,160 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. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
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.00068 $0.02160
Opus 5 $0.00034 $0.01080
Sonnet 5 $0.00014 $0.00432
Haiku 4.5 $0.00007 $0.00216

Measured 8d ago against content hash 19ccaf50b4c9, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

wordpress-ai-image-optimizer 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.

skills/wordpress-ai-image-optimizer/SKILL.md · 245 lines

How it starts

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

WordPress AI Image Optimizer

Version: 1.2.0 Updated: 2026-06-30 Freshly updated: v1.2.0 replaces per-image respira_update_media loops with a single respira_update_media_batch pass (up to ~50 items at once), snapshots the media library with respira_get_snapshot before the batch so the whole run is one-step reversible, runs the audit through respira_analyze_images, surfaces optional stock replacements via respira_search_stock_images + respira_sideload_image, and closes with a respira_generate_activity_report summary (e.g. "optimized 47 images, saved 1.2GB").

AI-powered image optimization for WordPress sites. Automatically compresses, converts formats, renames files, and updates all references. Processes images locally in AI code editor, creates optimized versions, and preserves originals for safety.

What This Skill Does

Scans:

  • All media library images
  • Images in posts and pages content
  • Featured images
  • Images in page builder elements (Elementor, Divi, Bricks, etc.)
  • WooCommerce product images
  • Images in custom post types

Detects:

  • File sizes (actual KB/MB on disk)
  • Image dimensions (width x height in pixels)
  • Format (JPG, PNG, GIF, WebP, AVIF, SVG)
  • Whether width/height attributes are set in HTML
  • Whether alt text exists (and quality)
  • Whether image is being used (orphaned media)
  • Whether responsive image sizes exist (WordPress srcset)
  • Compression quality (estimated from file size)
  • Lazy loading implementation
  • Non-SEO-friendly filenames (IMG_1234.jpg, screenshot.png, etc.)
  • Oversized originals (5000px uploaded when 2000px is max needed)
  • Missing srcset on content images
  • Builder images that bypass WordPress responsive system

Optimizes via AI Code Editor:

  • Downloads images from WordPress
  • Compresses with optimal quality settings (80-85% for JPG, lossless for PNG)
  • Converts to modern formats (WebP preferred, AVIF when appropriate)
  • Resizes oversized originals to optimal dimensions
  • Renames with SEO-friendly descriptive filenames
  • Generates missing alt text using AI
  • Regenerates WordPress responsive image sizes
  • Uploads optimized versions back to WordPress
  • Creates new media entries (keeps old files safe)
  • Updates all content references in duplicates

Read the full file on GitHub · 245 lines

Files

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.

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. 8d ago First seen · 245 lines · 68 tokens per session scan A 19ccaf50b4c9

Subscribe to this mod's changes

wordpress-ai-image-optimizer is a skill published in the GitHub repository respira-press/agent-skills-wordpress (42 stars, last pushed 11d ago), licensed MIT. It adds 68 tokens to every session and 2,160 once invoked, about $0.0003 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

baoyu-xhs-images

A tool that breaks content into a series of illustrated image cards for Xiaohongshu, a Chinese social platform also called Little Red Book, and similar social posts.

JimLiu/baoyu-skills · 100 tokens

video-shotcraft

Create cinematic product videos from shot recipe cards, a validated template, and code/audio assets (Remotion + real page screenshots + 2.5D camera moves + beat-synced cuts + sound design). Use when the user asks to turn a frontend project or webpage into a product video, says "use video-shotcraft to make a…

Vincentwei1021/video-shotcraft · 204 tokens

baoyu-comic

A tool for creating original educational comics that explain knowledge or ideas through multiple illustrated panels. It supports different art styles and tones and can create several comics in one batch.

JimLiu/baoyu-skills · 61 tokens

baoyu-image-gen

AI image generation with OpenAI GPT Image 2, Azure OpenAI, Google, OpenRouter, DashScope, Z.AI GLM-Image, MiniMax, Jimeng, Seedream, Replicate and Agnes APIs. Supports text-to-image, reference images, aspect ratios, and batch generation from saved prompt files. Sequential by default; use batch parallel generation when…

JimLiu/baoyu-skills · 105 tokens

baoyu-slide-deck

Generates professional slide deck images from content. Creates outlines with style instructions, then generates individual slide images. Use when user asks to "create slides", "make a presentation", "generate deck", "slide deck", or "PPT".

JimLiu/baoyu-skills · 54 tokens

baoyu-article-illustrator

A tool that reads an article’s structure and suggests where visual aids would help, then generates matching illustrations. It keeps the illustrations consistent through choices of image type, style, and color palette.

JimLiu/baoyu-skills · 59 tokens