AhmedRz1122/Lango

A production translation app used offline and online translation with speech recognition support created using Flutter and Genkit.

Dart

2

6 commits

updated Oct 16, 2026

See the code

README

Lango

A beautiful Flutter translation app with offline and online modes, voice-to-text support, and AI-powered insights via Genkit.

Features

  • Splash onboarding — Lexora-inspired design with Lango branding
  • Online translation — Seamless cloud translation (no provider branding in UI)
  • Offline translation — Tencent HY-MT1.5 model via Genkit backend
  • Voice input — Offline speech recognition with Vosk
  • AI assistant — Genkit-powered translation explanations and cultural insights
  • MVVM architecture — Clean separation of Models, Views, and ViewModels

Project Structure

lango/
├── lib/
│   ├── core/          # Theme, constants, utilities
│   ├── models/        # Data models
│   ├── services/      # Translation, speech, Genkit AI services
│   ├── viewmodels/    # MVVM ViewModels
│   └── views/         # Screens and widgets
├── backend/           # Genkit Node.js AI backend
│   ├── src/index.ts   # Genkit flows
│   └── hy_mt_service.py  # HY-MT1.5 Python service
└── assets/
    └── models/        # Vosk speech models

Prerequisites

  • Flutter 3.11+ (installed)
  • Node.js 20+
  • Python 3.10+ (for HY-MT1.5 offline service, optional)
  • Google AI API key (for Genkit AI features)

Setup

1. Flutter App

cd D:\Yards\Lango
flutter pub get

2. Vosk Speech Model

Download vosk-model-small-en-us-0.15.zip from https://alphacephei.com/vosk/models and place it in assets/models/.

For Windows, install Vosk native binaries:

dart run vosk_flutter_service install -t windows

3. Genkit Backend

cd backend
npm install
cp .env.example .env
# Edit .env and set GOOGLE_GENAI_API_KEY
npm run dev

The Genkit server runs on http://localhost:3400.

4. HY-MT1.5 Offline Service (Optional)

cd backend
pip install -r requirements.txt
python hy_mt_service.py

Runs on http://localhost:3401. Without this, offline mode uses Genkit AI fallback.

5. Run the App

flutter run

Translation Modes

ModeEngineWhen Used
OnlineCloud translation APIInternet available
OfflineTencent HY-MT1.5No internet or forced offline
AutoSwitches automaticallyDefault

Architecture (MVVM)

  • Models: Language, TranslationRecord, TranslationMode
  • ViewModels: AppViewModel, TranslateViewModel (via Provider)
  • Views: Screens and reusable widgets
  • Services: OnlineTranslationService, OfflineTranslationService, VoskSpeechService, GenkitAiService

Genkit Flows

FlowPurpose
hyMtTranslateFlowOffline HY-MT1.5 translation
explainTranslationFlowAI translation explanations
contextualTranslateFlowContext-aware translation
suggestPhrasesFlowTopic-based phrase suggestions

License

Private project.

AhmedRz1122/Lango

A production translation app used offline and online translation with speech recognition support created using Flutter and Genkit.

Dart

2

6 commits

updated Oct 16, 2026

See the code

README

Lango

A beautiful Flutter translation app with offline and online modes, voice-to-text support, and AI-powered insights via Genkit.

Features

  • Splash onboarding — Lexora-inspired design with Lango branding
  • Online translation — Seamless cloud translation (no provider branding in UI)
  • Offline translation — Tencent HY-MT1.5 model via Genkit backend
  • Voice input — Offline speech recognition with Vosk
  • AI assistant — Genkit-powered translation explanations and cultural insights
  • MVVM architecture — Clean separation of Models, Views, and ViewModels

Project Structure

lango/
├── lib/
│   ├── core/          # Theme, constants, utilities
│   ├── models/        # Data models
│   ├── services/      # Translation, speech, Genkit AI services
│   ├── viewmodels/    # MVVM ViewModels
│   └── views/         # Screens and widgets
├── backend/           # Genkit Node.js AI backend
│   ├── src/index.ts   # Genkit flows
│   └── hy_mt_service.py  # HY-MT1.5 Python service
└── assets/
    └── models/        # Vosk speech models

Prerequisites

  • Flutter 3.11+ (installed)
  • Node.js 20+
  • Python 3.10+ (for HY-MT1.5 offline service, optional)
  • Google AI API key (for Genkit AI features)

Setup

1. Flutter App

cd D:\Yards\Lango
flutter pub get

2. Vosk Speech Model

Download vosk-model-small-en-us-0.15.zip from https://alphacephei.com/vosk/models and place it in assets/models/.

For Windows, install Vosk native binaries:

dart run vosk_flutter_service install -t windows

3. Genkit Backend

cd backend
npm install
cp .env.example .env
# Edit .env and set GOOGLE_GENAI_API_KEY
npm run dev

The Genkit server runs on http://localhost:3400.

4. HY-MT1.5 Offline Service (Optional)

cd backend
pip install -r requirements.txt
python hy_mt_service.py

Runs on http://localhost:3401. Without this, offline mode uses Genkit AI fallback.

5. Run the App

flutter run

Translation Modes

ModeEngineWhen Used
OnlineCloud translation APIInternet available
OfflineTencent HY-MT1.5No internet or forced offline
AutoSwitches automaticallyDefault

Architecture (MVVM)

  • Models: Language, TranslationRecord, TranslationMode
  • ViewModels: AppViewModel, TranslateViewModel (via Provider)
  • Views: Screens and reusable widgets
  • Services: OnlineTranslationService, OfflineTranslationService, VoskSpeechService, GenkitAiService

Genkit Flows

FlowPurpose
hyMtTranslateFlowOffline HY-MT1.5 translation
explainTranslationFlowAI translation explanations
contextualTranslateFlowContext-aware translation
suggestPhrasesFlowTopic-based phrase suggestions

License

Private project.