Punctuation Formatting

View as Markdown
Real-Time

Punctuation formatting controls whether transcript text is returned with punctuation and capitalization applied, or as raw lowercase text. This is enabled by default.

Enabling Punctuation Formatting

Punctuation Formatting is currently only available for the Real-Time WebSocket API.

Add the format parameter to your WebSocket connection query parameters. Options: true (default), false.

Real-Time WebSocket API

1const url = new URL("wss://api.smallest.ai/waves/v1/pulse/get_text");
2url.searchParams.append("language", "en");
3url.searchParams.append("encoding", "linear16");
4url.searchParams.append("sample_rate", "16000");
5url.searchParams.append("format", "false"); // disable formatting
6
7const ws = new WebSocket(url.toString(), {
8 headers: {
9 Authorization: `Bearer ${API_KEY}`,
10 },
11});

Example Output

With format=true (default)

1{
2 "transcript": "Hello there, how can I help you today?",
3 "is_final": true
4}

With format=false

1{
2 "transcript": "hello there how can i help you today",
3 "is_final": true
4}

When to Use

Use caseRecommended setting
Live captions and subtitlesformat=true - human-readable output
Meeting transcriptionformat=true - properly formatted text
Feeding into LLMs or NLP pipelinesformat=false - raw text avoids double-formatting
Search indexingformat=false - normalized text for consistent matching
Custom post-processingformat=false - apply your own punctuation and casing rules