open-standards/aac/aac-rs/third_party/readium-speech
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Transaction Science ac08f2c324 feat(access-core): rank device voices by quality, and name the ones never to use
A device voice now has a tier, or a reason it is never used, decided from
what the browser exposes (its name, identifier and language) and the
platform, never from `default` or `localService` alone (WebKit sets both on
every voice):

- Rejected: a voice that sends the words away (not on the device, "Online",
  "-network"), eSpeak, Linux speech-dispatcher, Apple's Eloquence voices
  (Eddy, Flo, Grandma...), novelty voices (Readium's list, and Fred, Junior,
  Kathy and Ralph) and Apple's super-compact voices.
- Premium: Apple Premium (identifier, or its marker in the interface
  language), a local "(Natural)" voice, or one Readium rates high (Google's
  natural voices on ChromeOS among them).
- Enhanced: Apple Enhanced, or an Android speech engine's voice (Android
  Chrome lists them under localized names, so the platform comes in).
- Basic: Apple compact, Microsoft's desktop voices (David, Zira, Mark...),
  other "Chrome OS" voices, anything unknown.

rank_voices orders a language's usable voices by tier, then the region asked
for, the language's usual region, Readium's order. choose_voice gives the
person's chosen voice while the device has it, else the best that may speak
unasked (premium or enhanced), else none. SystemVoice gains the identifier
(voiceURI); Platform reads the user agent (iPadOS Safari says it is a Mac:
touch points tell them apart). earlier_choice keeps the old ranking, to keep
the voice of someone who was speaking with it; the app still uses it until
the next commit.

The facts come from Readium Speech v0.13.0 (npm latest; its json/ is
byte-identical to v0.11.0's), voice data CC0 and code BSD-3-Clause.
third_party/readium-speech/generate.py reads the pinned commit's files,
checks their digest, and writes them as Rust tables
(access-core/src/voice/readium.rs): nothing is fetched at run time. Tests
use voice lists as iPad and Mac Safari, Mac Chrome, Windows Chrome and Edge,
ChromeOS, Android Chrome and Linux give them.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-04 15:06:20 -04:00
..
generate.py feat(access-core): rank device voices by quality, and name the ones never to use 2026-10-04 15:06:20 -04:00
LICENSE.txt feat(access-core): rank device voices by quality, and name the ones never to use 2026-10-04 15:06:20 -04:00
NOTICE.txt feat(access-core): rank device voices by quality, and name the ones never to use 2026-10-04 15:06:20 -04:00