---
name: prompt-adapt
version: 0.1.0
description: Rewrite one image-generation prompt so it works well on other image models (GPT Image 2, Nano Banana 2, Seedream 5.0 Pro, FLUX.2, Grok Imagine, Qwen Image 3), keeping the meaning, the on-picture text and the style. Use when a prompt was written for one model and you want the version for another, or to compare the same idea across models.
---
# Prompt Adapt
One prompt in, one adapted prompt per target model out. Each result lists what changed and what may not carry over, and links to the Lab image arena so you can compare the pictures.

## Quick check without a key
`plan` prints the exact requests without sending anything. `targets` lists the supported models.
```sh
node scripts/adapt.mjs targets
node scripts/adapt.mjs plan --prompt 'A tiny astronaut watering a bonsai tree on the Moon, Earth in the sky, soft light' --to nano-banana-2,flux-2
```

## Adapt a prompt
Requires Node.js 18+ and `SANDBASE_API_KEY` in the current process environment. Never place the key in a prompt, a command argument, a file or a report.
```sh
node scripts/adapt.mjs run --prompt 'A tiny astronaut watering a bonsai tree on the Moon' --from gpt-image-2 --to nano-banana-2,seedream-5.0-pro --out ./adapted --lang zh-CN
node scripts/adapt.mjs run --file my-prompt.txt --to flux-2 --out ./adapted
```
- `--to` takes up to six targets, comma separated. A short name such as `nano-banana-2` is enough when it is unambiguous.
- `--from` is optional and only tells the rewriter which model the prompt was written for.
- `--lang` sets the language of the explanations (`en` or `zh-CN`). The adapted prompt itself keeps the language of the source.
- `--model` overrides the rewriting text model (default `anthropic/claude-sonnet-5.5`).

Each target is one short text request through SandBase, so a run with three targets is three small requests. Check current SandBase pricing before a large batch. A target that fails is recorded as failed and the others still finish.

Outputs: `report.json`, `report.en.html` and `report.zh-CN.html`. `{argument name="…" default="…"}` slots in the source are replaced by their defaults before rewriting.

## Replay the official example
```sh
node scripts/adapt.mjs replay --out ./adapted --lang en
```
This renders the archived example in `results/official.json` and makes no model call.

## What to check
An adapted prompt is a starting point. The guidelines per model live in `assets/targets.json` and are general advice, not guarantees. Generate the same idea on each model, for example in the Lab image arena (the report links there when the prompt is short enough), and compare the pictures before relying on one. Read [references/workflow.md](references/workflow.md) for the request, the output shape and the failure codes.

## Boundaries
The skill rewrites text. It does not generate pictures, does not search for prompts, and does not name real people or add brands the source did not contain. Prompts shared by other people belong to their creators; keep their credit when you republish.
