feat(voice): add authenticated Phase 2 live lifecycle

Add cookie authentication, owned conversations, durable Live reservations,
tool completion/replay fencing, revocation, and startup reconciliation.
Introduce forward lifecycle/owner-chain migrations and the temporary Gemini
adapter while preserving the existing OpenAI Realtime adapter.

Include the executable audio client, regression coverage, configuration,
API/database documentation, and recorded acceptance evidence.

Validation: focused review suite 82 passed; Python/TOML parsing, JavaScript
syntax, and whitespace checks passed. Full PostgreSQL/provider-free results
are recorded in the repair report; real-provider/browser acceptance is unrun.

Follow-up work remains for configurable OpenAI/Gemini selection, transport
admission, authority diagnostics, playback message bounds, and client replay
identity after ambiguous creation responses.
This commit is contained in:
11linear11
2026-10-09 07:59:02 -04:00
parent 07245cd5ca
commit 996435d2ae
42 changed files with 4551 additions and 88 deletions
+3 -3
View File
@@ -470,8 +470,8 @@ def test_smoke_never_succeeds_from_early_transcript(runner, persisted, monkeypat
for event in events:
await transport.incoming.put(canonical_json(event))
transport.send = send
async def connection(*_): return transport
monkeypatch.setattr(voice_smoke, "connect", connection)
async def connection(config, limits): return RealtimeAdapter(transport, settings=limits)
monkeypatch.setattr(voice_smoke, "create_adapter", connection)
original_runtime = voice_smoke.VoiceRuntime
if failure == "delivery":
def runtime_factory(adapter, service, shared_runner, actor, emit, **kwargs):
@@ -603,7 +603,7 @@ def test_queue_duration_environment_and_consistency(monkeypatch):
def test_invalid_smoke_configuration_never_connects(runner, monkeypatch):
from app import voice_smoke
async def forbidden(*_): pytest.fail("Provider connection before valid configuration")
monkeypatch.setattr(voice_smoke, "connect", forbidden)
monkeypatch.setattr(voice_smoke, "create_adapter", forbidden)
config = SimpleNamespace(runtime_settings={"setup_timeout_seconds": 0})
with pytest.raises(ValueError):
asyncio.run(voice_smoke.run(SimpleNamespace(), runner, uuid4(), config, "q", 3, 4))