Wires two more capabilities into examples/converse_server.rs:
--lora <path> [--lora-rank N --lora-alpha A] inject voice-clone adapter
--watermark-generator <path> \
--watermark-detector <path> embed AudioSeal on every
[--watermark-message 0xCAFE] assistant utterance
LoRA path: parallels examples/generate.rs — load Generator (FP), build
LoraConfig, add_lora_to_backbone(VarMap), load_lora_adapter, refresh_lora.
Voice clones now work in the conversation pipeline. Combining with
--quantized-gguf is rejected at boot; the LoRA-on-Q8 path works in
generate but the server hasn't been audited so it's gated for now.
Watermark path: parallels examples/generate.rs — load AudioSeal generator
+ detector safetensors via VarBuilder::from_mmaped_safetensors, build
AudioSealWatermarker, wrap in ResampledWatermarker(24k↔16k), install via
generator.set_watermarker(...). converse.rs::synthesize already calls
the watermarker per-utterance, so no plumbing changes needed downstream.
Verified end-to-end:
* boot server with --watermark-generator/-detector --watermark-message 0xCAFE
* single conversation turn (10.43s LibriSpeech in -> 4.24s assistant out)
* detect on response WAV: mean_presence=0.9995, decoded=0xCAFE,
16/16 message bits matching after full STT->LLM->TTS->post->watermark
->24k->WS->wav round-trip.
Also adds audioseal_apply --detect-only flag (skip embed, run detector
against arbitrary WAV) — used to verify the round-trip above. --out is
now optional and only required when not in detect-only mode.
Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
End-to-end watermarker driver that handles any source sample rate by
resampling to AudioSeal's 16 kHz native, embedding, then resampling back.
Tested on 10s of real CSM 24 kHz speech: mean_presence=0.9988 detection,
12/16 message bits round-trip (4-bit erosion from double resample).
- examples/audioseal_apply.rs: --in/--out/--source-rate/--message; loads
source via audio_io::load_mono_at_rate, calls AudioSealWatermarker
through the public Watermarker trait, verifies via in-process detect.
- Fix bit-match counter overflow in audioseal_demo.rs and audioseal_apply.rs.
Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>