@optima-chat/comfy-cli 0.4.0 → 0.4.1
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/dist/commands/config.d.ts.map +1 -1
- package/dist/commands/config.js +92 -6
- package/dist/commands/config.js.map +1 -1
- package/dist/commands/download.d.ts.map +1 -1
- package/dist/commands/download.js +43 -4
- package/dist/commands/download.js.map +1 -1
- package/dist/commands/edit.d.ts.map +1 -1
- package/dist/commands/edit.js +42 -4
- package/dist/commands/edit.js.map +1 -1
- package/dist/commands/generate.d.ts.map +1 -1
- package/dist/commands/generate.js +49 -6
- package/dist/commands/generate.js.map +1 -1
- package/dist/commands/interrupt.d.ts.map +1 -1
- package/dist/commands/interrupt.js +29 -2
- package/dist/commands/interrupt.js.map +1 -1
- package/dist/commands/model.d.ts.map +1 -1
- package/dist/commands/model.js +36 -2
- package/dist/commands/model.js.map +1 -1
- package/dist/commands/node.d.ts.map +1 -1
- package/dist/commands/node.js +76 -4
- package/dist/commands/node.js.map +1 -1
- package/dist/commands/queue.d.ts.map +1 -1
- package/dist/commands/queue.js +83 -8
- package/dist/commands/queue.js.map +1 -1
- package/dist/commands/system.d.ts.map +1 -1
- package/dist/commands/system.js +40 -2
- package/dist/commands/system.js.map +1 -1
- package/dist/commands/video.d.ts.map +1 -1
- package/dist/commands/video.js +52 -7
- package/dist/commands/video.js.map +1 -1
- package/dist/commands/workflow.d.ts.map +1 -1
- package/dist/commands/workflow.js +100 -8
- package/dist/commands/workflow.js.map +1 -1
- package/dist/index.js +26 -2
- package/dist/index.js.map +1 -1
- package/dist/utils/helpText.d.ts +15 -0
- package/dist/utils/helpText.d.ts.map +1 -0
- package/dist/utils/helpText.js +37 -0
- package/dist/utils/helpText.js.map +1 -0
- package/package.json +1 -1
package/dist/commands/node.js
CHANGED
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
import { ComfyAPIClient } from '../services/api.js';
|
|
2
2
|
import { info } from '../utils/logger.js';
|
|
3
3
|
import { outputSuccess, outputError, isPrettyMode } from '../utils/output.js';
|
|
4
|
+
import { addEnhancedHelp } from '../utils/helpText.js';
|
|
4
5
|
import Table from 'cli-table3';
|
|
5
6
|
export function registerNodeCommand(program) {
|
|
6
7
|
const nodeCmd = program
|
|
7
8
|
.command('node')
|
|
8
9
|
.description('节点信息查询');
|
|
9
10
|
// comfy node list
|
|
10
|
-
nodeCmd
|
|
11
|
+
const listCmd = nodeCmd
|
|
11
12
|
.command('list')
|
|
12
|
-
.description('列出所有节点类型')
|
|
13
|
+
.description('列出所有节点类型 - 查看 ComfyUI 中可用的所有节点类型')
|
|
13
14
|
.option('--filter <text>', '过滤节点名称')
|
|
14
15
|
.action(async (options) => {
|
|
15
16
|
const pretty = isPrettyMode(options);
|
|
@@ -47,10 +48,45 @@ export function registerNodeCommand(program) {
|
|
|
47
48
|
outputError('NODE_LIST_FAILED', `获取节点列表失败: ${err}`, options);
|
|
48
49
|
}
|
|
49
50
|
});
|
|
51
|
+
// Add enhanced help for list command
|
|
52
|
+
addEnhancedHelp(listCmd, {
|
|
53
|
+
examples: [
|
|
54
|
+
'# 列出所有节点类型',
|
|
55
|
+
'$ comfy node list',
|
|
56
|
+
'',
|
|
57
|
+
'# 过滤包含 "Load" 的节点',
|
|
58
|
+
'$ comfy node list --filter Load',
|
|
59
|
+
'',
|
|
60
|
+
'# Pretty 模式',
|
|
61
|
+
'$ comfy node list --pretty',
|
|
62
|
+
],
|
|
63
|
+
outputJson: `{
|
|
64
|
+
"success": true,
|
|
65
|
+
"data": {
|
|
66
|
+
"nodes": [
|
|
67
|
+
"KSampler",
|
|
68
|
+
"LoadImage",
|
|
69
|
+
"SaveImage",
|
|
70
|
+
"CLIPTextEncode"
|
|
71
|
+
],
|
|
72
|
+
"total": 4,
|
|
73
|
+
"filter": null
|
|
74
|
+
}
|
|
75
|
+
}`,
|
|
76
|
+
relatedCommands: [
|
|
77
|
+
{ command: 'node info <class>', description: '查看特定节点的详细信息' },
|
|
78
|
+
{ command: 'model list', description: '列出可用模型' },
|
|
79
|
+
],
|
|
80
|
+
notes: [
|
|
81
|
+
'返回 ComfyUI 中所有可用节点类型',
|
|
82
|
+
'使用 --filter 参数进行模糊搜索',
|
|
83
|
+
'配合 node info 命令查看节点详细信息',
|
|
84
|
+
],
|
|
85
|
+
});
|
|
50
86
|
// comfy node info
|
|
51
|
-
nodeCmd
|
|
87
|
+
const infoCmd = nodeCmd
|
|
52
88
|
.command('info')
|
|
53
|
-
.description('查看节点详情')
|
|
89
|
+
.description('查看节点详情 - 查看指定节点的输入输出参数和配置')
|
|
54
90
|
.argument('<class>', '节点类名')
|
|
55
91
|
.action(async (nodeClass, options) => {
|
|
56
92
|
const pretty = isPrettyMode(options);
|
|
@@ -72,5 +108,41 @@ export function registerNodeCommand(program) {
|
|
|
72
108
|
outputError('NODE_INFO_FAILED', `获取节点信息失败: ${err}`, options);
|
|
73
109
|
}
|
|
74
110
|
});
|
|
111
|
+
// Add enhanced help for info command
|
|
112
|
+
addEnhancedHelp(infoCmd, {
|
|
113
|
+
examples: [
|
|
114
|
+
'# 查看 KSampler 节点详情',
|
|
115
|
+
'$ comfy node info KSampler',
|
|
116
|
+
'',
|
|
117
|
+
'# 查看 LoadImage 节点详情',
|
|
118
|
+
'$ comfy node info LoadImage',
|
|
119
|
+
'',
|
|
120
|
+
'# Pretty 模式',
|
|
121
|
+
'$ comfy node info SaveImage --pretty',
|
|
122
|
+
],
|
|
123
|
+
outputJson: `{
|
|
124
|
+
"success": true,
|
|
125
|
+
"data": {
|
|
126
|
+
"class": "KSampler",
|
|
127
|
+
"info": {
|
|
128
|
+
"input": {
|
|
129
|
+
"required": {...},
|
|
130
|
+
"optional": {...}
|
|
131
|
+
},
|
|
132
|
+
"output": [...],
|
|
133
|
+
"category": "sampling"
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
}`,
|
|
137
|
+
relatedCommands: [
|
|
138
|
+
{ command: 'node list', description: '列出所有节点类型' },
|
|
139
|
+
{ command: 'node list --filter <text>', description: '搜索节点' },
|
|
140
|
+
],
|
|
141
|
+
notes: [
|
|
142
|
+
'返回节点的完整定义信息',
|
|
143
|
+
'包含输入参数、输出类型、分类等',
|
|
144
|
+
'用于构建自定义 workflow 时了解节点接口',
|
|
145
|
+
],
|
|
146
|
+
});
|
|
75
147
|
}
|
|
76
148
|
//# sourceMappingURL=node.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"node.js","sourceRoot":"","sources":["../../src/commands/node.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAAS,IAAI,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAC9E,OAAO,KAAK,MAAM,YAAY,CAAC;AAE/B,MAAM,UAAU,mBAAmB,CAAC,OAAgB;IAClD,MAAM,OAAO,GAAG,OAAO;SACpB,OAAO,CAAC,MAAM,CAAC;SACf,WAAW,CAAC,QAAQ,CAAC,CAAC;IAEzB,kBAAkB;IAClB,OAAO;
|
|
1
|
+
{"version":3,"file":"node.js","sourceRoot":"","sources":["../../src/commands/node.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAAS,IAAI,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAC9E,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AACvD,OAAO,KAAK,MAAM,YAAY,CAAC;AAE/B,MAAM,UAAU,mBAAmB,CAAC,OAAgB;IAClD,MAAM,OAAO,GAAG,OAAO;SACpB,OAAO,CAAC,MAAM,CAAC;SACf,WAAW,CAAC,QAAQ,CAAC,CAAC;IAEzB,kBAAkB;IAClB,MAAM,OAAO,GAAG,OAA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E,CAAC;gBACX,OAAO,CAAC,GAAG,CAAC,YAAY,SAAS,IAAI,CAAC,CAAC;gBACvC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,SAAS,CAAC,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC;YACjD,CAAC;iBAAM,CAAC;gBACN,aAAa,CAAC;oBACZ,KAAK,EAAE,SAAS;oBAChB,IAAI,EAAE,QAAQ;iBACf,CAAC,CAAC;YACL,CAAC;QACH,CAAC;QAAC,OAAO,GAAG,EAAE,CAAC;YACb,WAAW,CAAC,kBAAkB,EAAE,aAAa,GAAG,EAAE,EAAE,OAAO,CAAC,CAAC;QAC/D,CAAC;IACH,CAAC,CAAC,CAAC;IAEL,qCAAqC;IACrC,eAAe,CAAC,OAAO,EAAE;QACvB,QAAQ,EAAE;YACR,oBAAoB;YACpB,4BAA4B;YAC5B,EAAE;YACF,qBAAqB;YACrB,6BAA6B;YAC7B,EAAE;YACF,aAAa;YACb,sCAAsC;SACvC;QACD,UAAU,EAAE;;;;;;;;;;;;;EAad;QACE,eAAe,EAAE;YACf,EAAE,OAAO,EAAE,WAAW,EAAE,WAAW,EAAE,UAAU,EAAE;YACjD,EAAE,OAAO,EAAE,2BAA2B,EAAE,WAAW,EAAE,MAAM,EAAE;SAC9D;QACD,KAAK,EAAE;YACL,aAAa;YACb,iBAAiB;YACjB,0BAA0B;SAC3B;KACF,CAAC,CAAC;AACL,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"queue.d.ts","sourceRoot":"","sources":["../../src/commands/queue.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;
|
|
1
|
+
{"version":3,"file":"queue.d.ts","sourceRoot":"","sources":["../../src/commands/queue.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAOpC,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,OAAO,QA+MpD"}
|
package/dist/commands/queue.js
CHANGED
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
import { ComfyAPIClient } from '../services/api.js';
|
|
2
2
|
import { success, info } from '../utils/logger.js';
|
|
3
3
|
import { outputSuccess, outputError, isPrettyMode } from '../utils/output.js';
|
|
4
|
+
import { addEnhancedHelp } from '../utils/helpText.js';
|
|
4
5
|
import Table from 'cli-table3';
|
|
5
6
|
export function registerQueueCommand(program) {
|
|
6
7
|
const queueCmd = program
|
|
7
8
|
.command('queue')
|
|
8
9
|
.description('队列管理');
|
|
9
10
|
// comfy queue status
|
|
10
|
-
queueCmd
|
|
11
|
+
const statusCmd = queueCmd
|
|
11
12
|
.command('status')
|
|
12
|
-
.description('查看队列状态')
|
|
13
|
+
.description('查看队列状态 - 查看 ComfyUI 当前正在执行和等待的任务')
|
|
13
14
|
.action(async (options) => {
|
|
14
15
|
const pretty = isPrettyMode(options);
|
|
15
16
|
try {
|
|
@@ -72,11 +73,40 @@ export function registerQueueCommand(program) {
|
|
|
72
73
|
outputError('QUEUE_STATUS_FAILED', `获取队列状态失败: ${err}`, options);
|
|
73
74
|
}
|
|
74
75
|
});
|
|
76
|
+
// Add enhanced help for status command
|
|
77
|
+
addEnhancedHelp(statusCmd, {
|
|
78
|
+
examples: [
|
|
79
|
+
'# 查看队列状态(JSON 模式)',
|
|
80
|
+
'$ comfy queue status',
|
|
81
|
+
'',
|
|
82
|
+
'# Pretty 模式',
|
|
83
|
+
'$ comfy queue status --pretty',
|
|
84
|
+
],
|
|
85
|
+
outputJson: `{
|
|
86
|
+
"success": true,
|
|
87
|
+
"data": {
|
|
88
|
+
"running": [],
|
|
89
|
+
"pending": [],
|
|
90
|
+
"running_count": 0,
|
|
91
|
+
"pending_count": 0
|
|
92
|
+
}
|
|
93
|
+
}`,
|
|
94
|
+
relatedCommands: [
|
|
95
|
+
{ command: 'queue clear --confirm', description: '清空队列' },
|
|
96
|
+
{ command: 'queue delete <id>', description: '删除指定任务' },
|
|
97
|
+
{ command: 'interrupt', description: '中断当前执行' },
|
|
98
|
+
],
|
|
99
|
+
notes: [
|
|
100
|
+
'running: 正在执行的任务列表',
|
|
101
|
+
'pending: 等待执行的任务列表',
|
|
102
|
+
'每个任务包含 prompt_id 和节点数量信息',
|
|
103
|
+
],
|
|
104
|
+
});
|
|
75
105
|
// comfy queue clear
|
|
76
|
-
queueCmd
|
|
106
|
+
const clearCmd = queueCmd
|
|
77
107
|
.command('clear')
|
|
78
|
-
.description('清空队列')
|
|
79
|
-
.option('--confirm', '
|
|
108
|
+
.description('清空队列 - 清空所有等待中的任务(需要确认)')
|
|
109
|
+
.option('--confirm', '确认清空(必需)')
|
|
80
110
|
.action(async (options) => {
|
|
81
111
|
const pretty = isPrettyMode(options);
|
|
82
112
|
try {
|
|
@@ -96,11 +126,33 @@ export function registerQueueCommand(program) {
|
|
|
96
126
|
outputError('QUEUE_CLEAR_FAILED', `清空队列失败: ${err}`, options);
|
|
97
127
|
}
|
|
98
128
|
});
|
|
129
|
+
// Add enhanced help for clear command
|
|
130
|
+
addEnhancedHelp(clearCmd, {
|
|
131
|
+
examples: [
|
|
132
|
+
'# 清空队列(需要 --confirm)',
|
|
133
|
+
'$ comfy queue clear --confirm',
|
|
134
|
+
],
|
|
135
|
+
outputJson: `{
|
|
136
|
+
"success": true,
|
|
137
|
+
"data": {
|
|
138
|
+
"message": "队列已清空"
|
|
139
|
+
}
|
|
140
|
+
}`,
|
|
141
|
+
relatedCommands: [
|
|
142
|
+
{ command: 'queue status', description: '查看队列状态' },
|
|
143
|
+
{ command: 'queue delete <id>', description: '删除单个任务' },
|
|
144
|
+
],
|
|
145
|
+
notes: [
|
|
146
|
+
'必须使用 --confirm 选项才能执行',
|
|
147
|
+
'只清空等待中的任务,不影响正在执行的任务',
|
|
148
|
+
'此操作不可撤销',
|
|
149
|
+
],
|
|
150
|
+
});
|
|
99
151
|
// comfy queue delete
|
|
100
|
-
queueCmd
|
|
152
|
+
const deleteCmd = queueCmd
|
|
101
153
|
.command('delete')
|
|
102
|
-
.description('删除指定队列项')
|
|
103
|
-
.argument('<item_id>', '队列项 ID')
|
|
154
|
+
.description('删除指定队列项 - 从队列中删除指定的任务')
|
|
155
|
+
.argument('<item_id>', '队列项 ID(从 queue status 获取)')
|
|
104
156
|
.action(async (itemId, options) => {
|
|
105
157
|
const pretty = isPrettyMode(options);
|
|
106
158
|
try {
|
|
@@ -120,5 +172,28 @@ export function registerQueueCommand(program) {
|
|
|
120
172
|
outputError('QUEUE_DELETE_FAILED', `删除失败: ${err}`, options);
|
|
121
173
|
}
|
|
122
174
|
});
|
|
175
|
+
// Add enhanced help for delete command
|
|
176
|
+
addEnhancedHelp(deleteCmd, {
|
|
177
|
+
examples: [
|
|
178
|
+
'# 删除指定队列项',
|
|
179
|
+
'$ comfy queue delete abc-123-def',
|
|
180
|
+
],
|
|
181
|
+
outputJson: `{
|
|
182
|
+
"success": true,
|
|
183
|
+
"data": {
|
|
184
|
+
"message": "已删除队列项",
|
|
185
|
+
"item_id": "abc-123-def"
|
|
186
|
+
}
|
|
187
|
+
}`,
|
|
188
|
+
relatedCommands: [
|
|
189
|
+
{ command: 'queue status', description: '查看队列获取 item_id' },
|
|
190
|
+
{ command: 'queue clear --confirm', description: '清空所有队列' },
|
|
191
|
+
],
|
|
192
|
+
notes: [
|
|
193
|
+
'item_id 从 queue status 命令获取',
|
|
194
|
+
'只能删除等待中的任务',
|
|
195
|
+
'正在执行的任务需要使用 interrupt 命令',
|
|
196
|
+
],
|
|
197
|
+
});
|
|
123
198
|
}
|
|
124
199
|
//# sourceMappingURL=queue.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"queue.js","sourceRoot":"","sources":["../../src/commands/queue.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAAE,OAAO,EAAS,IAAI,EAAE,MAAM,oBAAoB,CAAC;AAC1D,OAAO,EAAE,aAAa,EAAE,WAAW,E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;;;;EAMd;QACE,eAAe,EAAE;YACf,EAAE,OAAO,EAAE,cAAc,EAAE,WAAW,EAAE,gBAAgB,EAAE;YAC1D,EAAE,OAAO,EAAE,uBAAuB,EAAE,WAAW,EAAE,QAAQ,EAAE;SAC5D;QACD,KAAK,EAAE;YACL,6BAA6B;YAC7B,YAAY;YACZ,0BAA0B;SAC3B;KACF,CAAC,CAAC;AACL,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"system.d.ts","sourceRoot":"","sources":["../../src/commands/system.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;
|
|
1
|
+
{"version":3,"file":"system.d.ts","sourceRoot":"","sources":["../../src/commands/system.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAOpC,wBAAgB,qBAAqB,CAAC,OAAO,EAAE,OAAO,QAoFrD"}
|
package/dist/commands/system.js
CHANGED
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
import { ComfyAPIClient } from '../services/api.js';
|
|
2
2
|
import { info } from '../utils/logger.js';
|
|
3
3
|
import { outputSuccess, outputError, isPrettyMode } from '../utils/output.js';
|
|
4
|
+
import { addEnhancedHelp } from '../utils/helpText.js';
|
|
4
5
|
import Table from 'cli-table3';
|
|
5
6
|
export function registerSystemCommand(program) {
|
|
6
7
|
const systemCmd = program
|
|
7
8
|
.command('system')
|
|
8
9
|
.description('系统信息');
|
|
9
10
|
// comfy system stats
|
|
10
|
-
systemCmd
|
|
11
|
+
const statsCmd = systemCmd
|
|
11
12
|
.command('stats')
|
|
12
|
-
.description('查看系统统计信息')
|
|
13
|
+
.description('查看系统统计信息 - 查看 ComfyUI 服务器的系统资源和设备状态')
|
|
13
14
|
.action(async (options) => {
|
|
14
15
|
const pretty = isPrettyMode(options);
|
|
15
16
|
try {
|
|
@@ -43,5 +44,42 @@ export function registerSystemCommand(program) {
|
|
|
43
44
|
outputError('SYSTEM_STATS_FAILED', `获取系统信息失败: ${err}`, options);
|
|
44
45
|
}
|
|
45
46
|
});
|
|
47
|
+
// Add enhanced help for stats command
|
|
48
|
+
addEnhancedHelp(statsCmd, {
|
|
49
|
+
examples: [
|
|
50
|
+
'# 查看系统统计信息',
|
|
51
|
+
'$ comfy system stats',
|
|
52
|
+
'',
|
|
53
|
+
'# Pretty 模式',
|
|
54
|
+
'$ comfy system stats --pretty',
|
|
55
|
+
],
|
|
56
|
+
outputJson: `{
|
|
57
|
+
"success": true,
|
|
58
|
+
"data": {
|
|
59
|
+
"system": {
|
|
60
|
+
"os": "linux",
|
|
61
|
+
"python_version": "3.10.12",
|
|
62
|
+
"pytorch_version": "2.0.1"
|
|
63
|
+
},
|
|
64
|
+
"devices": [
|
|
65
|
+
{
|
|
66
|
+
"name": "NVIDIA GeForce RTX 4090",
|
|
67
|
+
"type": "cuda",
|
|
68
|
+
"vram_total": 24564,
|
|
69
|
+
"vram_free": 18432
|
|
70
|
+
}
|
|
71
|
+
]
|
|
72
|
+
}
|
|
73
|
+
}`,
|
|
74
|
+
relatedCommands: [
|
|
75
|
+
{ command: 'queue status', description: '查看队列状态' },
|
|
76
|
+
{ command: 'model list', description: '列出可用模型' },
|
|
77
|
+
],
|
|
78
|
+
notes: [
|
|
79
|
+
'显示 ComfyUI 服务器的系统信息',
|
|
80
|
+
'包含 CPU、内存、GPU 等硬件信息',
|
|
81
|
+
'用于诊断性能问题和资源使用情况',
|
|
82
|
+
],
|
|
83
|
+
});
|
|
46
84
|
}
|
|
47
85
|
//# sourceMappingURL=system.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"system.js","sourceRoot":"","sources":["../../src/commands/system.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAAS,IAAI,EAAW,MAAM,oBAAoB,CAAC;AAC1D,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,YAAY,EAAE,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E,WAAW,EAAE,QAAQ,EAAE;YAClD,EAAE,OAAO,EAAE,YAAY,EAAE,WAAW,EAAE,QAAQ,EAAE;SACjD;QACD,KAAK,EAAE;YACL,qBAAqB;YACrB,qBAAqB;YACrB,iBAAiB;SAClB;KACF,CAAC,CAAC;AACL,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"video.d.ts","sourceRoot":"","sources":["../../src/commands/video.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;
|
|
1
|
+
{"version":3,"file":"video.d.ts","sourceRoot":"","sources":["../../src/commands/video.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAWpC,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,OAAO,QA2KpD"}
|
package/dist/commands/video.js
CHANGED
|
@@ -5,18 +5,19 @@ import { ComfyAPIClient } from '../services/api.js';
|
|
|
5
5
|
import { loadWorkflow, getBuiltinWorkflowPath, replaceVariables } from '../utils/workflow.js';
|
|
6
6
|
import { success, info } from '../utils/logger.js';
|
|
7
7
|
import { outputSuccess, outputError, isPrettyMode } from '../utils/output.js';
|
|
8
|
+
import { addEnhancedHelp } from '../utils/helpText.js';
|
|
8
9
|
import { monitorProgress } from '../services/websocket.js';
|
|
9
10
|
export function registerVideoCommand(program) {
|
|
10
|
-
program
|
|
11
|
+
const cmd = program
|
|
11
12
|
.command('video')
|
|
12
|
-
.description('
|
|
13
|
+
.description('生成视频(图生视频)- 使用 Wan2.1 模型将静态图像转换为动态视频')
|
|
13
14
|
.argument('<image>', '输入图像路径')
|
|
14
|
-
.option('-p, --prompt <text>', '
|
|
15
|
+
.option('-p, --prompt <text>', '运动描述提示词(如 "camera zoom in")', '')
|
|
15
16
|
.option('-n, --negative <text>', '负向提示词', '')
|
|
16
|
-
.option('-o, --output <dir>', '输出目录', './output')
|
|
17
|
-
.option('--width <number>', '视频宽度', '512')
|
|
18
|
-
.option('--height <number>', '视频高度', '512')
|
|
19
|
-
.option('--no-wait', '
|
|
17
|
+
.option('-o, --output <dir>', '输出目录 (默认: ./output)', './output')
|
|
18
|
+
.option('--width <number>', '视频宽度 (默认: 512)', '512')
|
|
19
|
+
.option('--height <number>', '视频高度 (默认: 512)', '512')
|
|
20
|
+
.option('--no-wait', '提交任务后立即返回,不等待生成完成')
|
|
20
21
|
.action(async (image, options) => {
|
|
21
22
|
const pretty = isPrettyMode(options);
|
|
22
23
|
try {
|
|
@@ -124,5 +125,49 @@ export function registerVideoCommand(program) {
|
|
|
124
125
|
outputError('VIDEO_FAILED', `生成失败: ${err}`, options);
|
|
125
126
|
}
|
|
126
127
|
});
|
|
128
|
+
// Add enhanced help text
|
|
129
|
+
addEnhancedHelp(cmd, {
|
|
130
|
+
examples: [
|
|
131
|
+
'# 基础用法:图像转视频',
|
|
132
|
+
'$ comfy video landscape.png',
|
|
133
|
+
'',
|
|
134
|
+
'# 添加运动提示词',
|
|
135
|
+
'$ comfy video photo.jpg --prompt "camera zoom in"',
|
|
136
|
+
'',
|
|
137
|
+
'# 指定视频尺寸',
|
|
138
|
+
'$ comfy video image.png --width 720 --height 480',
|
|
139
|
+
'',
|
|
140
|
+
'# 不等待完成',
|
|
141
|
+
'$ comfy video sunset.png --no-wait',
|
|
142
|
+
'',
|
|
143
|
+
'# Pretty 模式',
|
|
144
|
+
'$ comfy video cat.png --prompt "cat walking" --pretty',
|
|
145
|
+
],
|
|
146
|
+
outputJson: `{
|
|
147
|
+
"success": true,
|
|
148
|
+
"data": {
|
|
149
|
+
"prompt_id": "abc-123-def",
|
|
150
|
+
"image": "landscape.png",
|
|
151
|
+
"width": 512,
|
|
152
|
+
"height": 512,
|
|
153
|
+
"frames": 33,
|
|
154
|
+
"fps": 8,
|
|
155
|
+
"duration": 4.1,
|
|
156
|
+
"status": "submitted_waiting"
|
|
157
|
+
}
|
|
158
|
+
}`,
|
|
159
|
+
relatedCommands: [
|
|
160
|
+
{ command: 'download <prompt_id>', description: '下载生成的视频' },
|
|
161
|
+
{ command: 'generate <prompt>', description: '生成新图像' },
|
|
162
|
+
{ command: 'edit <image> <prompt>', description: '编辑现有图像' },
|
|
163
|
+
],
|
|
164
|
+
notes: [
|
|
165
|
+
'默认使用 Wan2.1 模型,生成 4.1 秒视频(33 帧 @ 8 FPS)',
|
|
166
|
+
'图像会先上传到 ComfyUI 服务器',
|
|
167
|
+
'支持常见图像格式:PNG, JPG, JPEG',
|
|
168
|
+
'建议图像尺寸为 512x512 以获得最佳效果',
|
|
169
|
+
'视频生成时间较长,建议使用 --no-wait 立即返回',
|
|
170
|
+
],
|
|
171
|
+
});
|
|
127
172
|
}
|
|
128
173
|
//# sourceMappingURL=video.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"video.js","sourceRoot":"","sources":["../../src/commands/video.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,IAAI,MAAM,MAAM,CAAC;AAC7B,OAAO,KAAK,EAAE,MAAM,IAAI,CAAC;AACzB,OAAO,GAAG,MAAM,KAAK,CAAC;AACtB,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAAE,YAAY,EAAE,sBAAsB,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AAC9F,OAAO,EAAE,OAAO,EAAS,IAAI,EAAE,MAAM,oBAAoB,CAAC;AAC1D,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAC9E,OAAO,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAE3D,MAAM,UAAU,oBAAoB,CAAC,OAAgB;IACnD,OAAO;
|
|
1
|
+
{"version":3,"file":"video.js","sourceRoot":"","sources":["../../src/commands/video.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,IAAI,MAAM,MAAM,CAAC;AAC7B,OAAO,KAAK,EAAE,MAAM,IAAI,CAAC;AACzB,OAAO,GAAG,MAAM,KAA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MAAM,CAAC,GAAG;oBACf,QAAQ,EAAE,UAAU,CAAC,CAAC,MAAM,CAAC,MAAM,GAAG,MAAM,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC;oBAC7D,MAAM,EAAE,OAAO,CAAC,IAAI,KAAK,KAAK,CAAC,CAAC,CAAC,mBAAmB,CAAC,CAAC,CAAC,WAAW;iBACnE,CAAC,CAAC;YACL,CAAC;QACH,CAAC;QAAC,OAAO,GAAG,EAAE,CAAC;YACb,WAAW,CAAC,cAAc,EAAE,SAAS,GAAG,EAAE,EAAE,OAAO,CAAC,CAAC;QACvD,CAAC;IACH,CAAC,CAAC,CAAC;IAEL,yBAAyB;IACzB,eAAe,CAAC,GAAG,EAAE;QACnB,QAAQ,EAAE;YACR,cAAc;YACd,6BAA6B;YAC7B,EAAE;YACF,WAAW;YACX,mDAAmD;YACnD,EAAE;YACF,UAAU;YACV,kDAAkD;YAClD,EAAE;YACF,SAAS;YACT,oCAAoC;YACpC,EAAE;YACF,aAAa;YACb,uDAAuD;SACxD;QACD,UAAU,EAAE;;;;;;;;;;;;EAYd;QACE,eAAe,EAAE;YACf,EAAE,OAAO,EAAE,sBAAsB,EAAE,WAAW,EAAE,SAAS,EAAE;YAC3D,EAAE,OAAO,EAAE,mBAAmB,EAAE,WAAW,EAAE,OAAO,EAAE;YACtD,EAAE,OAAO,EAAE,uBAAuB,EAAE,WAAW,EAAE,QAAQ,EAAE;SAC5D;QACD,KAAK,EAAE;YACL,yCAAyC;YACzC,qBAAqB;YACrB,yBAAyB;YACzB,yBAAyB;YACzB,8BAA8B;SAC/B;KACF,CAAC,CAAC;AACL,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"workflow.d.ts","sourceRoot":"","sources":["../../src/commands/workflow.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;
|
|
1
|
+
{"version":3,"file":"workflow.d.ts","sourceRoot":"","sources":["../../src/commands/workflow.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AASpC,wBAAgB,uBAAuB,CAAC,OAAO,EAAE,OAAO,QAyPvD"}
|
|
@@ -2,15 +2,16 @@ import { ComfyAPIClient } from '../services/api.js';
|
|
|
2
2
|
import { loadWorkflow, extractVariables } from '../utils/workflow.js';
|
|
3
3
|
import { success, info } from '../utils/logger.js';
|
|
4
4
|
import { outputSuccess, outputError, isPrettyMode } from '../utils/output.js';
|
|
5
|
+
import { addEnhancedHelp } from '../utils/helpText.js';
|
|
5
6
|
import Table from 'cli-table3';
|
|
6
7
|
export function registerWorkflowCommand(program) {
|
|
7
8
|
const workflowCmd = program
|
|
8
9
|
.command('workflow')
|
|
9
10
|
.description('工作流管理');
|
|
10
11
|
// comfy workflow submit
|
|
11
|
-
workflowCmd
|
|
12
|
+
const submitCmd = workflowCmd
|
|
12
13
|
.command('submit')
|
|
13
|
-
.description('提交工作流')
|
|
14
|
+
.description('提交工作流 - 提交自定义 ComfyUI workflow JSON 文件')
|
|
14
15
|
.argument('<file>', 'workflow JSON 文件路径')
|
|
15
16
|
.option('--wait', '等待执行完成')
|
|
16
17
|
.action(async (file, options) => {
|
|
@@ -53,11 +54,38 @@ export function registerWorkflowCommand(program) {
|
|
|
53
54
|
outputError('WORKFLOW_SUBMIT_FAILED', `提交失败: ${err}`, options);
|
|
54
55
|
}
|
|
55
56
|
});
|
|
57
|
+
// Add enhanced help for submit command
|
|
58
|
+
addEnhancedHelp(submitCmd, {
|
|
59
|
+
examples: [
|
|
60
|
+
'# 提交工作流',
|
|
61
|
+
'$ comfy workflow submit my-workflow.json',
|
|
62
|
+
'',
|
|
63
|
+
'# 提交并等待完成',
|
|
64
|
+
'$ comfy workflow submit my-workflow.json --wait',
|
|
65
|
+
],
|
|
66
|
+
outputJson: `{
|
|
67
|
+
"success": true,
|
|
68
|
+
"data": {
|
|
69
|
+
"prompt_id": "abc-123-def",
|
|
70
|
+
"variables": ["prompt", "width"]
|
|
71
|
+
}
|
|
72
|
+
}`,
|
|
73
|
+
relatedCommands: [
|
|
74
|
+
{ command: 'workflow list', description: '查看工作流历史' },
|
|
75
|
+
{ command: 'workflow get <id>', description: '查看工作流结果' },
|
|
76
|
+
{ command: 'download <id>', description: '下载输出结果' },
|
|
77
|
+
],
|
|
78
|
+
notes: [
|
|
79
|
+
'workflow 文件为标准 ComfyUI workflow JSON 格式',
|
|
80
|
+
'支持变量替换(使用 {{variable_name}} 格式)',
|
|
81
|
+
'提交后返回 prompt_id 用于查询和下载结果',
|
|
82
|
+
],
|
|
83
|
+
});
|
|
56
84
|
// comfy workflow list
|
|
57
|
-
workflowCmd
|
|
85
|
+
const listCmd = workflowCmd
|
|
58
86
|
.command('list')
|
|
59
|
-
.description('列出工作流历史')
|
|
60
|
-
.option('--limit <number>', '限制数量', '10')
|
|
87
|
+
.description('列出工作流历史 - 查看最近提交的工作流执行记录')
|
|
88
|
+
.option('--limit <number>', '限制数量 (默认: 10)', '10')
|
|
61
89
|
.action(async (options) => {
|
|
62
90
|
const pretty = isPrettyMode(options);
|
|
63
91
|
try {
|
|
@@ -97,13 +125,49 @@ export function registerWorkflowCommand(program) {
|
|
|
97
125
|
outputError('WORKFLOW_LIST_FAILED', `获取历史失败: ${err}`, options);
|
|
98
126
|
}
|
|
99
127
|
});
|
|
128
|
+
// Add enhanced help for list command
|
|
129
|
+
addEnhancedHelp(listCmd, {
|
|
130
|
+
examples: [
|
|
131
|
+
'# 列出最近 10 条工作流历史(默认 JSON)',
|
|
132
|
+
'$ comfy workflow list',
|
|
133
|
+
'',
|
|
134
|
+
'# 列出最近 20 条',
|
|
135
|
+
'$ comfy workflow list --limit 20',
|
|
136
|
+
'',
|
|
137
|
+
'# Pretty 模式',
|
|
138
|
+
'$ comfy workflow list --pretty',
|
|
139
|
+
],
|
|
140
|
+
outputJson: `{
|
|
141
|
+
"success": true,
|
|
142
|
+
"data": {
|
|
143
|
+
"workflows": [
|
|
144
|
+
{
|
|
145
|
+
"prompt_id": "abc-123-def",
|
|
146
|
+
"completed": true,
|
|
147
|
+
"status_str": "success"
|
|
148
|
+
}
|
|
149
|
+
],
|
|
150
|
+
"total": 10
|
|
151
|
+
}
|
|
152
|
+
}`,
|
|
153
|
+
relatedCommands: [
|
|
154
|
+
{ command: 'workflow get <id>', description: '查看单个工作流详情' },
|
|
155
|
+
{ command: 'download <id>', description: '下载工作流输出结果' },
|
|
156
|
+
{ command: 'queue status', description: '查看当前队列状态' },
|
|
157
|
+
],
|
|
158
|
+
notes: [
|
|
159
|
+
'默认显示最近 10 条记录',
|
|
160
|
+
'使用 --limit 参数控制数量',
|
|
161
|
+
'记录包含 prompt_id、完成状态和状态信息',
|
|
162
|
+
],
|
|
163
|
+
});
|
|
100
164
|
// comfy workflow get
|
|
101
|
-
workflowCmd
|
|
165
|
+
const getCmd = workflowCmd
|
|
102
166
|
.command('get')
|
|
103
|
-
.description('获取工作流结果')
|
|
167
|
+
.description('获取工作流结果 - 查看指定工作流的执行详情和输出')
|
|
104
168
|
.argument('<prompt_id>', 'Prompt ID')
|
|
105
169
|
.option('--download', '下载输出图像')
|
|
106
|
-
.option('--output <dir>', '输出目录', './output')
|
|
170
|
+
.option('--output <dir>', '输出目录 (默认: ./output)', './output')
|
|
107
171
|
.action(async (promptId, options) => {
|
|
108
172
|
const pretty = isPrettyMode(options);
|
|
109
173
|
try {
|
|
@@ -142,5 +206,33 @@ export function registerWorkflowCommand(program) {
|
|
|
142
206
|
outputError('WORKFLOW_GET_FAILED', `获取结果失败: ${err}`, options);
|
|
143
207
|
}
|
|
144
208
|
});
|
|
209
|
+
// Add enhanced help for get command
|
|
210
|
+
addEnhancedHelp(getCmd, {
|
|
211
|
+
examples: [
|
|
212
|
+
'# 查看工作流结果',
|
|
213
|
+
'$ comfy workflow get abc-123-def',
|
|
214
|
+
'',
|
|
215
|
+
'# Pretty 模式',
|
|
216
|
+
'$ comfy workflow get abc-123-def --pretty',
|
|
217
|
+
],
|
|
218
|
+
outputJson: `{
|
|
219
|
+
"success": true,
|
|
220
|
+
"data": {
|
|
221
|
+
"prompt_id": "abc-123-def",
|
|
222
|
+
"completed": true,
|
|
223
|
+
"status_str": "success",
|
|
224
|
+
"outputs": {...}
|
|
225
|
+
}
|
|
226
|
+
}`,
|
|
227
|
+
relatedCommands: [
|
|
228
|
+
{ command: 'download <id>', description: '下载工作流输出文件' },
|
|
229
|
+
{ command: 'workflow list', description: '查看所有工作流历史' },
|
|
230
|
+
],
|
|
231
|
+
notes: [
|
|
232
|
+
'返回工作流的完整执行信息',
|
|
233
|
+
'包含状态、输出节点等详细信息',
|
|
234
|
+
'使用 download 命令下载实际文件',
|
|
235
|
+
],
|
|
236
|
+
});
|
|
145
237
|
}
|
|
146
238
|
//# sourceMappingURL=workflow.js.map
|