skillfree 0.1.12 → 0.1.14
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/SKILL.md +15 -12
- package/bin/skillfree.js +11 -1
- package/package.json +1 -1
- package/scripts/commands/models.js +27 -23
- package/scripts/commands/pilot.js +2 -2
package/SKILL.md
CHANGED
|
@@ -170,18 +170,21 @@ skillfree pilot --type ocr --prompt "解析这个PDF" --file ./document.pdf
|
|
|
170
170
|
## ⚡ 快速决策指南
|
|
171
171
|
|
|
172
172
|
```
|
|
173
|
-
日常对话/写作
|
|
174
|
-
长文档/中文理解
|
|
175
|
-
复杂推理/数学
|
|
176
|
-
实时搜索/新闻
|
|
177
|
-
专业写作/分析
|
|
178
|
-
最强对话
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
173
|
+
日常对话/写作 → DeepSeek-V3.2-Fast(1积分)
|
|
174
|
+
长文档/中文理解 → kimi-k2.5(1积分)
|
|
175
|
+
复杂推理/数学 → DeepSeek-V3.2-Thinking(2积分)
|
|
176
|
+
实时搜索/新闻 → perplexity-sonar-pro-search-ssvip(12积分)
|
|
177
|
+
专业写作/分析 → claude-sonnet-4-6(12积分)
|
|
178
|
+
最强对话 → claude-opus-4-6(59积分)
|
|
179
|
+
中文图像生成 → doubao-seedream-5.0-lite(11积分)
|
|
180
|
+
写实图像生成 → gpt-image-1.5-ssvip(47积分)
|
|
181
|
+
图片编辑 → qwen-image-edit-plus-20260226(27积分)
|
|
182
|
+
中文配音 → speech-2.8-hd(18积分)
|
|
183
|
+
英文配音 → gemini-2.5-pro-preview-tts(18积分)
|
|
184
|
+
视频生成(性价比) → paiwo-v5.6-ttv(160积分)
|
|
185
|
+
视频生成(旗舰) → kling-v2-6-text2video(427积分)
|
|
186
|
+
音乐生成 → chirp-v5(107积分)
|
|
187
|
+
文档OCR解析 → hehe-tywd(3积分)
|
|
185
188
|
```
|
|
186
189
|
|
|
187
190
|
---
|
package/bin/skillfree.js
CHANGED
|
@@ -54,6 +54,16 @@ program
|
|
|
54
54
|
await pilot({ type: 'chat', prompt, ...flags }).catch(e => { console.error('❌', e.message); process.exit(1) })
|
|
55
55
|
})
|
|
56
56
|
|
|
57
|
+
// ── models ────────────────────────────────────────────────────────────────────
|
|
58
|
+
program
|
|
59
|
+
.command('models')
|
|
60
|
+
.description('查看所有可用模型')
|
|
61
|
+
.option('--type <type>', '按类型过滤: chat | image | tts | video | music | ocr | embedding')
|
|
62
|
+
.action(async (flags) => {
|
|
63
|
+
const { listModels } = require('../scripts/commands/models')
|
|
64
|
+
await listModels(flags.type).catch(e => { console.error('❌', e.message); process.exit(1) })
|
|
65
|
+
})
|
|
66
|
+
|
|
57
67
|
// ── balance ───────────────────────────────────────────────────────────────────
|
|
58
68
|
program
|
|
59
69
|
.command('balance')
|
|
@@ -100,7 +110,7 @@ program
|
|
|
100
110
|
}
|
|
101
111
|
|
|
102
112
|
// 视频任务
|
|
103
|
-
const res = await request(`/
|
|
113
|
+
const res = await request(`/tasks/${taskId}`, { method: 'GET' })
|
|
104
114
|
const task = await res.json()
|
|
105
115
|
console.log(`\n📋 任务 ${taskId}`)
|
|
106
116
|
console.log(` 状态:${task.status}`)
|
package/package.json
CHANGED
|
@@ -1,32 +1,36 @@
|
|
|
1
|
-
const {
|
|
1
|
+
const { request } = require('../lib/client')
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
* @param {string} [params.vendor] - Filter by vendor
|
|
8
|
-
* @returns {Promise<object>} Models list
|
|
9
|
-
*/
|
|
10
|
-
async function listModels(params = {}) {
|
|
11
|
-
const response = await apiHubGet('/v1/models')
|
|
12
|
-
let models = response.models || []
|
|
3
|
+
async function listModels(type) {
|
|
4
|
+
const res = await request('/models', { method: 'GET' })
|
|
5
|
+
const data = await res.json()
|
|
6
|
+
const all = data.data || []
|
|
13
7
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
const
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
)
|
|
8
|
+
const groups = {}
|
|
9
|
+
for (const m of all) {
|
|
10
|
+
const t = m.type || 'chat'
|
|
11
|
+
if (type && t !== type) continue
|
|
12
|
+
if (!groups[t]) groups[t] = []
|
|
13
|
+
groups[t].push(m.id)
|
|
21
14
|
}
|
|
22
15
|
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
16
|
+
const typeLabel = {
|
|
17
|
+
chat: '💬 对话',
|
|
18
|
+
image: '🎨 图像',
|
|
19
|
+
tts: '🔊 语音合成',
|
|
20
|
+
video: '🎬 视频',
|
|
21
|
+
music: '🎵 音乐',
|
|
22
|
+
ocr: '📄 OCR',
|
|
23
|
+
embedding: '🔢 Embedding',
|
|
27
24
|
}
|
|
28
25
|
|
|
29
|
-
|
|
26
|
+
console.log('\n🦞 SkillFree 可用模型\n')
|
|
27
|
+
for (const [t, ids] of Object.entries(groups)) {
|
|
28
|
+
console.log(`${typeLabel[t] || t}`)
|
|
29
|
+
ids.forEach(id => console.log(` ${id}`))
|
|
30
|
+
console.log()
|
|
31
|
+
}
|
|
32
|
+
console.log(`共 ${all.length} 个模型`)
|
|
33
|
+
console.log(`\n用法示例:skillfree pilot --type chat --model DeepSeek-V3.2-Fast --prompt "你好"`)
|
|
30
34
|
}
|
|
31
35
|
|
|
32
36
|
module.exports = { listModels }
|
|
@@ -339,7 +339,7 @@ async function pilot(flags) {
|
|
|
339
339
|
|
|
340
340
|
// 1. 提交任务
|
|
341
341
|
process.stdout.write(`🎬 提交视频任务(${videoModel})...`)
|
|
342
|
-
const res = await request('/
|
|
342
|
+
const res = await request('/video/generations', {
|
|
343
343
|
method: 'POST',
|
|
344
344
|
body: JSON.stringify({ model: videoModel, prompt }),
|
|
345
345
|
})
|
|
@@ -357,7 +357,7 @@ async function pilot(flags) {
|
|
|
357
357
|
|
|
358
358
|
while (Date.now() - start < maxWait) {
|
|
359
359
|
await new Promise(r => setTimeout(r, interval))
|
|
360
|
-
const pollRes = await request(`/
|
|
360
|
+
const pollRes = await request(`/tasks/${taskId}`, { method: 'GET' })
|
|
361
361
|
const task = await pollRes.json()
|
|
362
362
|
const status = task.status
|
|
363
363
|
|