AI-native translation tool using source text as keys
Project description
TransDuck
AI-powered translation for apps and websites. Fast. Cheap. No keys to manage.
TransDuck translates your app's strings using AI, then caches them locally in SQLite so you never pay for the same translation twice. No translation files. No key naming. No sync headaches.
import transduck
from transduck import ait, ait_plural
transduck.initialize()
transduck.set_language("DE")
ait("Welcome to Mallorca") # → "Willkommen auf Mallorca"
ait("Hello {name}", vars={"name": "Tim"}) # → "Hallo Tim"
ait_plural("{count} night", "{count} nights", count=7) # → "7 Nächte"
Why TransDuck?
- No keys to manage — your source text is the key
- No translation files — translations live in a local SQLite database
- Translate once, pay once — cached lookups take ~0.015ms, zero API costs after first call
- AI that understands context — project and per-string context for accurate translations
- Pluralization that works everywhere — handles Russian (4 forms), Arabic (6 forms) automatically
- Dirt cheap — 1,000 strings × 5 languages ≈ $0.10 with gpt-4.1-mini
Quick Start
pip install transduck
export OPENAI_API_KEY=sk-...
transduck init
CLI
transduck scan --warm --langs DE,ES,IT # scan codebase and translate everything
transduck translate "Hello" --to DE # translate a single string
transduck stats # check your translation database
Also available for JavaScript/TypeScript
npm install transduck
Includes React/Next.js integration via transduck/react with synchronous t() for client components.
Links
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file transduck-0.7.0.tar.gz.
File metadata
- Download URL: transduck-0.7.0.tar.gz
- Upload date:
- Size: 39.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1377a4913f1d93d8e9b7bb56c682cfbb78589da9fe335d2fbfd8a20a8836ef30
|
|
| MD5 |
0fbf3c7083544f37762cfd06859c44bd
|
|
| BLAKE2b-256 |
3522deca235f5f93d230e3daacc54e01a58d950e51f8db02d576ca789718f460
|
File details
Details for the file transduck-0.7.0-py3-none-any.whl.
File metadata
- Download URL: transduck-0.7.0-py3-none-any.whl
- Upload date:
- Size: 29.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4c56484fcbe77d0780054cae5c919ddaa7444c16acecf7239e03f3099fda4356
|
|
| MD5 |
f16fa3cc823661fa2083d276218b7ae4
|
|
| BLAKE2b-256 |
4d5c5f9e6a24bac918eca62cee74c8636c342ede1a786b94fa18839fcac66a6f
|