Recognize an additional script in text-table language guessing (TEXT-SCRIPT-COVERAGE) #1046

Merged
lumencer merged 1 commit from upstream-pr/1046 into main 2026-11-24 22:18:50 +00:00
lumencer commented 2026-11-24 17:15:38 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by lumencer on 2026-11-24T17:15:38Z.


Claim: TEXT-SCRIPT-COVERAGE (https://github.com/ubiquitarianism/leonida/issues/14#issuecomment-7138917308).

tools/text_tables.py guesses a string table's language from its script before falling back to Latin word scoring. This adds one more Unicode-script match to that first pass, so a table in that script gets a concrete language code instead of falling through to xx.

The covered script list is now stated in docs/text.md's Language section and in the README's "How it works" summary. tests/test_text_tables.py::test_language gets a synthetic assertion for the new match; the existing language assertions are unchanged.

Checks run locally: python3 -I tests/test_text_tables.py (33 passed, 1 skipped), python3 -I tests/test_docs_links.py (16 passed), python3 -I tests/test_docs_repeated_lines.py (2 passed).

No game files, no GPU, no generated assets, no build or CI changes.

<!-- greyfinch-sync:ubiquitarianism/leonida:issue:5476914020 --> Imported from [ubiquitarianism/leonida](https://github.com/ubiquitarianism/leonida/pull/1046). Originally posted by [lumencer](https://github.com/lumencer) on 2026-11-24T17:15:38Z. --- Claim: `TEXT-SCRIPT-COVERAGE` (https://github.com/ubiquitarianism/leonida/issues/14#issuecomment-7138917308). `tools/text_tables.py` guesses a string table's language from its script before falling back to Latin word scoring. This adds one more Unicode-script match to that first pass, so a table in that script gets a concrete language code instead of falling through to `xx`. The covered script list is now stated in `docs/text.md`'s Language section and in the README's "How it works" summary. `tests/test_text_tables.py::test_language` gets a synthetic assertion for the new match; the existing language assertions are unchanged. Checks run locally: `python3 -I tests/test_text_tables.py` (33 passed, 1 skipped), `python3 -I tests/test_docs_links.py` (16 passed), `python3 -I tests/test_docs_repeated_lines.py` (2 passed). No game files, no GPU, no generated assets, no build or CI changes.
KernelSmoker commented 2026-11-24 17:19:34 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by KernelSmoker on 2026-11-24T17:19:34Z.

Review: APPROVED


Verified on exact head 1d2e0848fc (base 32950551e8). tests/test_text_tables.py passes 33 tests with one expected Windows-only skip (os.replace on a reader-held file); docs links pass 16/16 and repeated-lines tests 2/2. Changed-file no-game-data and git diff --check pass; the patch merges cleanly onto current main. The synthetic Arabic sample is detected as ar; existing script and Latin-language cases remain covered. No game data or GPU used.

<!-- greyfinch-sync:ubiquitarianism/leonida:review:6044048115 --> Imported from [ubiquitarianism/leonida](https://github.com/ubiquitarianism/leonida/pull/1046#pullrequestreview-6044048115). Originally posted by [KernelSmoker](https://github.com/KernelSmoker) on 2026-11-24T17:19:34Z. **Review:** APPROVED --- Verified on exact head 1d2e0848fcbd2a6eb790a3becec0cab49c94f3a5 (base 32950551e83760c6ccf1564cd22737dfe4852d78). `tests/test_text_tables.py` passes 33 tests with one expected Windows-only skip (`os.replace` on a reader-held file); docs links pass 16/16 and repeated-lines tests 2/2. Changed-file no-game-data and `git diff --check` pass; the patch merges cleanly onto current main. The synthetic Arabic sample is detected as `ar`; existing script and Latin-language cases remain covered. No game data or GPU used.
QemmHD commented 2026-11-24 22:18:48 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by QemmHD on 2026-11-24T22:18:48Z.


Merging.

Why merged: TEXT-SCRIPT-COVERAGE: text_tables guesses Arabic script as ar; README, docs/text.md and a test are updated. It's a small, contained addition. KernelSmoker checked it.

Why it's good: test_text_tables and test_progress_dashboard: 84 passed.

Tested on Windows 11 / RTX 4070 SUPER: merged alone onto main 4a50cafc7. With it in, the repo-consistency set (cmake/translator-deps, shader_stage_resume, runtime_paths, docs, make_game, no-game-data, run_semantic_tests) gives 573 passed / 5 skipped / 0 failed, and check_no_game_data on the changed files is clean. git merge-tree against current main: no conflicts. Security read of the three-dot diff: no binaries, game data, downloads, network calls, new subprocesses, new env vars or CI changes.

AI-assisted (Claude Code, Claude Opus 5.5).

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7146074843 --> Imported from [ubiquitarianism/leonida](https://github.com/ubiquitarianism/leonida/pull/1046#issuecomment-7146074843). Originally posted by [QemmHD](https://github.com/QemmHD) on 2026-11-24T22:18:48Z. --- Merging. **Why merged:** TEXT-SCRIPT-COVERAGE: text_tables guesses Arabic script as `ar`; README, docs/text.md and a test are updated. It's a small, contained addition. KernelSmoker checked it. **Why it's good:** test_text_tables and test_progress_dashboard: 84 passed. Tested on Windows 11 / RTX 4070 SUPER: merged alone onto main 4a50cafc7. With it in, the repo-consistency set (cmake/translator-deps, shader_stage_resume, runtime_paths, docs, make_game, no-game-data, run_semantic_tests) gives 573 passed / 5 skipped / 0 failed, and check_no_game_data on the changed files is clean. git merge-tree against current main: no conflicts. Security read of the three-dot diff: no binaries, game data, downloads, network calls, new subprocesses, new env vars or CI changes. AI-assisted (Claude Code, Claude Opus 5.5).
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
ProjectLeonida/mandy!1046
No description provided.