SuperAPI AI 工具集

nano-banana-imagegen

设计与创作

查看项目

更新于 10-16 01:09

技能介绍

用途:通过 nano-banana CLI 调用 Google Gemini 图像模型,完成文生图与图像编辑。适用于用户要求创建、生成或编辑 AI 图片的场景。

主要能力:支持文本生成图像、基于已有图片的编辑、指定输出路径、选择特定 Gemini 模型,以及使用 --flash 调用 gemini-2.5-flash-image 获得更快、更简单的图像。

使用方式:需先设置 GEMINI_API_KEY 环境变量,CLI 通过 npx @the-focus-ai/nano-banana 运行。生成示例:npx @the-focus-ai/nano-banana "a serene mountain landscape at sunset"。编辑示例:npx @the-focus-ai/nano-banana "add a hot air balloon to the sky" --file photo.jpg。指定输出:npx @the-focus-ai/nano-banana "a minimalist logo" --output logo.png。指定模型:npx @the-focus-ai/nano-banana "detailed illustration" --model gemini-2.5-flash-image。默认输出为 output/generated-<timestamp>.png。

选项:--file 输入待编辑图片,--output 自定义输出路径,--model 指定 Gemini 模型,--flash 使用 gemini-2.5-flash-image,--prompt-file 从文件读取提示词,--list-models 列出可用模型。

适用场景:页眉/主视觉图、产品摄影风格图、插画、图标与 Logo 等。建议提示词具体描述主体、风格、氛围、构图与用途,并加入负面约束;编辑时明确修改内容并保留不变部分,逐步迭代。

限制:需有效的 GEMINI_API_KEY;提示词可能触发安全过滤导致无图像返回;模型默认生成方形图,宽高比需在提示词中描述;效果依赖提示词质量与所选模型。其他收费、价格与平台细节暂未提供。