nano-banana-edit
Edit images with Google Nano Banana 2 (image-to-image edit endpoint) on RunComfy. Documents Nano Banana Edit's strengths (preserve subject identity, swap background, localize edits with spatial language, multi-image batch edits up to 20 inputs), the schema, and when to route to GPT Image 2 edit / Flux Kontext / Nano Banana 2 t2i instead. Calls `runcomfy run google/nano-banana-2/edit` through the local RunComfy CLI. Triggers on "nano banana edit", "edit with nano banana", "image edit nano banana", or any explicit ask to edit with this model.
1How It Works & Mechanism
Dedicated single-endpoint documentation (i2i editing): Centers around `google/nano-banana-2/edit`. Core parameters include the `image_urls` array (1–20 publicly crawlable URLs, with the first image acting as the primary anchor), `number_of_images` (1–4 outputs), `seed`, `aspect_ratio`, `resolution`, `output_format`, `safety_tolerance`, `limit_generations`, and `enable_web_search`.
| `image_urls` | array | yes | — | **1–20** publicly-fetchable HTTPS URLs. |
First prompt principle = preservation-first: Explicitly prepend 'Keep [identity/pose/clothing/brand/framing] unchanged' before describing modifications. The documentation explains the underlying mechanism (the model strictly adheres only to front-loaded preservation targets).
**Preservation first, change last.** Always lead with `"Keep [identity / pose / clothing / brand / framing] unchanged."` Then state the change in one clean sentence. Models honor what's stated up front; tail-end preservations get ignored.
Localized edits are achieved via spatial language: Concrete spatial scopes like 'background only', 'the left object', or 'upper-right corner' are strictly respected by the model, whereas vague directives like 'make it more X' lead to drift.
**Localize with spatial language.** "background only", "the left object", "the upper-right corner", "above the headline" — concrete spatial scopes are honored. "make it more X" is vague and drifts.
Batch consistency discipline: Series edits must lock `aspect_ratio` + `resolution` and share the same prompt syntax, ensuring batch outputs appear as 'siblings' rather than remixes; complex edits must be decomposed into small iterative passes rather than executed as a single compound prompt.
**Batch consistency** — when editing a series, lock `aspect_ratio` and `resolution`. Use the same prompt grammar across the batch so each output reads as a sibling, not a remix.
Boundaries and routing: Multilingual in-image text edits are explicitly routed to GPT Image 2 edit; high-fidelity single-reference localized edits are routed to Flux Kontext; scratch generation is routed to the sibling nano-banana-2 t2i—the skill does not claim to be all-purpose.
| Edit multilingual text inside the image (signs, labels) | GPT Image 2 edit |
Execution delegated to runcomfy CLI + cloud inference: Executes `runcomfy run google/nano-banana-2/edit --input '{...}' --output-dir`, where the CLI sends a POST request to the full API URL, polls for completion, and downloads the results.
The skill invokes `runcomfy run google/nano-banana-2/edit` with a JSON body matching the schema. The CLI POSTs to `https://model-api.runcomfy.net/v1/models/google/nano-banana-2/edit`, polls the request, fetches the result, and downloads any `.runcomfy.net`/`.runcomfy.com` URL into `--output-dir`.
2Core Capabilities
3External Dependencies
| Kind | Dependency / Endpoint |
|---|---|
| cli | runcomfy(@runcomfy/cli 官方 CLI) |
| package | @runcomfy/cli(npm 全局安装) |
| api | Google Nano Banana 2 图生图编辑端点(RunComfy Model API 托管) |
| network | 生成结果下载白名单 |
| network | 用户提供的 1–20 张输入图 URL——由 RunComfy 模型服务器抓取 |
| network | RunComfy 模型页 / 文档站(引用链接) |
4Recommended Governance & Evidence
- 网络端点: Declared external network access: model-api.runcomfy.net/v1/models/google/nano-banana-2/edit — Edit request submission (via runcomfy CLI)
- 本地工作目录: File I/O and artifact output: The CLI downloads generated results into the local directory specified by --output-dir (path determined by the caller)
- SKILL.md: Declared invocation of host CLI interpreter or external runtime environment
5Second-Pass Verification
- [ok] 端点 ID 与完整 URL 一致(google/nano-banana-2/edit) — description、schema 标题、How-it-works 完整 URL 三处一致,无拼写漂移。
- [ok] 1–20 输入与 1–4 输出约束在 description/schema/Limitations 三处一致 — description(up to 20 inputs)、schema(1–20 / 1–4)、Limitations(1–20 input images / 1–4 outputs)数字自洽。
- [ok] 与 image-edit Route 1 的同源关系 — preservation-first 话术、cyberpunk 背景与 AURA 水印示例在 nano-banana-edit 与 image-edit 中逐字一致——确认为同源内容,非本文件独有。
- [ok] 多语种文字编辑让位 GPT Image 2 / 单参考让位 Flux Kontext 的导流 — When-to-pick 表与 Limitations 两处一致;对应品牌技能 gpt-image-edit/、flux-kontext/ 在仓库内真实存在。
- [unlocatable] SKILL.md 对 CLI 行为的断言(token 0600、2 GiB、无 shell 展开) — CLI 源码不在本仓库,仅文档自述,无法独立证实。
- [unlocatable] 『verified to produce strong results』sample prompts — 样例提示词自称 verified,仓内无评测证据可复核。
- [discrepancy] 身份/安装链接一致性 — SKILL.md 安装与 GitHub 链接指向 agentspace-so/runcomfy-skills,被 pin 镜像为 prime-skills/runcomfy-agent-skills——来源标识不一致(发布身份漂移)。
6Verdict & Scenarios
ba0f1dd15b2c6baf…