fix(fish-s2): reference_id was a silent no-op — populate per-voice dirs + guard the regression

reference_id=<name> resolves against the DIRECTORY references/<name>/
(audio + same-basename .lab), not a flat references/<name>.wav. Voices
were staged flat with the per-name dirs left empty, so every
reference_id resolved to nothing and Fish fell back to its default
speaker — every dropdown voice produced byte-identical audio (proven:
Abigail == Imogen == no-ref, same text+seed). This was the real "no
accent" root cause, independent of the asset-engine "undefined" select
bug.

Server fix (applied to irv-ml1): populated references/<name>/<name>.wav
+ <name>.lab for all 32 voices; re-test confirms Imogen/Eleanor/
Beatrice/Abigail/no-ref now all distinct.

Durable hardening + record correction:
- playbook: normalize-layout step (flat <name>.wav -> nested dir, cp -u
  idempotent, when-gated on count mismatch) + an A/B verify gate that
  hard-fails the deploy if two reference_ids yield identical output.
- services.yaml: correct the reference_id resolution doc (dir + .lab,
  not flat wav).
- README + persistent-memory: correct the "reference_id-by-name is THE
  working path, verified" claim — it was a no-op until this fix; the
  prior ECAPA 0.79 result came through the inline base64 path.
This commit is contained in:
vh
2026-06-01 16:42:30 -07:00
parent 3b54519d60
commit c5bbb90980
4 changed files with 100 additions and 26 deletions
+33 -15
View File
@@ -118,16 +118,30 @@ _As of 2026-06-01:_
`01KT2K2SY9N7AY69R9V0B4RXSW` → asset-engine-dev). **Workaround until fixed:
click the dropdown (fires change) or hit the API directly.** My half
(`blendable: false` catalog flag) is queued — see Recent decisions.
- **Fish cloning RESOLVED — it clones competently; "not British" was the
undefined bug.** ECAPA-TDNN re-test (2026-06-01): an Imogen-referenced Fish
clone scores **~0.79 cosine vs the real `Imogen.wav`** (firmly same-speaker)
and only **~0.10 vs Fish's no-reference default voice**. So Fish faithfully
clones Imogen WHEN it receives the reference. The operator's "Imogen doesn't
sound British at all" was the `"undefined"` select bug feeding Fish its
DEFAULT voice (≈ a different speaker), NOT a Fish cloning failure. Earlier
resemblyzer-based "weak cloner" verdict RETRACTED. No Fish-side fix needed —
the blocker is entirely the undefined bug (asset-engine-dev). Future voice
clones operator-handled (pitch-shift deepening abandoned).
- **Fish "not British" had TWO independent root causes — BOTH now fixed.**
The ECAPA-TDNN re-test (2026-06-01) showed Fish's cloning *engine* works: an
Imogen reference scores **~0.79 cosine vs real `Imogen.wav`** vs **~0.10 vs
the no-reference default** — but that test fed the reference via the inline
base64 `references` path, which masked the real defect. **`reference_id`-by-
name (the path the catalog + form actually use) was silently a NO-OP.** Proof
(2026-06-01): `reference_id=Abigail`, `=Imogen`, and no-reference all returned
**byte-identical** audio (md5 `40b6ac73…`, same text+seed) → reference_id was
being ignored entirely, so every dropdown voice collapsed to Fish's default
speaker. Cause: fish-speech resolves `reference_id=<name>` against the
**directory** `references/<name>/` (audio + same-basename `.lab`), but the
voices were staged as **flat** `references/<name>.wav` + `.txt` with the
per-name dirs left **empty** → nothing resolved. **FIX (2026-06-01):**
populated `references/<name>/<name>.wav` + `<name>.lab` for all 32 voices;
re-test → Imogen/Eleanor/Beatrice/Abigail/no-ref all 5 **distinct**.
reference_id now works; British accents come through. Hardened: the
deploy playbook gained a normalize-layout step + an A/B smoke gate
(`reference_id` MUST change output) so the empty-dir regression can't ship
silently. So the "not British" saga was (A) the `"undefined"` select bug
(asset-engine, still belt-and-suspenders) AND (B) this reference_id no-op
(server-side, FIXED) — B alone would have kept every voice identical even
with A fixed. Earlier "reference_id-by-name is THE working path, verified"
claim RETRACTED. Pitch-shift deepening abandoned; future clones operator-
handled.
- **On-host consented voice library** — ~992 real-person clips cached in the
kyutai tts-voices repo (`/worktank/kyutai-tts/.../snapshots/.../`): VCTK
(CC BY 4.0, accent-tagged speaker IDs), Unmute voice-donations (CC0), EARS +
@@ -182,8 +196,11 @@ _As of 2026-06-01:_
- `[2026-06-01]` **Fish-S2 catalog v1→v6** (`f3c260e`..`38d9e3b`) — was a
blank 2-field form; now exposes the full fish-speech ServeTTSRequest surface
+ a 32-voice `reference_id` "Voice" dropdown (STATIC list — Fish has no
/voices API). `reference_id`-by-name is the WORKING clone path; the
path-form `references` shape 500s (see Tried and abandoned). Corrected vram
/voices API). `reference_id`-by-name works ONLY when each voice is staged as
a `references/<name>/` dir with `<name>.wav` + `<name>.lab` — was silently a
no-op until that layout fix on 2026-06-01 (see the two-root-causes entry
above); the inline-path-as-filesystem-path `references` shape 500s (see Tried
and abandoned). Corrected vram
4→24 GB, cold_start 8→240s, seedable false→true. Added 3 consenting
British-female VCTK voices (Imogen=p225/Eleanor=p228/Beatrice=p229).
@@ -256,9 +273,10 @@ _25 older entries archived to archival-memory.md._
- `[2026-06-01]` **Fish path-form references** (`{audio:"/app/references/x.wav"}`)
→ HTTP 500 on this build, despite the stack README showing that shape. The
working clone paths are `reference_id` (by name → reads `<name>.wav` +
optional `<name>.txt`) or inline base64 `references`. The catalog now uses
`reference_id`.
working clone paths are `reference_id` (by name → resolves the DIRECTORY
`references/<name>/` containing `<name>.wav` + `<name>.lab`; the flat
`references/<name>.wav` is ignored — see the two-root-causes entry above) or
inline base64 `references`. The catalog uses `reference_id`.
- `[2026-06-01]` **Reference transcript barely affects Fish clone IDENTITY**
(disproving my mid-session theory). I'd blamed a bogus provenance-note `.txt`