feat(vela): retire mocked.turn.trigger from shared contract

This commit is contained in:
2026-04-08 22:05:13 +02:00
parent 8e14eaeed0
commit 742e84e40f
7 changed files with 23 additions and 5 deletions

View File

@@ -184,6 +184,7 @@ Polish the system after the core voice loop is reliable.
- `apps/vela-ui` now boots as a minimal SvelteKit app with a starter page
- `apps/vela-ui` now includes a minimal voice-session shell that can connect to the gateway `/ws` endpoint and display developer-visible session status
- `apps/vela-ui` now exposes a visible push-to-talk mic control shell that sends placeholder `input_audio.append` / `input_audio.commit` events without requesting browser mic permission or capturing real audio
- placeholder push-to-talk via `input_audio.append` + `input_audio.commit` is now the only supported mocked turn entry path in the shared client protocol contract
- `apps/vela-ui` now includes browser-level coverage for the placeholder push-to-talk mocked transcript/response slice, including connect, disconnect, and cancel behavior
- `apps/vela-gateway` now boots as a minimal Fastify app with `/` and `/health` endpoints
- `apps/vela-gateway` now exposes a minimal `/ws` WebSocket session skeleton with ephemeral in-memory sessions and defensive message handling

View File

@@ -41,7 +41,6 @@ This increment intentionally keeps the envelope minimal:
```ts
type ClientEvent =
| { type: "session.start"; payload: {} }
| { type: "mocked.turn.trigger"; payload: {} }
| { type: "input_audio.append"; payload: { chunk: string } }
| { type: "input_audio.commit"; payload: {} }
| { type: "response.cancel"; payload: {} };
@@ -50,11 +49,15 @@ type ClientEvent =
#### Client event intent
- `session.start` initializes a voice session without locking in transport or auth details yet
- `mocked.turn.trigger` is a retired legacy event name that the gateway now rejects with a deterministic recoverable error
- `input_audio.append` carries a chunk of captured input audio as an encoded string
- `input_audio.commit` marks the current buffered user turn as ready for downstream processing
- `response.cancel` interrupts the active listen/think/speak flow
Legacy compatibility note:
- `mocked.turn.trigger` is no longer part of the active shared client contract
- the gateway still handles raw incoming `mocked.turn.trigger` envelopes explicitly and rejects them with a deterministic recoverable error for backward compatibility
### Current skeleton behavior
- on connect, the gateway creates an ephemeral in-memory session and emits `session.ready` plus `session.state`