一键导入
gemini-seo-image-assets
// Use when a web project needs Google AI Studio or Gemini-generated favicon and Open Graph images, exported icon variants, and matching SEO metadata wiring.
// Use when a web project needs Google AI Studio or Gemini-generated favicon and Open Graph images, exported icon variants, and matching SEO metadata wiring.
| name | gemini-seo-image-assets |
| description | Use when a web project needs Google AI Studio or Gemini-generated favicon and Open Graph images, exported icon variants, and matching SEO metadata wiring. |
Generate image-first SEO assets with Gemini 3.1, then finish the exact typography, icon sizes, manifest, and metadata locally.
Core rule: let Gemini generate composition and texture; do not rely on Gemini for exact text rendering.
favicon.ico, apple-touch-icon, or og-image.title, description, og:*, twitter:*, and canonical wiring.Do not use this skill when:
Confirm these before generating anything:
| Check | Why it matters |
|---|---|
| Root layout / head entry | Needed for icons, manifest, theme-color, global meta |
| Route metadata API | Determines where title, description, robots, and canonical belong |
public/ assets | Prevents accidental overwrite and reveals existing filenames |
| Build command | Required for verification after wiring |
.env.local first, then .env.GOOGLE_AI_STUDIO_API_KEY.gemini-3.1-flash-image-preview.Minimal request shape:
{
"contents": [{ "parts": [{ "text": "..." }] }],
"generationConfig": {
"responseModalities": ["IMAGE"],
"imageConfig": {
"aspectRatio": "1:1",
"imageSize": "2K"
}
}
}
Always generate background/base artwork, not final text-complete share cards.
| Asset | Aspect ratio | Purpose | Rule |
|---|---|---|---|
| Favicon source | 1:1 | Master square artwork for all icon exports | No text, strong silhouette, readable at 16px |
| OG background | 16:9 | Base for 1200x630 social preview | Reserve calm negative space for local title overlay |
Use the prompt templates in references/prompts.md. Adapt the palette, mood, and product nouns to the project.
Do the deterministic steps on the local machine:
1024x1024.favicon.icofavicon-16x16.pngfavicon-32x32.pngapple-touch-icon.pngandroid-chrome-192x192.pngandroid-chrome-512x512.png1200x630.Preferred structure:
| Layer | Responsibility |
|---|---|
| Root layout | icons, manifest, theme-color, color-scheme, app name |
| Shared SEO helper | builds title, description, robots, og:*, twitter:*, canonical |
| Route modules | call the helper with route-specific values |
Recommended rules:
index,follow.noindex,nofollow.VITE_SITE_URL to produce absolute canonical, og:url, and og:image.Run all of the following:
| Verification | Purpose |
|---|---|
| Visual self-check or model-based image inspection | Confirms icon has no stray text and OG text is legible |
| Typecheck | Confirms metadata helper and route integration compile |
| Production build | Confirms asset links and route modules build successfully |
| Rule | Reason |
|---|---|
| Do not trust Gemini for exact Chinese or brand text | Text rendering is the least reliable part of the model output |
| Keep favicon imagery simple | Browser icons collapse under detail very quickly |
| Keep OG imagery quieter than the UI | Social previews need text contrast and scanability |
| Do not hardcode a production domain in source | Canonical origin often differs by environment |
| Do not overwrite user-owned assets blindly | Existing branding may already be in use |