server: sampling overrides on the speech endpoint

The speech body accepts seed, max_new_tokens, temperature, top_k,
top_p, and repetition_penalty. Unset fields keep the engine defaults,
a temperature of zero selects greedy decoding, and the subtalker
mirrors the talker knobs. A fixed seed makes a request reproducible.
This commit is contained in:
Pascal
2026-07-05 15:01:37 +02:00
parent 1a680e8816
commit 73fe0c67bb
4 changed files with 100 additions and 2 deletions
+7 -1
View File
@@ -139,9 +139,15 @@ curl -X POST localhost:8080/v1/voices -H "Content-Type: application/json" \
\"spk_b64\":\"$(base64 -w0 ref.spk)\",\"rvq_b64\":\"$(base64 -w0 ref.rvq)\"}"
curl -X POST localhost:8080/v1/audio/speech -H "Content-Type: application/json" \
-d '{"input":"Hello world.","voice":"freeman","response_format":"wav"}' -o out.wav
-d '{"input":"Hello world.","voice":"freeman","response_format":"wav",
"seed":42,"temperature":0.8}' -o out.wav
```
The speech body accepts optional sampling overrides (`seed`,
`max_new_tokens`, `temperature`, `top_k`, `top_p`,
`repetition_penalty`); unset fields keep the engine defaults and a
fixed seed makes the request reproducible.
## Embedding the library
The CLI tools are thin wrappers over a public ABI. Single-header,