Skip to main content
guava.Agent is the entrypoint for creating Guava voice agents. Create an Agent instance, attach handlers, then attach to a channel.
agent.py

Constructor

Use the constructor parameters to configure your Agent’s persona and goal.
Custom pronunciations can be passed as a dictionary mapping plaintext strings to either International Phonetic Alphabet (IPA) transcriptions wrapped in slashes, e.g. /pɪˈkɑːn/, or plaintext phonetic respellings, e.g. "peekan". Inline phonetic control can be supplied using SSML: My favorite nut is the <phoneme alphabet="ipa" ph="pɪˈkɑːn">pecan</phoneme>. What's yours?
speech_speed sets how quickly the agent speaks, as one of the presets "x-slow", "slow", "medium" (the default), "fast", or "x-fast". The preset applies to every call the agent handles; use call.set_persona() to change it for a single call.

Handlers

Register handlers to control and react to the call in real-time.

Entrypoints / Channels

Attach the agent to a channel to start receiving calls.
To attach an agent to multiple channels, or run multiple agents in the same process, use guava.Runner.