闲社服务运行正常AI智能体自动化平台
r

Recraft图像处理

技能标识:recraft

Generate, vectorize, upscale, replace background, variate, remove background, and transform images via Recraft API.

作者:admin | 来源记录:ClawHub
登记来源
ClawHub
版本
V 1.0.0
检测标记
后台标记通过
免费
免费获取
0
收藏
来源与检测标记为平台登记信息,并不代表已展示可复核的检测报告。使用前请核对版本、依赖和所需权限,建议先在隔离环境中运行。
概述
安装方式
版本历史

Recraft图像处理

Recraft

使用捆绑脚本通过 Recraft API 生成、矢量化、放大、替换背景、变换、移除背景以及转换图像。

设置

  1. 1. 要获取您的 API 密钥,请登录 Recraft 并访问页面:https://www.recraft.ai/profile/api
  2. 点击“生成新密钥”按钮生成令牌(仅当您的 API 单位余额大于零时可用)
  3. 设置环境变量:
bash export RECRAFTAPITOKEN=your-api-token

命令

生成图像

bash
uv run {baseDir}/scripts/recraft.py generate --prompt 您的图像描述 --style Recraft V3 Raw --filename output.png --size 16:9

图像到图像

bash
uv run {baseDir}/scripts/recraft.py image-to-image --prompt 您的图像描述 --style Recraft V3 Raw --input /path/to/input.png --filename output.png --strength 0.5

替换背景

bash
uv run {baseDir}/scripts/recraft.py replace-background --prompt 您的背景描述 --style Recraft V3 Raw --input /path/to/input.png --filename output.png

矢量化图像

bash
uv run {baseDir}/scripts/recraft.py vectorize --input /path/to/input.png --filename output.svg

移除背景

bash
uv run {baseDir}/scripts/recraft.py remove-background --input /path/to/input.png --filename output.png

清晰放大

bash
uv run {baseDir}/scripts/recraft.py crisp-upscale --input /path/to/input.png --filename output.png

创意放大

bash
uv run {baseDir}/scripts/recraft.py creative-upscale --input /path/to/input.png --filename output.png

变换图像

bash
uv run {baseDir}/scripts/recraft.py variate --input /path/to/input.png --filename output.png --size 16:9

获取用户信息

bash
uv run {baseDir}/scripts/recraft.py user-info

参数

  • - --prompt, -p:图像生成或编辑的文本描述,最多 1000 个字符
  • --input, -i:输入图像路径(用于编辑/转换命令)
  • --filename, -f:输出文件名
  • --style, -s:视觉风格(默认:Recraft V3 Raw)
- Recraft V3 Raw、Photorealism、Illustration、Vector art、Icon
  • - --size:输出尺寸(宽高比)(默认:1:1)
- 1:1、2:1、1:2、3:2、2:3、4:3、3:4、5:4、4:5、6:10、14:10、10:14、16:9、9:16
  • - --strength:图像到图像的变换强度(0.0-1.0,默认:0.5),0 表示几乎相同,1 表示最小相似度

API 密钥

  • - RECRAFTAPITOKEN 环境变量
  • 或在 ~/.openclaw/openclaw.json 中设置 skills.recraft.apiKey / skills.recraft.env.RECRAFTAPITOKEN

注意事项

  • - 在文件名中使用时间戳:yyyy-mm-dd-hh-mm-ss-name.png。
  • 脚本会打印 MEDIA: 行,供 OpenClaw 在支持的聊天提供商上自动附加。
  • 不要回读图像;仅报告保存路径。
  • 矢量艺术和图标样式输出 SVG 格式。
  • 速率限制:每分钟 100 个请求;每秒 5 个请求。

标签

skill ai

通过对话安装

以下为平台配置的接入选项,并非逐项实测通过。能否安装取决于客户端支持、技能来源和运行环境:

OpenClaw WorkBuddy QClaw Kimi Claude

方式一:安装 SkillHub 和技能

帮我安装 SkillHub 和 recraft-ai-1776359968 技能

方式二:设置 SkillHub 为优先技能安装源

设置 SkillHub 为我的优先技能安装源,然后帮我安装 recraft-ai-1776359968 技能

通过命令行安装

skillhub install recraft-ai-1776359968

下载

⬇ 下载 recraft v1.0.0(免费)

文件大小: 4.84 KB | 发布时间: 2026-4-17 14:19

v1.0.0 最新 2026-4-17 14:19
Initial release of the recraft skill.

- Generate, vectorize, upscale, variate, replace/remove backgrounds, and transform images via the Recraft API.
- Offers multiple visual styles including photorealism, illustration, vector art, and icon.
- Supports custom prompt, input/output file paths, style, size, and transformation strength.
- Includes commands for image generation, editing, background operations, upscaling, and user info retrieval.
- Requires RECRAFT_API_TOKEN for authentication; setup instructions and rate limits documented.
返回顶部