skillfree 0.1.29 → 0.1.38
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 +100 -147
- package/bin/skillfree.js +16 -84
- package/install.sh +25 -27
- package/package.json +1 -1
- package/scripts/commands/models.js +21 -13
- package/scripts/commands/pilot.js +43 -320
- package/scripts/commands/video.js +14 -90
- package/skillfree-0.1.37.tgz +0 -0
- package/scripts/commands/music.js +0 -28
- package/scripts/commands/stt.js +0 -47
- package/scripts/commands/tts.js +0 -67
package/scripts/commands/tts.js
DELETED
|
@@ -1,67 +0,0 @@
|
|
|
1
|
-
const { run } = require('./run')
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Text-to-speech command
|
|
5
|
-
* @param {object} params - TTS parameters
|
|
6
|
-
* @param {string} params.model - Model in "vendor/model" format
|
|
7
|
-
* @param {string} params.text - Text to synthesize
|
|
8
|
-
* @param {string} [params.voiceId] - Voice ID (provider-specific)
|
|
9
|
-
* @param {string} params.output - Output audio file path
|
|
10
|
-
* @returns {Promise<object>} TTS result
|
|
11
|
-
*/
|
|
12
|
-
async function tts(params) {
|
|
13
|
-
if (!params.text) {
|
|
14
|
-
throw new Error('--text is required for TTS')
|
|
15
|
-
}
|
|
16
|
-
if (!params.output) {
|
|
17
|
-
throw new Error('--output is required for TTS')
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
const inputs = {}
|
|
21
|
-
|
|
22
|
-
// Provider-specific input mapping
|
|
23
|
-
const [vendor] = params.model.split('/')
|
|
24
|
-
if (vendor === 'elevenlabs') {
|
|
25
|
-
// ElevenLabs uses 'text' and requires voice_id - default to "Rachel"
|
|
26
|
-
inputs.text = params.text
|
|
27
|
-
inputs.voice_id = params.voiceId || 'EXAVITQu4vr4xnSDxMaL'
|
|
28
|
-
} else if (vendor === 'minimax') {
|
|
29
|
-
// MiniMax uses 'text' and 'voice_setting' object
|
|
30
|
-
inputs.text = params.text
|
|
31
|
-
inputs.voice_setting = {
|
|
32
|
-
voice_id: params.voiceId || 'male-qn-qingse',
|
|
33
|
-
speed: 1.0,
|
|
34
|
-
vol: 1.0,
|
|
35
|
-
pitch: 0,
|
|
36
|
-
}
|
|
37
|
-
} else if (vendor === 'openai') {
|
|
38
|
-
// OpenAI TTS uses 'input' and 'voice'
|
|
39
|
-
inputs.input = params.text
|
|
40
|
-
inputs.voice = params.voiceId || 'alloy'
|
|
41
|
-
} else if (vendor === 'replicate') {
|
|
42
|
-
// Replicate XTTS uses 'text' and requires 'speaker' (audio URL for voice cloning)
|
|
43
|
-
inputs.text = params.text
|
|
44
|
-
if (params.speaker) {
|
|
45
|
-
inputs.speaker = params.speaker
|
|
46
|
-
} else if (params.voiceId) {
|
|
47
|
-
inputs.speaker = params.voiceId
|
|
48
|
-
} else {
|
|
49
|
-
// Default speaker sample
|
|
50
|
-
inputs.speaker =
|
|
51
|
-
'https://replicate.delivery/pbxt/Jt79w0xsT64R1JsiJ0LQRL8UcWspg5J4RFrU6YwEKpOT1ukS/male.wav'
|
|
52
|
-
}
|
|
53
|
-
} else if (vendor === 'mm') {
|
|
54
|
-
// MM TTS (qwen3-tts-flash) uses 'text' and optional 'voice'
|
|
55
|
-
inputs.text = params.text
|
|
56
|
-
if (params.voiceId) {
|
|
57
|
-
inputs.voice = params.voiceId
|
|
58
|
-
}
|
|
59
|
-
} else {
|
|
60
|
-
// Default: use 'text'
|
|
61
|
-
inputs.text = params.text
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
return run({ model: params.model, inputs, output: params.output })
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
module.exports = { tts }
|