Skip to content

Commit 738735b

Browse files
xitzhangXiting Zhang
andauthored
[VoiceLive] Release 1.2.0b1 - Add MCP support (#44013)
* ADD MCP support * fix docs --------- Co-authored-by: Xiting Zhang <xitzhang@microsoft.com>
1 parent 0e4a03b commit 738735b

File tree

9 files changed

+1134
-70
lines changed

9 files changed

+1134
-70
lines changed

sdk/ai/azure-ai-voicelive/CHANGELOG.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,18 @@
11
# Release History
22

3+
## 1.2.0b1 (2025-11-14)
4+
5+
### Features Added
6+
7+
- **MCP (Model Context Protocol) Support**: Added comprehensive support for Model Context Protocol integration:
8+
- `MCPServer` tool type for defining MCP server configurations with authorization, headers, and approval requirements
9+
- `MCPTool` model for representing MCP tool definitions with input schemas and annotations
10+
- `MCPApprovalType` enum for controlling approval workflows (`never`, `always`, or tool-specific)
11+
- New item types: `MCPApprovalResponseRequestItem`, `ResponseMCPApprovalRequestItem`, `ResponseMCPApprovalResponseItem`, `ResponseMCPCallItem`, and `ResponseMCPListToolItem`
12+
- New server events: `ServerEventMcpListToolsInProgress`, `ServerEventMcpListToolsCompleted`, `ServerEventMcpListToolsFailed`, `ServerEventResponseMcpCallArgumentsDelta`, and `ServerEventResponseMcpCallArgumentsDone`
13+
- Client event `MCP_APPROVAL_RESPONSE` for responding to approval requests
14+
- Enhanced `ItemType` enum with MCP-related types: `mcp_list_tools`, `mcp_call`, `mcp_approval_request`, and `mcp_approval_response`
15+
316
## 1.1.0 (2025-11-03)
417

518
### Features Added

sdk/ai/azure-ai-voicelive/apiview-properties.json

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,9 @@
5454
"azure.ai.voicelive.models.InputTextContentPart": "VoiceLive.InputTextContentPart",
5555
"azure.ai.voicelive.models.InputTokenDetails": "VoiceLive.InputTokenDetails",
5656
"azure.ai.voicelive.models.LogProbProperties": "VoiceLive.LogProbProperties",
57+
"azure.ai.voicelive.models.MCPApprovalResponseRequestItem": "VoiceLive.MCPApprovalResponseRequestItem",
58+
"azure.ai.voicelive.models.MCPServer": "VoiceLive.MCPServer",
59+
"azure.ai.voicelive.models.MCPTool": "VoiceLive.MCPTool",
5760
"azure.ai.voicelive.models.OpenAIVoice": "VoiceLive.OpenAIVoice",
5861
"azure.ai.voicelive.models.OutputTextContentPart": "VoiceLive.OutputTextContentPart",
5962
"azure.ai.voicelive.models.OutputTokenDetails": "VoiceLive.OutputTokenDetails",
@@ -70,6 +73,10 @@
7073
"azure.ai.voicelive.models.ResponseFunctionCallItem": "VoiceLive.ResponseFunctionCallItem",
7174
"azure.ai.voicelive.models.ResponseFunctionCallOutputItem": "VoiceLive.ResponseFunctionCallOutputItem",
7275
"azure.ai.voicelive.models.ResponseIncompleteDetails": "VoiceLive.ResponseIncompleteDetails",
76+
"azure.ai.voicelive.models.ResponseMCPApprovalRequestItem": "VoiceLive.ResponseMCPApprovalRequestItem",
77+
"azure.ai.voicelive.models.ResponseMCPApprovalResponseItem": "VoiceLive.ResponseMCPApprovalResponseItem",
78+
"azure.ai.voicelive.models.ResponseMCPCallItem": "VoiceLive.ResponseMCPCallItem",
79+
"azure.ai.voicelive.models.ResponseMCPListToolItem": "VoiceLive.ResponseMCPListToolItem",
7380
"azure.ai.voicelive.models.ResponseMessageItem": "VoiceLive.ResponseMessageItem",
7481
"azure.ai.voicelive.models.ResponseSession": "VoiceLive.ResponseSession",
7582
"azure.ai.voicelive.models.ResponseTextContentPart": "VoiceLive.ResponseTextContentPart",
@@ -87,6 +94,9 @@
8794
"azure.ai.voicelive.models.ServerEventInputAudioBufferCommitted": "VoiceLive.ServerEventInputAudioBufferCommitted",
8895
"azure.ai.voicelive.models.ServerEventInputAudioBufferSpeechStarted": "VoiceLive.ServerEventInputAudioBufferSpeechStarted",
8996
"azure.ai.voicelive.models.ServerEventInputAudioBufferSpeechStopped": "VoiceLive.ServerEventInputAudioBufferSpeechStopped",
97+
"azure.ai.voicelive.models.ServerEventMcpListToolsCompleted": "VoiceLive.ServerEventMcpListToolsCompleted",
98+
"azure.ai.voicelive.models.ServerEventMcpListToolsFailed": "VoiceLive.ServerEventMcpListToolsFailed",
99+
"azure.ai.voicelive.models.ServerEventMcpListToolsInProgress": "VoiceLive.ServerEventMcpListToolsInProgress",
90100
"azure.ai.voicelive.models.ServerEventResponseAnimationBlendshapeDelta": "VoiceLive.ServerEventResponseAnimationBlendshapeDelta",
91101
"azure.ai.voicelive.models.ServerEventResponseAnimationBlendshapeDone": "VoiceLive.ServerEventResponseAnimationBlendshapeDone",
92102
"azure.ai.voicelive.models.ServerEventResponseAnimationVisemeDelta": "VoiceLive.ServerEventResponseAnimationVisemeDelta",
@@ -103,6 +113,8 @@
103113
"azure.ai.voicelive.models.ServerEventResponseDone": "VoiceLive.ServerEventResponseDone",
104114
"azure.ai.voicelive.models.ServerEventResponseFunctionCallArgumentsDelta": "VoiceLive.ServerEventResponseFunctionCallArgumentsDelta",
105115
"azure.ai.voicelive.models.ServerEventResponseFunctionCallArgumentsDone": "VoiceLive.ServerEventResponseFunctionCallArgumentsDone",
116+
"azure.ai.voicelive.models.ServerEventResponseMcpCallArgumentsDelta": "VoiceLive.ServerEventResponseMcpCallArgumentsDelta",
117+
"azure.ai.voicelive.models.ServerEventResponseMcpCallArgumentsDone": "VoiceLive.ServerEventResponseMcpCallArgumentsDone",
106118
"azure.ai.voicelive.models.ServerEventResponseOutputItemAdded": "VoiceLive.ServerEventResponseOutputItemAdded",
107119
"azure.ai.voicelive.models.ServerEventResponseOutputItemDone": "VoiceLive.ServerEventResponseOutputItemDone",
108120
"azure.ai.voicelive.models.ServerEventResponseTextDelta": "VoiceLive.ServerEventResponseTextDelta",
@@ -132,6 +144,7 @@
132144
"azure.ai.voicelive.models.PersonalVoiceModels": "VoiceLive.PersonalVoiceModels",
133145
"azure.ai.voicelive.models.OutputAudioFormat": "VoiceLive.OutputAudioFormat",
134146
"azure.ai.voicelive.models.ToolType": "VoiceLive.ToolType",
147+
"azure.ai.voicelive.models.MCPApprovalType": "VoiceLive.MCPApprovalType",
135148
"azure.ai.voicelive.models.AnimationOutputType": "VoiceLive.AnimationOutputType",
136149
"azure.ai.voicelive.models.InputAudioFormat": "VoiceLive.InputAudioFormat",
137150
"azure.ai.voicelive.models.TurnDetectionType": "VoiceLive.TurnDetectionType",

sdk/ai/azure-ai-voicelive/azure/ai/voicelive/_version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,4 @@
66
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
77
# --------------------------------------------------------------------------
88

9-
VERSION = "1.1.0"
9+
VERSION = "1.2.0b1"

sdk/ai/azure-ai-voicelive/azure/ai/voicelive/models/__init__.py

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,9 @@
6363
InputTextContentPart,
6464
InputTokenDetails,
6565
LogProbProperties,
66+
MCPApprovalResponseRequestItem,
67+
MCPServer,
68+
MCPTool,
6669
MessageContentPart,
6770
MessageItem,
6871
OpenAIVoice,
@@ -80,6 +83,10 @@
8083
ResponseFunctionCallOutputItem,
8184
ResponseIncompleteDetails,
8285
ResponseItem,
86+
ResponseMCPApprovalRequestItem,
87+
ResponseMCPApprovalResponseItem,
88+
ResponseMCPCallItem,
89+
ResponseMCPListToolItem,
8390
ResponseMessageItem,
8491
ResponseSession,
8592
ResponseStatusDetails,
@@ -98,6 +105,9 @@
98105
ServerEventInputAudioBufferCommitted,
99106
ServerEventInputAudioBufferSpeechStarted,
100107
ServerEventInputAudioBufferSpeechStopped,
108+
ServerEventMcpListToolsCompleted,
109+
ServerEventMcpListToolsFailed,
110+
ServerEventMcpListToolsInProgress,
101111
ServerEventResponseAnimationBlendshapeDelta,
102112
ServerEventResponseAnimationBlendshapeDone,
103113
ServerEventResponseAnimationVisemeDelta,
@@ -114,6 +124,8 @@
114124
ServerEventResponseDone,
115125
ServerEventResponseFunctionCallArgumentsDelta,
116126
ServerEventResponseFunctionCallArgumentsDone,
127+
ServerEventResponseMcpCallArgumentsDelta,
128+
ServerEventResponseMcpCallArgumentsDone,
117129
ServerEventResponseOutputItemAdded,
118130
ServerEventResponseOutputItemDone,
119131
ServerEventResponseTextDelta,
@@ -146,6 +158,7 @@
146158
InputAudioFormat,
147159
ItemParamStatus,
148160
ItemType,
161+
MCPApprovalType,
149162
MessageRole,
150163
Modality,
151164
OpenAIVoiceName,
@@ -212,6 +225,9 @@
212225
"InputTextContentPart",
213226
"InputTokenDetails",
214227
"LogProbProperties",
228+
"MCPApprovalResponseRequestItem",
229+
"MCPServer",
230+
"MCPTool",
215231
"MessageContentPart",
216232
"MessageItem",
217233
"OpenAIVoice",
@@ -229,6 +245,10 @@
229245
"ResponseFunctionCallOutputItem",
230246
"ResponseIncompleteDetails",
231247
"ResponseItem",
248+
"ResponseMCPApprovalRequestItem",
249+
"ResponseMCPApprovalResponseItem",
250+
"ResponseMCPCallItem",
251+
"ResponseMCPListToolItem",
232252
"ResponseMessageItem",
233253
"ResponseSession",
234254
"ResponseStatusDetails",
@@ -247,6 +267,9 @@
247267
"ServerEventInputAudioBufferCommitted",
248268
"ServerEventInputAudioBufferSpeechStarted",
249269
"ServerEventInputAudioBufferSpeechStopped",
270+
"ServerEventMcpListToolsCompleted",
271+
"ServerEventMcpListToolsFailed",
272+
"ServerEventMcpListToolsInProgress",
250273
"ServerEventResponseAnimationBlendshapeDelta",
251274
"ServerEventResponseAnimationBlendshapeDone",
252275
"ServerEventResponseAnimationVisemeDelta",
@@ -263,6 +286,8 @@
263286
"ServerEventResponseDone",
264287
"ServerEventResponseFunctionCallArgumentsDelta",
265288
"ServerEventResponseFunctionCallArgumentsDone",
289+
"ServerEventResponseMcpCallArgumentsDelta",
290+
"ServerEventResponseMcpCallArgumentsDone",
266291
"ServerEventResponseOutputItemAdded",
267292
"ServerEventResponseOutputItemDone",
268293
"ServerEventResponseTextDelta",
@@ -292,6 +317,7 @@
292317
"InputAudioFormat",
293318
"ItemParamStatus",
294319
"ItemType",
320+
"MCPApprovalType",
295321
"MessageRole",
296322
"Modality",
297323
"OpenAIVoiceName",

sdk/ai/azure-ai-voicelive/azure/ai/voicelive/models/_enums.py

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ class ClientEventType(str, Enum, metaclass=CaseInsensitiveEnumMeta):
5656
RESPONSE_CREATE = "response.create"
5757
RESPONSE_CANCEL = "response.cancel"
5858
SESSION_AVATAR_CONNECT = "session.avatar.connect"
59+
MCP_APPROVAL_RESPONSE = "mcp_approval_response"
5960

6061

6162
class ContentPartType(str, Enum, metaclass=CaseInsensitiveEnumMeta):
@@ -106,6 +107,19 @@ class ItemType(str, Enum, metaclass=CaseInsensitiveEnumMeta):
106107
MESSAGE = "message"
107108
FUNCTION_CALL = "function_call"
108109
FUNCTION_CALL_OUTPUT = "function_call_output"
110+
MCP_LIST_TOOLS = "mcp_list_tools"
111+
MCP_CALL = "mcp_call"
112+
MCP_APPROVAL_REQUEST = "mcp_approval_request"
113+
MCP_APPROVAL_RESPONSE = "mcp_approval_response"
114+
115+
116+
class MCPApprovalType(str, Enum, metaclass=CaseInsensitiveEnumMeta):
117+
"""The available set of MCP approval types."""
118+
119+
NEVER = "never"
120+
"""Approval is never required."""
121+
ALWAYS = "always"
122+
"""Approval is always required."""
109123

110124

111125
class MessageRole(str, Enum, metaclass=CaseInsensitiveEnumMeta):
@@ -235,6 +249,16 @@ class ServerEventType(str, Enum, metaclass=CaseInsensitiveEnumMeta):
235249
RESPONSE_ANIMATION_VISEME_DONE = "response.animation_viseme.done"
236250
RESPONSE_FUNCTION_CALL_ARGUMENTS_DELTA = "response.function_call_arguments.delta"
237251
RESPONSE_FUNCTION_CALL_ARGUMENTS_DONE = "response.function_call_arguments.done"
252+
MCP_LIST_TOOLS_IN_PROGRESS = "mcp_list_tools.in_progress"
253+
MCP_LIST_TOOLS_COMPLETED = "mcp_list_tools.completed"
254+
MCP_LIST_TOOLS_FAILED = "mcp_list_tools.failed"
255+
RESPONSE_MCP_CALL_ARGUMENTS_DELTA = "response.mcp_call_arguments.delta"
256+
RESPONSE_MCP_CALL_ARGUMENTS_DONE = "response.mcp_call_arguments.done"
257+
MCP_APPROVAL_REQUEST = "mcp_approval_request"
258+
MCP_APPROVAL_RESPONSE = "mcp_approval_response"
259+
RESPONSE_MCP_CALL_IN_PROGRESS = "response.mcp_call.in_progress"
260+
RESPONSE_MCP_CALL_COMPLETED = "response.mcp_call.completed"
261+
RESPONSE_MCP_CALL_FAILED = "response.mcp_call.failed"
238262

239263

240264
class ToolChoiceLiteral(str, Enum, metaclass=CaseInsensitiveEnumMeta):
@@ -254,6 +278,7 @@ class ToolType(str, Enum, metaclass=CaseInsensitiveEnumMeta):
254278
"""
255279

256280
FUNCTION = "function"
281+
MCP = "mcp"
257282

258283

259284
class TurnDetectionType(str, Enum, metaclass=CaseInsensitiveEnumMeta):

0 commit comments

Comments
 (0)