Anam
Updated
Integrate Anam AI avatars into Conversational AI Engine.
Anam provides AI-powered avatars with real-time video rendering, enabling natural video conversations with your AI agents.
Info
This integration is fully supported for use with Conversational AI Engine. While it has completed functional validation, it is newer to the platform, and additional provider-specific edge cases may be identified as usage scales across a broader range of applications and workloads.
Sample configuration
The following examples show how to configure an Anam avatar when starting a conversational AI agent.
from agora_agent import Agent
from agora_agent.agentkit.vendors import AnamAvatar
# client is your configured Agora client
agent = (
Agent(client)
.with_stt(...) # configure your STT vendor
.with_llm(...) # configure your LLM vendor
.with_tts(...) # configure your TTS vendor
.with_avatar(AnamAvatar(
api_key='your-anam-key',
persona_id='<anam_persona_id>',
))
)import { Agent, AnamAvatar } from 'agora-agents';
// client is your configured Agora client
const agent = new Agent({ client })
.withStt(/* configure your STT vendor */)
.withLlm(/* configure your LLM vendor */)
.withTts(/* configure your TTS vendor */)
.withAvatar(new AnamAvatar({
apiKey: 'your-anam-key',
personaId: '<anam_persona_id>',
}));import "github.com/AgoraIO/agora-agents-go/v2/agentkit/vendors"
// client is your configured Agora client
agent := agentkit.NewAgent(client).WithStt(/* configure your STT vendor */).
WithLlm(/* configure your LLM vendor */).
WithTts(/* configure your TTS vendor */).
WithAvatar(
vendors.NewAnamAvatar(vendors.AnamAvatarOptions{
APIKey: "your-anam-key",
PersonaID: "<anam_persona_id>",
}),
)Use the following avatar configuration in your request:
"avatar": {
"vendor": "anam",
"enable": true,
"params": {
"api_key": "<anam_key>",
"avatar_id": "960f614f-ea88-47c3-9883-f02094f70874",
"agora_uid": "<avatar_rtc_uid>",
"agora_token": "<avatar_rtc_token>",
"sample_rate": 24000,
"quality": "high",
"video_encoding": "H264"
}
}Key parameters
api_keystringThe API key used for authentication with Anam's services. Get your API key from the Anam console.
avatar_idstringThe unique identifier for the Anam avatar you want to use.
agora_uidstringThe unique identifier for the avatar's RTC connection. This must be different from other participants in the channel.
agora_tokenstringThe RTC token that authorizes the avatar to join the video channel. Generate this token using your Agora project credentials.
sample_ratenumber- Default value
- 24000
- Possible values
160002400048000
The audio sample rate in Hz.
qualitystring- Default value
- high
- Possible values
highmediumlow
The video quality level.
video_encodingstring- Default value
- H264
- Possible values
H264AV1
The video encoding format.
