@kuralle-syrinx/server-workers 3.1.0 → 4.0.0

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kuralle-syrinx/server-workers",
3
- "version": "3.1.0",
3
+ "version": "4.0.0",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -15,16 +15,16 @@
15
15
  "agents": "0.14.0",
16
16
  "ai": "^6.0.0",
17
17
  "zod": "^4.1.8",
18
- "@kuralle-syrinx/core": "3.1.0",
19
- "@kuralle-syrinx/aisdk": "3.1.0",
20
- "@kuralle-syrinx/cf-agents": "3.1.0",
21
- "@kuralle-syrinx/server-websocket": "3.1.0",
22
- "@kuralle-syrinx/kuralle": "3.1.0",
23
- "@kuralle-syrinx/recorder": "3.1.0",
24
- "@kuralle-syrinx/realtime": "3.1.0",
25
- "@kuralle-syrinx/ws": "3.1.0",
26
- "@kuralle-syrinx/deepgram": "3.1.0",
27
- "@kuralle-syrinx/cartesia": "3.1.0"
18
+ "@kuralle-syrinx/core": "4.0.0",
19
+ "@kuralle-syrinx/aisdk": "4.0.0",
20
+ "@kuralle-syrinx/server-websocket": "4.0.0",
21
+ "@kuralle-syrinx/kuralle": "4.0.0",
22
+ "@kuralle-syrinx/realtime": "4.0.0",
23
+ "@kuralle-syrinx/ws": "4.0.0",
24
+ "@kuralle-syrinx/recorder": "4.0.0",
25
+ "@kuralle-syrinx/deepgram": "4.0.0",
26
+ "@kuralle-syrinx/cf-agents": "4.0.0",
27
+ "@kuralle-syrinx/cartesia": "4.0.0"
28
28
  },
29
29
  "devDependencies": {
30
30
  "@cloudflare/workers-types": "^4.20260601.0",
@@ -27,7 +27,7 @@ describe("liveCascadedPipeline", () => {
27
27
  const env = { DEEPGRAM_API_KEY: "dg-key", OPENAI_API_KEY: "oa-key", VECTORIZE: mockVectorize };
28
28
  const stt = liveCascadedPipeline.stt(env, ctx);
29
29
  expect(stt.plugin).toBeInstanceOf(DeepgramSTTPlugin);
30
- expect(stt.config).toMatchObject({ model: "nova-3", endpointing: 300, vad_events: true, api_key: "dg-key" });
30
+ expect(stt.config).toMatchObject({ model: "nova-3", endpointing: 500, vad_events: true, utterance_end_ms: 1000, api_key: "dg-key" });
31
31
 
32
32
  const tts = liveCascadedPipeline.tts(env, ctx);
33
33
  expect(tts.plugin).toBeInstanceOf(DeepgramTTSPlugin);
@@ -50,7 +50,18 @@ export const liveCascadedPipeline: CascadedPipeline<LiveSessionEnv> = {
50
50
  sample_rate: INPUT_SAMPLE_RATE_HZ,
51
51
  model: "nova-3",
52
52
  language: "en-US",
53
- endpointing: 300,
53
+ // Silence (ms) before Deepgram finalizes a turn. 300ms is too aggressive with
54
+ // no semantic layer behind it: a natural mid-sentence pause ("my address is
55
+ // forty-two… Elm Street") finalizes early and the agent answers half an
56
+ // utterance. 500ms is the middle ground — it stops the worst cut-offs, and the
57
+ // ~200ms cost is negligible against the LLM-dominated v2v budget. The real fix
58
+ // for the edge is a semantic/dynamic endpointer (smart-turn has no Workers
59
+ // build yet); until then this is the sane default. Tune per deployment.
60
+ endpointing: 500,
61
+ // Gap-based backstop: on a noisy/continuous line where Deepgram never detects
62
+ // clean silence, `speech_final` can fail to fire and the turn wedges. UtteranceEnd
63
+ // completes it. Requires interim_results (on by default).
64
+ utterance_end_ms: 1000,
54
65
  provider_finalize_timeout_ms: 2500,
55
66
  finalize_timeout_fallback: true,
56
67
  // No local VAD on the edge: Deepgram SpeechStarted is the barge-in