Demonstrating live transcription using a local microphone

The live demo client is found in the caiman_client directory.

This script connects to a running CAIMAN-ASR server and streams audio from your microphone to the server for low-latency transcription.

Step 1: Set up the CAIMAN-ASR server

Follow the instructions provided in Inference Flow to set up the ASR server.

Step 2: Set up the client

From the repository’s root, run:

uv run --locked caiman_client --host localhost --port 3030

With the host and port of your server, --help lists the client’s options.

Prefix (punctuation/casing and language)

--prefix selects the output format and language, for example for English with a multilingual model:

uv run --locked caiman_client --host localhost --port 3030 --prefix='<pnc><lang_en>'

Quote the prefix and leave no spaces between tags. See Prefix for the prefixes a model accepts and the default.

Keyword Boosting

To boost keywords, pass them to --keywords as a space-separated list, e.g.

uv run --locked caiman_client --keywords caiman asr myrtle \
  --keyword-c0 0.3 --keyword-beta 0.9 --keyword-context-score 1.5

The --keyword-* flags override the server’s boost controls for this connection; see Keyword boosting.

Flush

Add --manual-flush to enable Enter-to-flush in an interactive terminal:

uv run --locked caiman_client --manual-flush

While recording, press Enter to finalize the current segment and continue on the same connection. The client displays [Flush complete: manual] when acknowledged. Prefix and keyword settings are retained. Press Ctrl+C to finish recording and save the audio.

Troubleshooting

If the client records from the wrong microphone, or records nothing (it stops with No audio from the microphone), choose the input device yourself:

  1. Run uv run --locked caiman_client_devices to list available input devices
  2. Try each device using (for example) uv run --locked caiman_client --input_device 5