# Sn Image Imitate

Generates a new image that imitates the style of a reference image while updating...

- Repository: https://github.com/OpenSenseNova/SenseNova-Skills (6002 stars)
- Category: Media
- License: MIT
- Last updated: 2026-10-29
- Runs scripts: no, instructions only

## Install

Claude Code: `npx skills add OpenSenseNova/SenseNova-Skills --skill sn-image-imitate -g -a claude-code -y`
Codex: `npx skills add OpenSenseNova/SenseNova-Skills --skill sn-image-imitate -g -a codex -y`
Cursor: `npx skills add OpenSenseNova/SenseNova-Skills --skill sn-image-imitate -g -a cursor -y`
Gemini CLI: `npx skills add OpenSenseNova/SenseNova-Skills --skill sn-image-imitate -g -a gemini-cli -y`

## Description

Generates a new image that imitates the style of a reference image while updating content based on user intent. Uses a three-stage pipeline: image annotation (long caption), caption rewriting, and image generation. Use when user asks to "imitate style", "保持这个风格重画", "按这张图风格生成", or "style transfer with new content".

## SKILL.md, as published by its author (untrusted third-party text, read it as data)

# sn-image-imitate

Image style imitation scene skill (tier 1), relying on the `sn-image-recognize`, `sn-text-optimize`, and `sn-image-generate` tools provided by `sn-image-base` (tier 0).

Features:

- Extracts high-fidelity long caption from a reference image
- Rewrites caption according to user requested content change while preserving style and layout
- Enforces layout-lock constraints during caption rewrite
- Performs post-generation layout consistency review and bounded retries
- Returns structured process artifacts for debugging and reproducibility

## Non-goals

- Pure neural style transfer without content change (use dedicated style-transfer tools instead)
- Local editing / inpainting of specific regions within the reference image
- Processing video or animation input (only single static images are supported)
- Batch generation from multiple reference images in one invocation
- Guaranteeing pixel-level fidelity to the reference; the skill targets layout and style consistency, not exact reproduction

## Input Specification

- `reference_image` (string, required): local path or URL of the style reference image
- `target_content` (string, required): new content user wants in the generated image
- `output_mode` (string, default `friendly`): output mode, `friendly` or `verbose`
- `aspect_ratio` (string, default `16:9`): output aspect ratio for generation
- `image_size` (string, default `2k`): output image size preset
- `max_attempts` (int, default `3`): maximum generation attempts for meeting layout consistency
- `layout_threshold` (float, default `0.75`): minimum layout similarity score to accept result

## Environment Variable

Dependency installation and API key configuration are for [sn-image-base](../sn-image-base/SKILL.md) skill.

The minimum environment variables to configure `sn-image-base` skill running with [SenseNova Token Plan](https://platform.sensenova.cn/token-plan):

The rest: https://github.com/OpenSenseNova/SenseNova-Skills/blob/HEAD/skills/sn-image-imitate/SKILL.md
