@unityclaw/skills 1.0.6 → 1.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # @unityclaw/skills
2
2
 
3
- UnityClaw Skills - Claude Code and OpenClaw skill definitions for AI-powered image/video generation, media analysis, and document processing.
3
+ UnityClaw Skills for Claude Code and OpenClaw.
4
4
 
5
5
  ## Installation
6
6
 
@@ -14,20 +14,15 @@ npx @unityclaw/skills --help
14
14
 
15
15
  ## API Key Configuration
16
16
 
17
- All skills require an API key. You can configure it using the SDK CLI:
17
+ All skills require an API key:
18
18
 
19
19
  ```bash
20
- # Install SDK globally
21
20
  npm install -g @unityclaw/sdk
22
-
23
- # Configure API key (stored in ~/.unityclaw/config.json)
24
21
  unityclaw-sdk config set apiKey your-api-key
25
-
26
- # Verify configuration
27
22
  unityclaw-sdk config
28
23
  ```
29
24
 
30
- Or set the environment variable:
25
+ Or:
31
26
 
32
27
  ```bash
33
28
  export UNITYCLAW_API_KEY=your-api-key
@@ -35,102 +30,100 @@ export UNITYCLAW_API_KEY=your-api-key
35
30
 
36
31
  ## CLI Commands
37
32
 
38
- ### Install Skills
39
-
40
- Install skills to Claude Code or OpenClaw:
41
-
42
33
  ```bash
43
34
  # Install all skills to Claude Code
44
35
  npx @unityclaw/skills install
45
36
 
46
37
  # Install specific skills
47
- npx @unityclaw/skills install unityclaw-image-generation unityclaw-video-generation-sora
38
+ npx @unityclaw/skills install unityclaw-image-generation unityclaw-video-generation-kling
48
39
 
49
40
  # Install to OpenClaw
50
41
  npx @unityclaw/skills install --target openclaw
51
- ```
52
42
 
53
- ### List Available Skills
54
-
55
- ```bash
43
+ # List available skills
56
44
  npx @unityclaw/skills list
57
- ```
58
-
59
- ### Update Packages
60
45
 
61
- Update SDK and skills to the latest version:
62
-
63
- ```bash
64
- # Update local packages
46
+ # Update sdk + skills
65
47
  npx @unityclaw/skills update
66
-
67
- # Update global packages
68
- npx @unityclaw/skills update --global
69
48
  ```
70
49
 
71
- ### Execute Skills Directly
72
-
73
- Execute a skill via Claude Code CLI:
50
+ ## Reorganized Skill List
74
51
 
75
- ```bash
76
- # Generate an image
77
- npx @unityclaw/skills /unityclaw-image-generation 我要一张竖屏的桌面背景图
52
+ This list is aligned with `~/moox/field-feishu` shortcuts and `server` `ParameterModel` definitions.
78
53
 
79
- # Analyze a video
80
- npx @unityclaw/skills /unityclaw-media-analysis https://youtube.com/watch?v=...
81
- ```
54
+ - Removed from skill list: `sora/*`, `veo/*`
55
+ - No version-level split for same model family (for example, no separate `jimeng-image-v3` skill)
56
+ - Document conversion is abstracted as one skill/API entry instead of many individual shortcut skills
82
57
 
83
- ## Available Skills
58
+ ### Image
84
59
 
85
- ### Image Skills
60
+ - [unityclaw-image-generation](./unityclaw-image-generation/SKILL.md)
61
+ : Covers `gemini/image/v2` + `jimeng/image` (unified)
62
+ - [unityclaw-image-compress](./unityclaw-image-compress/SKILL.md)
63
+ : Covers `image/compress`
86
64
 
87
- | Skill | Description | Emoji |
88
- |-------|-------------|-------|
89
- | [unityclaw-image-generation](./unityclaw-image-generation/SKILL.md) | Generate images using Gemini or JiMeng models | 🎨 |
90
- | [unityclaw-image-compress](./unityclaw-image-compress/SKILL.md) | Compress images with quality control | 🗜️ |
65
+ ### Video
91
66
 
92
- ### Video Skills
93
- | Skill | Description | Emoji |
94
- |-------|-------------|-------|
95
- | [unityclaw-video-generation-kling](./unityclaw-video-generation-kling/SKILL.md) | Generate videos using Kling AI | 📹 |
96
- | [unityclaw-video-generation-other](./unityclaw-video-generation-other/SKILL.md) | Generate videos using Doubao, Wan, MiniMax, JiMeng | 🎞️ |
67
+ - [unityclaw-video-generation-kling](./unityclaw-video-generation-kling/SKILL.md)
68
+ : Covers `kling/video`
69
+ - [unityclaw-video-generation-jimeng-doubao](./unityclaw-video-generation-jimeng-doubao/SKILL.md)
70
+ : Covers `jimeng/video`, `doubao/video`
71
+ - [unityclaw-video-generation-wan-minimax](./unityclaw-video-generation-wan-minimax/SKILL.md)
72
+ : Covers `wan/video`, `minimax/video`
97
73
 
98
- ### Document Skills
74
+ ### Document
99
75
 
100
- | Skill | Description | Emoji |
101
- |-------|-------------|-------|
102
- | [unityclaw-document-translation](./unityclaw-document-translation/SKILL.md) | Translate documents between languages | 🌐 |
103
- | [unityclaw-document-convert](./unityclaw-document-convert/SKILL.md) | Convert document formats (PDF/Word/PPT/Excel/Image) | 📄 |
76
+ - [unityclaw-document-translation](./unityclaw-document-translation/SKILL.md)
77
+ : Covers `doc/translate`
78
+ - [unityclaw-document-convert](./unityclaw-document-convert/SKILL.md)
79
+ : Covers generic `doc_convert/image` + `doc_convert/pdf`
104
80
 
105
- ### Media Skills
81
+ ### Media
106
82
 
107
- | Skill | Description | Emoji |
108
- |-------|-------------|-------|
109
- | [unityclaw-media-analysis](./unityclaw-media-analysis/SKILL.md) | Analyze video/audio content and extract insights | 📊 |
83
+ - [unityclaw-media-analysis](./unityclaw-media-analysis/SKILL.md)
84
+ : Covers `media_analysis`
85
+ - [unityclaw-media-stats](./unityclaw-media-stats/SKILL.md)
86
+ : Covers `media_stats`
87
+ - [unityclaw-media-user-info](./unityclaw-media-user-info/SKILL.md)
88
+ : Covers `media_user_info`
89
+ - [unityclaw-media-download-xhs](./unityclaw-media-download-xhs/SKILL.md)
90
+ : Covers `xiaohongshu/download`
91
+ - [unityclaw-video-frame-extract](./unityclaw-video-frame-extract/SKILL.md)
92
+ : Covers `video/frame`
110
93
 
111
- ## Programmatic Usage
94
+ ### IDP
112
95
 
113
- ```typescript
114
- import { listSkills, installSkills, executeSkill } from '@unityclaw/skills';
96
+ - [unityclaw-idp-personal-documents](./unityclaw-idp-personal-documents/SKILL.md)
97
+ : Covers `idp/id_card`, `idp/vehicle_license`, `idp/bank_card`
98
+ - [unityclaw-idp-invoice-extraction](./unityclaw-idp-invoice-extraction/SKILL.md)
99
+ : Covers `idp/vat_invoice`, `idp/train_invoice`, `idp/taxi_invoice`
100
+ - [unityclaw-idp-business-extraction](./unityclaw-idp-business-extraction/SKILL.md)
101
+ : Covers `idp/business_license`, `idp/business_card`
102
+ - [unityclaw-idp-contract-extraction](./unityclaw-idp-contract-extraction/SKILL.md)
103
+ : Covers `idp/contract`
115
104
 
116
- // List available skills
117
- const skills = await listSkills();
118
- console.log(skills);
105
+ IDP is intentionally split by scenario (personal/invoice/business/contract), instead of one generic skill, to improve skill routing accuracy and parameter selection success.
119
106
 
120
- // Install skills to Claude Code
121
- await installSkills('claude', ['unityclaw-image-generation']);
107
+ ## Local File Input Support
122
108
 
123
- // Install all skills to OpenClaw
124
- await installSkills('openclaw');
109
+ With latest SDK, skill examples can use local file paths directly:
125
110
 
126
- // Execute a skill
127
- await executeSkill('/unityclaw-image-generation A beautiful sunset');
111
+ ```ts
112
+ attachment: [{ path: './files/input.pdf' }]
128
113
  ```
129
114
 
130
- ## SDK Documentation
115
+ SDK will auto-upload the local file through `/api/upload` and replace it with a valid `tmp_url`.
116
+
117
+ ## Parameter Normalization Notes
118
+
119
+ Only endpoints that **require** field-feishu structures are normalized.
131
120
 
132
- - [npm: @unityclaw/sdk](https://www.npmjs.com/package/@unityclaw/sdk)
133
- - [UnityClaw Homepage](https://unityclaw.com)
121
+ - Text array conversion (`string` -> `[{ type: 'text', text: '...' }]`) is applied only for:
122
+ `jimeng/image`, `jimeng/image/v3`, `sora/video`, `sora/video/stable`, `veo/video`, `jimeng/video`, `doubao/video`.
123
+ - Label conversion (`'16:9'` -> `{ value: '16:9', label: '16:9' }`) is applied only for endpoints whose `ParameterModel` expects `LabelFieldItem`.
124
+ - For `doubao/video`, duration should use numeric value in `LabelFieldItem.value` when provided (for example `{ value: 5, label: '5' }`).
125
+ - Endpoints that already support plain strings are kept as-is (no forced conversion).
126
+ - If you pass full field-feishu structures, SDK keeps them unchanged.
134
127
 
135
128
  ## License
136
129
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@unityclaw/skills",
3
- "version": "1.0.6",
3
+ "version": "1.0.8",
4
4
  "description": "UnityClaw Skills - Claude Code and OpenClaw skill definitions for AI-powered image/video generation, media analysis, and more",
5
5
  "type": "module",
6
6
  "bin": {
@@ -22,6 +22,7 @@ metadata:
22
22
  # UnityClaw Document Convert
23
23
 
24
24
  Convert documents between various formats including PDF, Word, PowerPoint, Excel, and images.
25
+ Recommended API is unified `client.document.convertDocument(...)`.
25
26
 
26
27
  ## Installation
27
28
 
@@ -71,11 +72,13 @@ import { UnityClawClient } from '@unityclaw/sdk';
71
72
 
72
73
  const client = new UnityClawClient();
73
74
 
74
- // Convert PDF to Word
75
- const result = await client.document.pdf2Word({
75
+ // Convert PDF to Word (unified API)
76
+ const result = await client.document.convertDocument({
76
77
  attachment: [
77
- { tmp_url: 'https://example.com/document.pdf', name: 'document.pdf' }
78
- ]
78
+ { path: './files/document.pdf' }
79
+ ],
80
+ input_format: 'pdf',
81
+ output_format: 'docx'
79
82
  });
80
83
 
81
84
  // ✅ Correct: Check result.success, access data via result.response.data
@@ -108,6 +111,7 @@ if (result.success && result.response?.data) {
108
111
 
109
112
  | Method | Description |
110
113
  |--------|-------------|
114
+ | `convertDocument()` | Recommended unified conversion API |
111
115
  | `convert()` | Generic conversion with format specification |
112
116
 
113
117
  ## API Reference
@@ -73,7 +73,7 @@ const client = new UnityClawClient();
73
73
 
74
74
  const result = await client.document.translate({
75
75
  attachment: [
76
- { tmp_url: 'https://example.com/document.pdf', name: 'document.pdf' }
76
+ { path: './files/document.pdf' }
77
77
  ],
78
78
  source_language: { value: 'en', label: 'English' },
79
79
  target_language: { value: 'zh', label: 'Chinese' }
@@ -0,0 +1,54 @@
1
+ ---
2
+ name: unityclaw-idp-business-extraction
3
+ description: Extract fields from business documents (business license, business card)
4
+ version: 1.0.0
5
+ metadata:
6
+ openclaw:
7
+ requires:
8
+ env:
9
+ - UNITYCLAW_API_KEY
10
+ bins:
11
+ - node
12
+ - npm
13
+ primaryEnv: UNITYCLAW_API_KEY
14
+ emoji: "🏢"
15
+ homepage: https://unityclaw.com
16
+ install:
17
+ - kind: node
18
+ package: "@unityclaw/sdk"
19
+ bins: []
20
+ ---
21
+
22
+ # UnityClaw IDP - Business Extraction
23
+
24
+ Use this skill for business document extraction:
25
+ - `business_license`
26
+ - `business_card`
27
+
28
+ ## SDK APIs
29
+
30
+ ```typescript
31
+ await client.idp.businessLicense({ attachments: [{ path: './files/business-license.jpg' }] });
32
+ await client.idp.businessCard({ attachments: [{ path: './files/business-card.jpg' }] });
33
+ ```
34
+
35
+ Or generic API:
36
+
37
+ ```typescript
38
+ await client.idp.extract('business_license', {
39
+ attachments: [{ path: './files/business-license.jpg' }]
40
+ });
41
+ ```
42
+
43
+ ## Input
44
+
45
+ ```typescript
46
+ {
47
+ attachments: AttachmentInput[]
48
+ }
49
+ ```
50
+
51
+ ## Notes
52
+
53
+ - This skill groups enterprise scenarios to avoid over-generic routing.
54
+ - Output fields vary between license and card extraction.
@@ -0,0 +1,54 @@
1
+ ---
2
+ name: unityclaw-idp-contract-extraction
3
+ description: Extract structured fields from contract files
4
+ version: 1.0.0
5
+ metadata:
6
+ openclaw:
7
+ requires:
8
+ env:
9
+ - UNITYCLAW_API_KEY
10
+ bins:
11
+ - node
12
+ - npm
13
+ primaryEnv: UNITYCLAW_API_KEY
14
+ emoji: "📑"
15
+ homepage: https://unityclaw.com
16
+ install:
17
+ - kind: node
18
+ package: "@unityclaw/sdk"
19
+ bins: []
20
+ ---
21
+
22
+ # UnityClaw IDP - Contract Extraction
23
+
24
+ Use this skill for contract parsing:
25
+ - `contract`
26
+
27
+ ## SDK APIs
28
+
29
+ ```typescript
30
+ await client.idp.contract({
31
+ attachments: [{ path: './files/contract.pdf' }]
32
+ });
33
+ ```
34
+
35
+ Or generic API:
36
+
37
+ ```typescript
38
+ await client.idp.extract('contract', {
39
+ attachments: [{ path: './files/contract.pdf' }]
40
+ });
41
+ ```
42
+
43
+ ## Input
44
+
45
+ ```typescript
46
+ {
47
+ attachments: AttachmentInput[]
48
+ }
49
+ ```
50
+
51
+ ## Notes
52
+
53
+ - Preferred for long contract OCR + key field extraction scenarios.
54
+ - Read extracted data from `result.response.data`.
@@ -0,0 +1,56 @@
1
+ ---
2
+ name: unityclaw-idp-invoice-extraction
3
+ description: Extract fields from invoice and ticket documents (VAT, train, taxi)
4
+ version: 1.0.0
5
+ metadata:
6
+ openclaw:
7
+ requires:
8
+ env:
9
+ - UNITYCLAW_API_KEY
10
+ bins:
11
+ - node
12
+ - npm
13
+ primaryEnv: UNITYCLAW_API_KEY
14
+ emoji: "🧾"
15
+ homepage: https://unityclaw.com
16
+ install:
17
+ - kind: node
18
+ package: "@unityclaw/sdk"
19
+ bins: []
20
+ ---
21
+
22
+ # UnityClaw IDP - Invoice Extraction
23
+
24
+ Use this skill for invoice/ticket extraction:
25
+ - `vat_invoice`
26
+ - `train_invoice`
27
+ - `taxi_invoice`
28
+
29
+ ## SDK APIs
30
+
31
+ ```typescript
32
+ await client.idp.vatInvoice({ attachments: [{ path: './files/vat-invoice.pdf' }] });
33
+ await client.idp.trainInvoice({ attachments: [{ path: './files/train-ticket.jpg' }] });
34
+ await client.idp.taxiInvoice({ attachments: [{ path: './files/taxi-invoice.jpg' }] });
35
+ ```
36
+
37
+ Or generic API:
38
+
39
+ ```typescript
40
+ await client.idp.extract('vat_invoice', {
41
+ attachments: [{ path: './files/vat-invoice.pdf' }]
42
+ });
43
+ ```
44
+
45
+ ## Input
46
+
47
+ ```typescript
48
+ {
49
+ attachments: AttachmentInput[]
50
+ }
51
+ ```
52
+
53
+ ## Notes
54
+
55
+ - Files can be image/PDF according to each underlying IDP type.
56
+ - Output schema differs by type; parse from `result.response.data`.
@@ -0,0 +1,60 @@
1
+ ---
2
+ name: unityclaw-idp-personal-documents
3
+ description: Extract structured fields from personal identity documents (ID card, vehicle license, bank card)
4
+ version: 1.0.0
5
+ metadata:
6
+ openclaw:
7
+ requires:
8
+ env:
9
+ - UNITYCLAW_API_KEY
10
+ bins:
11
+ - node
12
+ - npm
13
+ primaryEnv: UNITYCLAW_API_KEY
14
+ emoji: "🪪"
15
+ homepage: https://unityclaw.com
16
+ install:
17
+ - kind: node
18
+ package: "@unityclaw/sdk"
19
+ bins: []
20
+ ---
21
+
22
+ # UnityClaw IDP - Personal Documents
23
+
24
+ Use this skill for personal document extraction:
25
+ - `id_card`
26
+ - `vehicle_license`
27
+ - `bank_card`
28
+
29
+ ## SDK APIs
30
+
31
+ ```typescript
32
+ await client.idp.idCard({ attachments: [{ path: './files/id-card.jpg' }] });
33
+ await client.idp.vehicleLicense({ attachments: [{ path: './files/vehicle-license.jpg' }] });
34
+ await client.idp.bankCard({ attachments: [{ path: './files/bank-card.jpg' }] });
35
+ ```
36
+
37
+ Or generic API:
38
+
39
+ ```typescript
40
+ await client.idp.extract('id_card', {
41
+ attachments: [{ path: './files/id-card.jpg' }]
42
+ });
43
+ ```
44
+
45
+ ## Input
46
+
47
+ ```typescript
48
+ {
49
+ attachments: AttachmentInput[]
50
+ }
51
+ ```
52
+
53
+ `AttachmentInput` supports:
54
+ - `tmp_url`
55
+ - local path (`path` / `localPath` / `filePath`), SDK auto-uploads to `/api/upload`
56
+
57
+ ## Notes
58
+
59
+ - This category is split from invoice/business/contract to improve skill routing success.
60
+ - Output fields vary by type; read from `result.response.data`.
@@ -22,6 +22,7 @@ metadata:
22
22
  # UnityClaw Image Generation
23
23
 
24
24
  Generate high-quality images using Gemini or JiMeng (Doubao) AI models.
25
+ This skill keeps JiMeng as one unified entry (no separate v3 skill).
25
26
 
26
27
  ## Installation
27
28
 
@@ -89,6 +90,12 @@ if (result.success && result.response?.data) {
89
90
  }
90
91
  ```
91
92
 
93
+ You can pass local files directly and SDK will auto-upload them:
94
+
95
+ ```typescript
96
+ attachment: [{ path: './files/reference.jpg' }]
97
+ ```
98
+
92
99
  ## Available APIs
93
100
 
94
101
  ### Gemini Image Generation
@@ -117,30 +124,56 @@ const result = await client.image.geminiV2({
117
124
 
118
125
  ### JiMeng Image Generation
119
126
 
127
+ > **IMPORTANT:** JiMeng uses different parameters than Gemini. Pay attention to the `size` and `model_selector` values.
128
+
120
129
  ```typescript
121
- // Basic usage
130
+ // Basic usage (defaults to Seedream 5.0 Lite model)
122
131
  const result = await client.image.jimeng({
123
132
  prompt: '一只可爱的猫咪在花园里玩耍',
124
- size: { value: '1024x1024', label: '1:1' }
133
+ size: { value: '2048x2048', label: '2K 1:1' }
125
134
  });
126
135
 
127
- // With all options
136
+ // With Seedream 5.0 Lite (supports web_search, 2K and 3K resolutions)
128
137
  const result = await client.image.jimeng({
129
138
  prompt: 'A serene Japanese garden in autumn',
130
139
  attachment: [{ tmp_url: 'https://...', name: 'style.jpg' }],
131
- size: { value: '1024x1024', label: '1:1' },
132
- model_selector: { value: 'general', label: 'General' },
133
- web_search: { value: true, label: 'Enable' },
140
+ size: { value: '2048x2048', label: '2K 1:1' },
141
+ model_selector: { value: 'doubao-seedream-5-0-260128', label: 'Seedream 5.0 Lite' },
142
+ web_search: { value: 'true', label: 'Enable' },
134
143
  image_count: { value: 4, label: '4 images' }
135
144
  });
136
145
 
137
- // JiMeng V3
138
- const result = await client.image.jimengV3({
146
+ // With Seedream 4.5 (supports 4K resolution, no web_search)
147
+ const result = await client.image.jimeng({
139
148
  prompt: 'A mystical forest with glowing mushrooms',
140
- size: { value: '1024x1024', label: '1:1' }
149
+ size: { value: '4096x4096', label: '4K 1:1' },
150
+ model_selector: { value: 'doubao-seedream-4-5-251128', label: 'Seedream 4.5' }
141
151
  });
152
+
142
153
  ```
143
154
 
155
+ #### JiMeng Size Options
156
+
157
+ | Resolution | 5.0 Lite | 4.5 | Size Values |
158
+ |------------|----------|-----|-------------|
159
+ | 2K | ✅ | ✅ | `2048x2048`, `1728x2304`, `2304x1728`, `2848x1600`, `1600x2848`, `2496x1664`, `1664x2496`, `3136x1344` |
160
+ | 3K | ✅ | ❌ | `3072x3072`, `2592x3456`, `3456x2592`, `4096x2304`, `2304x4096`, `3744x2496`, `2496x3744`, `4704x2016` |
161
+ | 4K | ❌ | ✅ | `4096x4096`, `3520x4704`, `4704x3520`, `5504x3040`, `3040x5504`, `4992x3328`, `3328x4992`, `6240x2656` |
162
+
163
+ > **Note:** `web_search` only works with Seedream 5.0 Lite model.
164
+
165
+ ## Troubleshooting (`/api/jimeng/image`)
166
+
167
+ If you see backend errors like `{"code":1254500}`, check these first:
168
+
169
+ - Do not use `jimeng/image/v3` size values (for example `1152x896`) on `/api/jimeng/image`.
170
+ - For `/api/jimeng/image`, use 2K/3K/4K size values such as:
171
+ `2048x2048`, `3072x3072`, `4096x4096`.
172
+ - Model and size must match:
173
+ - `doubao-seedream-5-0-260128` does **not** support 4K.
174
+ - `doubao-seedream-4-5-251128` does **not** support 3K.
175
+ - `web_search=true` only works with `doubao-seedream-5-0-260128`.
176
+
144
177
  ## Parameter Types
145
178
 
146
179
  ### GeminiImageParams
@@ -158,11 +191,12 @@ const result = await client.image.jimengV3({
158
191
  | Parameter | Type | Required | Description |
159
192
  |-----------|------|----------|-------------|
160
193
  | `prompt` | `string \| TextFieldItem[]` | Yes | Text description (supports Chinese) |
161
- | `attachment` | `AttachmentFieldItem[]` | No | Reference images |
162
- | `size` | `LabelFieldItem` | Yes | Size: `'1024x1024'` (1:1), `'896x1152'` (9:16), `'1152x896'` (16:9) |
163
- | `model_selector` | `LabelFieldItem` | No | Model type |
164
- | `web_search` | `LabelFieldItem` | No | Enable web search for references |
165
- | `image_count` | `LabelFieldItem \| number` | No | Number of images to generate |
194
+ | `attachment` | `AttachmentFieldItem[]` | No | Reference images for style transfer |
195
+ | `size` | `LabelFieldItem` | Yes | Size: `'2048x2048'` (2K), `'3072x3072'` (3K), `'4096x4096'` (4K) and more |
196
+ | `model_selector` | `LabelFieldItem` | No | Model: `'doubao-seedream-5-0-260128'` (5.0 Lite) or `'doubao-seedream-4-5-251128'` (4.5) |
197
+ | `web_search` | `LabelFieldItem` | No | Enable web search (5.0 Lite only): `'true'` or `'false'` |
198
+ | `image_count` | `LabelFieldItem \| number` | No | Number of images to generate (0-5) |
199
+ | `model` | `string` | No | Direct model override |
166
200
 
167
201
  ## Examples
168
202
 
@@ -267,4 +301,4 @@ console.log('Task Folder:', result.taskFolder); // e.g., "~/Documents/tasks/2026
267
301
  ## Related Skills
268
302
 
269
303
  - [unityclaw-image-compress](../unityclaw-image-compress/SKILL.md) - Compress generated images
270
- - [unityclaw-video-generation-sora](../unityclaw-video-generation-sora/SKILL.md) - Generate videos with Sora
304
+ - [unityclaw-video-generation-kling](../unityclaw-video-generation-kling/SKILL.md) - Generate videos
@@ -96,18 +96,17 @@ await client.media.analyze({
96
96
 
97
97
  ### analyzeVideo()
98
98
 
99
- Analyze a video file directly.
99
+ Analyze a video file directly (SDK helper on top of `/api/media_analysis`).
100
100
 
101
101
  ```typescript
102
102
  await client.media.analyzeVideo({
103
103
  file: { tmp_url: string; type?: string; name?: string; size?: number };
104
- prompt?: string;
105
104
  }): Promise<APIResponse<MediaAnalysisResult>>
106
105
  ```
107
106
 
108
107
  ### analyzeSocialVideo()
109
108
 
110
- Analyze social media videos (TikTok, YouTube, etc.).
109
+ Analyze social media videos by URL (SDK helper on top of `/api/media_analysis`).
111
110
 
112
111
  ```typescript
113
112
  await client.media.analyzeSocialVideo({
@@ -172,8 +171,8 @@ const result = await client.media.analyzeSocialVideo({
172
171
  url: 'https://www.tiktok.com/@user/video/123456789'
173
172
  });
174
173
 
175
- if (result.code === 0 && result.data) {
176
- console.log('Content:', result.data.summary);
174
+ if (result.success && result.response?.data) {
175
+ console.log('Content:', result.response.data.summary);
177
176
  }
178
177
  ```
179
178
 
@@ -188,8 +187,8 @@ const result = await client.media.analyzeVideo({
188
187
  }
189
188
  });
190
189
 
191
- if (result.code === 0 && result.data) {
192
- console.log('Meeting summary:', result.data.summary);
190
+ if (result.success && result.response?.data) {
191
+ console.log('Meeting summary:', result.response.data.summary);
193
192
  }
194
193
  ```
195
194
 
@@ -204,8 +203,8 @@ const result = await client.media.analyzeVideo({
204
203
  prompt: 'Extract all code snippets and programming concepts mentioned in this tutorial'
205
204
  });
206
205
 
207
- if (result.code === 0 && result.data) {
208
- console.log('Analysis:', result.data.summary);
206
+ if (result.success && result.response?.data) {
207
+ console.log('Analysis:', result.response.data.summary);
209
208
  }
210
209
  ```
211
210
 
@@ -242,9 +241,9 @@ const result = await client.media.analyze({
242
241
  ]
243
242
  });
244
243
 
245
- if (result.code === 0 && result.data) {
246
- console.log('Podcast summary:', result.data.summary);
247
- console.log('Transcript:', result.data.subtitle);
244
+ if (result.success && result.response?.data) {
245
+ console.log('Podcast summary:', result.response.data.summary);
246
+ console.log('Transcript:', result.response.data.subtitle);
248
247
  }
249
248
  ```
250
249
 
@@ -259,8 +258,8 @@ const result = await client.media.analyzeVideo({
259
258
  prompt: 'Extract action items, decisions made, and key discussion points'
260
259
  });
261
260
 
262
- if (result.code === 0 && result.data) {
263
- console.log('Meeting Notes:', result.data.summary);
261
+ if (result.success && result.response?.data) {
262
+ console.log('Meeting Notes:', result.response.data.summary);
264
263
  }
265
264
  ```
266
265
 
@@ -271,9 +270,9 @@ const result = await client.media.analyze({
271
270
  url: [{ link: 'https://youtube.com/watch?v=lecture-id' }]
272
271
  });
273
272
 
274
- if (result.code === 0 && result.data) {
275
- console.log('Lecture Summary:', result.data.summary);
276
- console.log('Full Transcript:', result.data.subtitle);
273
+ if (result.success && result.response?.data) {
274
+ console.log('Lecture Summary:', result.response.data.summary);
275
+ console.log('Full Transcript:', result.response.data.subtitle);
277
276
  }
278
277
  ```
279
278
 
@@ -347,4 +346,4 @@ console.log('Task Folder:', result.taskFolder);
347
346
  ## Related Skills
348
347
 
349
348
  - [unityclaw-document-translation](../unityclaw-document-translation/SKILL.md) - Translate transcripts
350
- - [unityclaw-video-generation-sora](../unityclaw-video-generation-sora/SKILL.md) - Generate videos
349
+ - [unityclaw-video-generation-kling](../unityclaw-video-generation-kling/SKILL.md) - Generate videos
@@ -0,0 +1,40 @@
1
+ ---
2
+ name: unityclaw-media-download-xhs
3
+ description: Download Xiaohongshu media and return cover/video URLs
4
+ version: 1.0.1
5
+ metadata:
6
+ openclaw:
7
+ requires:
8
+ env:
9
+ - UNITYCLAW_API_KEY
10
+ bins:
11
+ - node
12
+ - npm
13
+ primaryEnv: UNITYCLAW_API_KEY
14
+ emoji: "📥"
15
+ homepage: https://unityclaw.com
16
+ install:
17
+ - kind: node
18
+ package: "@unityclaw/sdk"
19
+ bins: []
20
+ ---
21
+
22
+ # UnityClaw Xiaohongshu Download
23
+
24
+ Download media metadata from Xiaohongshu links.
25
+
26
+ ```typescript
27
+ import { UnityClawClient } from '@unityclaw/sdk';
28
+
29
+ const client = new UnityClawClient();
30
+ const result = await client.media.downloadXiaohongshu({
31
+ url: [{ link: 'https://www.xiaohongshu.com/explore/xxxx' }],
32
+ });
33
+
34
+ if (result.success && result.response?.data) {
35
+ console.log(result.response.data.cover_url, result.response.data.video_urls);
36
+ }
37
+ ```
38
+
39
+ - API: `/api/xiaohongshu/download`
40
+ - field-feishu: `xiaohongshu/download`
@@ -0,0 +1,40 @@
1
+ ---
2
+ name: unityclaw-media-stats
3
+ description: Extract social media post metrics (play, like, comment, share, etc.) from links
4
+ version: 1.0.1
5
+ metadata:
6
+ openclaw:
7
+ requires:
8
+ env:
9
+ - UNITYCLAW_API_KEY
10
+ bins:
11
+ - node
12
+ - npm
13
+ primaryEnv: UNITYCLAW_API_KEY
14
+ emoji: "📈"
15
+ homepage: https://unityclaw.com
16
+ install:
17
+ - kind: node
18
+ package: "@unityclaw/sdk"
19
+ bins: []
20
+ ---
21
+
22
+ # UnityClaw Media Stats
23
+
24
+ Get media metrics from social video links.
25
+
26
+ ```typescript
27
+ import { UnityClawClient } from '@unityclaw/sdk';
28
+
29
+ const client = new UnityClawClient();
30
+ const result = await client.media.stats({
31
+ link: [{ link: 'https://www.xiaohongshu.com/explore/xxxx' }],
32
+ });
33
+
34
+ if (result.success && result.response?.data) {
35
+ console.log(result.response.data.play_count, result.response.data.like_count);
36
+ }
37
+ ```
38
+
39
+ - API: `/api/media_stats`
40
+ - field-feishu: `media_stats`
@@ -0,0 +1,40 @@
1
+ ---
2
+ name: unityclaw-media-user-info
3
+ description: Extract social media user profile metrics from homepage links
4
+ version: 1.0.1
5
+ metadata:
6
+ openclaw:
7
+ requires:
8
+ env:
9
+ - UNITYCLAW_API_KEY
10
+ bins:
11
+ - node
12
+ - npm
13
+ primaryEnv: UNITYCLAW_API_KEY
14
+ emoji: "👤"
15
+ homepage: https://unityclaw.com
16
+ install:
17
+ - kind: node
18
+ package: "@unityclaw/sdk"
19
+ bins: []
20
+ ---
21
+
22
+ # UnityClaw Media User Info
23
+
24
+ Get user profile information from social media homepage links.
25
+
26
+ ```typescript
27
+ import { UnityClawClient } from '@unityclaw/sdk';
28
+
29
+ const client = new UnityClawClient();
30
+ const result = await client.media.userInfo({
31
+ link: [{ link: 'https://www.xiaohongshu.com/user/profile/xxxx' }],
32
+ });
33
+
34
+ if (result.success && result.response?.data) {
35
+ console.log(result.response.data.user_id, result.response.data.follower_count);
36
+ }
37
+ ```
38
+
39
+ - API: `/api/media_user_info`
40
+ - field-feishu: `media_user_info`
@@ -0,0 +1,41 @@
1
+ ---
2
+ name: unityclaw-video-frame-extract
3
+ description: Extract first/last/specified-time frame from video attachments
4
+ version: 1.0.1
5
+ metadata:
6
+ openclaw:
7
+ requires:
8
+ env:
9
+ - UNITYCLAW_API_KEY
10
+ bins:
11
+ - node
12
+ - npm
13
+ primaryEnv: UNITYCLAW_API_KEY
14
+ emoji: "🖼️"
15
+ homepage: https://unityclaw.com
16
+ install:
17
+ - kind: node
18
+ package: "@unityclaw/sdk"
19
+ bins: []
20
+ ---
21
+
22
+ # UnityClaw Video Frame Extract
23
+
24
+ Extract one frame from video at first frame, last frame, or specific `mm:ss`.
25
+
26
+ ```typescript
27
+ import { UnityClawClient } from '@unityclaw/sdk';
28
+
29
+ const client = new UnityClawClient();
30
+ const result = await client.media.extractFrame({
31
+ attachment: [{ path: './files/demo.mp4' }],
32
+ frame_option: 'first',
33
+ });
34
+
35
+ if (result.success && result.response?.data?.[0]) {
36
+ console.log(result.response.data[0].content);
37
+ }
38
+ ```
39
+
40
+ - API: `/api/video/frame`
41
+ - field-feishu: `video/frame`
@@ -0,0 +1,70 @@
1
+ ---
2
+ name: unityclaw-video-generation-jimeng-doubao
3
+ description: Generate videos with JiMeng or Doubao models (text-to-video and image-to-video)
4
+ version: 1.0.1
5
+ metadata:
6
+ openclaw:
7
+ requires:
8
+ env:
9
+ - UNITYCLAW_API_KEY
10
+ bins:
11
+ - node
12
+ - npm
13
+ primaryEnv: UNITYCLAW_API_KEY
14
+ emoji: "🎬"
15
+ homepage: https://unityclaw.com
16
+ install:
17
+ - kind: node
18
+ package: "@unityclaw/sdk"
19
+ bins: []
20
+ ---
21
+
22
+ # UnityClaw Video Generation - JiMeng & Doubao
23
+
24
+ Use this skill when the task matches `client.video.jimeng(...)` or `client.video.doubao(...)`.
25
+
26
+ ## When To Use
27
+
28
+ - JiMeng: explicit `action` + `aspect_ratio` flow
29
+ - Doubao: `resolution` + `ratio` flow, optional image input
30
+
31
+ ## Quick Start
32
+
33
+ ```typescript
34
+ import { UnityClawClient } from '@unityclaw/sdk';
35
+
36
+ const client = new UnityClawClient();
37
+
38
+ const result = await client.video.doubao({
39
+ prompt: 'A cinematic drone shot of mountains at sunrise',
40
+ resolution: '1080p',
41
+ ratio: '16:9',
42
+ duration: 5,
43
+ });
44
+
45
+ if (result.success && result.response?.data) {
46
+ console.log(result.response.data[0].content);
47
+ }
48
+ ```
49
+
50
+ ## API Map
51
+
52
+ - `client.video.jimeng(...)`
53
+ : fields: `action`, `prompt`, `attachment`, `aspect_ratio`
54
+ - `client.video.doubao(...)`
55
+ : fields: `prompt`, `attachment`, `resolution`, `ratio`, `duration`
56
+
57
+ ## Local File Input
58
+
59
+ ```typescript
60
+ attachment: [{ path: './files/first-frame.jpg' }]
61
+ ```
62
+
63
+ SDK will auto-upload local files and fill `tmp_url`.
64
+
65
+ ## Notes For Agent
66
+
67
+ - Prefer `doubao` for generic prompts if user did not specify model family.
68
+ - For JiMeng, ensure `action` and `aspect_ratio` are provided.
69
+ - For Doubao, prefer numeric duration values (`5`, `10`) instead of string duration.
70
+ - Always check `result.success` first, then read `result.response.data`.
@@ -264,6 +264,5 @@ console.log('Downloaded Videos:', result.attachments);
264
264
 
265
265
  ## Related Skills
266
266
 
267
- - [unityclaw-video-generation-sora](../unityclaw-video-generation-sora/SKILL.md) - OpenAI Sora
268
- - [unityclaw-video-generation-veo](../unityclaw-video-generation-veo/SKILL.md) - Google Veo
269
- - [unityclaw-video-generation-other](../unityclaw-video-generation-other/SKILL.md) - Other video models
267
+ - [unityclaw-video-generation-jimeng-doubao](../unityclaw-video-generation-jimeng-doubao/SKILL.md) - JiMeng and Doubao video models
268
+ - [unityclaw-video-generation-wan-minimax](../unityclaw-video-generation-wan-minimax/SKILL.md) - Wan and MiniMax video models
@@ -0,0 +1,70 @@
1
+ ---
2
+ name: unityclaw-video-generation-wan-minimax
3
+ description: Generate videos with Wan and MiniMax models for cinematic or controllable workflows
4
+ version: 1.0.1
5
+ metadata:
6
+ openclaw:
7
+ requires:
8
+ env:
9
+ - UNITYCLAW_API_KEY
10
+ bins:
11
+ - node
12
+ - npm
13
+ primaryEnv: UNITYCLAW_API_KEY
14
+ emoji: "🎞️"
15
+ homepage: https://unityclaw.com
16
+ install:
17
+ - kind: node
18
+ package: "@unityclaw/sdk"
19
+ bins: []
20
+ ---
21
+
22
+ # UnityClaw Video Generation - Wan & MiniMax
23
+
24
+ Use this skill when the task matches `client.video.wan(...)` or `client.video.minimax(...)`.
25
+
26
+ ## When To Use
27
+
28
+ - Wan: stronger control on model/shot style (`model`, `shot_type`, `size`, `duration`)
29
+ - MiniMax: Hailuo model family workflows (`model`, `size`, `duration`)
30
+
31
+ ## Quick Start
32
+
33
+ ```typescript
34
+ import { UnityClawClient } from '@unityclaw/sdk';
35
+
36
+ const client = new UnityClawClient();
37
+
38
+ const result = await client.video.wan({
39
+ prompt: 'A samurai crossing a snowy bridge in cinematic style',
40
+ model: 'wan2.6-t2v',
41
+ size: '1280*720',
42
+ duration: '5',
43
+ shot_type: 'single',
44
+ });
45
+
46
+ if (result.success && result.response?.data) {
47
+ console.log(result.response.data[0].content);
48
+ }
49
+ ```
50
+
51
+ ## API Map
52
+
53
+ - `client.video.wan(...)`
54
+ : fields: `prompt`, `attachment`, `model`, `size`, `duration`, `shot_type`
55
+ - `client.video.minimax(...)`
56
+ : fields: `prompt`, `attachment`, `model`, `size`, `duration`
57
+
58
+ ## Local File Input
59
+
60
+ ```typescript
61
+ attachment: [{ path: './files/reference.jpg' }]
62
+ ```
63
+
64
+ SDK will auto-upload local files and fill `tmp_url`.
65
+
66
+ ## Notes For Agent
67
+
68
+ - If model family is not specified, default to Wan for cinematic control.
69
+ - Keep prompt concise and explicit; avoid overlong instructions.
70
+ - Always check `result.success` first, then read `result.response.data`.
@@ -1,324 +0,0 @@
1
- ---
2
- name: unityclaw-video-generation-other
3
- description: Generate videos using Doubao, Wan (Alibaba), MiniMax, and JiMeng models
4
- version: 1.0.1
5
- metadata:
6
- openclaw:
7
- requires:
8
- env:
9
- - UNITYCLAW_API_KEY
10
- bins:
11
- - node
12
- - npm
13
- primaryEnv: UNITYCLAW_API_KEY
14
- emoji: "🎞️"
15
- homepage: https://unityclaw.com
16
- install:
17
- - kind: node
18
- package: "@unityclaw/sdk"
19
- bins: []
20
- ---
21
-
22
- # UnityClaw Video Generation - Other Models
23
-
24
- Generate videos using multiple AI models: Doubao, Wan (Alibaba), MiniMax, and JiMeng.
25
-
26
- ## Installation
27
-
28
- ```bash
29
- npm install @unityclaw/sdk
30
- ```
31
-
32
- ## Configuration
33
-
34
- Set your API key using one of these methods:
35
-
36
- ```bash
37
- # Method 1: Use SDK CLI (recommended - persists across sessions)
38
- npx @unityclaw/sdk config set apiKey your-api-key
39
-
40
- # Method 2: Environment variable
41
- export UNITYCLAW_API_KEY=your-api-key
42
- ```
43
-
44
- ## Response Structure
45
-
46
- > **IMPORTANT:** The result has a nested structure. Use `result.success` to check overall success, and access data via `result.response.data`.
47
-
48
- ```typescript
49
- interface UnityClawResult {
50
- success: boolean; // ✅ Use this to check if SDK call succeeded
51
- taskId: string; // Task identifier
52
- taskFolder: string; // Path to task folder with logs
53
- duration: number; // Request duration in ms
54
- response: { // API response object
55
- code: number; // 0 = success
56
- data: Array<{ // ✅ Result data here
57
- name: string;
58
- contentType: string;
59
- content: string; // URL to generated video
60
- }> | null;
61
- };
62
- logs: Array<{ timestamp; level; message }>;
63
- attachments: any[];
64
- }
65
- ```
66
-
67
- ## Quick Start
68
-
69
- ```typescript
70
- import { UnityClawClient } from '@unityclaw/sdk';
71
-
72
- const client = new UnityClawClient();
73
-
74
- // Using Doubao
75
- const result = await client.video.doubao({
76
- prompt: 'A cinematic drone shot of mountains',
77
- resolution: { value: '1080p', label: '1080p' },
78
- ratio: { value: '16:9', label: '16:9' }
79
- });
80
-
81
- // ✅ Correct: Check result.success, access data via result.response.data
82
- if (result.success && result.response?.data) {
83
- console.log('Generated video:', result.response.data);
84
- }
85
- ```
86
-
87
- ## Available APIs
88
-
89
- ### 1. Doubao Video
90
-
91
- ```typescript
92
- const result = await client.video.doubao({
93
- prompt: 'A cinematic drone shot of mountains at golden hour',
94
- resolution: { value: '1080p', label: '1080p' },
95
- ratio: { value: '16:9', label: '16:9' },
96
- duration: { value: '5', label: '5s' }
97
- });
98
- ```
99
-
100
- **Parameters:**
101
-
102
- | Parameter | Type | Required | Description |
103
- |-----------|------|----------|-------------|
104
- | `prompt` | `string \| TextFieldItem[]` | No | Text description |
105
- | `attachment` | `AttachmentFieldItem[]` | No | Reference image |
106
- | `action` | `LabelFieldItem \| string` | No | Action type |
107
- | `resolution` | `LabelFieldItem \| string` | Yes | Video resolution |
108
- | `ratio` | `LabelFieldItem \| string` | Yes | Aspect ratio |
109
- | `duration` | `LabelFieldItem \| string` | No | Video duration |
110
-
111
- ### 2. Wan Video (Alibaba)
112
-
113
- ```typescript
114
- const result = await client.video.wan({
115
- prompt: 'A futuristic city at night with neon lights',
116
- size: { value: '1280*720', label: '720p' },
117
- duration: { value: '5', label: '5s' },
118
- model: { value: 'wan2.6-t2v', label: 'Wan 2.6' }
119
- });
120
- ```
121
-
122
- **Parameters:**
123
-
124
- | Parameter | Type | Required | Description |
125
- |-----------|------|----------|-------------|
126
- | `prompt` | `string \| TextFieldItem[]` | No | Text description |
127
- | `attachment` | `AttachmentFieldItem[]` | No | Reference image |
128
- | `size` | `LabelFieldItem \| string` | No | Video size (e.g., '1280*720') |
129
- | `duration` | `LabelFieldItem \| string` | No | Video duration |
130
- | `model` | `LabelFieldItem \| string` | No | Model version |
131
- | `shot_type` | `LabelFieldItem \| string` | No | Camera shot type |
132
-
133
- ### 3. MiniMax Video
134
-
135
- ```typescript
136
- const result = await client.video.minimax({
137
- prompt: 'A person walking through a serene forest',
138
- size: { value: '1360*768', label: '768p' },
139
- model: { value: 'MiniMax-Hailuo-2.3', label: 'Hailuo 2.3' }
140
- });
141
- ```
142
-
143
- **Parameters:**
144
-
145
- | Parameter | Type | Required | Description |
146
- |-----------|------|----------|-------------|
147
- | `prompt` | `string \| TextFieldItem[]` | No | Text description |
148
- | `attachment` | `AttachmentFieldItem[]` | No | Reference image |
149
- | `size` | `LabelFieldItem \| string` | No | Video size |
150
- | `duration` | `LabelFieldItem \| string` | No | Video duration |
151
- | `model` | `LabelFieldItem \| string` | No | Model version |
152
-
153
- ### 4. JiMeng Video
154
-
155
- ```typescript
156
- const result = await client.video.jimeng({
157
- action: { value: 't2v', label: 'Text to Video' },
158
- prompt: 'A beautiful landscape with flowing river',
159
- aspect_ratio: { value: '16:9', label: '16:9' }
160
- });
161
- ```
162
-
163
- **Parameters:**
164
-
165
- | Parameter | Type | Required | Description |
166
- |-----------|------|----------|-------------|
167
- | `action` | `LabelFieldItem \| string` | Yes | Action type ('t2v' for text-to-video) |
168
- | `prompt` | `string \| TextFieldItem[]` | No | Text description |
169
- | `attachment` | `AttachmentFieldItem[]` | No | Reference image |
170
- | `aspect_ratio` | `LabelFieldItem \| string` | Yes | Aspect ratio |
171
-
172
- ## Examples
173
-
174
- ### Doubao - Text-to-Video
175
-
176
- ```typescript
177
- const client = new UnityClawClient();
178
-
179
- const result = await client.video.doubao({
180
- prompt: 'A luxury car driving along a coastal road at sunset',
181
- resolution: { value: '1080p', label: '1080p' },
182
- ratio: { value: '16:9', label: '16:9' },
183
- duration: { value: '5', label: '5s' }
184
- });
185
- ```
186
-
187
- ### Doubao - Image-to-Video
188
-
189
- ```typescript
190
- const result = await client.video.doubao({
191
- action: { value: 'i2v', label: 'Image to Video' },
192
- attachment: [
193
- { tmp_url: 'https://example.com/image.jpg', name: 'image.jpg' }
194
- ],
195
- prompt: 'Animate this image with gentle movement',
196
- resolution: { value: '1080p', label: '1080p' },
197
- ratio: { value: '16:9', label: '16:9' }
198
- });
199
- ```
200
-
201
- ### Wan - High Quality
202
-
203
- ```typescript
204
- const result = await client.video.wan({
205
- prompt: 'A samurai walking through cherry blossom petals falling',
206
- size: { value: '1920*1080', label: '1080p' },
207
- duration: { value: '5', label: '5s' },
208
- model: { value: 'wan2.6-t2v', label: 'Wan 2.6' },
209
- shot_type: { value: 'cinematic', label: 'Cinematic' }
210
- });
211
- ```
212
-
213
- ### MiniMax - Portrait Video
214
-
215
- ```typescript
216
- const result = await client.video.minimax({
217
- prompt: 'A dancer performing an elegant routine',
218
- size: { value: '768*1360', label: 'Portrait 768p' },
219
- model: { value: 'MiniMax-Hailuo-2.3', label: 'Hailuo 2.3' }
220
- });
221
- ```
222
-
223
- ### JiMeng - Chinese Prompt
224
-
225
- ```typescript
226
- const result = await client.video.jimeng({
227
- action: { value: 't2v', label: 'Text to Video' },
228
- prompt: '一只可爱的熊猫在竹林里吃竹子',
229
- aspect_ratio: { value: '16:9', label: '16:9' }
230
- });
231
- ```
232
-
233
- ### Compare Multiple Models
234
-
235
- ```typescript
236
- const prompt = 'A serene mountain lake at sunrise';
237
-
238
- const results = await Promise.all([
239
- client.video.doubao({
240
- prompt,
241
- resolution: '1080p',
242
- ratio: '16:9'
243
- }),
244
- client.video.wan({
245
- prompt,
246
- size: '1280*720'
247
- }),
248
- client.video.minimax({
249
- prompt,
250
- size: '1360*768'
251
- })
252
- ]);
253
-
254
- results.forEach((result, i) => {
255
- const model = ['Doubao', 'Wan', 'MiniMax'][i];
256
- if (result.success && result.response?.data) {
257
- console.log(`${model}: ${result.response.data?.[0]?.content}`);
258
- }
259
- });
260
- ```
261
-
262
- ## Model Comparison
263
-
264
- | Model | Strengths | Best For |
265
- |-------|-----------|----------|
266
- | Doubao | High quality, Chinese prompts | General purpose, Chinese content |
267
- | Wan | Multiple shot types | Cinematic videos |
268
- | MiniMax | Fast generation | Quick iterations |
269
- | JiMeng | Chinese language | Chinese content |
270
-
271
- ## Response Format
272
-
273
- ```typescript
274
- interface AttachmentResult {
275
- name: string;
276
- contentType: 'attachment/url';
277
- content: string; // URL to generated video
278
- }
279
- ```
280
-
281
- ## Error Handling
282
-
283
- ```typescript
284
- const result = await client.video.doubao({
285
- prompt: 'test',
286
- resolution: '1080p',
287
- ratio: '16:9'
288
- });
289
-
290
- if (!result.success) {
291
- console.error('Request failed');
292
- console.log('Check logs:', result.logs);
293
- return;
294
- }
295
-
296
- if (result.response?.code !== 0) {
297
- console.error('API error:', result.response);
298
- return;
299
- }
300
-
301
- // Success
302
- console.log('Success:', result.response.data);
303
- ```
304
-
305
- ## Task Folders
306
-
307
- Each execution creates a task folder:
308
-
309
- ```typescript
310
- const result = await client.video.wan({
311
- prompt: 'test',
312
- size: '1280*720'
313
- });
314
-
315
- console.log('Task ID:', result.taskId);
316
- console.log('Task Folder:', result.taskFolder);
317
- console.log('Videos:', result.attachments);
318
- ```
319
-
320
- ## Related Skills
321
-
322
- - [unityclaw-video-generation-sora](../unityclaw-video-generation-sora/SKILL.md) - OpenAI Sora
323
- - [unityclaw-video-generation-veo](../unityclaw-video-generation-veo/SKILL.md) - Google Veo
324
- - [unityclaw-video-generation-kling](../unityclaw-video-generation-kling/SKILL.md) - Kling