You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
DOC: Document server_vad and ServerVadConfig on the Realtime Target page #4501
RealtimeTarget uses server-side voice activity detection (VAD) to decide when the speaker has finished a turn. The server_vad constructor argument accepts True (default tuning), False, or a ServerVadConfig with custom tuning. ServerVadConfig is exported from pyrit.prompt_target, but the Realtime Target page does not mention server_vad or the config at all.
ServerVadConfig has three fields:
Field
Default
Valid range
threshold
0.4
0.0 to 1.0
prefix_padding_ms
200
0 or more
silence_duration_ms
1500
0 or more
What to change
Add a short section to doc/code/targets/realtime_target.py that covers:
What server-side VAD does for a realtime conversation, and what each of the three fields controls. Take the meaning of the fields from the RealtimeTarget code and the Realtime API documentation, and link the latter.
When someone would change the defaults (for example, audio with long pauses that gets cut off early).
A code example constructing RealtimeTarget(server_vad=ServerVadConfig(...)), and a sentence on what server_vad=False does.
Executing this notebook needs a Realtime API endpoint. If you have none, make the same edit by hand in both the .py and .ipynb files without re-executing the notebook, and say so in the PR.
Done when
The page explains server_vad and ServerVadConfig with a construction example.
The field names, defaults and ranges match the code.
The .py and .ipynb files match, and pre-commit passes.
Read the class and its unit tests first, and describe only what the code does today.
Keep the text short and concrete. Lead with when someone would use the class, then show the smallest example that works.
pre-commit runs the doc validation hooks; they must pass.
How to contribute
Claim it first. Before you start, comment on this issue to say you are taking it.
First comment wins. If yours is the first claim comment, go ahead and open a PR; you do not need to wait for a reply. If someone has already commented, this issue is taken, so please pick a different one.
I’d like to take this one. I’ll add a short server-side VAD section to the Realtime Target page covering server_vad and ServerVadConfig, with an example. I don’t have a Realtime endpoint, so I’ll edit the .py and .ipynb by hand and say so in the PR.
Activity
seung-waedet commentedon Nov 21, 2026
I’d like to take this one. I’ll add a short server-side VAD section to the Realtime Target page covering server_vad and ServerVadConfig, with an example. I don’t have a Realtime endpoint, so I’ll edit the .py and .ipynb by hand and say so in the PR.