Deployment contract
Realtime streaming and captions
Use online or two-pass WebSocket protocols for microphones, meeting captions, and continuous speech streams.
Workload boundary
Decide whether it fits your production constraints
Good fit
- Live captions
- Clients continuously send PCM audio
- Online drafts plus offline correction
Not a fit
- Complete-file transcription only
- Clients cannot handle reconnects and backpressure
- Endpoint and final-result semantics are undefined
| Models | Paraformer-online / FSMN-VAD / CT-Transformer punctuation / Fun-ASR-Nano realtime |
|---|---|
| Hardware | cpu / nvidia-gpu / kubernetes |
| Operating systems | Linux |
| Interfaces | WebSocket / Python client / C++ client / Go client |
Run path
From installation to known-audio verification
These commands come from the current verification registry. Pin dependencies, model, and hardware before rollout.
Install
pip install funasr websockets ffmpeg-python
Launch
cd runtime/python/websocket && python funasr_wss_server.py --port 10095
Health check
ss -ltn | grep 10095
Smoke test
Minimum verification before promotion
cd runtime/python/websocket && python funasr_wss_client.py --host 127.0.0.1 --port 10095 --mode 2pass --chunk_size "8,8,4" --audio_in ../../tests/test_audio/zh.wav
Operations and capacity
Move from runnable to operable
Operational checks
- Monitor active connections, queued audio seconds, and final latency
- Validate graceful disconnect and reconnect
- Pin chunk_size, VAD, and punctuation configuration
Capacity variables
- Audio duration, language, channels, and VAD segment distribution
- Concurrency, queue time, warmup, and model-cache state
- Exact hardware, driver, runtime, and thread configuration
Troubleshooting
- Start with the repository client and a fixed WAV
- Confirm PCM16, 16 kHz, mono audio
- Record draft and final-result timestamps separately
Security boundary
Treat production ingress as untrusted
- Limit origins, connections, and message size at the proxy
- Use TLS WebSocket
- Do not put long-lived credentials in URL query strings
Known limitation
Capacity depends on realtime ratio, chunks, VAD, connection count, and client backpressure; file RTFx does not replace concurrency tests.
Public benchmarks are reproduction starting points, not substitutes for target-workload testing.
Evidence and feedback