diff options
| author | Jiang Xin <worldhello.net@gmail.com> | 2026-02-15 14:06:19 +0800 |
|---|---|---|
| committer | Jiang Xin <worldhello.net@gmail.com> | 2026-04-03 07:36:52 +0800 |
| commit | fc59ba0dfe134fbb51230d50f396f5efc9ba1721 (patch) | |
| tree | 2450127bbed5f5336ab1f876f81a5279b39de23f /t/t4013/diff.format-patch_--stdout_initial..master^ | |
| parent | b5690272f2457bb667542c57ae52c37768f295b6 (diff) | |
| download | git-fc59ba0dfe134fbb51230d50f396f5efc9ba1721.tar.gz git-fc59ba0dfe134fbb51230d50f396f5efc9ba1721.zip | |
l10n: docs: add translation instructions in AGENTS.md
Add a new "Translating po/XX.po" section to po/AGENTS.md with detailed
workflow and procedures for AI agents to translate language-specific PO
files. Users can invoke AI-assisted translation in coding tools with a
prompt such as:
"Translate the po/XX.po file by referring to @po/AGENTS.md"
Translation results serve as drafts; human contributors must review and
approve before submission.
To address the low translation efficiency of some LLMs, batch
translation replaces entry-by-entry translation. git-po-helper
implements a gettext JSON format for translation files, replacing PO
format during translation to enable batch processing.
Evaluation with the Qwen model:
git-po-helper agent-run --agent=qwen translate po/zh_CN.po
Test translation (127 entries, 50 per batch):
Initial state: 5998 translated, 91 fuzzy, 36 untranslated
Final state: 6125 translated, 0 fuzzy, 0 untranslated
Successfully translated: 127 entries (91 fuzzy + 36 untranslated)
Success rate: 100%
Benchmark results (3-run average):
AI agent using gettext tools:
| Metric | Value |
|------------------|--------------------------------|
| Avg. Num turns | 86 (176, 44, 40) |
| Avg. Exec. Time | 20m44s (39m56s, 14m38s, 7m38s) |
| Successful runs | 3/3 |
AI agent using git-po-helper (JSON batch flow):
| Metric | Value |
|------------------|--------------------------------|
| Avg. Num turns | 56 (68, 39, 63) |
| Avg. Exec. Time | 19m8s (28m55s, 9m1s, 19m28s) |
| Successful runs | 3/3 |
The git-po-helper flow reduces the number of turns (86 → 56) with
similar execution time; the bottleneck appears to be LLM processing
rather than network interaction.
Signed-off-by: Jiang Xin <worldhello.net@gmail.com>
Diffstat (limited to 't/t4013/diff.format-patch_--stdout_initial..master^')
0 files changed, 0 insertions, 0 deletions
