Skip to content

sudoeren/localce

Repository files navigation

Localce

Localce

Privacy-first AI translation that runs entirely on your machine

Features β€’ Quick Start β€’ Installation β€’ Usage β€’ Tech Stack

Next.js React TypeScript Tailwind License

Localce Screenshot


Why Localce?

Traditional translation services send your text to remote servers. Localce is different β€” it uses LM Studio to run AI models locally on your computer. Your data never leaves your device.

Feature Localce Cloud Services
Privacy βœ… 100% Local ❌ Data sent to servers
Internet Required ❌ Works offline βœ… Always required
Cost βœ… Free forever πŸ’° Usually paid
Speed ⚑ Instant 🐌 Network latency

Features

πŸ”’ Complete Privacy

All translations happen locally using LM Studio. No data is ever sent to external servers.

🌍 Multi-Language Support

Translate between 12+ languages including English, Turkish, Spanish, French, German, Italian, Portuguese, Russian, Japanese, Chinese, Korean, and Arabic.

πŸ“„ Text & File Translation

Translate plain text or upload files (.txt, .md, .json, .csv, .srt, and more).

🎭 Translation Tones

Choose from Standard, Formal, Casual, or Technical tones to match your context.

πŸ“š History & Favorites

Automatically save your translation history and star your favorite translations.

🎨 Beautiful UI

Modern, responsive design with dark mode support and smooth animations.

πŸ”Š Text-to-Speech

Listen to translations with built-in TTS support for multiple languages.


Quick Start

Prerequisites

  1. LM Studio β€” Download and install
  2. Translation Model β€” Download a model (recommended: HY-MT1.5-7B)
  3. Start Local Server β€” Run LM Studio's local server on port 1234

Run Localce

# Clone
git clone https://github.com/sudoeren/localce.git && cd localce

# Install
npm install

# Start
npm run dev

Open http://localhost:3000 and start translating!


Installation

Option 1: Development

git clone https://github.com/sudoeren/localce.git
cd localce
npm install
npm run dev

Option 2: Docker

git clone https://github.com/sudoeren/localce.git
cd localce
docker-compose up -d

Option 3: Docker Build

docker build -t localce .
docker run -p 3000:3000 --add-host=host.docker.internal:host-gateway localce

Usage

Text Translation

  1. Select source language (or Auto Detect)
  2. Select target language
  3. Choose translation tone (optional)
  4. Enter text
  5. Press Ctrl+Enter or click Translate

File Translation

  1. Switch to File mode
  2. Upload a text file
  3. Select target language
  4. Click Translate
  5. Download the translated file

Keyboard Shortcuts

Shortcut Action
Ctrl+Enter Translate
Ctrl+C Copy translation

Configuration

Environment Variables

Create a .env.local file:

LM_STUDIO_URL=http://localhost:1234/v1/chat/completions
LM_STUDIO_MODEL=hy-mt1.5-7b/HY-MT1.5-7B-Q4_K_M.gguf
LM_STUDIO_TEMPERATURE=0.2

In-App Settings

Navigate to Settings to configure:

  • LM Studio connection URL
  • Model temperature
  • Theme (Light/Dark/System)
  • Language (English/Turkish)

Tech Stack

Category Technology
Framework Next.js 16
UI Library React 19
Language TypeScript
Styling Tailwind CSS v4
Components shadcn/ui + Radix UI
Animations Framer Motion
AI Backend LM Studio

Project Structure

localce/
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ app/                    # Next.js App Router
β”‚   β”‚   β”œβ”€β”€ page.tsx           # Main translator
β”‚   β”‚   β”œβ”€β”€ history/           # Translation history
β”‚   β”‚   β”œβ”€β”€ favorites/         # Saved translations
β”‚   β”‚   β”œβ”€β”€ settings/          # App settings
β”‚   β”‚   └── api/translate/     # Translation API
β”‚   β”œβ”€β”€ components/            # React components
β”‚   β”œβ”€β”€ contexts/              # React contexts
β”‚   β”œβ”€β”€ hooks/                 # Custom hooks
β”‚   └── lib/                   # Utilities
β”œβ”€β”€ public/                    # Static assets
β”œβ”€β”€ Dockerfile                # Docker config
└── docker-compose.yml        # Docker Compose

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing)
  3. Commit your changes (git commit -m 'Add amazing feature')
  4. Push to the branch (git push origin feature/amazing)
  5. Open a Pull Request

License

MIT License β€” see LICENSE for details.


Developed by Eren Cakar

Packages

 
 
 

Contributors

Languages