yuanflow-cli 0.1.44 → 0.1.46
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 +38 -23
- package/package.json +1 -1
- package/skills/yuanflow-skill/HTML/346/212/245/345/221/212/347/224/237/346/210/220/SKILL.md +4 -0
- package/skills/yuanflow-skill/IP/350/277/220/350/220/245/SKILL.md +4 -0
- package/skills/yuanflow-skill/README.md +3 -0
- package/skills/yuanflow-skill//344/270/252/344/272/272/345/210/233/344/275/234/345/272/223/SKILL.md +2 -2
- package/skills/yuanflow-skill//345/205/254/344/274/227/345/217/267/347/224/237/346/210/220/344/270/216/345/217/221/345/270/203/SKILL.md +2 -2
- package/skills/yuanflow-skill//345/210/233/344/275/234/346/200/273/347/233/221/SKILL.md +4 -0
- package/skills/yuanflow-skill//345/243/260/351/237/263/345/205/213/351/232/206/SKILL.md +146 -0
- package/skills/yuanflow-skill//345/243/260/351/237/263/345/244/215/345/210/273/SKILL.md +103 -0
- package/skills/yuanflow-skill//345/260/217/347/272/242/344/271/246/350/277/220/350/220/245/SKILL.md +1 -1
- package/skills/yuanflow-skill//345/260/217/347/272/242/344/271/246/350/277/220/350/220/245/references/commands.md +1 -2
- package/skills/yuanflow-skill//345/270/220/345/217/267/345/256/232/344/275/215/SKILL.md +4 -0
- package/skills/yuanflow-skill//345/270/220/345/217/267/347/233/221/346/216/247/SKILL.md +1 -1
- package/skills/yuanflow-skill//346/226/207/346/241/210/345/210/233/344/275/234/SKILL.md +4 -0
- package/skills/yuanflow-skill//346/234/254/345/234/260/351/237/263/350/247/206/351/242/221/350/275/254/346/226/207/345/255/227/SKILL.md +15 -13
- package/skills/yuanflow-skill//347/224/237/345/233/276/346/212/200/350/203/275/SKILL.md +2 -2
- package/skills/yuanflow-skill//347/233/264/346/222/255/346/212/225/346/265/201/347/255/226/347/225/245/SKILL.md +4 -0
- package/skills/yuanflow-skill//347/233/264/346/222/255/350/257/235/346/234/257/347/224/237/346/210/220/SKILL.md +4 -0
- package/skills/yuanflow-skill//350/207/252/345/252/222/344/275/223/346/265/217/350/247/210/345/231/250/350/207/252/345/212/250/345/214/226/SKILL.md +4 -4
- package/skills/yuanflow-skill//350/247/206/350/247/211/347/220/206/350/247/243/SKILL.md +4 -4
- package/skills/yuanflow-skill//350/247/206/351/242/221/346/212/225/346/265/201/347/255/226/347/225/245/SKILL.md +1 -1
- package/skills/yuanflow-skill//350/247/206/351/242/221/346/213/206/350/247/243/SKILL.md +6 -6
- package/skills/yuanflow-skill//350/247/206/351/242/221/346/231/272/350/203/275/345/211/252/350/276/221/SKILL.md +22 -22
- package/skills/yuanflow-skill//351/200/211/351/242/230/347/255/226/345/210/222/SKILL.md +4 -0
- package/skills/yuanflow-skill//351/237/263/350/247/206/351/242/221/345/234/250/347/272/277/350/275/254/346/226/207/345/255/227/SKILL.md +2 -2
- package/src/agent-protocol.js +3 -3
- package/src/cli.js +24 -22
- package/src/voice-tools.js +471 -0
- package/src/video-tools.js +0 -969
|
@@ -16,6 +16,10 @@ emoji: 🎤
|
|
|
16
16
|
|
|
17
17
|
不要在回复、日志或文件中暴露 token。用户主流程统一称为 YuanFlow API 和 YuanFlow 文件中转,不要求用户配置第三方平台 Key。
|
|
18
18
|
|
|
19
|
+
## YuanFlow-main 内置环境
|
|
20
|
+
|
|
21
|
+
在 YuanFlow-main 内置环境中,只有需要调用知识库、个人创作库、HTML 报告或其它 YuanFlow 能力时,才使用 `yuanflow_cli_call`、`yuanflow_image_request`、`artifact_files_register` 等受控工具。token、受管包路径和输出目录由 YuanFlow-main 管理,不写成外部用户必备步骤。
|
|
22
|
+
|
|
19
23
|
本 Skill 用于生成直播话术和直播节奏脚本。执行时必须先查历史资产,再查自媒体知识库,最后结合用户本次直播目标输出可直接使用的话术。
|
|
20
24
|
|
|
21
25
|
## 固定流程
|
|
@@ -130,13 +130,13 @@ yuanflow-cli browser task-plan --platform douyin --task publish --account main -
|
|
|
130
130
|
默认本地根目录:
|
|
131
131
|
|
|
132
132
|
```text
|
|
133
|
-
|
|
133
|
+
由运行环境管理的 YuanFlow 浏览器自动化目录
|
|
134
134
|
```
|
|
135
135
|
|
|
136
136
|
单账号目录:
|
|
137
137
|
|
|
138
138
|
```text
|
|
139
|
-
|
|
139
|
+
<浏览器自动化目录>/accounts/<platform>/<account>
|
|
140
140
|
```
|
|
141
141
|
|
|
142
142
|
关键子目录:
|
|
@@ -235,13 +235,13 @@ downloads 浏览器下载文件
|
|
|
235
235
|
"--account",
|
|
236
236
|
"main",
|
|
237
237
|
"--file",
|
|
238
|
-
"
|
|
238
|
+
"<本地发布素材路径>",
|
|
239
239
|
"--title",
|
|
240
240
|
"标题",
|
|
241
241
|
"--caption",
|
|
242
242
|
"正文",
|
|
243
243
|
"--cover",
|
|
244
|
-
"
|
|
244
|
+
"<本地封面路径>",
|
|
245
245
|
"--format",
|
|
246
246
|
"agent-json"
|
|
247
247
|
]
|
|
@@ -50,11 +50,11 @@ emoji: 👁️
|
|
|
50
50
|
## 外部 CLI 示例
|
|
51
51
|
|
|
52
52
|
```powershell
|
|
53
|
-
yuanflow-cli ai qwen3-vl-plus --prompt "描述这张图的主体、文字和环境" --image-file "
|
|
53
|
+
yuanflow-cli ai qwen3-vl-plus --prompt "描述这张图的主体、文字和环境" --image-file "<本地图片路径>" --format agent-json
|
|
54
54
|
```
|
|
55
55
|
|
|
56
56
|
```powershell
|
|
57
|
-
yuanflow-cli ai qwen3-vl-plus --prompt "总结视频画面变化和关键细节" --video-file "
|
|
57
|
+
yuanflow-cli ai qwen3-vl-plus --prompt "总结视频画面变化和关键细节" --video-file "<本地视频路径>" --format agent-json
|
|
58
58
|
```
|
|
59
59
|
|
|
60
60
|
## YuanFlow-main 内置环境
|
|
@@ -109,7 +109,7 @@ yuanflow-cli ai qwen3-vl-plus --prompt "总结视频画面变化和关键细节"
|
|
|
109
109
|
"--prompt",
|
|
110
110
|
"请识别这张图片中的关键信息,并按主体、文字、细节、可能风险输出。",
|
|
111
111
|
"--image-file",
|
|
112
|
-
"
|
|
112
|
+
"<本地图片路径>",
|
|
113
113
|
"--format",
|
|
114
114
|
"agent-json"
|
|
115
115
|
],
|
|
@@ -127,7 +127,7 @@ yuanflow-cli ai qwen3-vl-plus --prompt "总结视频画面变化和关键细节"
|
|
|
127
127
|
"--prompt",
|
|
128
128
|
"请按时间顺序总结视频画面变化、人物动作、关键物品和屏幕文字。",
|
|
129
129
|
"--video-file",
|
|
130
|
-
"
|
|
130
|
+
"<本地视频路径>",
|
|
131
131
|
"--format",
|
|
132
132
|
"agent-json"
|
|
133
133
|
],
|
|
@@ -96,7 +96,7 @@ YuanFlow-main 内置环境调用见后文专属小节。
|
|
|
96
96
|
解析到可访问视频 URL 后,经用户授权保存到本地临时文件,再提交 qwen3-vl-plus。保存文件时使用清晰路径,例如:
|
|
97
97
|
|
|
98
98
|
```text
|
|
99
|
-
|
|
99
|
+
<视频拆解工作目录>/input.mp4
|
|
100
100
|
```
|
|
101
101
|
|
|
102
102
|
保存方式:
|
|
@@ -109,14 +109,14 @@ D:\素材\yuanflow-video-breakdown\input.mp4
|
|
|
109
109
|
外部 Agent 可用的保存示例:
|
|
110
110
|
|
|
111
111
|
```powershell
|
|
112
|
-
New-Item -ItemType Directory -Force "
|
|
113
|
-
Invoke-WebRequest -Uri "<解析得到的视频直链>" -OutFile "
|
|
112
|
+
New-Item -ItemType Directory -Force "<视频拆解工作目录>"
|
|
113
|
+
Invoke-WebRequest -Uri "<解析得到的视频直链>" -OutFile "<视频拆解工作目录>/input.mp4"
|
|
114
114
|
```
|
|
115
115
|
|
|
116
116
|
如果是 m3u8:
|
|
117
117
|
|
|
118
118
|
```powershell
|
|
119
|
-
ffmpeg -y -i "<解析得到的 m3u8 地址>" -c copy "
|
|
119
|
+
ffmpeg -y -i "<解析得到的 m3u8 地址>" -c copy "<视频拆解工作目录>/input.mp4"
|
|
120
120
|
```
|
|
121
121
|
|
|
122
122
|
如果平台解析只返回播放候选而没有稳定下载 URL,说明当前链接需要用户提供可下载文件,或先让用户使用其它授权方式保存视频。
|
|
@@ -128,7 +128,7 @@ ffmpeg -y -i "<解析得到的 m3u8 地址>" -c copy "D:\素材\yuanflow-video-b
|
|
|
128
128
|
外部 CLI 示例:
|
|
129
129
|
|
|
130
130
|
```powershell
|
|
131
|
-
yuanflow-cli ai qwen3-vl-plus --prompt "你是自媒体视频拆解助手。请按知识库规则拆解这个视频:..." --video-file "
|
|
131
|
+
yuanflow-cli ai qwen3-vl-plus --prompt "你是自媒体视频拆解助手。请按知识库规则拆解这个视频:..." --video-file "<本地视频路径>" --format agent-json
|
|
132
132
|
```
|
|
133
133
|
|
|
134
134
|
## YuanFlow-main 内置环境
|
|
@@ -145,7 +145,7 @@ YuanFlow-main 内置工具示例:
|
|
|
145
145
|
"--prompt",
|
|
146
146
|
"你是自媒体视频拆解助手。请严格按以下知识库规则拆解这个对标视频:\\n【知识库规则摘要】...\\n【用户目标】学习该视频的选题、开头、脚本结构、镜头节奏和可复用创作方法。\\n请输出:1. 一句话总结;2. 视频定位;3. 开头钩子;4. 内容结构;5. 镜头/画面节奏;6. 情绪和转化设计;7. 可复用模板;8. 不建议照搬的风险。",
|
|
147
147
|
"--video-file",
|
|
148
|
-
"
|
|
148
|
+
"<本地视频路径>",
|
|
149
149
|
"--format",
|
|
150
150
|
"agent-json"
|
|
151
151
|
],
|
|
@@ -93,9 +93,9 @@ YuanFlow-main 内置环境优先用 `yuanflow_cli_call` 调用知识库,不要
|
|
|
93
93
|
|
|
94
94
|
```bash
|
|
95
95
|
yuanflow-cli video strategy \
|
|
96
|
-
--project "
|
|
96
|
+
--project "<剪辑项目目录>" \
|
|
97
97
|
--template-type talking_head \
|
|
98
|
-
--rules-file "
|
|
98
|
+
--rules-file "<剪辑逻辑规则文件>,<口播模板规则文件>,<CLI校验规则文件>" \
|
|
99
99
|
--format agent-json
|
|
100
100
|
```
|
|
101
101
|
|
|
@@ -136,11 +136,11 @@ CLI 会生成 `strategy_snapshot.json`,后续 Agent 必须基于这个快照
|
|
|
136
136
|
"video",
|
|
137
137
|
"init",
|
|
138
138
|
"--input",
|
|
139
|
-
"
|
|
139
|
+
"<素材目录>",
|
|
140
140
|
"--primary-audio",
|
|
141
|
-
"
|
|
141
|
+
"<主音频文件>",
|
|
142
142
|
"--broll",
|
|
143
|
-
"
|
|
143
|
+
"<B-roll文件1>,<B-roll文件2>",
|
|
144
144
|
"--target-duration",
|
|
145
145
|
"60",
|
|
146
146
|
"--aspect",
|
|
@@ -157,9 +157,9 @@ CLI 会生成 `strategy_snapshot.json`,后续 Agent 必须基于这个快照
|
|
|
157
157
|
|
|
158
158
|
```bash
|
|
159
159
|
yuanflow-cli video init \
|
|
160
|
-
--input "
|
|
161
|
-
--primary-audio "
|
|
162
|
-
--broll "
|
|
160
|
+
--input "<素材目录>" \
|
|
161
|
+
--primary-audio "<主音频文件>" \
|
|
162
|
+
--broll "<B-roll文件1>,<B-roll文件2>" \
|
|
163
163
|
--target-duration 60 \
|
|
164
164
|
--aspect 9:16 \
|
|
165
165
|
--format agent-json
|
|
@@ -168,7 +168,7 @@ yuanflow-cli video init \
|
|
|
168
168
|
### 2. 扫描素材
|
|
169
169
|
|
|
170
170
|
```bash
|
|
171
|
-
yuanflow-cli video inspect --project "
|
|
171
|
+
yuanflow-cli video inspect --project "<剪辑项目目录>" --format agent-json
|
|
172
172
|
```
|
|
173
173
|
|
|
174
174
|
如果只是验证命令结构,可以加 `--dry-run`。
|
|
@@ -179,8 +179,8 @@ yuanflow-cli video inspect --project "D:\素材\yuanflow-video-edit" --format ag
|
|
|
179
179
|
|
|
180
180
|
```bash
|
|
181
181
|
yuanflow-cli video align \
|
|
182
|
-
--project "
|
|
183
|
-
--asr-file "
|
|
182
|
+
--project "<剪辑项目目录>" \
|
|
183
|
+
--asr-file "<ASR结果文件>" \
|
|
184
184
|
--format agent-json
|
|
185
185
|
```
|
|
186
186
|
|
|
@@ -199,7 +199,7 @@ yuanflow-cli video align \
|
|
|
199
199
|
|
|
200
200
|
```bash
|
|
201
201
|
yuanflow-cli video timeline \
|
|
202
|
-
--project "
|
|
202
|
+
--project "<剪辑项目目录>" \
|
|
203
203
|
--fps 1 \
|
|
204
204
|
--format agent-json
|
|
205
205
|
```
|
|
@@ -237,8 +237,8 @@ Agent 或人工查看抽帧图片后,先写出 `visual_review.agent.json`,
|
|
|
237
237
|
|
|
238
238
|
```bash
|
|
239
239
|
yuanflow-cli video visual-review \
|
|
240
|
-
--project "
|
|
241
|
-
--review-file "
|
|
240
|
+
--project "<剪辑项目目录>" \
|
|
241
|
+
--review-file "<视觉理解回写文件>" \
|
|
242
242
|
--format agent-json
|
|
243
243
|
```
|
|
244
244
|
|
|
@@ -330,8 +330,8 @@ Agent 读取:
|
|
|
330
330
|
|
|
331
331
|
```bash
|
|
332
332
|
yuanflow-cli video plan \
|
|
333
|
-
--project "
|
|
334
|
-
--timeline-plan "
|
|
333
|
+
--project "<剪辑项目目录>" \
|
|
334
|
+
--timeline-plan "<时间线计划文件>" \
|
|
335
335
|
--format agent-json
|
|
336
336
|
```
|
|
337
337
|
|
|
@@ -339,9 +339,9 @@ yuanflow-cli video plan \
|
|
|
339
339
|
|
|
340
340
|
```bash
|
|
341
341
|
yuanflow-cli video plan \
|
|
342
|
-
--project "
|
|
343
|
-
--timeline-plan "
|
|
344
|
-
--edl "
|
|
342
|
+
--project "<剪辑项目目录>" \
|
|
343
|
+
--timeline-plan "<时间线计划文件>" \
|
|
344
|
+
--edl "<EDL文件>" \
|
|
345
345
|
--format agent-json
|
|
346
346
|
```
|
|
347
347
|
|
|
@@ -350,14 +350,14 @@ yuanflow-cli video plan \
|
|
|
350
350
|
### 8. 渲染预览和自检
|
|
351
351
|
|
|
352
352
|
```bash
|
|
353
|
-
yuanflow-cli video render-preview --project "
|
|
354
|
-
yuanflow-cli video evaluate --project "
|
|
353
|
+
yuanflow-cli video render-preview --project "<剪辑项目目录>" --format agent-json
|
|
354
|
+
yuanflow-cli video evaluate --project "<剪辑项目目录>" --file "<预览视频文件>" --format agent-json
|
|
355
355
|
```
|
|
356
356
|
|
|
357
357
|
### 9. 最终导出
|
|
358
358
|
|
|
359
359
|
```bash
|
|
360
|
-
yuanflow-cli video render-final --project "
|
|
360
|
+
yuanflow-cli video render-final --project "<剪辑项目目录>" --format agent-json
|
|
361
361
|
```
|
|
362
362
|
|
|
363
363
|
完成后在 YuanFlow-main 内置环境必须调用 `artifact_files_register` 登记 `final.mp4`、`edl.json` 和 `eval_report.json`,不要只告诉用户内部路径。
|
|
@@ -16,6 +16,10 @@ emoji: 💡
|
|
|
16
16
|
|
|
17
17
|
不要在回复、日志或文件中暴露 token。用户主流程统一称为 YuanFlow API 和 YuanFlow 文件中转,不要求用户配置第三方平台 Key。
|
|
18
18
|
|
|
19
|
+
## YuanFlow-main 内置环境
|
|
20
|
+
|
|
21
|
+
在 YuanFlow-main 内置环境中,只有需要调用知识库、个人创作库、HTML 报告或其它 YuanFlow 能力时,才使用 `yuanflow_cli_call`、`yuanflow_image_request`、`artifact_files_register` 等受控工具。token、受管包路径和输出目录由 YuanFlow-main 管理,不写成外部用户必备步骤。
|
|
22
|
+
|
|
19
23
|
本 Skill 用于产出选题池、系列选题和选题优先级。执行时必须先查历史资产,再查自媒体知识库,最后结合用户本次目标输出可执行选题。
|
|
20
24
|
|
|
21
25
|
## 固定流程
|
|
@@ -45,7 +45,7 @@ emoji: ☁️
|
|
|
45
45
|
视频输入必须先抽音频:
|
|
46
46
|
|
|
47
47
|
```powershell
|
|
48
|
-
ffmpeg -y -i "
|
|
48
|
+
ffmpeg -y -i "<本地视频路径>" -vn -acodec libmp3lame -ar 44100 -ac 2 "transcription-input.mp3"
|
|
49
49
|
```
|
|
50
50
|
|
|
51
51
|
如果 ffmpeg 不可用,必须明确告诉用户缺少 ffmpeg,不能伪造转写结果。
|
|
@@ -60,7 +60,7 @@ YuanFlow-main 内置环境优先调用 `yuanflow_cli_call`,使用兼容子命
|
|
|
60
60
|
"oss",
|
|
61
61
|
"temp-upload",
|
|
62
62
|
"--file",
|
|
63
|
-
"
|
|
63
|
+
"<本地音频路径>",
|
|
64
64
|
"--filename",
|
|
65
65
|
"transcription-input.mp3",
|
|
66
66
|
"--content-type",
|
package/src/agent-protocol.js
CHANGED
|
@@ -5,9 +5,9 @@ import { listKnowledgeCommands } from './knowledge-tools.js';
|
|
|
5
5
|
import { listOssCommands } from './oss-tools.js';
|
|
6
6
|
import { listBrowserCommands } from './browser-tools.js';
|
|
7
7
|
import { listSearchCommands, listWorkCommands } from './work-tools.js';
|
|
8
|
-
import { listVideoCommands } from './video-tools.js';
|
|
9
8
|
import { listTrendingCommands } from './trending-tools.js';
|
|
10
9
|
import { listAiCommands } from './ai-tools.js';
|
|
10
|
+
import { listVoiceCommands } from './voice-tools.js';
|
|
11
11
|
|
|
12
12
|
const ERROR_MAP = [
|
|
13
13
|
{
|
|
@@ -110,9 +110,9 @@ export function buildCommandRegistry() {
|
|
|
110
110
|
const knowledgeCommands = listKnowledgeCommands();
|
|
111
111
|
const ossCommands = listOssCommands();
|
|
112
112
|
const browserCommands = listBrowserCommands();
|
|
113
|
-
const videoCommands = listVideoCommands();
|
|
114
113
|
const trendingCommands = listTrendingCommands();
|
|
115
114
|
const aiCommands = listAiCommands();
|
|
115
|
+
const voiceCommands = listVoiceCommands();
|
|
116
116
|
return [
|
|
117
117
|
...shortcuts,
|
|
118
118
|
...endpoints,
|
|
@@ -122,9 +122,9 @@ export function buildCommandRegistry() {
|
|
|
122
122
|
...knowledgeCommands,
|
|
123
123
|
...ossCommands,
|
|
124
124
|
...browserCommands,
|
|
125
|
-
...videoCommands,
|
|
126
125
|
...trendingCommands,
|
|
127
126
|
...aiCommands,
|
|
127
|
+
...voiceCommands,
|
|
128
128
|
].sort((left, right) => left.key.localeCompare(right.key));
|
|
129
129
|
}
|
|
130
130
|
|
package/src/cli.js
CHANGED
|
@@ -20,7 +20,6 @@ import { collectComments } from './comment-collector.js';
|
|
|
20
20
|
import { getKnowledgeDocs, navigateKnowledge } from './knowledge-tools.js';
|
|
21
21
|
import { copyObject, signedUrl, tempUpload } from './oss-tools.js';
|
|
22
22
|
import { runBrowserCommand } from './browser-tools.js';
|
|
23
|
-
import { runVideoCommand } from './video-tools.js';
|
|
24
23
|
import {
|
|
25
24
|
getWorkDetail,
|
|
26
25
|
getWorkDownload,
|
|
@@ -29,6 +28,7 @@ import {
|
|
|
29
28
|
} from './work-tools.js';
|
|
30
29
|
import { fetchVideoHotList } from './trending-tools.js';
|
|
31
30
|
import { formatAiHelp, runAiCommand } from './ai-tools.js';
|
|
31
|
+
import { formatVoiceHelp, runVoiceCommand } from './voice-tools.js';
|
|
32
32
|
|
|
33
33
|
export async function main(argv) {
|
|
34
34
|
const args = argv.slice(2);
|
|
@@ -94,13 +94,13 @@ export async function main(argv) {
|
|
|
94
94
|
return;
|
|
95
95
|
}
|
|
96
96
|
|
|
97
|
-
if (command === '
|
|
98
|
-
await
|
|
97
|
+
if (command === 'ai') {
|
|
98
|
+
await handleAi(rest);
|
|
99
99
|
return;
|
|
100
100
|
}
|
|
101
101
|
|
|
102
|
-
if (command === '
|
|
103
|
-
await
|
|
102
|
+
if (command === 'voice') {
|
|
103
|
+
await handleVoice(rest);
|
|
104
104
|
return;
|
|
105
105
|
}
|
|
106
106
|
|
|
@@ -427,16 +427,6 @@ async function handleBrowser(args) {
|
|
|
427
427
|
});
|
|
428
428
|
}
|
|
429
429
|
|
|
430
|
-
async function handleVideo(args) {
|
|
431
|
-
const { positionals, options } = parseOptions(args);
|
|
432
|
-
const [action = 'init'] = positionals;
|
|
433
|
-
const result = await runVideoCommand({ action, options });
|
|
434
|
-
await outputResult(result, options, {
|
|
435
|
-
command: `video ${action}`,
|
|
436
|
-
meta: { kind: 'video-editing' },
|
|
437
|
-
});
|
|
438
|
-
}
|
|
439
|
-
|
|
440
430
|
async function handleAi(args) {
|
|
441
431
|
const { positionals, options } = parseOptions(args);
|
|
442
432
|
const [action = 'help', ...rest] = positionals;
|
|
@@ -451,6 +441,20 @@ async function handleAi(args) {
|
|
|
451
441
|
});
|
|
452
442
|
}
|
|
453
443
|
|
|
444
|
+
async function handleVoice(args) {
|
|
445
|
+
const { positionals, options } = parseOptions(args);
|
|
446
|
+
const [action = 'help'] = positionals;
|
|
447
|
+
if (action === 'help' && !isAgentJsonFormat(options)) {
|
|
448
|
+
console.log(formatVoiceHelp());
|
|
449
|
+
return;
|
|
450
|
+
}
|
|
451
|
+
const result = await runVoiceCommand({ action, options });
|
|
452
|
+
await outputResult(result, { ...options, output: undefined }, {
|
|
453
|
+
command: `voice ${action}`,
|
|
454
|
+
meta: { endpoint: result.endpoint?.path, kind: result.endpoint?.kind || 'voice' },
|
|
455
|
+
});
|
|
456
|
+
}
|
|
457
|
+
|
|
454
458
|
async function handleGeneratedCommand(platform, args) {
|
|
455
459
|
if (!getPlatforms().includes(platform)) {
|
|
456
460
|
throw new Error(`未知平台:${platform}。可用平台:${getPlatforms().join(', ')}`);
|
|
@@ -623,16 +627,14 @@ function printHelp() {
|
|
|
623
627
|
yuanflow-cli oss signed-url --key path/to/file.png --ttl-seconds 1800 --format agent-json
|
|
624
628
|
yuanflow-cli browser profile-path --platform douyin --account main --format agent-json
|
|
625
629
|
yuanflow-cli browser task-plan --platform xiaohongshu --task publish --account main --format agent-json
|
|
626
|
-
yuanflow-cli video init --input "D:\\素材" --primary-audio "D:\\素材\\口播.mp3" --broll "D:\\素材\\画面.mp4" --format agent-json
|
|
627
|
-
yuanflow-cli video strategy --project "D:\\素材\\yuanflow-video-edit" --template-type talking_head --rules-file "D:\\规则\\logic.json,D:\\规则\\template.json,D:\\规则\\cli.json" --format agent-json
|
|
628
|
-
yuanflow-cli video align --project "D:\\素材\\yuanflow-video-edit" --asr-file "D:\\素材\\asr.json" --format agent-json
|
|
629
|
-
yuanflow-cli video timeline --project "D:\\素材\\yuanflow-video-edit" --fps 1 --format agent-json
|
|
630
|
-
yuanflow-cli video visual-review --project "D:\\素材\\yuanflow-video-edit" --review-file "D:\\素材\\yuanflow-video-edit\\visual_review.agent.json" --format agent-json
|
|
631
|
-
yuanflow-cli video plan --project "D:\\素材\\yuanflow-video-edit" --timeline-plan "D:\\素材\\yuanflow-video-edit\\timeline_plan.agent.json" --format agent-json
|
|
632
630
|
yuanflow-cli ai qwen3-vl-plus --prompt "描述这张图" --image-url "https://example.com/image.png" --dry-run
|
|
633
631
|
yuanflow-cli ai qwen3-vl-plus --prompt "总结这个视频画面" --video-url "https://example.com/video.mp4" --dry-run
|
|
634
632
|
yuanflow-cli ai qwen3-vl-plus --prompt "描述本地图片" --image-file "D:\\素材\\cover.png" --dry-run
|
|
635
633
|
yuanflow-cli ai qwen3-vl-plus --prompt "描述本地视频" --video-file "D:\\素材\\demo.mp4" --dry-run
|
|
634
|
+
yuanflow-cli voice clone --file-transfer "D:\\voice\\sample.wav" --name demo --activate --dry-run
|
|
635
|
+
yuanflow-cli voice list --dry-run
|
|
636
|
+
yuanflow-cli voice activate --voice voice_xxx --dry-run
|
|
637
|
+
yuanflow-cli voice replicate --text "你好" --voice voice_xxx --output "D:\\voice\\replicate.mp3" --dry-run
|
|
636
638
|
yuanflow-cli ai qwen-voice-enrollment --file "D:\\voice\\sample.wav" --name demo --activate --dry-run
|
|
637
639
|
yuanflow-cli ai qwen3-tts-vc-realtime-2026-01-15 --text "你好" --voice voice_xxx --output "D:\\voice\\qwen.mp3" --dry-run
|
|
638
640
|
yuanflow-cli ai fun-asr --audio-url "https://example.com/audio.wav" --response-format verbose_json --dry-run
|
|
@@ -648,7 +650,7 @@ function printHelp() {
|
|
|
648
650
|
qwen3-vl-plus 支持 --image-url、--video-url、--image-file、--video-file 四选一;视频建议最大 2GB、时长 2 秒到 1 小时。
|
|
649
651
|
qwen3-vl-plus 本地图片/视频会先走 YuanFlow 文件中转,内部调用 /atomic/oss/temp-upload 后把 signed_url 提交给模型。
|
|
650
652
|
browser 命令是自媒体平台专用浏览器自动化协议,只返回受控 profile/cookie/任务路径与执行计划,不用于普通网页搜索。
|
|
651
|
-
|
|
653
|
+
视频智能剪辑和视频制作执行链已迁移到独立项目 D:\\AI_project\\视频制作,不再由 yuanflow-cli video 命令提供;视频拆解仍由 yuanflow-skill 的“视频拆解”提供。
|
|
652
654
|
需要鉴权的请求都会使用 Authorization: Bearer <token>。
|
|
653
655
|
token 优先级:--token > YUANCHUANG_API_TOKEN > 本地 config.token。
|
|
654
656
|
YuanFlow-main 内置环境使用时,token 由 YuanFlow-main 内置环境注入,不需要手动配置。
|