Skip to content

fix: plumb the estimated flag end to end (#29) - #30

Merged
willwade merged 3 commits into
mainfrom
estimated-flag
Aug 20, 2026
Merged

fix: plumb the estimated flag end to end (#29)#30
willwade merged 3 commits into
mainfrom
estimated-flag

Conversation

@willwade

Copy link
Copy Markdown
Contributor

What

Fixes #29tts_set_on_boundary3's estimated argument was hardcoded 0 because the flag didn't exist at the trait layer.

  • OnBoundaryCallback is now (word, start, end, char_offset, char_len, estimated) and WordBoundary carries the field
  • tts_set_on_boundary3 passes the real value; tts_set_on_boundary/boundary2 signatures unchanged
  • Per-engine values: floravox forwards floravox-core's per-event WordTiming.estimated (the measured/unpatched distinction), sherpa-onnx = true (wpm estimates), cloud = false (provider timings track the audio), default estimator = true

SAPI can now badge "measured timings" voices truthfully and gate rescaling on the flag.

Breaking

OnBoundaryCallback signature change — all engines, examples, and tests updated in-tree.

Test plan

  • fmt / clippy -D warnings on the full feature set
  • cargo test green (system,cloud / sherpaonnx / floravox combinations)
  • floravox-demo synthesizes with measured boundaries unchanged

OnBoundaryCallback gains a 6th param `estimated: bool`; WordBoundary
carries the field; tts_set_on_boundary3 now reports the real value.

- floravox: forwards floravox-core WordTiming.estimated (true on
  unpatched voices, false on duration-tensor-measured ones)
- sherpa-onnx: true (150-wpm estimates)
- cloud: false (provider timings track the delivered audio)
- system/default estimator: true
- v1/v2 C-ABI callbacks unchanged; v3 (tts_set_on_boundary3) was the
  hardcoded-0 lie this removes
@willwade
willwade merged commit 9631a74 into main Aug 20, 2026
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

boundary3 C-ABI always reports estimated=0 - flag is never plumbed from floravox

1 participant