Examples
Runnable projects under examples/ on GitHub — each with its own config, committed locale outputs, and README. You can explore translated files without an API key; re-running translation requires a provider key (Providers and models).
Run standalone (npx degit)
Copy one example without cloning the full repository. Each declares a published caret range of ai-i18n-tools matching the current package version and installs the CLI from npm:
npx degit wsj-br/ai-i18n-tools/examples/<name> <name>
cd <name>
pnpm installIf you cloned the whole ai-i18n-tools repository instead, run pnpm install and pnpm run build at the repository root, then cd examples/<name>. Workspace examples use the local CLI via their pnpm run i18n:* scripts, or bare ai-i18n-tools … after PATH setup. See Installation — Cloned monorepo.
List of Examples
| Example | Best for | Copy with degit | Run |
|---|---|---|---|
| console-app | Smallest working app with t() UI strings + README translation | npx degit wsj-br/ai-i18n-tools/examples/console-app console-app | pnpm start |
| nextjs-app | React / Next.js + plurals + dashboard; nested Docusaurus docs + flat README + SVG assets | npx degit wsj-br/ai-i18n-tools/examples/nextjs-app nextjs-app | pnpm dev (app :3030; cd docs-site && pnpm start for docs :3040) |
| docusaurus-docs | Docusaurus documentation site only (docusaurus preset) | npx degit wsj-br/ai-i18n-tools/examples/docusaurus-docs docusaurus-docs | pnpm start (:3100; build + serve, locale menu works) |
| astro-website | Astro landing page: full-page HTML + t() hybrid | npx degit wsj-br/ai-i18n-tools/examples/astro-website astro-website | pnpm dev |
| astro-docs | Astro Starlight documentation site | npx degit wsj-br/ai-i18n-tools/examples/astro-docs astro-docs | pnpm dev (:3050) |
| vitepress-docs | VitePress docs site + theme JSON (pt-BR, zh-Hans) | npx degit wsj-br/ai-i18n-tools/examples/vitepress-docs vitepress-docs | pnpm run docs:dev (:3060) |
| nextra-docs | Nextra 4 MDX + _meta.ts / dictionary .ts shell (pt-BR, zh-Hans) | npx degit wsj-br/ai-i18n-tools/examples/nextra-docs nextra-docs | pnpm run dev (:3070) |
| fumadocs-docs | Fumadocs 4 MDX + meta.json / UI catalog (pt, zh, dot parser) | npx degit wsj-br/ai-i18n-tools/examples/fumadocs-docs fumadocs-docs | pnpm run dev (:3080) |
| plain-html | Plain HTML + data-i18n* markers; static locale JSON (dashboard-style UI) | npx degit wsj-br/ai-i18n-tools/examples/plain-html plain-html | pnpm dev (:3090) |
| multi-provider | Pick or benchmark an LLM provider (-P / --provider) | npx degit wsj-br/ai-i18n-tools/examples/multi-provider multi-provider | ai-i18n-tools translate-docs -P openai --force |
| test-markdown | Regression-test markdown / CJK translation (Devanagari, MDX) | npx degit wsj-br/ai-i18n-tools/examples/test-markdown test-markdown | pnpm build |
| intlayer-migration | Intlayer .content.ts → t() (migrate-intlayer, reset + AI-agent report) | npx degit wsj-br/ai-i18n-tools/examples/intlayer-migration intlayer-migration | pnpm reset && pnpm dev (:3091) |
Each Example name links to its GitHub README with full setup, commands, and project layout — or browse the examples index in the repository.
Disclaimer
Product names and icons belong to their respective owners and are used for identification purposes only. This software is not affiliated with or endorsed by those brands.