@jskit-ai/assistant-voice 0.2.15 → 0.2.17
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.
|
@@ -9,14 +9,14 @@
|
|
|
9
9
|
},
|
|
10
10
|
"dependencies": {
|
|
11
11
|
"@fastify/websocket": "^11.2.0",
|
|
12
|
-
"@jskit-ai/assistant-core": "0.2.
|
|
13
|
-
"@jskit-ai/assistant-runtime": "0.2.
|
|
14
|
-
"@jskit-ai/assistant-voice": "0.2.
|
|
15
|
-
"@jskit-ai/connectors-catalog": "0.2.
|
|
16
|
-
"@jskit-ai/http-runtime": "0.2.
|
|
17
|
-
"@jskit-ai/kernel": "0.2.
|
|
18
|
-
"@jskit-ai/realtime": "0.2.
|
|
19
|
-
"@jskit-ai/shell-web": "0.2.
|
|
12
|
+
"@jskit-ai/assistant-core": "0.2.15",
|
|
13
|
+
"@jskit-ai/assistant-runtime": "0.2.17",
|
|
14
|
+
"@jskit-ai/assistant-voice": "0.2.17",
|
|
15
|
+
"@jskit-ai/connectors-catalog": "0.2.7",
|
|
16
|
+
"@jskit-ai/http-runtime": "0.2.6",
|
|
17
|
+
"@jskit-ai/kernel": "0.2.6",
|
|
18
|
+
"@jskit-ai/realtime": "0.2.10",
|
|
19
|
+
"@jskit-ai/shell-web": "0.2.7",
|
|
20
20
|
"@mdi/js": "^7.4.47",
|
|
21
21
|
"@tanstack/vue-query": "^5.90.5",
|
|
22
22
|
"fastify": "^5.8.0",
|
package/locales/en.json
CHANGED
|
@@ -133,7 +133,8 @@
|
|
|
133
133
|
"noLongerAvailable": "This conversation is no longer available for voice.",
|
|
134
134
|
"hostDisposed": "The voice host has been disposed.",
|
|
135
135
|
"notAvailable": "This conversation is not available for voice.",
|
|
136
|
-
"finishBeforeEnding": "Finish or discard your recording before ending voice."
|
|
136
|
+
"finishBeforeEnding": "Finish or discard your recording before ending voice.",
|
|
137
|
+
"microphoneUnsupported": "This browser does not support microphone audio processing."
|
|
137
138
|
},
|
|
138
139
|
"protocol": {
|
|
139
140
|
"chooseVoice": "Choose an available voice before starting speech."
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jskit-ai/assistant-voice",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.17",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Duplex voice conversations with application-owned targets, authorization and speech services.",
|
|
6
6
|
"scripts": {
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"examples"
|
|
21
21
|
],
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@jskit-ai/assistant-core": "0.2.
|
|
23
|
+
"@jskit-ai/assistant-core": "0.2.15",
|
|
24
24
|
"@mdi/js": "^7.4.47",
|
|
25
25
|
"ws": "^8.20.1"
|
|
26
26
|
},
|
|
@@ -63,7 +63,7 @@
|
|
|
63
63
|
}
|
|
64
64
|
},
|
|
65
65
|
"peerDependencies": {
|
|
66
|
-
"@jskit-ai/kernel": "0.2.
|
|
66
|
+
"@jskit-ai/kernel": "0.2.6",
|
|
67
67
|
"vue": "^3.5.13",
|
|
68
68
|
"vuetify": "^4.0.0"
|
|
69
69
|
},
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { audioContextConstructor } from "./browser.js";
|
|
2
|
+
import { voiceError } from "./i18n.js";
|
|
2
3
|
|
|
3
4
|
const CAPTURE_WORKLET_NAME = "jskit-voice-capture";
|
|
4
5
|
const CAPTURE_FLUSH_TIMEOUT_MS = 500;
|
|
@@ -83,7 +84,7 @@ function noFlushPending() {}
|
|
|
83
84
|
async function createMicrophoneCapture({ onLevel = ignoreLevel, onPcm = ignorePcm, targetSampleRate = 16_000 } = {}) {
|
|
84
85
|
const AudioContextCtor = audioContextConstructor();
|
|
85
86
|
if (!AudioContextCtor) {
|
|
86
|
-
throw
|
|
87
|
+
throw voiceError("jskit.assistant.voice.errors.microphoneUnsupported");
|
|
87
88
|
}
|
|
88
89
|
const stream = await navigator.mediaDevices.getUserMedia({
|
|
89
90
|
audio: {
|