<t9n />
DOCUMENTATION

Documentation

Dive into t9n's features, from basic usage to advanced incremental updates and AI context optimization.

Basic Feature: Real-time Translation

t9n is designed for i18n JSON format. We have optimized the Prompt strategy to ensure all code variables (such as {name} or {{count}}) are strictly protected during the translation process.

  • Support batch selection of target languages, generating multiple translations at once.
  • Real-time preview: source content and target content compared side by side.
{
"welcome": "Welcome back, {user}!"
}

Context Awareness

"This app is a financial dashboard for crypto traders. Use professional terminology."
✓ "Portfolio" → "Investment Portfolio"
✗ "Portfolio" → "Artwork Collection"

Translation is more than just word-for-word. By providing application background, AI can choose vocabulary more accurately.

For example, the same word "Menu" is "menu" in a restaurant app and "function list" in design software. Providing Context can eliminate ambiguity.

Intelligent Incremental Update (Diff Mode)

When your source language file (e.g. en.json) has new content, you don't need to re-translate the entire file. t9n's incremental update mode now supports full automation.

New: Fully Automatic Multi-file Recognition
1. Multi-select Upload

Select English (base) and existing translation files (e.g., Chinese, Japanese) simultaneously in the upload dialog. No more manual comparisons.

2. Smart Base Detection

The system automatically counts keys in each file and treats the most complete one as the 'translation base', auto-filling missing parts in others.

3. Precision Translation

Missing keys are marked as 🚧 [MISSING]. AI only translates these markers, saving you over 90% in credits.

"Keep 100% of existing translations, only address new requirements."

t9n CLI

Professional i18n management from your terminal. Automate your translation workflow with our powerful command-line interface.

1. InstallationGlobal
$ npm install -g t9n-cli
2. Auth & Init
Link your local environment with your t9n account.
$ t9n auth <key>
Create t9n.config.json to save your project preferences.
$ t9n init
3. Translation
Directly translate local files and save results automatically.
$ t9n translate ./en.json -t zh-CN,ja
4. Scan & Diff
Find missing keys in your source code that aren't in your JSON yet.
$ t9n scan ./src
Smart incremental updates for all languages in a folder.
$ t9n diff ./dictionaries
Ready for Production