What survives when a poem crosses a language?
VerseShift is a poetry translation analysis tool that translates your verse and shows you where the translation breaks down, where meaning drifts, and where culture gets lost in the crossing.
Built for the Lingo.dev Multilingual Hackathon #3 · March 2025
- Poem of the Day
- Translation Voice (Brand Voice)
- Glossary Lock
- Auto Translate + Analysis (16 Languages)
- Drift Chain — The Telephone Game of Poetry
- Cultural Idiom Equivalence
- Audio Playback
- Download & Export
- Poetry Penpal Room
| Layer | Technology |
|---|---|
| Framework | Next.js 14 (App Router) |
| Translation | Lingo.dev SDK — lingo.dev/sdk |
| AI Analysis | Groq with llama-3.1-8b-instant |
| Styling | Vanilla CSS with CSS Variables (no framework) |
| Typography | Cormorant Garamond · Jost · Scheherazade New (Google Fonts) |
| Audio | Web Speech API (browser-native, zero cost) |
| Runtime | Node.js 18+ |
VerseShift uses Lingo.dev in three distinct ways:
lingo.localizeText()— Core translation across all 16 supported locales, used in both the Auto Translate and Drift Chain features- Glossary Lock pattern — Words wrapped in
«»markers before being passed to Lingo, preserving untranslatable terms through every hop - Brand Voice injection — Style persona prompts prepended to poem text before localization, mimicking Lingo.dev's brand voice capability
verseshift/
├── app/
│ ├── page.tsx # Main UI — all features
│ ├── layout.tsx
│ └── api/
│ ├── translate/
│ │ └── route.ts # Auto translate + analysis
│ ├── drift/
│ │ └── route.ts # Drift chain engine
│ ├── idioms/
│ │ └── route.ts # Cultural idiom equivalence
│ └── rooms/
│ ├── route.ts # Penpal room create/join/read
│ └── message/
│ └── route.ts # Send room message
├── lib/
│ ├── aiAnalysis.ts # Groq analysis (score + warnings)
│ └── roomStore.ts # In-memory room state
└── .env.local # API keys (see setup below)
# Clone the repo
git clone https://github.com/yourusername/verseshift.git
cd verseshift
# Install dependencies
npm install
# Set up environment variables
cp .env.example .env.localCreate a .env.local file in the root:
LINGODOTDEV_API_KEY=your_lingo_api_key_here
LINGODOTDEV_ENGINE_ID=your_lingo_engine_id_here
GROQ_API_KEY=your_groq_api_key_herenpm run dev- Select your source language
- Choose a translation voice (optional — try Lyrical or Minimalist)
- Add any locked words that should never be translated
- Paste your poem (or load the Poem of the Day)
- Select target languages and click Analyse Poem
- Enter a poem in the Analysis section
- Navigate to Drift Chain
- Build a chain by adding languages in sequence (e.g. FR → JA → AR → EN)
- Click Run Drift Chain to watch your poem evolve
- Enter your name and preferred reading language
- Click Create Room — share the code or link with a friend
- Each person writes in their own language — everyone reads in theirs
| Code | Language | RTL |
|---|---|---|
en |
English | — |
de |
German | — |
ar |
Arabic | ✓ |
ja |
Japanese | — |
fr |
French | — |
es |
Spanish | — |
hi |
Hindi | — |
ur |
Urdu | ✓ |
pa |
Punjabi | — |
ko |
Korean | — |
zh |
Chinese | — |
it |
Italian | — |
pt |
Portuguese | — |
ru |
Russian | — |
tr |
Turkish | — |
bn |
Bengali | — |
| Feature | Preview |
|---|---|
| Home | ![]() |
| Translation Analysis | ![]() |
| Share Card | ![]() |
- Lingo.dev — Translation infrastructure
- Groq — Fast LLM inference
- Next.js — Framework
- Google Fonts — Cormorant Garamond, Jost, Scheherazade New
MIT — see LICENSE
"Poetry is what gets lost in translation." — Robert Frost


