aillom-vox-client 2.1.3 → 2.1.5
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 +41 -5
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -52,9 +52,45 @@ Hosted docs: `https://vox.aillom.com/docs`
|
|
|
52
52
|
|
|
53
53
|
## Quick start
|
|
54
54
|
|
|
55
|
-
###
|
|
55
|
+
### Use the SDK in your app
|
|
56
56
|
|
|
57
|
-
|
|
57
|
+
You do **not** need to clone this repository to use the SDK. In your own project:
|
|
58
|
+
|
|
59
|
+
```bash
|
|
60
|
+
npm install aillom-vox-client
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
Then import it:
|
|
64
|
+
|
|
65
|
+
```typescript
|
|
66
|
+
import { AillomVox } from 'aillom-vox-client';
|
|
67
|
+
|
|
68
|
+
const client = new AillomVox({
|
|
69
|
+
apiKey: 'av_YOUR_API_KEY',
|
|
70
|
+
provider: 'aillomvox',
|
|
71
|
+
ttsEngine: 'inworld',
|
|
72
|
+
voice: 'Aanya',
|
|
73
|
+
language: 'en-US',
|
|
74
|
+
sampleRate: 16000,
|
|
75
|
+
systemPrompt: 'You are a concise and helpful assistant.',
|
|
76
|
+
});
|
|
77
|
+
|
|
78
|
+
await client.connect();
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
If you want a new browser app from zero:
|
|
82
|
+
|
|
83
|
+
```bash
|
|
84
|
+
npm create vite@latest my-vox-app -- --template vanilla-ts
|
|
85
|
+
cd my-vox-app
|
|
86
|
+
npm install
|
|
87
|
+
npm install aillom-vox-client
|
|
88
|
+
npm run dev
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
### Run the ready-made example UI
|
|
92
|
+
|
|
93
|
+
Clone the repository only when you want to run the example app that already has UI, microphone capture, playback, transcripts and logs.
|
|
58
94
|
|
|
59
95
|
Windows PowerShell:
|
|
60
96
|
|
|
@@ -93,9 +129,9 @@ npm install
|
|
|
93
129
|
npm run dev
|
|
94
130
|
```
|
|
95
131
|
|
|
96
|
-
Open the Vite URL, paste your `av_...` key,
|
|
132
|
+
Open the Vite URL, paste your `av_...` key, wait for the dynamic provider, TTS engine, and voice lists to load, then click **Start call**. Use **Refresh catalog** if you want to reload the live lists. Full setup and troubleshooting steps are in [docs/NPM_QUICKSTART.md](docs/NPM_QUICKSTART.md).
|
|
97
133
|
|
|
98
|
-
Terminal smoke test
|
|
134
|
+
### Terminal smoke test
|
|
99
135
|
|
|
100
136
|
```bash
|
|
101
137
|
mkdir vox-smoke && cd vox-smoke
|
|
@@ -110,7 +146,7 @@ Expected output:
|
|
|
110
146
|
{ providers: 7, pricing: 7 }
|
|
111
147
|
```
|
|
112
148
|
|
|
113
|
-
###
|
|
149
|
+
### Realtime voice snippet
|
|
114
150
|
|
|
115
151
|
```typescript
|
|
116
152
|
import { AillomVox } from 'aillom-vox-client';
|
package/package.json
CHANGED