feat:Rename enum mcp_tool_call to mcp_call; add output audio buffer events#229
feat:Rename enum mcp_tool_call to mcp_call; add output audio buffer events#229
Conversation
WalkthroughThe OpenAPI schema was updated to rename an enum value from mcp_tool_call to mcp_call and adjust its description. Additionally, three new realtime server event object types were added under x-oaiMeta: OutputAudioBufferStarted, OutputAudioBufferStopped, and OutputAudioBufferCleared. Changes
Sequence Diagram(s)sequenceDiagram
autonumber
participant C as Client
participant S as Realtime Server
Note over S: New output audio buffer lifecycle events
S-->>C: RealtimeServerEventOutputAudioBufferStarted
S-->>C: RealtimeServerEventOutputAudioBufferStopped
S-->>C: RealtimeServerEventOutputAudioBufferCleared
Note over C,S: Enum rename in tool execution
C->>S: RealtimeMCPToolExecution (type: "mcp_call")
S-->>C: Acknowledgement / result
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Poem
Pre-merge checks and finishing touches❌ Failed checks (1 inconclusive)
✅ Passed checks (2 passed)
✨ Finishing touches🧪 Generate unit tests
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 0
🧹 Nitpick comments (1)
src/libs/tryAGI.OpenAI/openapi.yaml (1)
32995-33003: Add one-line descriptions for OutputAudioBuffer union entries; add samples & client dispatch/testsVerified: event definitions, examples, generated models/enums/JsonConverters/JsonSerializerContext exist, and names match upstream (output_audio_buffer.started/stopped/cleared). The union entries in src/libs/tryAGI.OpenAI/openapi.yaml (≈lines 32995–33003) currently have only "type: object" — add brief descriptions so SDK/docs surface text. Also add e2e/sample payloads and update client event dispatch/tests to exercise these events.
Optional doc diff (apply to the union entries at the location above):
- key: RealtimeServerEventOutputAudioBufferStarted path: <auto> - type: object + type: object + description: Emitted when the output audio buffer begins accumulating frames. - key: RealtimeServerEventOutputAudioBufferStopped path: <auto> - type: object + type: object + description: Emitted when the output audio buffer stops receiving frames. - key: RealtimeServerEventOutputAudioBufferCleared path: <auto> - type: object + type: object + description: Emitted when the output audio buffer is cleared of all frames.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (2)
src/libs/tryAGI.OpenAI/Generated/tryAGI.OpenAI.Models.RealtimeMCPToolCall.g.csis excluded by!**/generated/**src/libs/tryAGI.OpenAI/Generated/tryAGI.OpenAI.Models.RealtimeMCPToolCallType.g.csis excluded by!**/generated/**
📒 Files selected for processing (1)
src/libs/tryAGI.OpenAI/openapi.yaml(2 hunks)
🔇 Additional comments (1)
src/libs/tryAGI.OpenAI/openapi.yaml (1)
22198-22201: Enum rename is a breaking wire change — confirm downstream updates and announce migration.openapi.yaml now uses
mcp_call(src/libs/tryAGI.OpenAI/openapi.yaml ≈ lines 22200); no occurrences ofmcp_tool_callwere found in the repo search and generated serializers/enums reference updated converters (e.g. src/libs/tryAGI.OpenAI/Generated/JsonSerializerContext.g.cs includes RealtimeMCPToolCallTypeJsonConverter), so the spec and generated code were changed here.Actions (choose one):
- Coordinate as a breaking change: add a changelog entry, regenerate all SDKs/clients, bump version and publish release notes/announce migration; or
- Provide backward compatibility: update JSON converters/ToEnum mappings to accept both "mcp_tool_call" and "mcp_call" for a migration window and mark the old value deprecated.
Also add the prior value to the schema for discoverability.
Minimal schema doc tweak:
- description: The type of the item. Always `mcp_call`. + description: The type of the item. Always `mcp_call`. Previously `mcp_tool_call`.Checks to run / confirm before release:
- rg -nP '\bmcp_tool_call\b' -C3
- rg -nP 'RealtimeMCPToolExecution|"\stype"\s:\s*"(mcp_tool_call|mcp_call)"' -C3
- Verify generated JsonConverters/ToEnum mappings accept required literals and regenerate SDKs/clients.
Summary by CodeRabbit
New Features
Refactor