Skip to content

Keep import in English, at glossary v2 - #54

Merged
tamnd merged 1 commit into
mainfrom
keep-six-identifiers-in-english
Aug 18, 2026
Merged

Keep import in English, at glossary v2#54
tamnd merged 1 commit into
mainfrom
keep-six-identifiers-in-english

Conversation

@tamnd

@tamnd tamnd commented Aug 18, 2026

Copy link
Copy Markdown
Owner

Built with pydocvi 0.1.9 (tamnd/python-docs-vi-translator#57).

L02 no longer reports an entry whose whole msgid is a term the glossary keeps in English. The decision moves out of the check and into a written row that G03 then checks in both directions.

Most of it was already written. sys, builtins, exec and NaN were keep_en rows in v1 already, and what was missing was the check reading them. import is the one row this PR adds, for the 5 index entries that read import and name the statement.

Infinity is deliberately not added

The proposal had it. Measuring it first is what stopped it:

entries
msgid is exactly Infinity 1
"infinity" inside prose, meaning the mathematical concept 80

vô cực is right for the 80 and wrong for the 1, and a row cannot say both. The prose wins, and that single index entry stays an L02 finding rather than 80 entries being told to un-translate a word.

Audit

check before after
L02 no entry is the English verbatim 139 86
G03 kept terms stayed in English 81 94
G06 no entry is on a stale glossary 0 860
total findings 1,439 2,259
checks passing 30 of 41 29 of 41
hard checks failing 4 4

G03 at 94 is the same change read the other way: 13 entries where import appears in prose and the translation rendered it in Vietnamese anyway. The corpus said both things, and now one of them is a finding.

G06 at 860 is the version bump itself. Every machine-translated entry was made against v1, stale --glossary is the command that re-queues them, and that needs a fleet run. It is a soft check and it is counting rather than failing, which is what its docstring says it is for.

Follow-up on the terminology this exposed: tamnd/python-docs-vi-translator#58. The glossary keeps list, type and Boolean in English and has no opinion about object or module, and all five are the same kind of Sphinx index category.

pydocvi 0.1.9. L02 no longer reports an entry whose whole msgid is a term the
glossary keeps in English, so the decision moves out of the check and into a
written row that G03 checks in both directions.

Most of the work was already done. sys, builtins, exec and NaN were keep_en
rows in v1 already, and what was missing was the check reading them. `import`
is the one row this adds, for the 5 index entries that read `import` and name
the statement.

Infinity is deliberately left as `vô cực`. It is the right answer for the 80
prose entries that mean the mathematical concept and the wrong one for the
single index entry next to NaN, and a row cannot say both. The prose wins and
that one entry stays an L02 finding.

Audit: 2,259 findings, 29 of 41 checks passing, 4 hard checks failing.

L02 139 to 86. G03 81 to 94, which is the same change read the other way: 13
entries where `import` appears in prose and the translation rendered it in
Vietnamese. The corpus said both, and now one of them is a finding.

G06 0 to 860 is the version bump itself. Every machine-translated entry was
made against v1, `stale --glossary` is what re-queues them, and that needs the
fleet. It is soft and it is counting, not failing.
@tamnd
tamnd merged commit c33c3e9 into main Aug 18, 2026
1 check failed
@tamnd
tamnd deleted the keep-six-identifiers-in-english branch August 18, 2026 08:27
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.

1 participant