strands.experimental.bidi.models
¶
Bidirectional model interfaces and implementations.
strands.experimental.bidi.models.model
¶
Bidirectional streaming model interface.
Defines the abstract interface for models that support real-time bidirectional communication with persistent connections. Unlike traditional request-response models, bidirectional models maintain an open connection for streaming audio, text, and tool interactions.
Features:
- Persistent connection management with connect/close lifecycle
- Real-time bidirectional communication (send and receive simultaneously)
- Provider-agnostic event normalization
- Support for audio, text, image, and tool result streaming
BidiModel
¶
Bases: Protocol
Protocol for bidirectional streaming models.
This interface defines the contract for models that support persistent streaming connections with real-time audio and text communication. Implementations handle provider-specific protocols while exposing a standardized event-based API.
Attributes:
| Name | Type | Description |
|---|---|---|
config |
dict[str, Any]
|
Configuration dictionary with provider-specific settings. |
Source code in strands/experimental/bidi/models/model.py
30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 | |
receive()
¶
Receive streaming events from the model.
Continuously yields events from the model as they arrive over the connection. Events are normalized to a provider-agnostic format for uniform processing. This method should be called in a loop or async task to process model responses.
The stream continues until the connection is closed or an error occurs.
Yields:
| Name | Type | Description |
|---|---|---|
BidiOutputEvent |
AsyncIterable[BidiOutputEvent]
|
Standardized event objects containing audio output, transcripts, tool calls, or control signals. |
Source code in strands/experimental/bidi/models/model.py
73 74 75 76 77 78 79 80 81 82 83 84 85 86 | |
send(content)
async
¶
Send content to the model over the active connection.
Transmits user input or tool results to the model during an active streaming session. Supports multiple content types including text, audio, images, and tool execution results. Can be called multiple times during a conversation.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
content
|
BidiInputEvent | ToolResultEvent
|
The content to send. Must be one of:
|
required |
Example
await model.send(BidiTextInputEvent(text="Hello", role="user"))
await model.send(BidiAudioInputEvent(audio=bytes, format="pcm", sample_rate=16000, channels=1))
await model.send(BidiImageInputEvent(image=bytes, mime_type="image/jpeg", encoding="raw"))
await model.send(ToolResultEvent(tool_result))
Source code in strands/experimental/bidi/models/model.py
88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 | |
start(system_prompt=None, tools=None, messages=None, **kwargs)
async
¶
Establish a persistent streaming connection with the model.
Opens a bidirectional connection that remains active for real-time communication. The connection supports concurrent sending and receiving of events until explicitly closed. Must be called before any send() or receive() operations.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
system_prompt
|
str | None
|
System instructions to configure model behavior. |
None
|
tools
|
list[ToolSpec] | None
|
Tool specifications that the model can invoke during the conversation. |
None
|
messages
|
Messages | None
|
Initial conversation history to provide context. |
None
|
**kwargs
|
Any
|
Provider-specific configuration options. |
{}
|
Source code in strands/experimental/bidi/models/model.py
43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 | |
stop()
async
¶
Close the streaming connection and release resources.
Terminates the active bidirectional connection and cleans up any associated resources such as network connections, buffers, or background tasks. After calling close(), the model instance cannot be used until start() is called again.
Source code in strands/experimental/bidi/models/model.py
64 65 66 67 68 69 70 71 | |
BidiModelTimeoutError
¶
Bases: Exception
Model timeout error.
Bidirectional models are often configured with a connection time limit. Nova sonic for example keeps the connection open for 8 minutes max. Upon receiving a timeout, the agent loop is configured to restart the model connection so as to create a seamless, uninterrupted experience for the user.
Source code in strands/experimental/bidi/models/model.py
117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 | |
__init__(message, **restart_config)
¶
Initialize error.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
message
|
str
|
Timeout message from model. |
required |
**restart_config
|
Any
|
Configure restart specific behaviors in the call to model start. |
{}
|
Source code in strands/experimental/bidi/models/model.py
125 126 127 128 129 130 131 132 133 134 | |
strands.experimental.bidi.models.gemini_live
¶
Gemini Live API bidirectional model provider using official Google GenAI SDK.
Implements the BidiModel interface for Google's Gemini Live API using the official Google GenAI SDK for simplified and robust WebSocket communication.
Key improvements over custom WebSocket implementation:
- Uses official google-genai SDK with native Live API support
- Simplified session management with client.aio.live.connect()
- Built-in tool integration and event handling
- Automatic WebSocket connection management and error handling
- Native support for audio/text streaming and interruption
BidiGeminiLiveModel
¶
Bases: BidiModel
Gemini Live API implementation using official Google GenAI SDK.
Combines model configuration and connection state in a single class. Provides a clean interface to Gemini Live API using the official SDK, eliminating custom WebSocket handling and providing robust error handling.
Source code in strands/experimental/bidi/models/gemini_live.py
54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 | |
__init__(model_id='gemini-2.5-flash-native-audio-preview-09-2025', provider_config=None, client_config=None, **kwargs)
¶
Initialize Gemini Live API bidirectional model.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
model_id
|
str
|
Model identifier (default: gemini-2.5-flash-native-audio-preview-09-2025) |
'gemini-2.5-flash-native-audio-preview-09-2025'
|
provider_config
|
dict[str, Any] | None
|
Model behavior (audio, inference) |
None
|
client_config
|
dict[str, Any] | None
|
Authentication (api_key, http_options) |
None
|
**kwargs
|
Any
|
Reserved for future parameters. |
{}
|
Source code in strands/experimental/bidi/models/gemini_live.py
62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 | |
receive()
async
¶
Receive Gemini Live API events and convert to provider-agnostic format.
Source code in strands/experimental/bidi/models/gemini_live.py
192 193 194 195 196 197 198 199 200 201 202 203 | |
send(content)
async
¶
Unified send method for all content types. Sends the given inputs to Google Live API.
Dispatches to appropriate internal handler based on content type.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
content
|
BidiInputEvent | ToolResultEvent
|
Typed event (BidiTextInputEvent, BidiAudioInputEvent, BidiImageInputEvent, or ToolResultEvent). |
required |
Raises:
| Type | Description |
|---|---|
ValueError
|
If content type not supported (e.g., image content). |
Source code in strands/experimental/bidi/models/gemini_live.py
373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 | |
start(system_prompt=None, tools=None, messages=None, **kwargs)
async
¶
Establish bidirectional connection with Gemini Live API.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
system_prompt
|
str | None
|
System instructions for the model. |
None
|
tools
|
list[ToolSpec] | None
|
List of tools available to the model. |
None
|
messages
|
Messages | None
|
Conversation history to initialize with. |
None
|
**kwargs
|
Any
|
Additional configuration options. |
{}
|
Source code in strands/experimental/bidi/models/gemini_live.py
135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 | |
stop()
async
¶
Close Gemini Live API connection.
Source code in strands/experimental/bidi/models/gemini_live.py
470 471 472 473 474 475 476 477 478 479 480 481 482 | |
strands.experimental.bidi.models.nova_sonic
¶
Nova Sonic bidirectional model provider for real-time streaming conversations.
Implements the BidiModel interface for Amazon's Nova Sonic, handling the complex event sequencing and audio processing required by Nova Sonic's InvokeModelWithBidirectionalStream protocol.
Nova Sonic specifics:
- Hierarchical event sequences: connectionStart → promptStart → content streaming
- Base64-encoded audio format with hex encoding
- Tool execution with content containers and identifier tracking
- 8-minute connection limits with proper cleanup sequences
- Interruption detection through stopReason events
BidiNovaSonicModel
¶
Bases: BidiModel
Nova Sonic implementation for bidirectional streaming.
Combines model configuration and connection state in a single class. Manages Nova Sonic's complex event sequencing, audio format conversion, and tool execution patterns while providing the standard BidiModel interface.
Attributes:
| Name | Type | Description |
|---|---|---|
_stream |
DuplexEventStream
|
open bedrock stream to nova sonic. |
Source code in strands/experimental/bidi/models/nova_sonic.py
89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 | |
__init__(model_id='amazon.nova-sonic-v1:0', provider_config=None, client_config=None, **kwargs)
¶
Initialize Nova Sonic bidirectional model.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
model_id
|
str
|
Model identifier (default: amazon.nova-sonic-v1:0) |
'amazon.nova-sonic-v1:0'
|
provider_config
|
dict[str, Any] | None
|
Model behavior (audio, inference settings) |
None
|
client_config
|
dict[str, Any] | None
|
AWS authentication (boto_session OR region, not both) |
None
|
**kwargs
|
Any
|
Reserved for future parameters. |
{}
|
Source code in strands/experimental/bidi/models/nova_sonic.py
102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 | |
receive()
async
¶
Receive Nova Sonic events and convert to provider-agnostic format.
Raises:
| Type | Description |
|---|---|
RuntimeError
|
If start has not been called. |
Source code in strands/experimental/bidi/models/nova_sonic.py
279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 | |
send(content)
async
¶
Unified send method for all content types. Sends the given content to Nova Sonic.
Dispatches to appropriate internal handler based on content type.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
content
|
BidiInputEvent | ToolResultEvent
|
Input event. |
required |
Raises:
| Type | Description |
|---|---|
ValueError
|
If content type not supported (e.g., image content). |
Source code in strands/experimental/bidi/models/nova_sonic.py
315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 | |
start(system_prompt=None, tools=None, messages=None, **kwargs)
async
¶
Establish bidirectional connection to Nova Sonic.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
system_prompt
|
str | None
|
System instructions for the model. |
None
|
tools
|
list[ToolSpec] | None
|
List of tools available to the model. |
None
|
messages
|
Messages | None
|
Conversation history to initialize with. |
None
|
**kwargs
|
Any
|
Additional configuration options. |
{}
|
Raises:
| Type | Description |
|---|---|
RuntimeError
|
If user calls start again without first stopping. |
Source code in strands/experimental/bidi/models/nova_sonic.py
179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 | |
stop()
async
¶
Close Nova Sonic connection with proper cleanup sequence.
Source code in strands/experimental/bidi/models/nova_sonic.py
451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 | |
strands.experimental.bidi.models.openai_realtime
¶
OpenAI Realtime API provider for Strands bidirectional streaming.
Provides real-time audio and text communication through OpenAI's Realtime API with WebSocket connections, voice activity detection, and function calling.
OPENAI_MAX_TIMEOUT_S = 3000
module-attribute
¶
Max timeout before closing connection.
OpenAI documents a 60 minute limit on realtime sessions (docs). However, OpenAI does not emit any warnings when approaching the limit. As a workaround, we configure a max timeout client side to gracefully handle the connection closure. We set the max to 50 minutes to provide enough buffer before hitting the real limit.
BidiOpenAIRealtimeModel
¶
Bases: BidiModel
OpenAI Realtime API implementation for bidirectional streaming.
Combines model configuration and connection state in a single class. Manages WebSocket connection to OpenAI's Realtime API with automatic VAD, function calling, and event conversion to Strands format.
Source code in strands/experimental/bidi/models/openai_realtime.py
79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 | |
__init__(model_id=DEFAULT_MODEL, provider_config=None, client_config=None, **kwargs)
¶
Initialize OpenAI Realtime bidirectional model.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
model_id
|
str
|
Model identifier (default: gpt-realtime) |
DEFAULT_MODEL
|
provider_config
|
dict[str, Any] | None
|
Model behavior (audio, instructions, turn_detection, etc.) |
None
|
client_config
|
dict[str, Any] | None
|
Authentication (api_key, organization, project) Falls back to OPENAI_API_KEY, OPENAI_ORGANIZATION, OPENAI_PROJECT env vars |
None
|
**kwargs
|
Any
|
Reserved for future parameters. |
{}
|
Source code in strands/experimental/bidi/models/openai_realtime.py
90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 | |
receive()
async
¶
Receive OpenAI events and convert to Strands TypedEvent format.
Source code in strands/experimental/bidi/models/openai_realtime.py
423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 | |
send(content)
async
¶
Unified send method for all content types. Sends the given content to OpenAI.
Dispatches to appropriate internal handler based on content type.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
content
|
BidiInputEvent | ToolResultEvent
|
Typed event (BidiTextInputEvent, BidiAudioInputEvent, BidiImageInputEvent, or ToolResultEvent). |
required |
Raises:
| Type | Description |
|---|---|
ValueError
|
If content type not supported (e.g., image content). |
Source code in strands/experimental/bidi/models/openai_realtime.py
703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 | |
start(system_prompt=None, tools=None, messages=None, **kwargs)
async
¶
Establish bidirectional connection to OpenAI Realtime API.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
system_prompt
|
str | None
|
System instructions for the model. |
None
|
tools
|
list[ToolSpec] | None
|
List of tools available to the model. |
None
|
messages
|
Messages | None
|
Conversation history to initialize with. |
None
|
**kwargs
|
Any
|
Additional configuration options. |
{}
|
Source code in strands/experimental/bidi/models/openai_realtime.py
180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 | |
stop()
async
¶
Close session and cleanup resources.
Source code in strands/experimental/bidi/models/openai_realtime.py
772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 | |