Skip to content

Commit 573a7c2

Browse files
Merge branch 'release/v1_2_0' into fern-bot/2026-03-11T14-01Z
2 parents 60f844d + 7271580 commit 573a7c2

11 files changed

Lines changed: 265 additions & 126 deletions

File tree

.github/workflows/ci.yml

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
name: ci
2-
on: [push]
2+
on:
3+
push:
4+
workflow_dispatch:
35
jobs:
46
compile:
57
runs-on: ubuntu-latest
@@ -31,14 +33,15 @@ jobs:
3133
curl -sSL https://install.python-poetry.org | python - -y --version 1.5.1
3234
- name: Install dependencies
3335
run: poetry install
34-
3536
- name: Test
3637
run: poetry run pytest -rP .
3738

3839
publish:
3940
needs: [compile, test]
40-
if: github.event_name == 'push' && contains(github.ref, 'refs/tags/')
41+
if: (github.event_name == 'push' && contains(github.ref, 'refs/tags/')) || github.event_name == 'workflow_dispatch'
4142
runs-on: ubuntu-latest
43+
permissions:
44+
id-token: write
4245
steps:
4346
- name: Checkout repo
4447
uses: actions/checkout@v4
@@ -51,10 +54,9 @@ jobs:
5154
curl -sSL https://install.python-poetry.org | python - -y --version 1.5.1
5255
- name: Install dependencies
5356
run: poetry install
54-
- name: Publish to pypi
55-
run: |
56-
poetry config repositories.remote https://upload.pypi.org/legacy/
57-
poetry --no-interaction -v publish --build --repository remote --username "$PYPI_USERNAME" --password "$PYPI_PASSWORD"
58-
env:
59-
PYPI_USERNAME: ${{ secrets.PYPI_USERNAME }}
60-
PYPI_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
57+
- name: Build package
58+
run: poetry build
59+
- name: Publish to PyPI
60+
uses: pypa/gh-action-pypi-publish@release/v1
61+
with:
62+
password: ${{ secrets.PYPI_API_TOKEN }}

README.md

Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Agoraio Python Library
22

33
[![fern shield](https://img.shields.io/badge/%F0%9F%8C%BF-Built%20with%20Fern-brightgreen)](https://buildwithfern.com?utm_source=github&utm_medium=github&utm_campaign=readme&utm_source=https%3A%2F%2Fgithub.com%2FAgoraIO-Conversational-AI%2Fagent-server-sdk-python)
4-
[![pypi](https://img.shields.io/pypi/v/agora-agent-server-sdk)](https://pypi.python.org/pypi/agora-agent-server-sdk)
4+
[![pypi](https://img.shields.io/pypi/v/agent-server-sdk-python)](https://pypi.python.org/pypi/agent-server-sdk-python)
55

66
The Agora Conversational AI SDK provides convenient access to the Agora Conversational AI APIs,
77
enabling you to build voice-powered AI agents with support for both cascading flows (ASR -> LLM -> TTS)
@@ -30,7 +30,7 @@ and multimodal flows (MLLM) for real-time audio processing.
3030
## Installation
3131

3232
```sh
33-
pip install agora-agent-server-sdk
33+
pip install agent-server-sdk-python
3434
```
3535

3636
## Quick Start
@@ -155,36 +155,37 @@ A full reference for this library is available [here](https://github.com/AgoraIO
155155
For real-time audio processing using OpenAI's Realtime API or Google Gemini Live, use the MLLM (Multimodal Large Language Model) flow instead of the cascading ASR -> LLM -> TTS flow. See the [MLLM Overview](https://docs.agora.io/en/conversational-ai/models/mllm/overview) for more details.
156156

157157
```python
158-
from agora-agent-server-sdk import Agora
159-
from agora-agent-server-sdk.agents import (
158+
from agora_agent import Agora, Area
159+
from agora_agent.agentkit import (
160+
AdvancedFeatures,
161+
TurnDetectionConfig,
162+
TurnDetectionTypeValues,
163+
)
164+
from agora_agent.agents import (
160165
StartAgentsRequestProperties,
161-
StartAgentsRequestPropertiesAdvancedFeatures,
162166
StartAgentsRequestPropertiesMllm,
163167
StartAgentsRequestPropertiesMllmVendor,
164168
StartAgentsRequestPropertiesTts,
165169
StartAgentsRequestPropertiesTtsVendor,
166170
StartAgentsRequestPropertiesLlm,
167-
StartAgentsRequestPropertiesTurnDetection,
168-
StartAgentsRequestPropertiesTurnDetectionType,
169171
)
170172

171173
client = Agora(
172-
customer_id="YOUR_CUSTOMER_ID",
173-
customer_secret="YOUR_CUSTOMER_SECRET",
174+
area=Area.US,
175+
app_id="YOUR_APP_ID",
176+
app_certificate="YOUR_APP_CERTIFICATE",
174177
)
175178

176179
client.agents.start(
177-
appid="your_app_id",
180+
client.app_id,
178181
name="mllm_agent",
179182
properties=StartAgentsRequestProperties(
180183
channel="channel_name",
181184
token="your_token",
182185
agent_rtc_uid="1001",
183186
remote_rtc_uids=["1002"],
184187
idle_timeout=120,
185-
advanced_features=StartAgentsRequestPropertiesAdvancedFeatures(
186-
enable_mllm=True,
187-
),
188+
advanced_features=AdvancedFeatures(enable_mllm=True),
188189
mllm=StartAgentsRequestPropertiesMllm(
189190
url="wss://api.openai.com/v1/realtime",
190191
api_key="<your_openai_api_key>",
@@ -197,8 +198,8 @@ client.agents.start(
197198
output_modalities=["text", "audio"],
198199
greeting_message="Hello! I'm ready to chat in real-time.",
199200
),
200-
turn_detection=StartAgentsRequestPropertiesTurnDetection(
201-
type=StartAgentsRequestPropertiesTurnDetectionType.SERVER_VAD,
201+
turn_detection=TurnDetectionConfig(
202+
type=TurnDetectionTypeValues.SERVER_VAD, # deprecated; use config.end_of_speech instead
202203
threshold=0.5,
203204
silence_duration_ms=500,
204205
),

0 commit comments

Comments
 (0)