AbsoluteJS

@absolutejs/voice-assemblyai

@absolutejs/voice-assemblyaiv0.0.19-beta.127betaVoice & Media

AssemblyAI speech-to-text adapter for @absolutejs/voice

#Installation

BASH
bun add @absolutejs/voice-assemblyai

#Capabilities

Overview

AssemblyAI speech-to-text adapter for @absolutejs/voice.

Setup

The adapter accepts 16kHz mono pcm_s16le audio from core and sends it to AssemblyAI's official streaming WebSocket API.

What It Maps

streaming Turn with end_of_turn=false -> partial

streaming Turn with end_of_turn=true -> final

streaming Turn with end_of_turn=true -> normalized endOfTurn

Show 3 more

websocket errors -> normalized error

websocket close -> normalized close

AssemblyAI's streaming output is immutable, so the adapter treats in-progress turns as partial updates and the terminal turn message as the final transcript for that turn.

Options

Supported options include:

apiKey

speechModel

Show 6 more

formatTurns

keytermsPrompt

endOfTurnConfidenceThreshold

minEndOfTurnSilenceWhenConfident

maxTurnSilence

token

API Key

Set ASSEMBLYAI_API_KEY in your runtime environment, or pass the key explicitly in the adapter config.

AssemblyAI references used for this adapter design:

https://www.assemblyai.com/docs/speech-to-text/streaming

Show 2 more

https://www.assemblyai.com/docs/streaming/universal-streaming

https://www.assemblyai.com/docs/universal-streaming/turn-detection

Outcomes

What you can build

Build on the supported package contract

Use @absolutejs/voice-assemblyai through its supported public entry points.

Hardening checklist

Production guidance

Make every external boundary explicitPin the deployed @absolutejs/voice-assemblyai version, replace example or memory-backed dependencies with durable implementations, bound external calls, protect credentials, and emit enough evidence to retry or recover safely.

Follow in order

Troubleshooting path

1
Trace from the first failed boundary
Reproduce the smallest canonical @absolutejs/voice-assemblyai example, confirm the supported entry point and version in the API explorer, then inspect the first boundary that did not produce its documented result.

#Setup

Partial snippet

Working example for Setup.

TS
import { assemblyai } from "@absolutejs/voice-assemblyai";

const stt = assemblyai({
  apiKey: process.env.ASSEMBLYAI_API_KEY!,
  speechModel: "universal-streaming-english",
  formatTurns: true,
});

#Public entry points

Supported entry points declared by this package manifest.

Package entry point declared in package.json.

@absolutejs/voice-assemblyai@absolutejs/voice-assemblyai/manifest@absolutejs/voice-assemblyai/manifest.json

#Package commands

Scripts declared by this package manifest.

bun run buildrm -rf dist && bun build ./src/index.ts ./src/manifest.ts --outdir dist --target bun --external @absolutejs/manifest --external '@absolutejs/manifest/*' --external @absolutejs/voice --external '@absolutejs/voice/*' --external @sinclair/typebox --external '@sinclair/typebox/*' && tsc --emitDeclarationOnly --project tsconfig.json && absolute-manifest emit
bun run check:packagebun run format && bun run typecheck && bun run test && bun run verify-package && bun run build && bun run verify-package --artifacts
bun run formatprettier --write "./**/*.{js,ts,json,md}"
bun run testbun test
bun run typecheckbun run tsc --noEmit

#API reference

Search the declarations exported by the current package type files. Expand a symbol to inspect its source-backed signature.

3 symbols
assemblyaiexportPermalinkSource
TS
assemblyai
Exported from @absolutejs/voice-assemblyai