SuperAPI AI 工具集

pollinations-image-gen

设计与创作

查看项目

更新于 10-15 23:40

技能介绍

用途:根据文本描述调用 Pollinations.ai API 生成图像,适合用户提出生成、创建、绘制或渲染图片,或提到 Pollinations 及受支持模型名称时使用。

主要能力:通过 node 运行 {baseDir}/scripts/generate.mjs,所有参数以 --key value 形式传入。必填参数为 --prompt(图像文本描述,建议写得详细)和 --model。可选参数包括 --output(输出路径,父目录自动创建,省略则用当前目录加时间戳文件名)、--width 与 --height(默认 1024)、--seed(默认 0,-1 为随机)、--enhance(true 让 AI 优化提示词)、--negative_prompt(默认 "worst quality, blurry")、--safe(true 启用安全过滤)、--quality(low/medium/high/hd,仅 gptimage)、--image(参考图 URL,多个用逗号或竖线分隔)、--transparent(true 透明背景,仅 gptimage)。

模型:免费模型有 flux(默认)、zimage、imagen-4、klein、klein-large、gptimage;付费模型需设置 POLLINATIONS_PAID=true,包括 seedream/seedream-pro、kontext、nanobanana/nanobanana-pro、gptimage-large。

用法示例:node {baseDir}/scripts/generate.mjs --prompt "a beautiful sunset over mountains" --model flux;可组合 --width、--height、--seed、--enhance、--negative_prompt、--safe、--quality、--transparent、--image、--output 等参数。

限制:模型可用性取决于 POLLINATIONS_PAID 环境变量,未设为 true 时只能用免费模型;quality 与 transparent 仅 gptimage 支持;生成完成后应告知用户输出文件路径。