Files
skills-software-development/asset-generation/SKILL.md
T

1.9 KiB

name, description
name description
asset-generation Generate images from text prompts using Gemini. Triggers - generate an image, create an asset, make a graphic, generate a logo, create an illustration, I need an image for.

Asset Generation

Generate images from text prompts using the Gemini model and save them to the project's /assets directory.

Prerequisites

  • Set GEMINI_API_KEY in a .env.tools file at the project root (see asset-generation/README.md).
  • Node.js installed.

When to use this skill

Use when:

  • The user asks to generate an image (logo, illustration, graphic, placeholder, etc.)
  • The user says "create an asset" / "make a graphic" / "I need an image for..."
  • A visual asset is needed for the project and no existing file fits

Workflow

1. Clarify the Prompt

Before generating, make sure you have a clear prompt:

  • What is the image for? (icon, hero image, placeholder, illustration, etc.)
  • What style? (flat, realistic, minimal, etc.)
  • Any specific colors, dimensions, or constraints?
  • What filename should it have?

If the user gave a clear enough description, proceed directly.

2. Generate the Image

node asset-generation/scripts/generate-image.mjs \
  --prompt "your detailed prompt here" \
  --output assets/filename.png

The script will:

  • Send the prompt to the Gemini API
  • Save the generated image to the specified path
  • Create the /assets directory if it doesn't exist

3. Verify the Output

  • Confirm the file was created at the expected path
  • Report the file path and size to the user
  • If the result doesn't match expectations, refine the prompt and regenerate

Rules

  • Always confirm the prompt with the user before generating (unless it's already specific)
  • Use descriptive filenames — hero-banner.png not image1.png
  • Save to /assets directory by default, unless the user specifies another location
  • Don't overwrite existing files without asking