Skip to content

fix(data): retranslate PT Rules with GPT-5.4-mini (#211) - #225

Merged
jsboige merged 1 commit into
masterfrom
feat/issue-211-pt-rules-retranslation
Apr 24, 2026
Merged

fix(data): retranslate PT Rules with GPT-5.4-mini (#211)#225
jsboige merged 1 commit into
masterfrom
feat/issue-211-pt-rules-retranslation

Conversation

@jsboige

@jsboige jsboige commented Apr 23, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Full retranslation of all 18 Rules cards from FR to PT using gpt-5.4-mini
  • Replaces catastrophic MT errors (English titles, garbled game terms like "o pêssego", "baratiner")
  • Translation validated for European Portuguese quality, markdown preservation, and game role consistency
  • Adds Validation/translate_rules_pt.py script for future retranslation needs

Before (catastrophic MT)

  • Row 4 PT: "# Roll of the English Channel" (English title!)
  • Row 4 PT: "### 1. o pêssego" (literal "the peach" instead of "Le piocheur")
  • Row 5 PT: "O baratiner exibe seus argumentos" (garbled game role)

After (GPT-5.4-mini)

  • Row 4 PT: "## Decorrer da ronda\n### 1. O comprador"
  • Row 5 PT: "O Baratineur expõe os seus argumentos"
  • Row 15 PT: "## A conversa apertada" (idiomatic for "La parlote coinchée")

Test plan

  • 18/18 rows translated successfully (0 errors)
  • European Portuguese (pt-PT) used throughout
  • Game roles preserved: Baratineur, Argumentum
  • Markdown formatting (headers, lists, bold, italic) preserved
  • Emojis and symbols preserved
  • ai-01 visual review of PT content quality
  • Pipeline regeneration to validate PDF output

Closes #211

🤖 Generated with Claude Code

Full retranslation of 18 Rules cards from FR to PT replacing catastrophic
MT errors (English titles, garbled game terms like "o pêssego", "baratiner").

Translation quality validated:
- Proper European Portuguese (pt-PT)
- Game roles preserved: Baratineur, Argumentum
- Markdown formatting and emojis preserved
- Idiomatic translations (e.g. "La parlote coinchée" → "A conversa apertada")

Also adds Validation/translate_rules_pt.py for future retranslation needs.

Closes #211

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@jsboige

jsboige commented Apr 24, 2026

Copy link
Copy Markdown
Contributor Author

Review (cross-agent posted as comment since same GH user)

Translation quality verified against 5 sample rows. The PT-PT is genuinely natural and fixes real defects:

  • Row 1: Liars' School (English leftover!) → A escola dos mentirosos
  • Row 3: SayNet de improvisação (gibberish) → pequena cena de improvisação
  • Row 3: material (lowercase) → Material
  • Row 3: 1 pacote de cartões falaciosos (awkward) → 1 baralho de cartas de argumentos falaciosos (idiomatic) ✓
  • Row 4: empate dos argumentos falaciosos (empate = tie?) → baralho de cartas de argumentos falaciosos

Game role preservation confirmed: Baratineur, Argumentum, Bingo argumentativo.
Markdown structure preserved across #/##/###/*/**.

Minor observation — BOM added (non-blocking)

The rewrite via Python utf-8-sig adds a UTF-8 BOM to the CSV. None of the other card CSVs (Fallacies, Scenarii, Virtues) have a BOM. CsvHelper handles both fine so runtime is unaffected, but style-wise it's a one-off. Easy fix if desired: change script to encoding="utf-8" on write, or strip BOM with a one-line git-level cleanup. Not worth blocking merge.

Non-blocking: script future-proofing

Confirmation for #222 (PR I opened)

po-2023 flagged in the dashboard that gpt-5.4-mini uses max_completion_tokens instead of max_tokens. I audited the DatasetUpdater C# code: it uses ChatCompletionOptions from official OpenAI SDK 2.10.0 without explicitly setting any token-limit property, so the SDK handles the new API field automatically. No additional code change needed in #222.

Recommendation: merge. Unblocks PT publication + validates the GPT-5.4-mini pipeline end-to-end.

@jsboige
jsboige merged commit 4221d13 into master Apr 24, 2026
1 check passed
jsboige added a commit that referenced this pull request Apr 24, 2026
Adds DatasetUpdater support for translating Argumentum Rules from FR to PT,
replacing the need for standalone Python scripts.

Changes:
- Rule.cs: add Pk property + ClassMap mapping (primary key for DatasetUpdater)
- Rules CSV: add pk column (Rules_01 through Rules_18)
- DatasetUpdaterRootConfig.cs: add TranslateRulesToPt config (Enabled=false)
- Prompt files for Rules FR→PT translation (markdown-aware, game terms preserved)

Config details:
- Model: gpt-5.4-mini (fallback: gpt-4.1-mini)
- DivisionMode: SequentialChunks, ChunkSize=3
- FunctionCalling enabled, SelectEmptyTargets=false (overwrite all)
- MaxDegreeOfParallelism=3

Complements PR #225 (Python-based PT Rules retranslation for immediate fix).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
jsboige added a commit that referenced this pull request Apr 24, 2026
Adds DatasetUpdater support for translating Argumentum Rules from FR to PT,
replacing the need for standalone Python scripts.

Changes:
- Rule.cs: add Pk property + ClassMap mapping (primary key for DatasetUpdater)
- Rules CSV: add pk column (Rules_01 through Rules_18)
- DatasetUpdaterRootConfig.cs: add TranslateRulesToPt config (Enabled=false)
- Prompt files for Rules FR→PT translation (markdown-aware, game terms preserved)

Config details:
- Model: gpt-5.4-mini (fallback: gpt-4.1-mini)
- DivisionMode: SequentialChunks, ChunkSize=3
- FunctionCalling enabled, SelectEmptyTargets=false (overwrite all)
- MaxDegreeOfParallelism=3

Complements PR #225 (Python-based PT Rules retranslation for immediate fix).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
jsboige added a commit that referenced this pull request Apr 24, 2026
Adds DatasetUpdater support for translating Argumentum Rules from FR to PT,
replacing the need for standalone Python scripts.

Changes:
- Rule.cs: add Pk property + ClassMap mapping (primary key for DatasetUpdater)
- Rules CSV: add pk column (Rules_01 through Rules_18)
- DatasetUpdaterRootConfig.cs: add TranslateRulesToPt config (Enabled=false)
- Prompt files for Rules FR→PT translation (markdown-aware, game terms preserved)

Config details:
- Model: gpt-5.4-mini (fallback: gpt-4.1-mini)
- DivisionMode: SequentialChunks, ChunkSize=3
- FunctionCalling enabled, SelectEmptyTargets=false (overwrite all)
- MaxDegreeOfParallelism=3

Complements PR #225 (Python-based PT Rules retranslation for immediate fix).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@clusterManager-Myia

Copy link
Copy Markdown
Collaborator

Post-hoc review — PR #225 fix(data): retranslate PT Rules with GPT-5.4-mini (#211)

Verdict: ✅ LGTM — good data quality fix

Critical fix for catastrophic MT errors in Portuguese Rules. The before/after examples in the PR description are compelling (e.g., "o pêssego" → correct PT game terminology).

Observations:

  • The standalone Python script (translate_rules_pt.py) is well-written but superseded by PR feat(dataset-updater): add Rules PT translation config #228's DatasetUpdater integration — the script stays in Validation/ as a reference/tool, which is fine.
  • CSV line ending change ( consistency) is a minor but positive cleanup.
  • print_and_play column preserved correctly.
  • The BOM () addition at start of CSV is intentional for Excel compatibility — consistent with other CSVs in the repo.

Translation spot-check (PT):

  • "A escola dos mentirosos" ✓ (correct pt-PT, not pt-BR)
  • "Regras do jogo" ✓ (not "Regras de jogo")
  • "cartas de argumento falacioso" ✓ (good formal register)
  • "lisonja é uma subcategoria do apelo às emoções" ✓ (correct logical terminology)

Good data quality. The PT Rules were genuinely broken and this fixes them properly.

@jsboige
jsboige deleted the feat/issue-211-pt-rules-retranslation branch June 1, 2026 21:41
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.

Full retranslation needed for PT Rules CSV (blocked by #183)

2 participants