Replies: 1 comment
|
In general, I appreciate this kind of thinking/effort SO much, and much of it sounds like the right move. My worry is that the glossaries won't be maintained, as we've already seen to be the case by the translations themselves... I worry it'll play second fiddle to an already-undermaintained feature. Anything that improves the automation of translations (always in flux) would be amazing. I wonder if the .pot file can include some structured comments that get passed through to the .po files or at least be leveraged by the AI translation backfill script, so more of the strings are "contextualized" with context, and we avoid at least these term ambiguity problems you pointed out (I always talk about "turkey" being a bird, a country, and an insult, but yours are more practical). I.e. if there was a .pot "way" to add comments like: Then that might provide enough context for AI (or humans) to know what to drop there. As for policies, I agree, standards are needed. I'd be supportive of a docs site entry covering these. Things like tu/usted framing in spanish, or how we standardize on gendered languages (presumably preferring gender-neutral). Until there is a rule, nobody's breaking the rule. |
Uh oh!
There was an error while loading. Please reload this page.
Why this Discussion exists
This continues a thread from Slack
#translations. I posted an RFC there about four contested Spanish terms, and @sfirke suggested the conversation belongs here, both to make it findable and because the problem is not specific to Spanish.Before writing this post I measured all 29 translation catalogs with polib, counting actual entries, and read through the terminology debates in past PRs. Every language is hitting the same traps on its own. Several languages have already made good decisions that are recorded nowhere. And in PR #40431, two German translators asked whether a glossary exists. The answer, on the record: "I don't think there is a glossary or something like that which can be followed."
So this proposes we create one. Most of the work is writing down what maintainers and translators already do.
The evidence
1. The same collision exists in five languages, independently.
In many languages the most natural translation of "dashboard" is some calque of "control panel". That rendering then collides with Explore's actual control panel (3 msgids), and one term ends up carrying two concepts. It has happened five separate times:
There are partial overlaps in pt, pt_BR, tr, lv and sl as well. Korean has a different collision: 데이터베이스 covers both "database" and "dataset", including on the bare
Datasetmsgid. Polish shows the opposite failure. No collision there, but "dashboard" fragments five ways (pulpit, pulpit nawigacyjny, panel kontrolny, plain dashboard, tablica) across 188 strings.Nobody did anything wrong. The trap is structural. A one-line shared principle, "check your dashboard rendering against your control panel rendering", would have prevented all five collisions.
2. Jargon fed to machine translation produces a recognizable mistranslation genre.
"Slug" is currently Slak (the snail) in Dutch, سبيكة (a metal ingot) in Arabic, Kopfzeile (a header) in German, and Logotyp (a logo) in Polish. Italian translates "Host" as Ospite, a guest. Russian renders "Backend" as Драйвер. These are exactly the words a do-not-translate list catches. We already have the machine-side infrastructure for that in
superset/translations/do-not-translate.txt. Nothing equivalent exists for human-language terminology.Heavily fuzzy catalogs also carry a second defect class: machine suggestions pasted in from unrelated strings entirely. Polish has "Create Tag" rendered as "Utwórz zestaw danych", which means "create dataset", and "Charts per row" as "Wiersz nagłówka", a header row. A glossary will not fix that class. A native review checklist will.
3. Good decisions already exist
Mining past PRs surfaced settled, well argued conventions that live only in closed review threads:
The next contributor in each language will re-argue all of this from zero unless it gets written down.
What other projects do
The mature projects converge on the same two-layer shape: one language-agnostic guide for principles and process, plus per-locale glossaries owned by each language community. WordPress runs per-locale glossaries with editor approval and a rule that changes happen "only by consensus and based on argued reasoning". Mozilla keeps a general style guide plus one guide per locale. GitLab keeps central meta-rules plus a glossary in Crowdin.
Two ideas are worth stealing outright.
GitLab keeps all git commands untranslated in every language, with the stated reason "to maintain consistency between GitLab and the git client". That is the principled version of the keep-English rule.
WordPress records the reasoning next to each glossary term. Their Spanish team documented why "dashboard" became Escritorio, rejecting tablero, cuadro de mando and salpicadero along the way. Whatever you think of the word they landed on, the next translator can read why instead of reopening the debate.
Those projects keep the live glossary inside their translation platform (Crowdin, GlotPress and the like). Superset translates via PRs, so in-repo markdown is our natural equivalent, and
do-not-translate.txtis existing precedent for keeping a terminology registry insidesuperset/translations/.Proposal
TRANSLATING.mdwould carry the shared principles. Deliberately few:(a) proper nouns and product names,
(b) code-level tokens, like SQL keywords and placeholders,
(c) external-ecosystem vocabulary. These are terms your users also see in tools outside Superset (Host, Slug, Backend, a Snowflake or Databricks Warehouse), where translating breaks the connection to what their database tooling shows them. This last category is the GitLab git-commands rule, generalized. The catalogs already vote this way: most languages keep or transliterate slug, host and backend, while "database" is translated natively in 27 of 29 and is every catalog's most internally consistent term.
glossary/<lang>.mdfiles hold each language's settled terms, each with a one-line why, plus a list of known bad renderings so that review, human or automated, can flag them mechanically.One packaging detail to be aware of: MANIFEST.in includes everything under superset/translations/, so glossary markdown placed there would ship inside the released PyPI package. Nothing reads it at runtime and the size cost is a few kilobytes, the same situation as the existing do-not-translate.txt.
If that bothers anyone, a one-line recursive-exclude keeps the glossary in the repo but out of releases. Flagging it so the choice is deliberate.
Open questions
superset/translations/plus aglossary/directory sound like the right home?Appendix: what a glossary entry could look like (Spanish, illustrative)
Two draft entries, shown for format only. The Spanish specifics are still under discussion with es speakers.
And the forbidden side of an entry, from shipped catalogs: "Slug" must never become Slak (Dutch, the snail), سبيكة (Arabic, a metal ingot) or Logotyp (Polish, a logo). All three are live today.
All reactions