@andresaya/edge-tts 1.2.0 → 1.2.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/README.md +6 -5
- package/dist/cli/edge-tts.d.ts +2 -0
- package/dist/cli/edge-tts.js +14 -4845
- package/dist/commands/SynthesizeCommand.d.ts +2 -0
- package/dist/commands/SynthesizeCommand.js +23 -4830
- package/dist/commands/VoiceListCommand.d.ts +2 -0
- package/dist/commands/VoiceListCommand.js +13 -4826
- package/dist/config/constants.d.ts +5 -0
- package/dist/config/constants.js +7 -28
- package/dist/index.d.ts +1 -0
- package/dist/index.js +5 -2976
- package/dist/services/EdgeTTS.d.ts +17 -0
- package/dist/services/EdgeTTS.js +101 -2959
- package/package.json +4 -5
package/README.md
CHANGED
|
@@ -37,7 +37,7 @@ bun install --global edge-tts
|
|
|
37
37
|
|
|
38
38
|
To synthesize speech from text, use the following command:
|
|
39
39
|
```bash
|
|
40
|
-
edge-tts synthesize -t "Hello, world!" -o
|
|
40
|
+
edge-tts synthesize -t "Hello, world!" -o hello_world_audio
|
|
41
41
|
```
|
|
42
42
|
|
|
43
43
|
To list available voices, run:
|
|
@@ -50,7 +50,7 @@ Integration into Your Project
|
|
|
50
50
|
To use Edge TTS in your Bun project, you can import it like this:
|
|
51
51
|
|
|
52
52
|
```js
|
|
53
|
-
import { EdgeTTS } from '@andresaya/edge-
|
|
53
|
+
import { EdgeTTS } from '@andresaya/edge-tts';
|
|
54
54
|
|
|
55
55
|
// Initialize the EdgeTTS service
|
|
56
56
|
const tts = new EdgeTTS();
|
|
@@ -68,7 +68,7 @@ await tts.synthesize("Hello, world!", 'en-US-AriaNeural', {
|
|
|
68
68
|
|
|
69
69
|
// Export synthesized audio in different formats
|
|
70
70
|
tts.toBase64(); // Get audio as base64
|
|
71
|
-
await tts.toFile("
|
|
71
|
+
await tts.toFile("output_audio"); // Save audio to file
|
|
72
72
|
await tts.toRaw(); // Get raw audio buffer
|
|
73
73
|
```
|
|
74
74
|
|
|
@@ -79,8 +79,9 @@ After synthesizing speech, you can export the audio in various formats:
|
|
|
79
79
|
- `toFile`: Saves the audio to a specified file (e.g., "output.wav").
|
|
80
80
|
- `toRaw`: Returns the raw audio stream.
|
|
81
81
|
|
|
82
|
-
##
|
|
83
|
-
|
|
82
|
+
## PHP Version
|
|
83
|
+
If you want to use Edge TTS with PHP, you can check out the PHP version of this package, [Edge TTS PHP](https://github.com/andresayac/edge-tts-php)
|
|
84
|
+
|
|
84
85
|
|
|
85
86
|
## License
|
|
86
87
|
This project is licensed under the GNU General Public License v3 (GPLv3).
|