docs(voice): plan phased local S2S adapter with execution prompts
This commit is contained in:
@@ -0,0 +1,57 @@
|
||||
# Phase 0 - Baseline and immutable upstream audit
|
||||
|
||||
Paste the following into a fresh implementation session in this repository.
|
||||
|
||||
```text
|
||||
Implement Phase 0 only: Baseline and immutable upstream audit.
|
||||
|
||||
Prerequisite:
|
||||
No implementation prerequisite. The current deployment must remain unchanged.
|
||||
|
||||
Required visible outcome:
|
||||
Produce a compatibility matrix and baseline evidence that a user can inspect before any adapter changes.
|
||||
|
||||
Execution rules:
|
||||
- Read docs/plans/local-s2s-adapter-plan.md and docs/plans/local-s2s-adapter-progress.md first. Read applicable AGENTS.md, repository skills and governing API/database/workflow sections. Inspect current code; historical defaults are not current evidence.
|
||||
- Implement only this phase. Check actual prerequisite artifacts, not just the existence of code. State observed, simulated, unverified and blocked outcomes separately.
|
||||
- Preserve OpenAI/Gemini behavior, original operational/rollback containers/images, frozen old profiles and unrelated working-tree changes. No database reset, compose down, pruning or implicit provider switch.
|
||||
- Keep existing browser PCM24k/application events, backend-derived identity, one canonical search implementation, document/chunk references and authorization/revision checks.
|
||||
- Make the smallest scoped change. No plugin framework, full runtime rewrite, new broker or unrelated refactor. Update intentional contracts and affected consumers coherently; never edit applied migrations.
|
||||
- Ordinary tests are provider-free. DB acceptance requires a verified disposable TEST_DATABASE_URL and --require-postgres; never production. Do not run a parallel application API against the operational database.
|
||||
- Reuse explicit authorization already present. Paid requests, downloads and operational switching need the applicable bounded authorization. Without it, finish independent offline preparation, identify the exact missing prerequisite and keep dependent live acceptance open.
|
||||
- Do not print keys/full environments/raw provider payloads or real user speech. Consent-controlled fixture artifacts are separate from default logs.
|
||||
- Never fake provider events, terminal success or history acknowledgements. Unsupported capabilities fail safely. Do not introduce automatic cross-provider fallback.
|
||||
- Before finishing: inspect diff, run meaningful checks, record exact commands/results and demo steps, update the progress ledger and list all not-run checks. Do not accept a phase with required live/human checks unrun. Do not begin the next phase.
|
||||
|
||||
Required work:
|
||||
1. Capture baseline selected profile, preserved container IDs/image digests, ports and mounts without credentials; do not recreate containers.
|
||||
2. Resolve an immutable speech-to-speech commit and dependency/build inputs. Inspect actual implementation/tests for setup, consumed input, manual turn control, identities, tools, audio, terminals, cancellation and history mutation.
|
||||
3. Map each required operation to supported / patch-required / unverified. Explicitly flag no-op truncate and completed-but-unplayed assistant history.
|
||||
4. Run focused current regressions and classify any pre-existing failures without changing assertions. Prepare an authorized frozen Persian fixture corpus and expected critical facts.
|
||||
5. Record exact heard-prefix policy, profile attestation design, missing live prerequisites and decision owners. Propose alternatives without silently accepting weaker history behavior.
|
||||
|
||||
Acceptance criteria:
|
||||
- Baseline and rollback identities are recorded; no service/data changes occurred.
|
||||
- Upstream is pinned and every required semantic has a proof test or explicit gap.
|
||||
- Existing test failures, missing credentials and live-unverified items are visible.
|
||||
- No unsupported acknowledgement is accepted by inference.
|
||||
|
||||
Relevant paths (verify actual locations before editing):
|
||||
app/modules/voice/, app/infrastructure/realtime.py, voice_provider.py, gemini_live.py, app/api/v1/live.py, app/main.py, current tests and pinned upstream sources.
|
||||
|
||||
Validation:
|
||||
Use current selected-provider/context-sync/search-reuse/sources/output-limit/style tests; inspect lifecycle/profile and schema constraints. No paid calls.
|
||||
|
||||
Visible demonstration:
|
||||
Open the compatibility matrix and replay one existing offline interruption trace. The user sees what works and what needs a patch.
|
||||
|
||||
Explicit stop/narrow condition:
|
||||
Unknown semantics stay unverified. Do not start refactoring or downloading models in this phase.
|
||||
|
||||
Deliver:
|
||||
1. Scoped code/configuration and necessary tests/contracts where this phase requires implementation; Phase 0 remains an audit.
|
||||
2. docs/evaluation/local-s2s/phase-00.md with exact commands, results, actual/simulated/unverified evidence, fingerprints, not-run checks and risks.
|
||||
3. Updated docs/plans/local-s2s-adapter-progress.md with a candid acceptance verdict.
|
||||
4. Exact demo instructions and rollback relevance. Preserve the operational provider unless this phase explicitly authorizes switching and session authorization exists.
|
||||
Do not implement the next phase. Do not mark acceptance complete with mandatory live or human checks unrun.
|
||||
```
|
||||
Reference in New Issue
Block a user