avartha-python-sdk 0.0.5__tar.gz → 0.0.6__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (271) hide show
  1. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/PKG-INFO +1 -1
  2. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/README.md +14 -4
  3. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/docs/compatibility.md +38 -1
  4. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/docs/migration.md +104 -7
  5. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/examples/realtime_asr.py +4 -2
  6. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/_realtime_asr.py +9 -1
  7. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/_speech_http.py +7 -1
  8. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/_speech_resources.py +47 -9
  9. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha_python_sdk.egg-info/PKG-INFO +1 -1
  10. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/LICENSE +0 -0
  11. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/MANIFEST.in +0 -0
  12. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/THIRD_PARTY_NOTICES +0 -0
  13. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/docs/platform.md +0 -0
  14. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/docs/pypi.md +0 -0
  15. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/examples/realtime.py +0 -0
  16. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/examples/tts.py +0 -0
  17. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/examples/tts_multi_context.py +0 -0
  18. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/pyproject.toml +0 -0
  19. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/setup.cfg +0 -0
  20. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/setup.py +0 -0
  21. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/__init__.py +0 -0
  22. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/_config.py +0 -0
  23. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/_exceptions.py +0 -0
  24. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/_http_errors.py +0 -0
  25. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/_models.py +0 -0
  26. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/_openai_http.py +0 -0
  27. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/_openai_http_errors.py +0 -0
  28. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/_pacing.py +0 -0
  29. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/_realtime_openai.py +0 -0
  30. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/_realtime_resources.py +0 -0
  31. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/_realtime_tts.py +0 -0
  32. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/_sentinels.py +0 -0
  33. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/_speech_config.py +0 -0
  34. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/_unsupported.py +0 -0
  35. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/_websocket.py +0 -0
  36. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/_ws_state.py +0 -0
  37. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/client.py +0 -0
  38. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/control.py +0 -0
  39. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/conversational_ai/__init__.py +0 -0
  40. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/elevenlabs.py +0 -0
  41. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/errors.py +0 -0
  42. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/openai.py +0 -0
  43. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/pagination.py +0 -0
  44. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/py.typed +0 -0
  45. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/realtime/__init__.py +0 -0
  46. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/realtime/speech.py +0 -0
  47. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/resources/__init__.py +0 -0
  48. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/resources/models.py +0 -0
  49. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/resources/realtime/__init__.py +0 -0
  50. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/resources/realtime/realtime.py +0 -0
  51. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/__init__.py +0 -0
  52. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/audio/__init__.py +0 -0
  53. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/audio/transcription_language.py +0 -0
  54. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/model.py +0 -0
  55. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/__init__.py +0 -0
  56. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/audio_transcription.py +0 -0
  57. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/audio_transcription_param.py +0 -0
  58. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_created_event.py +0 -0
  59. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_item.py +0 -0
  60. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_item_added.py +0 -0
  61. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_item_create_event.py +0 -0
  62. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_item_create_event_param.py +0 -0
  63. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_item_created_event.py +0 -0
  64. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_item_delete_event.py +0 -0
  65. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_item_delete_event_param.py +0 -0
  66. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_item_deleted_event.py +0 -0
  67. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_item_done.py +0 -0
  68. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_item_input_audio_transcription_completed_event.py +0 -0
  69. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_item_input_audio_transcription_delta_event.py +0 -0
  70. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_item_input_audio_transcription_failed_event.py +0 -0
  71. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_item_input_audio_transcription_segment.py +0 -0
  72. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_item_param.py +0 -0
  73. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_item_retrieve_event.py +0 -0
  74. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_item_retrieve_event_param.py +0 -0
  75. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_item_truncate_event.py +0 -0
  76. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_item_truncate_event_param.py +0 -0
  77. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/conversation_item_truncated_event.py +0 -0
  78. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/input_audio_buffer_append_event.py +0 -0
  79. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/input_audio_buffer_append_event_param.py +0 -0
  80. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/input_audio_buffer_clear_event.py +0 -0
  81. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/input_audio_buffer_clear_event_param.py +0 -0
  82. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/input_audio_buffer_cleared_event.py +0 -0
  83. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/input_audio_buffer_commit_event.py +0 -0
  84. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/input_audio_buffer_commit_event_param.py +0 -0
  85. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/input_audio_buffer_committed_event.py +0 -0
  86. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/input_audio_buffer_dtmf_event_received_event.py +0 -0
  87. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/input_audio_buffer_speech_started_event.py +0 -0
  88. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/input_audio_buffer_speech_stopped_event.py +0 -0
  89. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/input_audio_buffer_timeout_triggered.py +0 -0
  90. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/log_prob_properties.py +0 -0
  91. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/mcp_list_tools_completed.py +0 -0
  92. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/mcp_list_tools_failed.py +0 -0
  93. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/mcp_list_tools_in_progress.py +0 -0
  94. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/noise_reduction_type.py +0 -0
  95. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/output_audio_buffer_clear_event.py +0 -0
  96. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/output_audio_buffer_clear_event_param.py +0 -0
  97. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/rate_limits_updated_event.py +0 -0
  98. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_audio_config.py +0 -0
  99. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_audio_config_input.py +0 -0
  100. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_audio_config_input_param.py +0 -0
  101. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_audio_config_output.py +0 -0
  102. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_audio_config_output_param.py +0 -0
  103. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_audio_config_param.py +0 -0
  104. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_audio_formats.py +0 -0
  105. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_audio_formats_param.py +0 -0
  106. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_audio_input_turn_detection.py +0 -0
  107. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_audio_input_turn_detection_param.py +0 -0
  108. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_client_event.py +0 -0
  109. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_client_event_param.py +0 -0
  110. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_conversation_item_assistant_message.py +0 -0
  111. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_conversation_item_assistant_message_param.py +0 -0
  112. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_conversation_item_function_call.py +0 -0
  113. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_conversation_item_function_call_output.py +0 -0
  114. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_conversation_item_function_call_output_param.py +0 -0
  115. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_conversation_item_function_call_param.py +0 -0
  116. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_conversation_item_system_message.py +0 -0
  117. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_conversation_item_system_message_param.py +0 -0
  118. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_conversation_item_user_message.py +0 -0
  119. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_conversation_item_user_message_param.py +0 -0
  120. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_error.py +0 -0
  121. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_error_event.py +0 -0
  122. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_function_tool.py +0 -0
  123. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_function_tool_param.py +0 -0
  124. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_mcp_approval_request.py +0 -0
  125. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_mcp_approval_request_param.py +0 -0
  126. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_mcp_approval_response.py +0 -0
  127. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_mcp_approval_response_param.py +0 -0
  128. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_mcp_list_tools.py +0 -0
  129. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_mcp_list_tools_param.py +0 -0
  130. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_mcp_protocol_error.py +0 -0
  131. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_mcp_protocol_error_param.py +0 -0
  132. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_mcp_tool_call.py +0 -0
  133. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_mcp_tool_call_param.py +0 -0
  134. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_mcp_tool_execution_error.py +0 -0
  135. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_mcp_tool_execution_error_param.py +0 -0
  136. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_mcphttp_error.py +0 -0
  137. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_mcphttp_error_param.py +0 -0
  138. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_reasoning.py +0 -0
  139. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_reasoning_effort.py +0 -0
  140. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_reasoning_param.py +0 -0
  141. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_response.py +0 -0
  142. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_response_create_audio_output.py +0 -0
  143. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_response_create_audio_output_param.py +0 -0
  144. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_response_create_mcp_tool.py +0 -0
  145. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_response_create_mcp_tool_param.py +0 -0
  146. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_response_create_params.py +0 -0
  147. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_response_create_params_param.py +0 -0
  148. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_response_status.py +0 -0
  149. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_response_usage.py +0 -0
  150. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_response_usage_input_token_details.py +0 -0
  151. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_response_usage_output_token_details.py +0 -0
  152. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_server_event.py +0 -0
  153. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_session_create_request.py +0 -0
  154. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_session_create_request_param.py +0 -0
  155. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_tool_choice_config.py +0 -0
  156. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_tool_choice_config_param.py +0 -0
  157. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_tools_config.py +0 -0
  158. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_tools_config_param.py +0 -0
  159. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_tools_config_union.py +0 -0
  160. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_tracing_config.py +0 -0
  161. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_tracing_config_param.py +0 -0
  162. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_transcription_session_audio.py +0 -0
  163. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_transcription_session_audio_input.py +0 -0
  164. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_transcription_session_audio_input_param.py +0 -0
  165. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_transcription_session_audio_input_turn_detection.py +0 -0
  166. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_transcription_session_audio_input_turn_detection_param.py +0 -0
  167. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_transcription_session_audio_param.py +0 -0
  168. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_transcription_session_create_request.py +0 -0
  169. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_transcription_session_create_request_param.py +0 -0
  170. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_truncation.py +0 -0
  171. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_truncation_param.py +0 -0
  172. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_truncation_retention_ratio.py +0 -0
  173. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/realtime_truncation_retention_ratio_param.py +0 -0
  174. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_audio_delta_event.py +0 -0
  175. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_audio_done_event.py +0 -0
  176. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_audio_transcript_delta_event.py +0 -0
  177. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_audio_transcript_done_event.py +0 -0
  178. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_cancel_event.py +0 -0
  179. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_cancel_event_param.py +0 -0
  180. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_content_part_added_event.py +0 -0
  181. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_content_part_done_event.py +0 -0
  182. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_create_event.py +0 -0
  183. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_create_event_param.py +0 -0
  184. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_created_event.py +0 -0
  185. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_done_event.py +0 -0
  186. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_function_call_arguments_delta_event.py +0 -0
  187. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_function_call_arguments_done_event.py +0 -0
  188. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_mcp_call_arguments_delta.py +0 -0
  189. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_mcp_call_arguments_done.py +0 -0
  190. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_mcp_call_completed.py +0 -0
  191. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_mcp_call_failed.py +0 -0
  192. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_mcp_call_in_progress.py +0 -0
  193. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_output_item_added_event.py +0 -0
  194. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_output_item_done_event.py +0 -0
  195. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_text_delta_event.py +0 -0
  196. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/response_text_done_event.py +0 -0
  197. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/session_created_event.py +0 -0
  198. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/session_update_event.py +0 -0
  199. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/session_update_event_param.py +0 -0
  200. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/realtime/session_updated_event.py +0 -0
  201. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/responses/__init__.py +0 -0
  202. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/responses/image_detail.py +0 -0
  203. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/responses/response_input_file.py +0 -0
  204. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/responses/response_input_file_param.py +0 -0
  205. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/responses/response_input_image.py +0 -0
  206. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/responses/response_input_image_param.py +0 -0
  207. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/responses/response_input_text.py +0 -0
  208. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/responses/response_input_text_param.py +0 -0
  209. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/responses/response_prompt.py +0 -0
  210. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/responses/response_prompt_param.py +0 -0
  211. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/responses/tool_choice_function.py +0 -0
  212. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/responses/tool_choice_function_param.py +0 -0
  213. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/responses/tool_choice_mcp.py +0 -0
  214. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/responses/tool_choice_mcp_param.py +0 -0
  215. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/responses/tool_choice_options.py +0 -0
  216. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/shared/__init__.py +0 -0
  217. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/shared/metadata.py +0 -0
  218. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/shared_params/__init__.py +0 -0
  219. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/shared_params/metadata.py +0 -0
  220. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/__init__.py +0 -0
  221. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/alignment.py +0 -0
  222. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/audio_output_multi.py +0 -0
  223. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/close_context.py +0 -0
  224. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/close_socket.py +0 -0
  225. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/final_output_multi.py +0 -0
  226. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/fine_tuning_response.py +0 -0
  227. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/fine_tuning_response_state_value.py +0 -0
  228. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/flush_context.py +0 -0
  229. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/generation_config.py +0 -0
  230. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/get_voices_response.py +0 -0
  231. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/get_voices_v_2_response.py +0 -0
  232. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/initialize_connection_multi.py +0 -0
  233. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/language_response.py +0 -0
  234. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/manual_verification_file_response.py +0 -0
  235. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/manual_verification_response.py +0 -0
  236. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/model.py +0 -0
  237. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/model_rates_response_model.py +0 -0
  238. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/normalized_alignment.py +0 -0
  239. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/output_format.py +0 -0
  240. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/pronunciation_dictionary_locator.py +0 -0
  241. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/reader_resource_response_model.py +0 -0
  242. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/reader_resource_response_model_resource_type.py +0 -0
  243. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/realtime_voice_settings.py +0 -0
  244. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/recording_response.py +0 -0
  245. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/review_status.py +0 -0
  246. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/send_text_multi.py +0 -0
  247. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/speaker_response_model.py +0 -0
  248. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/speaker_separation_response_model.py +0 -0
  249. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/speaker_separation_response_model_status.py +0 -0
  250. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/utterance_response_model.py +0 -0
  251. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/verification_attempt_response.py +0 -0
  252. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/verified_voice_language_response_model.py +0 -0
  253. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/voice.py +0 -0
  254. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/voice_category.py +0 -0
  255. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/voice_labelling_status.py +0 -0
  256. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/voice_recording_quality.py +0 -0
  257. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/voice_safety_control.py +0 -0
  258. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/voice_sample.py +0 -0
  259. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/voice_settings.py +0 -0
  260. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/voice_sharing_moderation_check_response_model.py +0 -0
  261. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/voice_sharing_response.py +0 -0
  262. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/voice_sharing_response_category.py +0 -0
  263. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/voice_sharing_state.py +0 -0
  264. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech/voice_verification_response.py +0 -0
  265. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/speech_language.py +0 -0
  266. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/websocket_connection_options.py +0 -0
  267. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha/types/websocket_reconnection.py +0 -0
  268. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha_python_sdk.egg-info/SOURCES.txt +0 -0
  269. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha_python_sdk.egg-info/dependency_links.txt +0 -0
  270. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha_python_sdk.egg-info/requires.txt +0 -0
  271. {avartha_python_sdk-0.0.5 → avartha_python_sdk-0.0.6}/src/avartha_python_sdk.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: avartha-python-sdk
3
- Version: 0.0.5
3
+ Version: 0.0.6
4
4
  Summary: Python clients for Avartha Realtime text, streaming speech, and platform management
5
5
  Author-email: "Avartha Inc." <team@avartha.ai>
6
6
  License-Expression: LicenseRef-Avartha-Proprietary
@@ -221,7 +221,9 @@ Use `AsyncAvartha` or `AsyncElevenLabs` for an async application. See the
221
221
  [live STT execution guidance](docs/migration.md#live-speech-to-text) for scripts
222
222
  and applications with an existing event loop.
223
223
 
224
- Send mono PCM16 audio and await a committed transcript.
224
+ Current ASR models require 16 kHz mono PCM16 audio. Convert other formats or
225
+ sample rates before sending audio chunks; the SDK does not resample them.
226
+ Await a committed transcript before closing the session.
225
227
  [The complete example](examples/realtime_asr.py) reads a WAV file, registers
226
228
  transcript/error callbacks, streams chunks, commits, and closes the connection:
227
229
 
@@ -229,12 +231,20 @@ transcript/error callbacks, streams chunks, commits, and closes the connection:
229
231
  python examples/realtime_asr.py mistralai/voxtral-mini-4b-realtime-2602 speech-16k.wav
230
232
  ```
231
233
 
232
- `previous_text` is optional text context for transcription. When omitted from
233
- `connection.send` data, Avartha sends `null`, meaning no context. You can omit
234
- this field when streaming audio without prior text.
234
+ Current ASR models reject nonempty `previous_text`. Omit it from
235
+ `connection.send`; the SDK sends `null`. An empty string is also accepted.
236
+ For vocabulary hints on supported models, pass `keyterms` in the connection
237
+ options instead.
235
238
 
236
239
  File-based HTTP `speech_to_text.convert` is retired on managed inference.
237
240
 
241
+ Connection options cover background speech filtering, vocabulary hints,
242
+ manual/VAD commits, Smart Turn, word log probabilities, timestamps, and speaker
243
+ labels on supported models. Register `RealtimeEvents.WARNING` for nonfatal
244
+ warnings, including unavailable timing metadata. See
245
+ [ASR options and callbacks](docs/migration.md#recognition-and-context-hints)
246
+ for configuration and server requirements.
247
+
238
248
  ## Agents
239
249
 
240
250
  Agent management, tools, knowledge bases, and conversation sessions/history are
@@ -124,9 +124,13 @@ Speech discovery uses these HTTP routes under
124
124
  | `voices.search(...)` | `/v2/voices` | Same; supported filters are `search`, `page_size` (1–100), `next_page_token`, and `include_total_count` |
125
125
  | `voices.get(voice_id)` | `/v1/voices/{voice_id}` | Voice exists for the selected model |
126
126
  | `voices.settings.get(voice_id)` | `/v1/voices/{voice_id}/settings` | Same; server reports supported `speed=1.0` |
127
- | `speech_to_text.languages.list(model_id=...)` | `/v1/speech-to-text/languages` | A routable ASR model; runtime reports supported languages or unavailable hints |
127
+ | `speech_to_text.languages.list(model_id=...)` | `/v1/models` | Selects the ASR model's language metadata from the speech catalog |
128
128
 
129
129
  All methods have sync and async variants and typed raw-response access.
130
+ The language helper maps catalog `language_id` entries to `code`. An empty
131
+ language list means hints are unsupported; missing metadata or an unavailable
132
+ model raises `ApiError`. Its raw-response wrapper retains the catalog response's
133
+ HTTP status and headers while exposing the selected model's typed language list.
130
134
  Model/voice methods retain upstream signatures; language discovery is an
131
135
  Avartha extension. Pass the TTS `model_id` through
132
136
  `request_options.additional_query_parameters`, especially when multiple TTS
@@ -258,6 +262,39 @@ Audio formats and `voice_settings` depend on the selected model. Specifying an
258
262
  option in the SDK does not make it available on the server. Runnable examples:
259
263
  [single-context](../examples/tts.py), [multi-context](../examples/tts_multi_context.py).
260
264
 
265
+ ## Realtime ASR
266
+
267
+ Current ASR models require 16 kHz mono PCM16 audio. The SDK retains the other
268
+ `AudioFormat` enum values for protocol compatibility; their presence does not
269
+ imply server support. Audio-chunk mode sends samples unchanged. Convert the
270
+ source before sending, or use URL mode, which requires FFmpeg and converts to
271
+ 16 kHz mono PCM16.
272
+
273
+ The SDK also preserves `previous_text` on audio chunks, but current ASR models
274
+ accept only omission, `null`, or an empty string. Nonempty values are rejected.
275
+ Vocabulary hints use `keyterms` on models that support them.
276
+
277
+ The SDK forwards background filtering (`filter_background_audio`), vocabulary
278
+ hints (`keyterms`), manual/VAD commit controls, and `include_timestamps`.
279
+ It additionally exposes Avartha's `diarize`, `include_logprobs`, `turn_model`,
280
+ and `turn_threshold` options on both audio-chunk and URL connections. These
281
+ extensions are not a claim of upstream ElevenLabs realtime feature parity.
282
+ Omitted extension options are not added to the query; explicit booleans are
283
+ sent as `true` or `false`.
284
+
285
+ The server validates feature combinations and model availability. Diarization
286
+ requires timestamps and a model with speaker-label support. Timestamps also
287
+ depend on language support. Smart Turn requires VAD mode and a server with
288
+ `smart_turn_v3` enabled; `turn_threshold` is only meaningful in that mode.
289
+ Background filtering and vocabulary hints also depend on the model.
290
+
291
+ Transcript callbacks preserve server dictionaries, including `words` with
292
+ timing, speaker labels, and log probabilities when supplied.
293
+ `RealtimeEvents.WARNING` delivers nonfatal warnings without also dispatching
294
+ `ERROR`. A timing warning can replace a timed result; the preceding plain
295
+ committed transcript remains usable. See the
296
+ [ASR options and event guidance](migration.md#recognition-and-context-hints).
297
+
261
298
  ## URLs and authentication
262
299
 
263
300
  - `Avartha` and `Control` accept a platform root, including a proxy prefix.
@@ -191,9 +191,7 @@ with ElevenLabs() as client:
191
191
  if voices:
192
192
  voice = client.voices.get(voices[0].voice_id, request_options=options)
193
193
  settings = client.voices.settings.get(voice.voice_id, request_options=options)
194
- languages = client.speech_to_text.languages.list(
195
- model_id="mistralai/voxtral-mini-4b-realtime-2602"
196
- )
194
+ languages = client.speech_to_text.languages.list(model_id="YOUR_ASR_MODEL_ID")
197
195
  ```
198
196
 
199
197
  Use `AsyncElevenLabs` with `async with` and `await` for each call. Each resource
@@ -213,8 +211,10 @@ available as `error.__cause__`.
213
211
  `model_id` is an Avartha query extension for voice discovery. Specify it when
214
212
  more than one TTS model is available. The platform supports `search`, `page_size`,
215
213
  `next_page_token`, and `include_total_count` on `voices.search`; other vendor
216
- filters are forwarded and may be rejected by the server. ASR language hints
217
- can be unavailable, with `language_hints_supported=False` and an empty list.
214
+ filters are forwarded and may be rejected by the server. The language helper
215
+ selects the requested ASR model from `models.list()`. An empty language list
216
+ means hints are unsupported (`language_hints_supported=False`); a missing
217
+ model or missing language metadata raises `ApiError` instead.
218
218
  See [supported HTTP endpoints and server prerequisites](compatibility.md#speech-http-discovery).
219
219
 
220
220
  ### Speech-specific configuration
@@ -248,8 +248,17 @@ transcripts. Handlers can be ordinary functions or async functions.
248
248
  ASR events retain their names and raw dictionary payloads, including the
249
249
  deprecated `UNACCEPTED_TERMS_ERROR` callback alias.
250
250
 
251
- `previous_text` supplies optional text context for transcription. When omitted,
252
- Avartha sends `null`, meaning no context. Audio-send code can omit the field:
251
+ Current ASR models require raw 16 kHz mono PCM16 samples without a file header.
252
+ For audio chunks, select `AudioFormat.PCM_16000` and `sample_rate=16000`, and
253
+ convert other formats or sample rates before sending. The SDK does not
254
+ resample chunks or convert their encoding. URL mode uses FFmpeg to convert the
255
+ source to the required format and requires FFmpeg on `PATH`.
256
+
257
+ Nonempty `previous_text` is unsupported by current ASR models. The SDK
258
+ preserves this protocol field, but the server rejects nonempty values rather
259
+ than using them as context. Omission, `None`, or an empty string supplies no
260
+ context. Use `keyterms` in the connection options for vocabulary hints on
261
+ supported models. Audio-send code can omit `previous_text`; the SDK sends `null`:
253
262
 
254
263
  ```python
255
264
  async def send_audio(connection, encoded_chunk):
@@ -269,6 +278,94 @@ In an application or notebook with a running event loop, await the workflow
269
278
  directly instead of calling `asyncio.run()`. Close the live session before
270
279
  leaving the client context; closing the client only closes its HTTP transports.
271
280
 
281
+ #### Recognition and context hints
282
+
283
+ Pass options to `realtime.connect()` using `RealtimeAudioOptions` for audio
284
+ chunks or `RealtimeUrlOptions` for an audio URL. The SDK forwards these settings;
285
+ the selected model and server must support them.
286
+
287
+ `filter_background_audio=True` enables experimental background speech filtering
288
+ on supported models. Use it to reduce transcription of background speakers.
289
+ It defaults to off and is separate from microphone echo cancellation.
290
+
291
+ Use `keyterms=["Avartha", "Kubernetes"]` for vocabulary hints on models that
292
+ support them. The SDK sends each term as a separate query parameter and handles
293
+ URL encoding. Hints do not guarantee a spelling and are not a free-form prompt.
294
+ `language_code` can constrain recognition to a supported language; use
295
+ `speech_to_text.languages.list(model_id=...)` to check language support.
296
+
297
+ #### Ending an utterance
298
+
299
+ `commit_strategy=CommitStrategy.MANUAL` is the default. Send audio, then call
300
+ `await connection.commit()` when your application decides the utterance is
301
+ complete. This waits for the send, not the transcript: wait for
302
+ `RealtimeEvents.COMMITTED_TRANSCRIPT` before treating transcription as complete.
303
+ Do not commit an empty audio buffer as a completion check.
304
+
305
+ For automatic commits, use `commit_strategy=CommitStrategy.VAD`. Set
306
+ `turn_model="silence"` for silence-based turn detection; omitting it uses the
307
+ server's default. Tune `vad_silence_threshold_secs` for the silence
308
+ wait and `vad_threshold` for speech detection sensitivity. VAD controls require
309
+ VAD mode; omit them in manual mode.
310
+
311
+ On servers supporting Smart Turn, add `turn_model="smart_turn_v3"`. It uses an
312
+ end-of-turn model to judge whether the speaker has finished, with a silence
313
+ timeout as fallback. `turn_threshold` controls its decision threshold, defaults
314
+ to `0.5`, and must be strictly between `0` and `1`. Only pass this threshold with
315
+ Smart Turn. For example, inside an async client context:
316
+
317
+ ```python
318
+ from avartha import AudioFormat, CommitStrategy, RealtimeAudioOptions
319
+
320
+ options = RealtimeAudioOptions(
321
+ model_id="YOUR_ASR_MODEL_ID",
322
+ audio_format=AudioFormat.PCM_16000,
323
+ sample_rate=16000,
324
+ commit_strategy=CommitStrategy.VAD,
325
+ turn_model="smart_turn_v3",
326
+ turn_threshold=0.5,
327
+ )
328
+ connection = await client.speech_to_text.realtime.connect(options)
329
+ ```
330
+
331
+ #### Transcript details
332
+
333
+ `include_logprobs=True` requests word log probabilities in final transcripts.
334
+ These are model scores, not calibrated confidence percentages. This option does
335
+ not enable timestamps. `include_timestamps=True` requests a separate
336
+ `RealtimeEvents.COMMITTED_TRANSCRIPT_WITH_TIMESTAMPS` event after the plain
337
+ committed transcript. Use it to enrich the same utterance, not append a duplicate.
338
+
339
+ `diarize=True` requests speaker labels and requires `include_timestamps=True`.
340
+ On supported models, timed `words` entries can include `speaker_id` alongside
341
+ `start` and `end`. Speaker labels may be absent if diarization fails; timestamps
342
+ can still be returned. These three options default to off. For a model and
343
+ language that support the requested details:
344
+
345
+ Add `include_timestamps=True`, `diarize=True`, and `include_logprobs=True` to
346
+ the `RealtimeAudioOptions` above before connecting. Omit options you do not need.
347
+
348
+ Register handlers before sending audio. Callbacks receive the unmodified server
349
+ dictionary, including word scores, timestamps, and speaker labels:
350
+
351
+ ```python
352
+ from avartha import RealtimeEvents
353
+
354
+ connection.on(RealtimeEvents.COMMITTED_TRANSCRIPT, lambda event: print(event["text"]))
355
+ connection.on(
356
+ RealtimeEvents.COMMITTED_TRANSCRIPT_WITH_TIMESTAMPS,
357
+ lambda event: print(event.get("words", [])),
358
+ )
359
+ connection.on(RealtimeEvents.WARNING, lambda event: print("Warning:", event))
360
+ connection.on(RealtimeEvents.ERROR, lambda event: print("Error:", event))
361
+ ```
362
+
363
+ If timing cannot be produced, the server can send a `WARNING` instead of the
364
+ timed event. Retain the plain committed transcript. Warnings do not trigger the
365
+ `ERROR` callback or close the SDK connection. When waiting for optional metadata,
366
+ handle both the timed event and the warning, and use an application timeout.
367
+ Do not close immediately after the plain final if you still need its metadata.
368
+
272
369
  ## Configuration
273
370
 
274
371
  | Setting | Avartha behavior |
@@ -1,7 +1,8 @@
1
- """Stream mono, signed 16-bit PCM WAV audio with the ElevenLabs ASR protocol.
1
+ """Stream 16 kHz mono, signed 16-bit PCM WAV audio with the ElevenLabs ASR protocol.
2
2
 
3
3
  Set AVARTHA_API_KEY and optionally AVARTHA_BASE_URL.
4
- Run: python examples/realtime_asr.py MODEL_ID speech.wav
4
+ Run: python examples/realtime_asr.py MODEL_ID speech-16k.wav
5
+ Convert other sample rates before running; this example does not resample audio.
5
6
  """
6
7
 
7
8
  import argparse
@@ -39,6 +40,7 @@ async def run(model: str, audio_path: str):
39
40
 
40
41
  connection.on(RealtimeEvents.PARTIAL_TRANSCRIPT, lambda event: print(event["text"]))
41
42
  connection.on(RealtimeEvents.COMMITTED_TRANSCRIPT, transcript)
43
+ connection.on(RealtimeEvents.WARNING, lambda event: print("Warning:", event))
42
44
  connection.on(RealtimeEvents.ERROR, failed)
43
45
  try:
44
46
  while chunk := audio.readframes(sample_rate // 10):
@@ -7,7 +7,7 @@ import json
7
7
  import logging
8
8
  from collections.abc import Callable
9
9
  from enum import Enum
10
- from typing import Any, Required, TypedDict, cast
10
+ from typing import Any, Literal, Required, TypedDict, cast
11
11
 
12
12
  from websockets.asyncio.client import ClientConnection
13
13
 
@@ -45,6 +45,7 @@ class RealtimeEvents(str, Enum): # noqa: UP042 - preserve the upstream str() re
45
45
  COMMITTED_TRANSCRIPT = "committed_transcript"
46
46
  COMMITTED_TRANSCRIPT_WITH_TIMESTAMPS = "committed_transcript_with_timestamps"
47
47
  COMMITTED_TRANSCRIPT_ENTITIES = "committed_transcript_entities"
48
+ WARNING = "warning"
48
49
  ERROR = "error"
49
50
  AUTH_ERROR = "auth_error"
50
51
  QUOTA_EXCEEDED = "quota_exceeded"
@@ -69,9 +70,15 @@ class _SharedOptions(TypedDict, total=False):
69
70
  vad_threshold: float
70
71
  min_speech_duration_ms: int
71
72
  min_silence_duration_ms: int
73
+ # Avartha turn controls require VAD; availability is validated by the server.
74
+ turn_model: Literal["silence", "smart_turn_v3"]
75
+ turn_threshold: float
72
76
  language_code: str
73
77
  secondary_languages: list[str]
74
78
  include_timestamps: bool
79
+ # Avartha extensions: diarization also requires include_timestamps=True.
80
+ diarize: bool
81
+ include_logprobs: bool
75
82
  include_language_detection: bool
76
83
  keyterms: list[str]
77
84
  no_verbatim: bool
@@ -105,6 +112,7 @@ _NON_ERRORS = {
105
112
  RealtimeEvents.COMMITTED_TRANSCRIPT,
106
113
  RealtimeEvents.COMMITTED_TRANSCRIPT_WITH_TIMESTAMPS,
107
114
  RealtimeEvents.COMMITTED_TRANSCRIPT_ENTITIES,
115
+ RealtimeEvents.WARNING,
108
116
  RealtimeEvents.ERROR,
109
117
  }
110
118
 
@@ -5,7 +5,7 @@ import email.utils
5
5
  import json
6
6
  import random
7
7
  import time
8
- from collections.abc import Mapping
8
+ from collections.abc import Callable, Mapping
9
9
  from datetime import UTC, datetime
10
10
  from typing import Any
11
11
  from urllib.parse import quote
@@ -38,6 +38,9 @@ class HttpResponse[T]:
38
38
  def close(self) -> None:
39
39
  self._response.close()
40
40
 
41
+ def map_data[U](self, transform: Callable[[T], U]) -> "HttpResponse[U]":
42
+ return HttpResponse(self._response, transform(self.data))
43
+
41
44
 
42
45
  class AsyncHttpResponse[T]:
43
46
  """Async variant of the typed HTTP response wrapper."""
@@ -57,6 +60,9 @@ class AsyncHttpResponse[T]:
57
60
  async def close(self) -> None:
58
61
  await self._response.aclose()
59
62
 
63
+ def map_data[U](self, transform: Callable[[T], U]) -> "AsyncHttpResponse[U]":
64
+ return AsyncHttpResponse(self._response, transform(self.data))
65
+
60
66
 
61
67
  def segment(value: str) -> str:
62
68
  if value in {".", ".."}:
@@ -8,6 +8,7 @@ an Avartha extension. Transport and credentials are handled inside the SDK.
8
8
  import builtins
9
9
  from collections.abc import Sequence
10
10
 
11
+ from ._exceptions import ApiError
11
12
  from ._speech_config import RequestOptions
12
13
  from ._speech_http import (
13
14
  AsyncHttpResponse,
@@ -17,7 +18,42 @@ from ._speech_http import (
17
18
  segment,
18
19
  )
19
20
  from .types.speech import GetVoicesResponse, GetVoicesV2Response, Model, Voice, VoiceSettings
20
- from .types.speech_language import SpeechLanguageList
21
+ from .types.speech_language import SpeechLanguage, SpeechLanguageList
22
+
23
+
24
+ def _model_languages(models: list[Model], model_id: str) -> SpeechLanguageList:
25
+ matches = [model for model in models if model.model_id == model_id]
26
+ if len(matches) != 1:
27
+ raise ApiError(body=f"ASR model {model_id!r} is missing or ambiguous in the model catalog")
28
+ model = matches[0]
29
+ model_type = getattr(model, "model_type", None)
30
+ # Direct ASR runtimes expose vendor capabilities without Platform's type tag.
31
+ is_asr = model_type == "speech_to_text" or (
32
+ model_type is None
33
+ and model.can_do_text_to_speech is False
34
+ and model.can_do_voice_conversion is False
35
+ )
36
+ if not is_asr:
37
+ raise ApiError(body=f"Model {model_id!r} is not identified as ASR in the model catalog")
38
+ languages = model.languages
39
+ if languages is None:
40
+ raise ApiError(body=f"Language metadata is unavailable for ASR model {model_id!r}")
41
+ if not isinstance(languages, list) or any(
42
+ not isinstance(getattr(language, "language_id", None), str)
43
+ or not language.language_id
44
+ or not isinstance(getattr(language, "name", None), str)
45
+ or not language.name
46
+ for language in languages
47
+ ):
48
+ raise ApiError(body=f"Invalid language metadata for ASR model {model_id!r}")
49
+ return SpeechLanguageList(
50
+ object="list",
51
+ model=model_id,
52
+ language_hints_supported=bool(languages),
53
+ languages=[
54
+ SpeechLanguage(code=language.language_id, name=language.name) for language in languages
55
+ ],
56
+ )
21
57
 
22
58
 
23
59
  class RawVoices:
@@ -137,12 +173,13 @@ class RawLanguages:
137
173
  def list(
138
174
  self, *, model_id: str, request_options: RequestOptions | None = None
139
175
  ) -> HttpResponse[SpeechLanguageList]:
140
- return self._client.get(
141
- "v1/speech-to-text/languages",
142
- SpeechLanguageList,
143
- params={"model_id": model_id},
176
+ response = self._client.get(
177
+ "v1/models",
178
+ builtins.list[Model],
179
+ params={},
144
180
  request_options=request_options,
145
181
  )
182
+ return response.map_data(lambda models: _model_languages(models, model_id))
146
183
 
147
184
 
148
185
  class Voices:
@@ -361,12 +398,13 @@ class AsyncRawLanguages:
361
398
  async def list(
362
399
  self, *, model_id: str, request_options: RequestOptions | None = None
363
400
  ) -> AsyncHttpResponse[SpeechLanguageList]:
364
- return await self._client.get(
365
- "v1/speech-to-text/languages",
366
- SpeechLanguageList,
367
- params={"model_id": model_id},
401
+ response = await self._client.get(
402
+ "v1/models",
403
+ builtins.list[Model],
404
+ params={},
368
405
  request_options=request_options,
369
406
  )
407
+ return response.map_data(lambda models: _model_languages(models, model_id))
370
408
 
371
409
 
372
410
  class AsyncVoices:
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: avartha-python-sdk
3
- Version: 0.0.5
3
+ Version: 0.0.6
4
4
  Summary: Python clients for Avartha Realtime text, streaming speech, and platform management
5
5
  Author-email: "Avartha Inc." <team@avartha.ai>
6
6
  License-Expression: LicenseRef-Avartha-Proprietary