Skip to content

BiVox v0.2.14 — engine update

Latest

Choose a tag to compare

@DirectX DirectX released this 03 Dec 18:40
· 1 commit to main since this release

BiVox v0.2.14 — the tail truncation: LibreOffice counts nChars as BYTES

Good news first: your report says switching between apps works and both
LibreOffice Writer and gnome-text-editor receive text
— the whole
focus/watcher chain (D-020 watcher, decisive refusal) is doing its job.

The two remaining symptoms were one root cause, and it is not the model:

Diagnosis (measured on a real Writer, not guessed)

Replaying your exact fixture through the Rust worker: final text 247 chars,
exact Python parity, zero U+FFFD
— ASR delivers the full sentence. The loss
happens at injection. Field evidence aligned:

  • MISMATCH span=71 want=79 — the injector wanted 79 chars in its span, 71 landed;
  • `` in Writer — a multibyte character cut mid-sequence in the buffer.

Controlled experiment against live LibreOffice Writer via AT-SPI
EditableText.insertText(start, text, nChars):

sent nChars landed
101 cyrillic chars (180 bytes) 101 57 chars = 101 bytes
positions — stay CHAR-based (X@2 landed between аб and вгд)

Writer's VCL a11y bridge spends nChars as a byte budget, cutting the
string at the byte limit — mid-character, producing the replacement glyph.
GTK4 (gnome-text-editor) follows the spec (chars), which is why the tail
survived there; the residual MISMATCH there was the old settle budget
(4×5 ms) giving up before the a11y cache caught up on long finals.

Fix (D-025): verified repair loop, no per-app heuristics

Patcher.apply always sends spec-correct char counts, then:

  1. reads its span; strips any U+FFFD cut-artifact from the buffer;
  2. if the read is a stable short prefix of the target → re-inserts the
    shortfall; each round the quirky widget lands ~half the remainder, so
    convergence takes ≤2 repairs;
  3. discovers the quirk on the first repair (landed-bytes ≈ sent-chars →
    flips byte_cut, subsequent inserts send a byte budget) — one 32 ms
    round-trip on Writer, zero churn on compliant widgets;
  4. budgets: partials 120 ms (streaming feel), final 1.5 s (must converge).
    Drift policy (external conflicts freeze the span) unchanged — data safety
    first: the repair only ever touches OUR span.

Verified

  • Live Writer: 101/101 chars, verify=True, byte_cut discovered, 1 repair,
    32 ms, no U+FFFD in buffer.
  • Emulator (tools/writer_quirk_test.py, 4/4): byte-cut convergence,
    ASCII single-insert (0 repairs — compliant widgets unaffected), streaming
    partials→final, anchored append.
  • Full battery at tag: M1 21/21 · M2 9/9 · M3 13/13 · E2E 8/8 · m4 9/9 ·
    refusal 5/5 · G2 3/3 · stress 2/2 (rust) · guards PASS.

Assets

Code-only release per D-022 (models unchanged, v0.2.8 — URL embedded in deb).

sudo apt install ./bivox_0.2.14_amd64.deb
systemctl --user restart bivox-core bivox-hotkey

The injector ships inside the deb — no models reinstall needed.

Install

Component Package
Engine (code) bivox_0.2.14_amd64.deb (this release)
Models (unchanged, v0.2.8) https://github.com/DirectX/bivox/releases/download/v0.2.13/bivox-models-ru-en_0.2.8_all.deb — already installed if you have any BiVox ≥ 0.2.6
sudo apt install ./bivox_0.2.14_amd64.deb