feat(voice): support evidence reuse, 120s output capacity, and input ASR coalescing
- Add internal reuse_last_evidence tool for continuing existing topic without repeated retrieval - Expand OpenAI output capacity to 120s / 5,760,000 bytes and add delivery fairness - Coalesce adjacent user ASR transcript deltas to prevent client control queue overflow - Add server-side OPENAI_REALTIME_SPEED configuration and update style to v4 - Add extensive unit and integration regressions for evidence reuse, capacity, and fairness
This commit is contained in:
@@ -10,11 +10,12 @@ from uvicorn.protocols.websockets.websockets_impl import WebSocketProtocol
|
||||
from websockets.exceptions import ProtocolError
|
||||
from websockets.legacy.framing import Frame
|
||||
from app.modules.voice.settings import RuntimeSettings
|
||||
from app.modules.voice.configuration import VoiceSettings
|
||||
|
||||
|
||||
class BoundedWebSocketProtocol(WebSocketProtocol):
|
||||
def __init__(self, config, server_state, app_state, _loop=None):
|
||||
settings = getattr(config, 'ws_settings', None) or RuntimeSettings()
|
||||
settings = getattr(config, 'ws_settings', None) or RuntimeSettings.for_provider(VoiceSettings().provider)
|
||||
self.settings = settings
|
||||
self.max_binary_message_bytes = settings.max_binary_message_bytes
|
||||
self.max_client_control_bytes = settings.max_client_control_bytes
|
||||
|
||||
Reference in New Issue
Block a user