← Back to Skills Marketplace
papayalove

Kay Image

by papayalove · GitHub ↗ · v1.0.3 · MIT-0
cross-platform ⚠ suspicious
117
Downloads
1
Stars
0
Active Installs
4
Versions
Install in OpenClaw
/install kay-image
Description
AI 图片生成与理解工具 - 支持文生图、图生图、图片理解、视频理解。 基于 KIE AI API,支持 4K 输出、多种宽高比和参考图。 **所需凭证**: 需要 KIE_API_KEY 环境变量(从 https://kie.ai/ 获取)
README (SKILL.md)

Kay Image - AI 图片生成与理解

基于 KIE AI API 的图片生成与理解工具。

⚠️ 必需凭证

使用本工具前,必须配置 API Key:

获取 KIE API Key

  1. 访问 https://kie.ai/
  2. 注册并登录账号
  3. 进入控制台 → API 管理
  4. 创建 API Key 并复制

配置环境变量

export KIE_API_KEY="your-kie-api-key-here"

或在 skill 目录创建 .env 文件:

# 创建 .env 文件
nano skills/kay-image/.env

.env 文件内容:

KIE_API_KEY=your-kie-api-key-here

注意: 没有 API Key 将无法使用本工具的任何功能。


特性

  • 文生图: 根据文本描述生成图片
  • 图生图: 基于参考图进行编辑/变换
  • 图片理解: 分析图片内容(使用 GPT-5/Gemini)
  • 视频理解: 分析视频内容(使用 Gemini)
  • 多分辨率: 支持 1K/2K/4K 输出
  • 多宽高比: 支持 1:1, 3:4, 4:3, 9:16, 16:9, 21:9 等

使用方法

基本文生图

kay-image --prompt "一只可爱的橘猫在草地上玩耍" --output cat.png

指定宽高比和分辨率

kay-image --prompt "上海外滩夜景" --output shanghai.png --ar 16:9 --resolution 2K

图生图

kay-image --prompt "转换成动漫风格" --input https://example.com/photo.jpg --output anime.png

图片理解

kay-image --understand --image https://example.com/photo.jpg --prompt "描述这张图片"

视频理解

kay-image --understand --video https://example.com/video.mp4 --prompt "分析这个视频"

参数说明

参数 简写 说明 默认值
--prompt -p 提示词 -
--output -o 输出路径 -
--input -i 参考图路径 -
--ar - 宽高比 1:1
--resolution -r 分辨率 1K
--understand -u 理解模式 false
--image - 图片路径 -
--video - 视频路径 -

环境变量

变量名 必需 说明
KIE_API_KEY ✅ 是 KIE AI API 密钥
KIE_UNDERSTANDING_API_KEY ❌ 否 理解功能 API 密钥(默认使用 KIE_API_KEY)
LAOZHANG_API_KEY ❌ 否 LaoZhang API 密钥(可选)

价格参考

  • 1K 图片: ~$0.04
  • 2K 图片: ~$0.06
  • 4K 图片: ~$0.09
  • 图片理解: ~$0.005-0.01/张

支持的宽高比

  • 1:1 - 正方形
  • 3:4 - 小红书/Instagram 竖版
  • 4:3 - 标准横版
  • 9:16 - 手机竖屏
  • 16:9 - 宽屏
  • 21:9 - 超宽屏

示例

生成小红书封面

kay-image -p "清新风格护肤品封面,粉色渐变背景" -o cover.png --ar 3:4 -r 2K

生成头像

kay-image -p "动漫风格女生头像,粉色头发" -o avatar.png --ar 1:1

图片风格迁移

kay-image -p "转换成油画风格" -i photo.jpg -o painting.png

OCR 文字提取

kay-image -u --image document.jpg --prompt "提取所有文字"

脚本位置

${SKILL_DIR}/scripts/main.ts


注意事项

  • 视频理解: 仅 Gemini 模型支持
  • 图片格式: 支持 JPG、PNG、WebP
  • 视频格式: 支持 MP4、MOV
  • 文件大小: 建议图片 \x3C 10MB,视频 \x3C 100MB
Usage Guidance
This skill appears to implement an image-generation and understanding CLI that calls KIE (and optionally LaoZhang) APIs — that is coherent with its description. Before installing, verify these things: 1) Source and trust: the package has no homepage and the publisher identity is unknown — consider whether you trust the author. 2) Runtime: the script requires Bun (#! /usr/bin/env bun) and is TypeScript; ensure your environment supports Bun or the platform will need to provide it. 3) Credentials: the tool uploads images/videos to remote APIs; only provide an API key with minimal permissions and avoid committing .env files into repos or shared storage. 4) Understanding mode requires either KIE_UNDERSTANDING_API_KEY or LAOZHANG_API_KEY (the metadata only listed KIE_API_KEY) — set these intentionally. 5) Review the full script for any endpoints you don’t recognize and test in a sandbox before running on sensitive files. If you want higher assurance, ask the author for source provenance, an explicit runtime requirement list (Bun/node), and a published homepage or repository for review.
Capability Analysis
Type: OpenClaw Skill Name: kay-image Version: 1.0.3 The kay-image skill is a legitimate tool for AI image generation and analysis using the KIE and LaoZhang APIs. The implementation in scripts/main.ts follows the documented functionality, using standard fetch calls to interact with specified API endpoints (api.kie.ai and api.laozhang.ai) and handling local file reading only when explicitly requested by the user for image/video understanding tasks.
Capability Assessment
Purpose & Capability
Name/description (text→image, image→image, image/video understanding via KIE or LaoZhang) align with the code and CLI options. However, the package metadata declares only KIE_API_KEY as required while the implementation also requires KIE_UNDERSTANDING_API_KEY or LAOZHANG_API_KEY for 'understand' mode. Also the script uses a Bun shebang (#!/usr/bin/env bun) but 'required binaries' lists none — the runtime dependency on Bun is not declared.
Instruction Scope
SKILL.md CLI usage and the script consistently instruct reading local files, accepting remote URLs, and sending data to KIE or LaoZhang APIs — this is expected for the stated purpose. The docs recommend storing API keys in a .env file under skills/kay-image/.env (user-run instruction). Be aware the tool will read local files (fileToBase64) and upload their contents to remote APIs — expected, but sensitive files could be transmitted if provided.
Install Mechanism
No install spec (instruction-only) — low supply-chain risk. However, the script is written for Bun (shebang) and TypeScript; the skill does not declare Bun or any runtime as a required binary. That undeclared runtime requirement may cause failures or hidden assumptions about the environment.
Credentials
Requested credentials (KIE_API_KEY for generation; KIE_UNDERSTANDING_API_KEY or LAOZHANG_API_KEY for understanding) are proportionate to the functionality. Minor inconsistency: metadata frontmatter lists only KIE_API_KEY as required while the code enforces additional environment variables for understanding mode. No unrelated cloud or system credentials are requested.
Persistence & Privilege
The skill is not flagged 'always: true' and does not request system-wide configuration or other skills' credentials. It has no install step that would persist new system services. It does read/write local files only under user-directed paths (output path, optional .env), which is expected for a CLI.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install kay-image
  3. After installation, invoke the skill by name or use /kay-image
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.3
Simplify setup: direct .env creation instead of copying from example
v1.0.2
Rename .env.example to env.example to ensure it's included in package
v1.0.1
Include .env.example file in package
v1.0.0
Initial release with clear dependency declaration and credential requirements
Metadata
Slug kay-image
Version 1.0.3
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 4
Frequently Asked Questions

What is Kay Image?

AI 图片生成与理解工具 - 支持文生图、图生图、图片理解、视频理解。 基于 KIE AI API,支持 4K 输出、多种宽高比和参考图。 **所需凭证**: 需要 KIE_API_KEY 环境变量(从 https://kie.ai/ 获取). It is an AI Agent Skill for Claude Code / OpenClaw, with 117 downloads so far.

How do I install Kay Image?

Run "/install kay-image" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is Kay Image free?

Yes, Kay Image is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does Kay Image support?

Kay Image is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created Kay Image?

It is built and maintained by papayalove (@papayalove); the current version is v1.0.3.

💬 Comments