← 返回
未分类 Key 中文

sudocode-nano-banana2

Generate or edit images with Sudocode's nano-banana2 image service. Use when the user wants text-to-image or image-to-image generation through the bundled Su...
使用 Sudocode 的 nano-banana2 图像服务生成或编辑图像,适用于文生图或图生图需求。
shengy983 shengy983 来源
未分类 clawhub v1.0.1 1 版本 100000 Key: 需要
★ 0
Stars
📥 416
下载
💾 4
安装
1
版本
#latest

概述

Sudocode Nano Banana2

Generate images from text prompts or edit a local image with a prompt through the remote Sudocode API.

Initialize environment on first run

Before the first real use, check whether the required variables exist:

uv run python <skill_dir>/scripts/init_env.py --check-only

If the check reports missing variables, tell the user to first register at https://sudocode.us and apply for an API key, then run:

uv run python <skill_dir>/scripts/init_env.py

The initializer will prompt for values and persist them to ~/.openclaw/.env.

Use the bundled script

Run:

uv run python <skill_dir>/scripts/sudocode_nano_banana2.py --prompt "..." [--input_image path] [--output path]

Inputs:

  • --prompt: required
  • --input_image: optional local image path for image-to-image editing
  • --output: optional output path, defaults to output.png

Environment:

  • SUDOCODE_IMAGE_API_KEY: required API key; if missing, direct the user to register at https://sudocode.us and apply for an API key first
  • SUDOCODE_BASE_URL: optional API base URL for the remote Sudocode service, defaults to https://sudocode.run

Behavior notes:

  • This skill is an API client, not a local inference model
  • It sends prompts and optional input images to the configured Sudocode endpoint
  • It stores credentials in ~/.openclaw/.env only when the initializer is used
  • It writes generated image files and per-run logs to local disk near the chosen output path

The initializer writes these values into ~/.openclaw/.env so future sessions can reuse them.

Remote API and model naming

This skill is named sudocode-nano-banana2 because it packages Sudocode's Nano Banana 2 image capability for OpenClaw.

The bundled script currently calls the upstream model identifier gemini-3.1-flash-image-preview exposed by the configured Sudocode-compatible endpoint. The skill name and upstream model identifier are intentionally different: one is the packaged skill name, the other is the current backend route used by the service.

If requests is missing, install it with:

uv pip install requests

Packaging and portability

This skill is structured as a standard skill package:

  • SKILL.md: trigger metadata and operating instructions
  • scripts/init_env.py: first-run environment bootstrap helper
  • scripts/sudocode_nano_banana2.py: bundled runtime script

Do not include generated images, logs, or other local run artifacts in the distributable package.

Delivering generated images

When using this skill inside OpenClaw, send the generated file with the message tool so the user can actually receive the image.

Use:

message(action="send", filePath="/absolute/path/to/output.png")

Then reply NO_REPLY to avoid duplicate text.

Do not rely on reading the image file or pasting a local path into chat.

Error handling

If the script exits with code 2, relay this message to the user:

❌ 额度不足或请求过于频繁!
👉 请前往 https://sudocode.us 登录并充值后重试。

For other failures, show the script output directly.

版本历史

共 1 个版本

  • v1.0.1 当前
    2026-03-30 19:34 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

design-media

Nano Banana Pro

steipete
使用 Nano Banana Pro (Gemini 3 Pro Image) 生成或编辑图像。支持文生图、图生图及 1K/2K/4K 分辨率,适用于图像创建、修改及编辑请求,使用 --input-image 指定输入图像。
★ 435 📥 117,870
design-media

Openai Whisper

steipete
使用 Whisper CLI 进行本地语音转文字(无需 API 密钥)
★ 335 📥 94,697
design-media

UI/UX Pro Max

xobi667
提供 UI/UX 设计智能与实现指导,帮助打造精美界面。适用于 UI 设计、UX 流程、信息架构、视觉风格、设计系统/标记、组件规格、文案/微文案、无障碍及前端 UI(HTML/CSS/JS、React、Next.js、Vue、Svelte
★ 227 📥 48,865