Describe the bug
When bootstrapping a standard AgentSession voice pipeline on Windows 10/11 x64 using the Bun runtime ecosystem (bun src/main.ts dev), the worker runtime crashes immediately during initialization when setting up inference.TurnDetector().
Even when explicitly attempting to set turnHandling.turnDetection: undefined, the underlying engine still defaults to warming up the lk_eot_audio engine, triggering a failure because Bun on Windows does not fetch or bind platform-specific native C++ Node addons (@livekit/local-inference-win32-x64-msvc) properly out of optional dependencies.
Changing the flag to the explicit string variant 'vad' bypasses it, but the default fallback state crashes out of the box when run with Bun.
Relevant log output
bun src/main.ts dev
◇ injected env (0) from .env.local
[01:33:51.054] DEBUG (18628): initializing inference runner
runner: "lk_eot_audio"
6 | #logger = log();
7 | #mod;
8 | async initialize() {
9 | this.#mod = _getLocalInferenceModule();
10 | if (this.#mod === void 0) {
11 | throw new Error(
^
error: EotRunner: @livekit/local-inference native binding unavailable in the inference process
at initialize (...\node_modules@livekit\agents\dist\inference\eot\runner.js:11:17)
at (...\node_modules@livekit\agents\dist\ipc\inference_proc_lazy_main.js:43:17)
[01:33:51.531] WARN (18628): @livekit/local-inference native binding not loadable; local VAD/EOT paths disabled
err: "@livekit/local-inference: failed to load @livekit/local-inference-win32-x64-msvc. Re-run npm install (or pnpm install) so the optional platform dependency for win32-x64 is fetched."
[01:33:51.583] FATAL (23772): closing worker due to error.
Describe your environment
- OS: Windows 11 (x64)
- Runtime: Bun v1.3.14 (Windows x64 Native)
- Framework Packages:
@livekit/agents (Latest JS SDK version)
Minimal reproducible example
-
Scaffold a fresh repository on a Windows machine.
-
Initialize dependencies using bun add @livekit/agents @livekit/plugins-ai-coustics livekit-server-sdk
-
Put down standard agent cli.runApp worker code containing turnDetection: new inference.TurnDetector().
-
Fire bun src/main.ts dev.
Additional information
No response
Describe the bug
When bootstrapping a standard
AgentSessionvoice pipeline on Windows 10/11 x64 using the Bun runtime ecosystem (bun src/main.ts dev), the worker runtime crashes immediately during initialization when setting upinference.TurnDetector().Even when explicitly attempting to set
turnHandling.turnDetection: undefined, the underlying engine still defaults to warming up thelk_eot_audioengine, triggering a failure because Bun on Windows does not fetch or bind platform-specific native C++ Node addons (@livekit/local-inference-win32-x64-msvc) properly out of optional dependencies.Changing the flag to the explicit string variant
'vad'bypasses it, but the default fallback state crashes out of the box when run with Bun.Relevant log output
bun src/main.ts dev
◇ injected env (0) from .env.local
[01:33:51.054] DEBUG (18628): initializing inference runner
runner: "lk_eot_audio"
6 | #logger = log();
7 | #mod;
8 | async initialize() {
9 | this.#mod = _getLocalInferenceModule();
10 | if (this.#mod === void 0) {
11 | throw new Error(
^
error: EotRunner: @livekit/local-inference native binding unavailable in the inference process
at initialize (...\node_modules@livekit\agents\dist\inference\eot\runner.js:11:17)
at (...\node_modules@livekit\agents\dist\ipc\inference_proc_lazy_main.js:43:17)
[01:33:51.531] WARN (18628): @livekit/local-inference native binding not loadable; local VAD/EOT paths disabled
err: "@livekit/local-inference: failed to load @livekit/local-inference-win32-x64-msvc. Re-run
npm install(orpnpm install) so the optional platform dependency for win32-x64 is fetched."[01:33:51.583] FATAL (23772): closing worker due to error.
Describe your environment
@livekit/agents(Latest JS SDK version)Minimal reproducible example
Scaffold a fresh repository on a Windows machine.
Initialize dependencies using bun add @livekit/agents @livekit/plugins-ai-coustics livekit-server-sdk
Put down standard agent cli.runApp worker code containing turnDetection: new inference.TurnDetector().
Fire bun src/main.ts dev.
Additional information
No response