okareo.augmentations
Voice simulation augmentation payload wrappers.
Import these from okareo.augmentations and pass them into
Okareo.run_simulation(..., augmentation=...).
AugmentationConfig Objects
@_attrs_define
class AugmentationConfig(_DictSerializable)
Base helper for simulation augmentation payload wrappers.
Subclasses are thin JSON shapers for simulation_params["augmentation"].
They serialize only the fields you set.
CAPAugmentation Objects
@_attrs_define
class CAPAugmentation(AugmentationConfig)
Concurrent-ask augmentation config.
Arguments:
probability- Probability that the driver emits an extra follow-up message.pause_ms- Pause duration in milliseconds before emitting the follow-up message.
DirectedSpeechAugmentation Objects
@_attrs_define
class DirectedSpeechAugmentation(AugmentationConfig)
Directed-speech augmentation config.
Arguments:
probability- Probability that directed speech is injected for a given opportunity.prompt- Optional independent prompt for the directed speech content.lpf_cutoff_hz- Low-pass filter cutoff used for off-mic speech.gain_db- Gain reduction applied to off-mic speech.start_at_turn- First turn this may fire on. Turns are counted as the CALLER's own turns -- the turns Okareo's simulated caller takes, not the agent's replies. Counting begins once the agent has said something, so ringing, dial tone, hold music and an empty greeting do not advance it. Not the transcript's turn numbering: on a call that takes a while to get going, the window opens later in the transcript than the number alone suggests. Defaults to 1 server-side, i.e. the first turn of the conversation proper.end_at_turn- Last turn this may fire on, counted the same way. Defaults to unbounded. Set it equal tostart_at_turnto narrow the window to a single turn -- but a window is only a window: theprobabilityabove is still drawn inside it, so pair a one-turn window withprobability=1.0to actually fire on that turn.prompt2 - Play the remark over the agent's next reply instead of in the caller's turn. The caller says their line as usual; the remark then overlaps the agent's reply to it and does not take a turn. Needs a connection that can interrupt the agent, as barge-in does. Defaults to off server-side.prompt3 - Withinterrupt: earliest delay, after the agent starts speaking, before the remark plays. Defaults to 200 server-side, as on barge-in. Only valid withinterrupt.prompt8 - Withinterrupt: latest such delay; at leastmin_offset_ms. Defaults to 600 server-side, as on barge-in. Only valid withinterrupt.lpf_cutoff_hz5 - Optional seed that makes the probability and offset draws reproducible.
NoiseAugmentation Objects
@_attrs_define
class NoiseAugmentation(AugmentationConfig)
Background noise augmentation config.
Arguments:
probability- Probability that background noise is applied during a run.profile- Noise profile name, e.g."cafeteria"or"traffic".snr_db- Target signal-to-noise ratio in dB.
SecondarySpeakerAugmentation Objects
@_attrs_define
class SecondarySpeakerAugmentation(AugmentationConfig)
Secondary-speaker augmentation config.
Arguments:
probability- Probability that a secondary-speaker segment is injected for a given opportunity.voice- Voice identifier for the secondary speaker.prompt- Optional independent prompt for the secondary speaker.lpf_cutoff_hz- Optional low-pass filter cutoff applied only to the secondary speaker audio.gain_db- Optional gain adjustment applied only to the secondary speaker audio.inter_speaker_pause_ms- Optional pause inserted between the primary and secondary speaker audio segments. Not valid withinterrupt, where the remark is timed from the agent's speech instead.start_at_turn- First turn this may fire on. Turns are counted as the CALLER's own turns -- the turns Okareo's simulated caller takes, not the agent's replies. Counting begins once the agent has said something, so ringing, dial tone, hold music and an empty greeting do not advance it. Not the transcript's turn numbering: on a call that takes a while to get going, the window opens later in the transcript than the number alone suggests. Defaults to 1 server-side, i.e. the first turn of the conversation proper.end_at_turn- Last turn this may fire on, counted the same way. Defaults to unbounded. Set it equal tostart_at_turnto narrow the window to a single turn -- but a window is only a window: theprobabilityabove is still drawn inside it, so pair a one-turn window withprobability=1.0to actually fire on that turn.voice6 - Play the remark over the agent's next reply instead of in the caller's turn. The caller says their line as usual; the remark then overlaps the agent's reply to it and does not take a turn. Needs a connection that can interrupt the agent, as barge-in does. Defaults to off server-side.voice7 - Withinterrupt: earliest delay, after the agent starts speaking, before the remark plays. Defaults to 200 server-side, as on barge-in. Only valid withinterrupt.prompt2 - Withinterrupt: latest such delay; at leastmin_offset_ms. Defaults to 600 server-side, as on barge-in. Only valid withinterrupt.prompt9 - Optional seed that makes the probability and offset draws reproducible.
BackchannelAugmentation Objects
@_attrs_define
class BackchannelAugmentation(AugmentationConfig)
Backchannel injection augmentation config.
Arguments:
probability- Probability that a short backchannel is injected.utterance- Optional backchannel text override, e.g."mm-hmm".min_offset_ms- Minimum delay before the injection fires.max_offset_ms- Maximum delay before the injection fires.start_at_turn- First turn this may fire on. Turns are counted as the CALLER's own turns -- the turns Okareo's simulated caller takes, not the agent's replies. Counting begins once the agent has said something, so ringing, dial tone, hold music and an empty greeting do not advance it. Not the transcript's turn numbering: on a call that takes a while to get going, the window opens later in the transcript than the number alone suggests. Defaults to 1 server-side, i.e. the first turn of the conversation proper.end_at_turn- Last turn this may fire on, counted the same way. Defaults to unbounded. Set it equal tostart_at_turnto narrow the window to a single turn -- but a window is only a window: theprobabilityabove is still drawn inside it, so pair a one-turn window withprobability=1.0to actually fire on that turn.
BargeInAugmentation Objects
@_attrs_define
class BargeInAugmentation(AugmentationConfig)
Barge-in injection augmentation config.
Arguments:
probability- Probability that a barge-in interruption is injected.replacement_text- Text to use for the interruption utterance.prompt- Optional independent prompt for the barge-in content.utterance- Optional direct text override for the injected content.min_offset_ms- Minimum delay before the injection fires.max_offset_ms- Maximum delay before the injection fires.start_at_turn- First turn this may fire on. Turns are counted as the CALLER's own turns -- the turns Okareo's simulated caller takes, not the agent's replies. Counting begins once the agent has said something, so ringing, dial tone, hold music and an empty greeting do not advance it. Not the transcript's turn numbering: on a call that takes a while to get going, the window opens later in the transcript than the number alone suggests. Defaults to 1 server-side, i.e. the first turn of the conversation proper.end_at_turn- Last turn this may fire on, counted the same way. Defaults to unbounded. Set it equal tostart_at_turnto narrow the window to a single turn -- but a window is only a window: theprobabilityabove is still drawn inside it, so pair a one-turn window withprobability=1.0to actually fire on that turn.
DropoutAugmentation Objects
@_attrs_define
class DropoutAugmentation(AugmentationConfig)
Dropout augmentation config.
Arguments:
probability- Probability (0-1) that the driver drops an entire turn: nothing is said and the target hears silence for that turn.start_at_turn- First turn this may fire on. Turns are counted as the CALLER's own turns -- the turns Okareo's simulated caller takes, not the agent's replies. Counting begins once the agent has said something, so ringing, dial tone, hold music and an empty greeting do not advance it. Not the transcript's turn numbering: on a call that takes a while to get going, the window opens later in the transcript than the number alone suggests. Defaults to 1 server-side, i.e. the first turn of the conversation proper.end_at_turn- Last turn this may fire on, counted the same way. Defaults to unbounded. Set it equal tostart_at_turnto narrow the window to a single turn -- but a window is only a window: theprobabilityabove is still drawn inside it, so pair a one-turn window withprobability=1.0to actually fire on that turn.
Augmentation Objects
@_attrs_define
class Augmentation(_DictSerializable)
Container for voice simulation augmentation strategy config.
Configure one primary strategy at a time. noise may be combined with
one additional strategy.
Example:
Augmentation(noise=NoiseAugmentation(profile="cafeteria", snr_db=10))