mirror of
https://github.com/anomalyco/hex.git
synced 2026-11-27 07:58:01 +01:00
| Filename | Latest commit message | Latest commit date |
|---|---|---|
* Android: Faster English dictation writes numbers in digits, as the iPhone does
What: SpokenNumbers.kt, a port rule for rule of the iPhone's SpokenNumbers.swift, runs on Faster English
dictation's text in SpeechModel.decodeEnglish, after SentenceEnds. Numbers said in words are written in digits:
"twenty five dollars" becomes $25, "fifteen percent" 15%, "twenty twenty four" 2024, "six forty five PM" 6:45 PM,
"three chairs" 3 chairs. What the iPhone leaves as words stays as words: "at nine", lower-case "march third",
"one of them", and names the model capitalised. The dictation's custom vocabulary is never converted ("five guys").
Why: the faster model writes every number in words, the known limit the Labs row states. This is the step that
comes before Hex picks that model for anyone by itself.
How:
- Its own guard: any exception returns the text as it came, with a log line naming only the exception class.
- The standard model's path is unchanged; it writes digits itself.
- The Labs speed test's faster mode goes through it too, without vocabulary.
- Kotlin can't tell Chinese numerals such as 一 are numbers, where Swift can. English from this model never has them.
Verified (on basebook, before Ryan's rule moved Gradle off it):
- assembleDebug and testDebugUnitTest passed. SpokenNumbersTest is a new class in speech/SignatureTest.kt.
- Its expectations are the Swift original's output: the iPhone's own number cases, its 80-sentence set, and the
seven number sentences from Hex's clips.
- A compiled copy of the Swift agreed with the port on 80,000 generated sentences, apart from the 168 involving 一.
- Not run on a phone or emulator yet.
* Android Labs: Faster English dictation's row no longer says numbers come out as words
What: the row's detail becomes "Several times faster after a one-time 135 MB download. Other languages are
unchanged." and "一次性下载 135 MB 后,英语听写快数倍。其他语言不受影响。" (Ryan's wording). The comment above the
row loses its mention of the numbers limit.
Why: with the numbers step in this pull request, the faster model's numbers come out in digits, so "Numbers come out
as words for now" would be untrue.
Nothing else quotes the sentence: no test, README, docs or site text. The site's privacy page mentions the switch
by name only.
Verified: build and unit tests on the Studio.
|
||
| .. | ||
| src | ||
| build.gradle.kts | ||
| proguard-rules.pro | ||