Background
JS/PHP string translation is now automated via Aide (wcpos/translations#41). Docs are the remaining untranslated surface — 11 locales configured in Docusaurus but no translated markdown files exist yet.
What needs to happen
1. Dispatch trigger in wcpos/docs
Add a workflow that fires on push to versioned_docs/version-1.x/ and src/ (changed .md/.mdx files) and POSTs to Aide's webhook:
on:
push:
branches: [main]
paths:
- 'versioned_docs/version-1.x/**'
- 'src/pages/**'
Payload shape (similar to translations repo):
{
"project": "wcpos-docs",
"changed_files": ["versioned_docs/version-1.x/getting-started/index.md"]
}
2. New translate-docs skill for Aide
Different from translate-strings — docs are long-form MDX, not key-value pairs. Aide needs to:
- Fetch changed
.md/.mdx files from the docs repo
- Translate body content only — preserve frontmatter keys, JSX component tags and their props, code blocks, links
- Write output to
i18n/{locale}/docusaurus-plugin-content-docs/version-1.x/{same-relative-path}
- Commit all locales atomically (same approach as
translate-strings)
3. Translation Memory for docs
Docs TM is sentence/paragraph-level, not string-key-level. Options:
- Use the same TM infrastructure but key on SHA of each paragraph
- Or skip TM for docs initially (re-translate on every change, rely on git diff to see what actually changed)
4. Retire the manual translate.yml in this repo
Once Aide is wired up, translate.yml and qa-translations.yml can be retired the same way they were in wcpos/translations.
Key differences from JS/PHP string translation
|
JS/PHP strings |
Docs |
| Format |
Flat key-value JSON / POT |
Full markdown/MDX |
| Trigger |
repository_dispatch from monorepo |
push to versioned_docs/ |
| TM unit |
Single UI string |
Paragraph or heading |
| Output path |
translations/js/{locale}/ |
i18n/{locale}/docusaurus-plugin-content-docs/ |
| Placeholder concern |
{count}, %s etc. |
JSX tags, frontmatter, code blocks |
Open questions before implementation
References
Background
JS/PHP string translation is now automated via Aide (wcpos/translations#41). Docs are the remaining untranslated surface — 11 locales configured in Docusaurus but no translated markdown files exist yet.
What needs to happen
1. Dispatch trigger in wcpos/docs
Add a workflow that fires on push to
versioned_docs/version-1.x/andsrc/(changed .md/.mdx files) and POSTs to Aide's webhook:Payload shape (similar to translations repo):
{ "project": "wcpos-docs", "changed_files": ["versioned_docs/version-1.x/getting-started/index.md"] }2. New
translate-docsskill for AideDifferent from
translate-strings— docs are long-form MDX, not key-value pairs. Aide needs to:.md/.mdxfiles from the docs repoi18n/{locale}/docusaurus-plugin-content-docs/version-1.x/{same-relative-path}translate-strings)3. Translation Memory for docs
Docs TM is sentence/paragraph-level, not string-key-level. Options:
4. Retire the manual
translate.ymlin this repoOnce Aide is wired up,
translate.ymlandqa-translations.ymlcan be retired the same way they were in wcpos/translations.Key differences from JS/PHP string translation
repository_dispatchfrom monorepoversioned_docs/translations/js/{locale}/i18n/{locale}/docusaurus-plugin-content-docs/{count},%setc.Open questions before implementation
version-1.xonly, orversion-0.4.xas well?<Badge text="New" />)References
agents/aide/workspace/skills/translate-strings/SKILL.md