# Verbi is a speech-to-text API It listens to a recording or a live feed and hands back words your code can use: who said what, when, and how surely. - Send a file. One HTTP call, one complete transcript back. - Let Verbi listen live. Over a WebSocket, each utterance arrives about a second after the pause that ends it. **Verbi bills only for the speech it hears. Silence is free.** **And it hears more than words:** music, singing and everyday sounds — a knock, a cough, a barking dog, laughter, typing — each with the moment it started and ended, in files and live streams alike. No need to ask, and no extra charge. Verbi also tells speakers apart, times every word with confidence and spots the language — all of that in 25 European languages — naturally, by default. Ask, and it writes SRT/VTT captions and spells your rare names right from a glossary. Free tier: 2 speech-h/mo, or 10 speech-h/mo + a one-time 20 h welcome with a verified email. After that: flat $0.10 USD per speech-hour, prepaid — $1 minimum (10 hours). Getting started: nothing to set up on your side — no GPU, no model downloads, no scaling, no on-call. Integrate using the recipes below, or, easier still, ask your agent. Limits: - 2 transcriptions at a time without a verified email, 10 with one, 25 once paid. - Verbi reads no faster than it transcribes: a faster upload simply waits. The socket takes audio at no more than twice real time: a file goes by HTTP. What Verbi does not do, so you find out now rather than in week three: no word-by-word realtime ASR (the unit is a complete utterance, delivered about a second after it ends); no lyrics — sung vocals are kept out of the transcript and the bill, and under mode=vad_diar_off, which transcribes everything, lyrics come out poorly; no SOC 2 or standing DPA yet; speaker labels are measured in-house, not independently audited; no scoped or short-lived keys — every key acts for the whole account, so an app you ship to users reaches Verbi through your own server. The live demo on https://verbi.services can show its captions translated; that translation comes from a third-party service and is not a feature of Verbi. That's all there is to it. This page is what you need to evaluate Verbi, try it and decide: recipes first, then the reference. What comes up once you run it every day — reconnecting, files of any length, a speaker registry, what happens while Verbi scales up — is on a second page: https://verbi.services/tips-and-quirks.txt. And there's no retention policy to read, because **nothing is ever retained** — not the audio, not the transcript, not a voiceprint — less to worry about. Write to contact@verbi.services — or POST /v1/contact from a script — with anything: feedback, a bug, a gap in this file, a feature you want. And if a limit, the throughput or the price is in your way, say so: committed-volume plans raise or remove limits and come with volume discounts, and complex custom integrations are possible too. And if you have recordings with transcripts you trust, we can **tune the model on your own recordings** to match your vocabulary and transcript style, and serve it to your account alone. The recordings are needed for about an hour and then deleted. Your first tune is free — just ask. Terms https://verbi.services/terms · Privacy https://verbi.services/privacy · OpenAPI https://verbi.services/api/openapi.yaml ## Recipes ### Common options They work with every recipe — query parameters on the URL (the socket URL too), and one header, which on a socket goes in the start message instead: X-Glossary: ["SunTrust","paracetamol","Kühne + Nagel"] (socket: "glossary" in the start message) up to 100 rare terms, spelled the way you want them back, free. BOOST RARE TERMS ONLY: names, brands, jargon — an ordinary word can hijack a similar-sounding rare one. A bad term rejects the request before anything is billed. ?track=1 a different audio track of a multi-track video (0-based; default: the container's default track) ?channel=left one side of a stereo call instead of the downmix (left, right, or 0-based indices; several = a submix); send the file once per side and add mode=diar_off when the channel already says who spoke. Speakers are told apart by voice by default, never by channel ?captions=srt,vtt ready-to-publish caption files rendered from the word timestamps, free; the response carries them as {"captions": {"srt": ..., "vtt": ...}} ?speakers=4 how many people talk, when you know it — or a range, speakers=3-5 (which helps when: Speakers, in the reference) ?stable-names=true speaker names drawn from the voice, so a voice tends to keep its name across your files, captions included ?max_billed_speech_sec=600 stop this request at the last whole utterance inside the budget; the response says so ("capped": true) ?cost_center=site_17 tag the request; GET /v1/usage?since=&until= then reports what each label was billed (a label is an opaque id, never a name or email) ?mode=diar_off everything but speakers · ?mode=vad_diar_off everything decoded, full duration billed ?events=music,knock speech events always, plus only these other kinds (music, vocals and the sounds below; absent: every kind, the sounds included; events=speech_only: speech alone) — events_settled_upto then waits on those kinds alone (music ~1.2 s behind the audio, vocals ~4 s, a sound about a second plus its minimum length); the bill is the same whatever is reported; under vad_diar_off there are no speech events Sounds, reported by default (events=speech_only, or a list without them, turns them off): dog (barking, howling, whimpering), cat (meowing, purring), cough (coughs and sneezes), snoring, typing (a keyboard, a typewriter), water (a tap, a sink, a bath, pouring, a toilet flush), appliance (a hair dryer, a vacuum cleaner, an electric shaver or toothbrush), knock, shouting (screams, shouts, yells, cheering), laughter, rain, bird (birdsong and calls, wings), dishes (dishes, pots and pans, cutlery), siren (police, ambulance, fire engine and civil-defence sirens), doorbell, phone (a ringing telephone, a ringtone), crying (a baby or an adult crying, sobbing, whimpering). They say what the recording contained: detected from the audio signal only, indicative, not a substitute for human verification — a quiet or brief sound may be missed, and a sound can read as music too. ### API key Every recipe reads it from VERBI_KEY. Mint one once — no email, no card, the free tier starts immediately: VERBI_KEY=$(curl -s -XPOST "https://verbi.services/v1/signup" | python3 -c 'import sys,json;print(json.load(sys.stdin)["api_key"])') && export VERBI_KEY ### Transcribe a file Use cases: turn an interview or podcast into searchable text · give an agent word timestamps for quotations · transcribe a video as it is. Send the bytes, get one JSON object back: text, words with timestamps and confidence, speaker labels, music spans, billed seconds. A call takes up to 4 hours of audio and is billed only when the object is delivered, so a cut costs nothing. For a file of any length ask for parts: the folder recipe on the second page does. import os, requests KEY = os.environ["VERBI_KEY"] # your api key with open("episode.mp3", "rb") as f: r = requests.post("https://verbi.services/v1/transcribe", headers={"Authorization": f"Bearer {KEY}"}, data=f, timeout=(60, 120)) # (connect and each write, between-bytes) if not r.text.strip(): raise RuntimeError(f"HTTP {r.status_code}, empty body: retry") # Verbi at capacity out = r.json() # leading whitespace is fine if "error_code" in out: raise RuntimeError(out["error_code"]) print(out["text"], out["billed_speech_sec"]) #### Example single-response output The first 90 seconds of this NASA film, as one JSON object: https://images.nasa.gov/details/NHQ_2019_1219_How%20We%20Are%20Going%20to%20the%20Moon%20-%204K Abridged — most words and the token elided. The same 90 seconds streamed are on the second page, laid out the same way. { "text": "Mm-hmm. Between 1968 and 1972, America launched nine human missions to the moon, six of which successfully touched down, allowing 12 men to walk on the lunar surface. ...", "words": [{"word": "Mm-hmm.", "start": 0.18, "end": 0.725, "confidence": 0.0, "speaker": "Calm Wren"}, {"word": "Between", "start": 1.05, "end": 1.61, "confidence": 0.8776, "speaker": "Calm Wren"}, ...], "audio_events": [{"id": 1, "kind": "speech", "start": 0.18, "end": 37.275, "text": "..."}, {"id": 2, "kind": "music", "start": 4.78, "end": 89.98}, {"id": 3, "kind": "speech", "start": 38.47, "end": 89.995, "text": "..."}], "speaker_turns": [{"id": 1, "start": 0.18, "end": ..., "speaker": "Calm Wren"}, ...], "speaker_count": 1, "speakers": [{"speaker": "Calm Wren", "word_count": 246, "total_speech_sec": 88.3, "keys": ["Calm Wren"]}], "diar_state": "...", "audio_duration_sec": 90.0, "billed_speech_sec": 88.295, "billed_speech_hours": 0.0245, "speech_ratio": 0.981, "speech_segment_count": 2, "language": "en", "mode": "default", "engine": "verbi-2026-11-11.1", "speaker_engine": "verbi-spk-2026-11-24.1", "request_id": "51f5605-44", ... } ### Transcribe a live source Use cases: follow a broadcast, a radio channel or an RTSP/RTMP feed as it airs · feed a listening agent complete utterances from a microphone · give a robot hearing — voice commands, keyword triggers, reactions to speech or music starting · show the wearer of glasses or a badge, all day, what is said around them and what else is sounding. Use ffmpeg to feed a microphone, stream or recording to this client as 16 kHz mono PCM (the command above the code). It prints each frame as it arrives, one JSON object per line. The client for a capture that runs all day — it reconnects, carries speaker state across and resumes from the last transcribed second — is on the second page, with the browser version and the notes for devices. #### Stream # ffmpeg -v error -i -f s16le -ar 16000 -ac 1 - \ # | python3 live.py > transcript.ndjson (pip install websockets) import asyncio, json, os, sys, websockets KEY = os.environ["VERBI_KEY"] # your api key URL = "wss://verbi.services/v1/transcribe" # query parameters go here WAV = (b"RIFF\xff\xff\xff\xffWAVEfmt \x10\x00\x00\x00" b"\x01\x00\x01\x00\x80>\x00\x00\x00}\x00\x00\x02\x00\x10\x00" b"data\xff\xff\xff\xff") # 16 kHz mono PCM16, open-ended async def main(): async with websockets.connect(URL) as ws: await ws.send(json.dumps({"type": "start", "api_key": KEY})) await ws.send(WAV) async def pump(): # stdin to the socket, 100 ms a frame while chunk := await asyncio.to_thread(sys.stdin.buffer.read, 3200): await ws.send(chunk) await ws.send(json.dumps({"type": "end"})) # the source ended: keep reading asyncio.ensure_future(pump()) # send and read at the same time async for msg in ws: # frames back, one JSON object each frame = json.loads(msg) print(json.dumps(frame), flush=True) if frame["type"] == "error": sys.exit(frame["error_code"]) if frame["type"] == "final": return sys.exit("the socket closed without a final frame") asyncio.run(main()) ## Reference The contract also has a human-readable rendering at https://verbi.services/redoc. The figures in this reference are as of November 2026, with Verbi already running at full pace. A section this page points to and does not hold (Scaling up, Checkpointed delivery, Usage reports) is on the second page, https://verbi.services/tips-and-quirks.txt. ### Base address and authentication The base address is https://verbi.services. Every authenticated call carries the header `Authorization: Bearer `; a socket that cannot set headers, such as a browser's, sends the key in its start message instead (see The WebSocket). Everything is synchronous: the answer comes back on the same connection that asked, with no jobs and no polling. The single-response form is POST /v1/transcribe, which answers with one JSON object. The stream form is a WebSocket on the same path (see "The WebSocket" below). ### Billing Hours are drawn in a fixed order: the monthly allowance first, then the welcome grant, then paid credit. Monthly hours reset every 30 days on the account's own cycle and unused ones expire; the welcome grant never expires. The allowance, the credit and the concurrency belong to the account, not to a key: extra keys add no hours. The field `used_this_period_hours` counts the free allowance only. Paid credit is prepaid in whole hours through POST /v1/billing/topup, with a minimum of 10 hours = $1.00. Payment goes through a hosted Stripe Checkout page (no card data passes through Verbi), and the hours are credited when the checkout completes. ### Modes The `?mode=` parameter chooses what runs: - `default`: the speech meter plus diarization. - `diar_off`: the speech meter, no speakers. - `vad_diar_off`: no speech detection and no speakers. The audio is cut into chunks of about 15 s (never over 19 s), each at the quietest nearby point, and everything is decoded, singing included. The model is not built for lyrics and transcribes them poorly. Sound that is not speech can come back as stray words too, about 65 per hour of such sound. The full duration is billed, silence and music included; to pay only for speech, use the default mode. The transcript arrives in segments that are those chunks, not utterances, and carry no speech event id; music, vocals and the sounds are reported as `?events` selects them, as in every mode. It is several times faster (see Speed), and it is meant for callers who run their own VAD. The response reports the mode that ran. ### The speech meter What is billed is the detected speech in which Verbi makes out words, each segment in full except the longer pauses inside it, which are not billed: an utterance can run longer than the speech it bills, so a segment's `billed_speech_sec` can be shorter than its span. A speech segment in which no words can be made out (a breath, an unintelligible mumble) bills 0 and is not sent on the stream, although its speech event still opens and closes. A speech event in which no words could be made out closes with `empty: true`. Everyday sounds without speech bring back no words and bill nothing: across 20 recordings of sirens, doorbells, knocking, rain, running water and a barking dog, not one word and not one billed second. The one exception is `vad_diar_off` (see Modes). Every result carries `audio_duration_sec`, `billed_speech_sec` and `speech_ratio`, and the ratio is ≤1. Exactly `billed_speech_sec` is drawn from the balance. The single response, each part and the final frame also carry the same bill in the balance's unit, `billed_speech_hours` (4 decimals, like `remaining_hours`), and `billed_speech_hours_total` beside `billed_speech_sec_total` where they carry one, so a bill subtracts from `remaining_hours` without converting. The same audio sent twice usually bills the same seconds and can differ by up to about half a percent. To plan a budget: on recordings that are mostly talk (earnings calls, court arguments, hearings, meetings, radio programs, broadcast debates) the bill comes to between 84 % and 93 % of the running time; a recording with more silence or music bills less. `?max_billed_speech_sec` (see Limits) is the hard ceiling. Music is dropped from the bill only when it is confidently music without speech; when in doubt it is transcribed and billed. Sung vocals count as music: in `default` and `diar_off` they are kept out of the transcript and the bill. Rap, speech-rhythm vocals and dialogue over music are kept. Instrumental music bills at most 8 % of its runtime. Under `vad_diar_off` there is no meter: singing is transcribed and billed like everything else, and lyrics come out poorly. ### Delivery is billing A single response is charged only when the final object is delivered: a cut or failed request is free, so retry it. Stream frames are billed as they are delivered. On a disconnect or an in-stream error, what was delivered stays billed and the rest is not billed. A service failure bills nothing further. Each transcript segment carries its own `billed_speech_sec`. Each transcript frame carries `billed_speech_sec`, what that frame billed, and `billed_speech_sec_total`, the request's running total including that frame. A cut stream has no terminal frame, so the last `billed_speech_sec_total` seen is the bill. Budgets are always billed seconds, never wall time. ### Speed Live, over the socket: an utterance ends at a short pause, and its text arrives about a second after its last word; about 1 in 10 may wait more than two seconds. Text arrives per utterance and is final; `partials=true` also shows the one being spoken. Talk that runs on without a pause is handed over where a sentence ends; after 6 s, where a clause ends; after 10 s, at the first silence of a tenth of a second; and a stretch with none of those is split at 19 s, at the quietest point of its last 6 s. With `?mode=vad_diar_off` there is no pause or phrase detection: audio is transcribed in chunks of about 15 s, delivered as they come. A file sent as one HTTP call (either file recipe) transcribes at about 50 times real time, or about 250 times with `?mode=vad_diar_off`: an hour-long recording comes back in a little over a minute. That is a long file's pace: a clip of a few seconds comes back in about a second, and no answer takes less than about half a second. Files running in parallel share the service, so with 25 files transcribing concurrently their speeds add up to about 300 times real time in total, or over 1,000 times with `?mode=vad_diar_off` — about six minutes for that hour when 24 other files are running alongside it. Set the deadline accordingly. The first byte comes in under 1 s; then keep-alive whitespace arrives about every 5 s until the object. Set the read timeout to at least 60 s between bytes, never as a total. Set the write timeout to tens of seconds: an upload may be held back while Verbi catches up, and a paused write is backpressure, not a fault; a shared socket has one timeout. Python's `requests` applies its connect timeout to each upload write, so that is the one to set. The same audio on the same engine may differ in under 1 % of words (casing, punctuation, digits); cache the result if you need byte-identical output. ### Model and languages The model is a modified parakeet-ultra by Moondream (https://huggingface.co/moondream/parakeet-ultra), which is NVIDIA Parakeet-TDT 0.6B v3 (https://huggingface.co/nvidia/parakeet-tdt-0.6b-v3) trained further. It is used under CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). On the nine public test sets of the Open ASR Leaderboard (https://huggingface.co/spaces/hf-audio/open_asr_leaderboard), scored with the leaderboard's own normalizer, Verbi's word error rate averages 5.50 % for a file and 5.59 % live, level with the Parakeet-TDT models it is built on. Live text has a file's quality: on the same audio the stream and the file agree to within a tenth of a point. Your audio is not those sets, so measure on the free tier. There are 25 languages, detected automatically, with no parameter to set: Bulgarian, Croatian, Czech, Danish, Dutch, English, Estonian, Finnish, French, German, Greek, Hungarian, Italian, Latvian, Lithuanian, Maltese, Polish, Portuguese, Romanian, Russian, Slovak, Slovenian, Spanish, Swedish, Ukrainian. Text comes back in each language's native script. A short utterance on its own can start with a lower-case letter. Evaluation is deepest in English. Accuracy varies by language: on European Parliament speeches Spanish, French, Portuguese and Romanian come out best, most others close to English, and Greek, Dutch, Maltese, Swedish and Slovenian noticeably weaker. The language fields classify the output text. ### Limits A call without a delivery interval takes up to 240 minutes (4 hours) of audio. The cap is the shape's, not the service's: a one-object response is billed only when it is delivered, so the cap bounds what a lost connection can cost in re-upload and keeps the object a size any client parses — and it is the longest delivery interval. With `?delivery_interval_sec` a file has no length cap: each part is delivered and billed as it is transcribed, so a lost connection costs at most the undelivered part. With `parts_after_upload=true` the parts held until the upload has been read to its end cover up to 24 hours of audio (see Checkpointed delivery). The stream has no cap either: utterances are delivered and billed as they decode. `?max_billed_speech_sec=` bounds the billed speech of one request (for example, 10 h of audio at 7200 bills at most 2 speech-hours). The request stops at the last whole utterance under the ceiling, bills that prefix, and decodes nothing past it. The response or terminal frame carries `max_billed_speech_sec` and `capped`; `capped_reason="max_billed_speech_sec"` appears only when the ceiling was hit; and when capped, `audio_duration_sec` is the audio metered up to the stop. Bad syntax gets 400 INVALID_MAX_BILLED_SPEECH. Concurrency 2 in-flight transcriptions for anonymous accounts, 10 for email-verified, 25 once the account has paid. The limit is per account and shared by its keys, and the strongest rung earned applies: paying earns 25 without an email, and verifying an email later adds hours only. A request over the cap gets an immediate 429 with `retry_after_sec` and is never queued. A dead request frees its slot within about 2 min, and a standing capture holds one slot. /v1/billing reports `concurrency_limit`. Contracted accounts differ. The signup cap is 3 new accounts per 30 days per network (an office, campus or VPN egress shares one), anonymous and email signups together. Verifying an email or minting keys is not a signup. Up to 8 speakers, the count is within one of the true count in at least 5 of 6 recordings of a human-annotated reference set: broadcast talk in clips of up to a few minutes (VoxConverse). In a long conversation where people talk over each other it runs low (see Speakers). More than 8 is not promised; a meeting is counted by default, and a roster maximum (see Speakers) only caps it; a larger room, a parliament sitting or a hearing with dozens of speakers, is counted as well, usually to within a few of the true number. The speaker figures above are Verbi's own measurements; no third party has audited them. ### Data Audio, transcripts and voice embeddings exist only inside the request (a stream deletes delivered content as it goes), and none of it is ever used for training. The one exception is by arrangement: recordings and transcripts you send to have a model tuned for you train that model only, and are deleted when the tuning is done, which takes about an hour for 30 hours of recordings and under two for 100. To correct speaker labels, a stream keeps the id, start, end and speaker of each speaker span it sent until it ends, never words or audio. What is kept: the account record (the key hash, the email and its verification state), billing metadata (audio and billed seconds, timing, `cost_center`), the signup-network counters, admin audit entries and the email you send to support; never content. Voice memory across requests is the client's own `diar_state`: its keys in the clear, its voice evidence sealed and opened only by Verbi, and stored nowhere by Verbi. Deleting your copy is the deletion. Processing takes place on servers in the United States (the subprocessors are listed in the privacy policy). There is no SOC 2 or ISO 27001 certification, no standing DPA (ask for one), and no self-serve SLA. Committed volume brings discounts, raised or removed caps, faster turnaround, and an SLA with credits. By arrangement, Verbi can tune the model on recordings and transcripts you provide and serve it to your account alone. Under a compliance regime, use Verbi for the audio it does not cover (development, testing, QA, evaluation). ### Endpoints All endpoints take the Bearer key unless marked public; request and response bodies are in the OpenAPI document. - GET /health, public: liveness, `single_response_max_file_minutes`, `scaling` (see Scaling up), and `engine` and `speaker_engine`, so both ids can be read without sending audio. - GET /v1/pricing, public: prices, limits, the free tier, the modes, `engine` and `speaker_engine`. - POST /v1/signup, public: mints a key; an optional {"email"} sends the verification mail. - GET /v1/verify?token=, public: the link in that mail. - POST /v1/verify/resend. - POST /v1/email with {"email"}: attaches an address to an anonymous account (which keeps the anonymous grants until the address is verified). - GET /v1/billing: the account id, the plan, `email_verified`, `payment_verified` (whether a payment has been completed), the balances, the hours used this period, `remaining_hours`, the period's reset time and `concurrency_limit` (this one is authoritative). - GET /v1/usage?since=&until=. - POST /v1/contact with {"message"}, plus an optional "kind" (free text, for example feedback|bug|question) and an optional "reply_to": it reaches a human. - POST /v1/billing/topup with {"hours":N≥10 whole}. - GET and POST /v1/keys, and DELETE /v1/keys/{key_id}: ≤10 active keys on one shared balance. The secret is shown once, when the key is minted. Rotation, or a leak, is: mint, swap, revoke. The last key cannot be revoked. - POST /v1/transcribe: the raw audio is the body. ### Input Verbi takes anything ffmpeg decodes: wav, mp3, m4a, opus, ogg, flac, webm, and video in mp4/webm/mkv/mov. Audio is decoded as it arrives and never seeked, so in the MP4 family the metadata must be at the front; otherwise the answer is EMPTY_AUDIO with the fix (ffmpeg -i in.m4a -c copy -movflags +faststart out.m4a). Everything is normalized to 16 kHz mono 16-bit PCM, and a WAV that already is that passes through untranscoded. A live WAV declares the data-chunk size 0xFFFFFFFF; its 44-byte header for 16 kHz mono PCM16, in hex: 52494646 ffffffff 57415645 666d7420 10000000 0100 0100 803e0000 007d0000 0200 1000 64617461 ffffffff. Opus at 24 kbit/s is as accurate as that PCM at about a tenth of the bytes, so it is the efficient upload for files and live sources alike. By default the container's default track is used and all channels are downmixed. Speakers are told apart by voice, never by channel, and stereo is never billed twice. - `?track=<0–31>` picks a track. - `?channel=<1–8 of left|right|0–31>`: one channel means that channel, several mean a submix; absent means all channels; empty gets a 400. - Per-channel transcription is one request per channel. - The selection is echoed back (a channel as indices). - A well-formed selection the file does not have gets the verdict TRACK_NOT_FOUND or CHANNEL_NOT_FOUND, and nothing is billed. ### Query parameters Parameter names are exact: case-sensitive and untrimmed. A parameter present but empty is an error, and no parameter may appear twice. The socket URL takes the identical parameters, except `delivery_interval_sec` and `parts_after_upload`, which it refuses. - `mode` - `captions=srt|vtt|srt,vtt` - `stable-names=true|false` (default false) - `events` (see Common options) - `speakers=` or `speakers=-` (1–100): an exact count or a range (see Speakers). - `delivery_interval_sec=` (600 to 14400, the cap): the transcript in parts — one complete object per that many seconds of audio, cut at the next piece boundary (never inside a word), delivered and billed as each part is transcribed, as NDJSON lines; see Checkpointed delivery. - `parts_after_upload=true|false` (default false; only with `delivery_interval_sec`, otherwise 400 INVALID_PARAM): with `true` no part is written until the upload has been read to its end, then the parts come in order, each billed as it is delivered; see Checkpointed delivery. - `cost_center` - `max_billed_speech_sec` - `track=<0–31>` (see Input) - `channel=` (see Input) ### Headers - X-Glossary. - X-Verbi-Diar-State. - X-Correlation-Id: ≤128 printable ASCII characters, echoed on every response and error but the empty 503 (see Errors); only a fingerprint of it is stored. It is the id to quote when a cut response never delivered its `request_id`. On a socket the same three go in the start message as the fields "glossary", "diar_state" and "correlation_id", and `events` may ride there too (spelled as on the URL; given in both places, the values must be identical). A repeated parameter, or a repeated Authorization, X-Verbi-Diar-State, X-Glossary or X-Correlation-Id header, gets 400 INVALID_PARAM. ### Glossary The glossary is a JSON array of ≤100 terms. It is free, per request and stateless; multi-word and non-ASCII terms are fine. Common words gain nothing and can hijack similar rare ones. Write the spelling you want back. The recognizer is steered by the spoken form, and your spelling is restored where those words occur together, exactly and only there (& and + are read "and"; a term spoken as several words comes back as spoken). A term needs ≥2 letters or digits; the character rules are in the OpenAPI document. An empty, over-long or unrepresentable term, >100 terms, or two terms spoken identically get 400 INVALID_GLOSSARY (with `invalid_terms` and `invalid_chars`) before anything is billed. An accepted glossary has every term applied (`glossary_applied`). ### Speakers Diarization runs by default and is free (`?mode=diar_off` skips it). Words carry `speaker` (the display key), and the response carries `speakers`; stream words carry none, and the spans name their speaker (see Stream frames). Continuity is the `diar_state`: one entry per speaker, with the key-set in cleartext and the voice evidence sealed (only Verbi reads it, and Verbi stores none of it). `speaker_turns` lists the speech as spans {id, start, end, speaker}, the same on the single response and the stream. Speech spans never overlap each other. On the single response a word's own `speaker` is its label; at the edge of a turn it can differ from the span drawn over that moment. Where two people talk at once a word still has one speaker, since the transcript is one stream of words, and the second voice is a span of its own marked `"overlap": true`, holding no words, over the part of the first speaker's speech it talks over. For a recording that fits one HTTP call (up to 4 hours), that call's speaker labels are final when they arrive: the whole file is clustered once, after the audio ends. The utterance stream (the socket) labels each voice from what it has heard so far: its first labels come after about 30–60 s of speech, and from then on a voice that matches no one it knows gets a label of its own after about 4 s of its speech, and each clustering pass, and the end of the stream, corrects labels already sent (see Stream frames). Most corrections fall on voices heard for under about two minutes so far; once a voice has been heard for two minutes or more, only about 4–7 % of its labeled speech changes; each speech span on the stream says how long its speaker had been heard (`heard_sec`, see Stream frames). A client that applies the corrections ends with labels as accurate as one call's; one that ignores them keeps the labels as first sent, which are noticeably worse, and some corrections come only in the final frame. On the VoxConverse test set (232 recordings) the labels score 11.8 % diarization error rate, on one call and on a stream with its corrections applied. That set is broadcast talk, where people mostly take turns: your audio is not that set, so measure on the free tier. A stream that ends before its first labels are due gets them in its final frame. Opened with a `diar_state` token, a stream labels the voices the token holds within a few seconds of their speech. If you know exactly how many people speak, or a range, say so. It matters most for two-person calls. For meetings, the default counts the room itself; a roster maximum only caps it. An exact count is the number of people who talk at length, not everyone present: the single response labels that many voices, and when some of them say only a few words it reaches the number by splitting a main voice. A range bounds the count without fixing it; keep its low end at or below the number of people who talk at length, or it forces the same split. When one voice comes back under two labels, an exact count is the hint that can merge them. `?speakers=2` is an exact count, `?speakers=3-5` a range: whole numbers 1–100 in plain digits, on the single response, its parts and the stream. The response repeats it as `speakers_requested` {min,max}, next to `speaker_count`. The single response never labels more speakers than the top, and merging phantom speakers never goes below the low end, but `speaker_count` can still be lower when fewer people speak words. The stream holds to the top from its first frame (corrections applied; a speaker a merge retired stays in the survivor's `keys`) and never splits a voice to reach the low end. A value outside that grammar, a low end above the high end, or `speakers` under a `mode` other than default gets 400 INVALID_PARAM. Where speaker labels go wrong (on VoxConverse and AMI): - A voice with under about 30 s of speech in the whole recording gets a label of its own only about half the time, on the single response and the stream alike; otherwise its words go to another speaker. - The stream counts too many speakers in about half of two-person recordings. If you know it is a two-person call, send `speakers=2`. - With five to eight voices, the single response's count can differ between two sends of the same file. Send the range you know in `speakers` to bound it. And on long conversational recordings: - Around a table where four to seven people talk over each other for 20–30 minutes, expect labels for the three or four voices that carry the conversation; the others' words go to those. - A voice that dominates a long recording can come back under two labels. If you know how many people talk at length, an exact `speakers` count can undo it. `?stable-names=true` derives names from the voice, salted per account: best effort, and never comparable across accounts. Labels are acoustic estimates, not identity. ### Captions Captions are complete srt and vtt strings built from the word timestamps; request every format you need at once. Cues break at sentence ends, speaker changes, long pauses and length. With diarization, the speaker's display key (or your renamed key) opens that speaker's turn (keys are new on every unrelated request; `stable-names=true` lets a voice keep its name across files); under `diar_off` and `vad_diar_off` there are no prefixes (to subtitle, use default: under `vad_diar_off` music can surface as caption text). A cue is ≤2 lines × 42 chars and ≤7 s; cues never overlap; reading time is bought from silence at 20 chars/s; no words are dropped (layout details are in the OpenAPI document). & < > are escaped as entities. Words and renamed keys are untrusted text. On a stream, a cue waits for its speaker label. That delays the start only: the first captions come with the stream's first labels, after about 30–60 s of speech, and from then on a cue follows its text. Under `diar_off` no cue waits for a label. ### The JSON response The body is leading whitespace and then one object; check `error_code` even on a 200. The fields: - `text`. - `words` [{word,start,end,confidence,speaker?}]: times are seconds in the original audio. Starts are within ±0.2 s; ends are clamped to the speech region. `speaker` is present only with diarization. `confidence` is a good right/wrong signal on clean speech and a weak one on music-bedded audio. - `language` and `language_confidence`: the dominant language of the output text, ISO 639-1, and [0,1]; both are omitted when the text is too short. - `language_segments`, only when ≥2 languages occur: [{start,end,language,confidence}], sentence-level runs. - `speaker_turns` [{id,start,end,speaker,overlap?}] (with diarization): the speech spans and the second voices, in time order (see Speakers). - `speaker_count` and `speakers` [{speaker,word_count,total_speech_sec,keys?}]: `total_speech_sec` is the time the speaker's spans cover, a shared moment counting for both speakers; `keys` is the full key-set. `speakers_requested` {min,max} is the request's `speakers`, present when it was sent. - `diar_state` (when diarization ran and heard a speaker) and `diar_state_reused` (when a token was presented). - `audio_duration_sec`, `billed_speech_sec`, `billed_speech_hours` (the same bill in hours, 4 decimals), `speech_ratio`, `mode`. - `audio_events` [{id,kind,start,end,...}], chronological, ids 1..N: speech, music, vocals and the sounds (what each kind means is on the second page). - `events_settled_upto`: below it, no event of a reported kind can still open (in the JSON response it equals the duration; it is absent when no reported kind is detected: under `vad_diar_off` with `speech_only`). - `engine`: an opaque id, the same for every mode, which changes if and only if the engine changes. The engine is what makes the words, their times, the bill and the events; speaker labeling has its own id, `speaker_engine`. Every response carries it, a silent file's too, and that one bills nothing except under `vad_diar_off`. - `speaker_engine` (with diarization): an opaque id for the speaker labeling, which changes if and only if the speaker labeling changes. The same id can still label the same audio slightly differently. - `track` and `channel` (when sent). - `max_billed_speech_sec` and `capped` (when a ceiling was sent), and `capped_reason` (only when capped). - `remaining_hours`: an estimate (/v1/billing is authoritative). - `speech_segment_count`: the number of speech events, whatever `events` reports. - `scaling_up: true` when Verbi was scaling up while it decoded this response's utterances; absent otherwise (see Scaling up). - `request_id`. - `timing` {processing_sec, rtfx, plus queue/upload/latency diagnostics — OpenAPI}. - `captions` {"srt","vtt"} when requested. - `glossary_applied` when X-Glossary was sent. ### Stream frames A normal end is zero or more frames and then exactly one terminal frame (final or error). A transport cut has no terminal frame. Delivered content is deleted on the server, so keep every delta. type=transcript: `segments_delivered` is cumulative including this frame and never decreases. `segments` [{event_id?,start,end,text,words,billed_speech_sec,language?,language_confidence?}]: each is a new stretch, in order, sent once and never revised; join them with spaces. Frames that carry only captions omit `segments`. Speaker labels that arrive with no text go out as type=turns {speaker_turns} instead of a transcript frame: the first clustering pass's history, a later pass labeling text already delivered, a correction, or a second voice. A frame with segments carries `wait_sec` and `time_to_delta_sec`. type=event {id,kind:speech|music|vocals|a sound,edge:open|close,t}. A close adds `duration_sec` (its t minus the open's) and `duration_sec_total` (the running total for the same kind). That is a duration, not a bill: the bill is on the transcript segments. A speech close adds `empty: true` when no words could be made out during the event. Each edge is sent once, the open first, when it is final. The kinds settle independently, so sort by t: speech opens about 2 s after onset or with its first decoded piece, music about 2 s after it starts, vocals about 4 s (its minimum passage is 3 s), and a sound about a second after it has run its kind's minimum length. type=partial {start,end,text,words,speaker?,heard_sec?}, with `partials=true` (query or start message): the utterance being spoken, as heard so far. Each replaces the last; a frame with segments ends it. Never billed or kept; see tips-and-quirks.txt. type=stats, about every 10 s: `window_sec` 60, rolling wait_* and delta_latency_* figures, service health only; it can be ignored. type=diar_state {diar_state: the token, speakers, pass}: re-issued as the state advances, and always before the first transcript or turns frame that shows a new speaker. `speaker_turns` [{id,start,end,speaker,heard_sec?,overlap?}] are span deltas, not per-segment labels; ids are integers in delivery order, per connection. Hold spans by id: a span with an id you hold replaces that span, and a span once sent never disappears. There is no overlay by time: spans of two speakers that overlap mean both spoke, and one speaker's spans never overlap each other. A span is sent again under its id when the same speaker's speech extends it (a later end), or as a correction: a clustering pass or a merge of two voices changed the speaker of speech already labeled. The final frame's `speaker_turns` carries only the updates since the frame before, the corrections the end of the stream makes among them; hold state by id from the first frame. Its `speakers` summary counts the spans as you hold them after it. The first spans come after about 30–60 s of speech (covering earlier speech retroactively), then within about a frame. Stream words carry no speaker: a word takes the speaker of the span without `overlap` that covers most of it (the earlier one when two cover it equally) or, when none covers any of it, of the span whose middle is nearest the word's — the labelling script on the second page does this. For speaker labels on a recording that fits one HTTP call (up to 4 hours) rather than a live source, send it as that call (see Speakers). The captions on frames are cue deltas. Each speech span on the stream carries `heard_sec`: how many seconds of its speaker's speech lie before the span's start, in the spans as you hold them once that frame is applied (0 for a voice heard for the first time). A re-sent span carries it afresh, so a correction gives it for the speaker it now names. A second voice carries none. It tells which labels are still settling: on public corpora (VoxConverse, AMI), labels sent with under 30 s heard were later corrected about a quarter of the time, and with 120 s or more only about 4–7 % of the time. It is a hint, not a guarantee: no figure makes a label final. The single response's spans carry none, since its labels are final when they arrive. type=final: the last segments and cues plus the totals: `audio_duration_sec`, `billed_speech_sec` (its own last segments'), `billed_speech_sec_total` (the request's), `speech_ratio`, `mode`, `engine`, `speaker_engine` (with diarization on), `speech_segment_count`, `timing`, `speaker_turns` (its updates, by id; with diarization on always present, an empty list when there are none), `speakers` with `total_speech_sec` and keys but no word counts, `captions_corrections` (captioned streams, when the end of the stream corrected a cue), `language` (a word-weighted vote), `remaining_hours`, `request_id`, and the cap, selection and state fields. It never carries text or events. type=error: the error fields and `request_id` only. ### The WebSocket The socket is wss://verbi.services/v1/transcribe: the same path and query parameters as the POST (all but `delivery_interval_sec` and `parts_after_upload`), whose headers travel in the start message (below). It carries the utterance stream — the home of audio that arrives over time — and it is the only transport that does; the POST delivers objects, one or one per interval (see Checkpointed delivery). It takes audio at no more than twice real time: a client that sends faster is held back by back-pressure (its sends stall), never refused; a file belongs on the POST. Start: the first text frame is {"type":"start","api_key","glossary","diar_state","correlation_id","events","partials"}, where everything but "type" is optional. A client that can set headers may send them on the upgrade and skip the start message. A value given in both places must be identical. Unknown fields are refused, and ?key= in the URL is refused. A socket that stays silent for 30 s after the upgrade is closed. Audio: binary frames carry the request-body bytes, in order, about 100 ms each, in any accepted container (MediaRecorder WebM/Opus chunks concatenate correctly). The efficient shape is Opus at 24 kbit/s in chunks of about 100 ms (MediaRecorder audioBitsPerSecond 24000; ffmpeg -c:a libopus -b:a 24k -page_duration 100000): as accurate and as quick to text as 16 kHz mono PCM16 behind a WAV header with both sizes 0xFFFFFFFF, at about a tenth of the bytes. {"type":"end"} marks the end of the audio (sent before any audio, it is an empty request and gets EMPTY_AUDIO). It also ends the open utterance at once: a push-to-talk client sends it when the key is released, one socket per press, and does not wait for a pause. Keep the socket open until the final frame: closing is disconnecting (what was delivered is billed). Audio after the end message, or any other text frame, gets 4400. Silence: no audio for 30 s before the end message, while Verbi is reading, is treated as a disconnect (the socket closes with 1000 and no frame; a clean end always sends its final frame first). Send silence when the source is quiet; it is audio, and it is not billed. Out: text frames, one JSON object each. A clean end closes with 1000. The `request_id` rides the upgrade response (X-Request-Id) and the reason of every close except 1012. Refusals: one {"type":"error",...} frame with the usual envelope, then a close with 4000+status (4401, 4402, 4429 with `retry_after_sec`, 4400; 4500 is a server failure). ### Errors Classify an error by what failed, never by when. The envelope is the HTTP status plus {error_code,error_message,request_id} (on a socket: one error frame, then a close with 4000+status); nothing was processed or billed. For example, `?mode=fast` gets a 400 with {"error_code": "INVALID_MODE", "error_message": "mode must be one of: default, diar_off, vad_diar_off", "request_id": "..."} The ones a transcription client handles: - 401 UNAUTHORIZED - 402 QUOTA_EXCEEDED (the balance is exhausted; it carries a payment block) - 429 TOO_MANY_CONCURRENT (with `retry_after_sec`) - 429 SIGNUP_LIMIT - 403 ACCOUNT_SUSPENDED - 400 INVALID_PARAM (it names the offender and the rule), INVALID_MODE, INVALID_GLOSSARY (with `invalid_terms` and `invalid_chars`), INVALID_DIAR_STATE, INVALID_MAX_BILLED_SPEECH, INVALID_COST_CENTER, INVALID_TRACK / INVALID_CHANNEL (grammar or range) - 503 SERVICE_UNAVAILABLE (back off and retry) - When Verbi is at capacity it can hold a request for up to about 40 s and then answer 503 with an EMPTY body and no request_id (a socket's upgrade fails the same way): treat it like any 503; nothing was billed. Verdicts are answers where the audio was accepted (a 200) and the terminal object or frame carries `error_code`: - EMPTY_AUDIO: nothing decodable (MP4 metadata at the end gets the remux hint; HTTP chunk framing inside the body gets the curl hint). - FILE_TOO_LONG: over 240 minutes (4 hours) on the single response; nothing is billed. It arrives once Verbi has read past the 4 hours, minutes into the request. The stream has no cap. With `parts_after_upload=true`: the parts held passed 24 hours of audio before the upload's end was read; nothing is billed. - UPLOAD_STALLED: no body bytes for 30 s before the body's end; the message says how many arrived. The single response bills nothing; a stream keeps billed only the frames it delivered. - TRACK_NOT_FOUND / CHANNEL_NOT_FOUND: nothing billed. - QUOTA_EXCEEDED: the speech exceeds the balance mid-request; delivered frames stay billed. - ACCOUNT_SUSPENDED: the account was suspended while the request ran; it is cut within 40 s and delivered frames stay billed. On a socket the error frame is followed by a close with 4403. - PROCESSING_FAILED. Retrying: on a 429 wait `retry_after_sec`; on a 502 or 503 back off (an empty-bodied 503 included). A cut single response is retried (it was not billed); a cut stream is a new request that may repeat paid audio. A connection that is reset before any response arrives billed nothing: connect again. Never retry a verdict.