Skip to content
Back to skills

Sih Image Gen

ASecurity

AI图片生成与编辑工具,使用Sih.AI API进行自然语言驱动的图片处理。支持换装、换背景、换脸、风格转换(动漫/粘土/油画等)、美颜修图等功能。当用户需要通过自然语言描述来编辑图片(如\"把衣服换成bikini\"、\"背景换成海边\"、\"转换成动漫风格\")时使用此skill。

  • 33 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added September 5, 2026
ai-agentspythonbashapi

Works with

  • api

Security analysis

A100/100

Pro scans all 2 files and shows the line behind each finding

Scanned September 5, 2026

npx -y skills add dvcrn/openclaw-skills-marketplace --skill sih-image-gen --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Sih Image Gen?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Sih Image Gen
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/dvcrn-sih-image-gen/badge)](https://www.skillsdirectory.com/skills/dvcrn-sih-image-gen)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: sih-image-gen
description: "AI图片生成与编辑工具,使用Sih.AI API进行自然语言驱动的图片处理。支持换装、换背景、换脸、风格转换(动漫/粘土/油画等)、美颜修图等功能。当用户需要通过自然语言描述来编辑图片(如\"把衣服换成bikini\"、\"背景换成海边\"、\"转换成动漫风格\")时使用此skill。"
---

# Sih.AI 图片生成

## 快速开始

通过自然语言描述来编辑图片,使用 `scripts/image_gen.py` 脚本调用API。

### 基本用法

```bash
# 使用URL
python scripts/image_gen.py "https://example.com/image.jpg" "背景改为在海边"

# 使用本地文件
python scripts/image_gen.py "./photo.jpg" "换成动漫风格"

# 指定模型
python scripts/image_gen.py "./photo.jpg" "美颜修图" "sihai-image-27"
```

### 常用处理提示词

- **换背景**: "背景改为在海边"、"背景换成城市夜景"、"背景改为森林"
- **换装**: "把衣服换成bikini"、"换成晚礼服"、"换成运动装"
- **风格转换**: "转换成动漫风格"、"转换成油画风格"、"转换成粘土风格"
- **美颜**: "美颜修图"、"磨皮美白"、"瘦身"

## API参数

### image (必需)
- **类型**: string 或 array
- **格式**:
  - 图片URL: `https://example.com/image.jpg`
  - Base64: 纯base64编码字符串(**不带** `data:image/...;base64,` 前缀)
- **说明**: 脚本会自动将本地文件路径转换为纯Base64格式(适配sihai-image-27模型)

### prompt (必需)
- **类型**: string
- **说明**: 自然语言描述想要的编辑效果
- **建议**: 使用简洁、明确的中文描述

### model (可选)
- **类型**: string
- **默认值**: `sihai-image-27`
- **说明**: 使用的模型名称

## 输出格式

API返回JSON格式,包含生成的图片URL:

```json
{
  "model": "sihai-image-27",
  "created": 1773386658,
  "data": [
    {
      "url": "https://...",
      "size": "2048x2048"
    }
  ],
  "usage": {
    "generated_images": 1,
    "output_tokens": 16384,
    "total_tokens": 16384
  }
}
```

## 错误处理

- **401/403**: API token无效或过期
- **400**: 参数错误(图片URL无效、prompt为空等)
- **500/503**: 服务暂时不可用,稍后重试

## 注意事项

- 确保图片URL可公开访问
- sihai-image-27模型使用纯base64编码,**不需要** `data:image/...;base64,` 前缀
- 生成的图片URL有效期为24小时

Files in this skill

  • SKILL.md2.4 KB
  • scripts/image_gen.py2.6 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…