Gemma 4 31B leaks Korean/Arabic/Cyrillic into Chinese-Vietnamese translation; fixes fail
LambdaHominem · reddit · 2026-11-14
A Redditor using Gemma 4 31B for long-form Chinese→Vietnamese translation hits <0.5% language contamination: outputs occasionally contain Korean, Arabic, or Cyrillic characters absent from the source, often clustered around specific Chinese characters.
Attempted fixes that failed:
- Sampling tweaks (temp/top-k/top-p), q8 weights, fp16 KV cache — no help
- LLguidance with a huge Unicode-range regex — model hangs forever
- Vocabulary trimming — better suited to small models; repo abandoned
- Token masking via lmhead logit suppression (à la ThakiCloud/Qwen3.8-27B-vi-cjk-suppressed) — Gemma 4 ties lmhead to embedtokens, and editing embedtokens has no effect
Current workaround: spellcheck to locate contamination, then manually patch — running a second proofread pass is too slow at 31B local speeds. The poster asks for a more robust solution (a mapping of trigger characters works but needs constant updates and breaks on model upgrades).
More from coding & agent
- Dev with zero KiCad experience gets Codex to do PCB design in half a day — mckbrando · 2026-11-14
- One prompt, one 97KB HTML file: a procedural swimmable underwater world built by Claude — Any-Reputation8118 · 2026-11-14
- AG-UI, the agent-user interaction protocol for frontend apps, hits 17k GitHub stars — ag-ui-protocol · 2026-11-14
- Tencent open-sources LoopForge to self-host coding-agent workflows with approval gates — Tencent · 2026-11-14
- Solo dev shows off 2.5D turn-based RPG built with Godot and Claude Opus — irbrandonl · 2026-11-14
- The Test Engineer prompt: have AI design full unit, integration, and E2E test strategies — hey_abusiddik · 2026-11-14