Skip to main content
The self-hosted diarization stack adds speaker labels to a transcript on your own GPU servers. You post the audio and its word timestamps, and get each word’s speaker back in the same HTTP response. It’s built to follow the self-hosted Sync stack: a Sync response with word timestamps posts to it as is. Audio and transcripts never leave your network.
Self-hosting requires a commercial agreement with AssemblyAI. Contact our sales team to discuss your needs.
Everything you need to deploy and operate the stack lives in the public streaming-self-hosting-stack repository, and that repository is the source of truth. This page explains what the stack does and where to find things.

How it works

The stack is two Docker Compose services: a GPU container that serves the diarization API, and a license proxy that validates your license and reports usage. It needs an NVIDIA T4 or newer GPU with at least 16 GB of memory. To transcribe and label speakers in one deployment, run the repository’s sync-and-diarization example. It runs both services with one license proxy and one license file, on one GPU or on two.

Request and response

POST /v1/diarize takes multipart/form-data with two parts:
  • audio: the audio file.
  • transcript: JSON with a words array, where each word has text, start and end in milliseconds. A Sync STT response requested with "timestamps": true has this shape already.
The response has words and utterances, each with a speaker label (A, B, …) and a speaker_confidence, and a speakers list. The model reports at most 8 speakers. As with the Sync stack, the service doesn’t check credentials, but every request needs a non-empty Authorization header. By default the stack accepts up to 1 hour of audio and handles one request at a time. The stack’s README explains how to change both. This is a separate API from the hosted API’s speaker diarization, which you turn on with speaker_labels in a Pre-recorded STT request.

Getting started

  1. Ask your AssemblyAI representative for a license file and image-pull credentials.
  2. Complete the prerequisites in the repository README.
  3. Follow the diarization stack’s README, or the sync-and-diarization example to run it with Sync STT.

Support

For deployment questions, image access, license issues, or to report bugs, contact your AssemblyAI representative.