@voxd/sdk
v0.4.6
Published
Node and Bun SDK for local transcription and text-to-speech with Vox.
Downloads
1,338
Readme
@voxd/sdk
Use Vox transcription and text-to-speech from Bun or Node. The SDK connects to Vox Companion, which runs the speech models on the Mac.
Install
bun add @voxd/sdkOr with npm:
npm install @voxd/sdkRequires Node 22+ or Bun, plus Vox Companion running on the same Mac.
Quick start
import { VoxClient } from "@voxd/sdk";
const vox = new VoxClient({ clientId: "my-tool" });
await vox.connect();
const transcript = await vox.transcribeFile("/tmp/sample.wav");
console.log(transcript.text);
const speech = await vox.synthesize("Hello from Vox");
console.log(speech.audioBytes);
vox.disconnect();Warm up before a request
Warm-up is explicit, so your app decides when to spend the startup cost.
await vox.startWarmup("parakeet:v3");
const result = await vox.transcribeFile("/tmp/sample.wav", "parakeet:v3");
console.log(result.text);
console.log(result.metrics?.totalMs);Main API
connect()anddisconnect()transcribeFile()andannotateFile()listVoices()andsynthesize()startWarmup(),scheduleWarmup(), andgetWarmupStatus()createLiveSession()listHistory()anddeleteHistoryRecord()doctor()andhealth()
Use a stable clientId so metrics and sessions can be traced back to your tool.
Choose the right package
- Bun or Node:
@voxd/sdk - Browser:
@voxd/client - Terminal:
@voxd/cli - macOS or iOS app: embed
VoxCoreandVoxEngine
