image-optimizer
Get AI-powered image optimization suggestions. Use when images are slowing your site.
Why use this skill?
Scan your website assets for performance bottlenecks. Get AI-powered suggestions to optimize images, convert formats, and improve Lighthouse scores instantly.
Install via CLI (Recommended)
clawhub install openclaw/skills/skills/lxgicstudios/image-optimizerWhat This Skill Does
The image-optimizer skill is a specialized diagnostic utility designed to solve common web performance bottlenecks. By integrating directly with OpenClaw, this tool scans local directories to identify oversized, inefficient, or improperly formatted image assets. It leverages GPT-4o-mini to analyze image metadata—such as file size, dimensions, and current format—providing actionable intelligence to reduce load times. It identifies opportunities to convert assets to modern formats like WebP, suggests responsive sizing strategies, and highlights images that contribute most significantly to poor Lighthouse scores.
Installation
To integrate this tool into your OpenClaw environment, execute the following command in your terminal:
clawhub install openclaw/skills/skills/lxgicstudios/image-optimizer
Ensure you have Node.js 18+ installed on your system. Note that this skill requires an OPENAI_API_KEY to be set in your environment variables to facilitate the intelligent analysis provided by the AI model.
Use Cases
- Site Performance Audits: Use this skill when your Google Lighthouse report flags image-related issues like 'Properly size images' or 'Serve images in next-gen formats'.
- Pre-Deployment Checks: Run this before shipping code to production to ensure your build pipeline isn't bloated with unoptimized high-resolution assets.
- Asset Cleanup: Use it during refactoring sprints to identify and replace outdated or excessively heavy image files across large projects.
Example Prompts
- "Analyze the ./public/assets directory and give me a report on which images are the biggest performance bottlenecks."
- "I am getting a warning about image sizes on my homepage. Run the optimizer on ./client/src/images/home and tell me which ones I should convert to WebP."
- "Scan my project images folder and provide a summary of which files are over 1MB and need aggressive compression."
Tips & Limitations
To get the most out of the image-optimizer, always prioritize images 'above the fold' for optimization. While the tool provides excellent recommendations, always verify the visual quality of compressed images manually before pushing to production. The primary limitation is the requirement for an active OpenAI API connection; without it, the intelligence layer of the tool will not function. Remember that this tool is an analysis engine; it identifies the problems and provides the roadmap, but you remain in control of applying the transformations.
Metadata
Not sure this is the right skill?
Describe what you want to build — we'll match you to the best skill from 16,000+ options.
Find the right skillPaste this into your clawhub.json to enable this plugin.
{
"plugins": {
"official-lxgicstudios-image-optimizer": {
"enabled": true,
"auto_update": true
}
}
}Tags(AI)
Flags: file-read, external-api
Related Skills
script-gen
Generate package.json scripts with AI. Use when setting up npm scripts.
email-template-gen
Generate responsive email templates. Use when building transactional emails.
branch-namer
Generate descriptive git branch names from plain English. Use when you need a branch name that follows conventions.
cloudflare-gen
Generate Cloudflare Workers configuration and code. Use when building on the edge.
adr-writer
Generate Architecture Decision Records with AI. Use when documenting technical decisions.