Setup guide

Live Translator Setup Hub.

Start with the focused setup cards below. Each section opens only the part you need: test the app, configure Firebase login, expose the RTX backend with ngrok, run the Windows service, or tune safety settings.

faster-whisper FastAPI WebSocket WebRTC VAD HTTPS for LAN microphones Firebase login ngrok test tunnel Galaxy S25 client/native path
Start here

Choose one setup topic, open it, and follow it from top to bottom.

The live translator has several moving parts. This top page keeps the common paths short: test the public app, configure Firebase login, expose the RTX backend with ngrok, start the protected Windows server, and understand the safety settings. Each path now also has a copyable Markdown checklist.

1 Access: sign in, then connect backend Use this when the RTX PC backend and ngrok are already running.
Frontend

The GitHub Pages website that shows the microphone UI and transcript boxes.

Backend origin

The HTTPS URL that points to the RTX PC, for example an ngrok URL.

Admin approval

Your admin account decides which signed-in emails can use the GPU.

  1. Open the live translator app.
  2. Open Connect to server, then in 1 Access press Sign in with Google.
  3. In 2 Backend, paste the backend origin such as https://alone-catalog-rejoice.ngrok-free.dev.
  4. Press Connect backend. If your email is approved, the app asks for microphone permission and starts listening automatically.
  5. If you are admin, press Refresh admin to see active sessions and approve pending users.
2 Firebase: Google login and admin approval Use this when you want only approved email addresses to access your GPU.
Firebase Auth

Google or Facebook login for the browser app. The user's password stays with Google/Firebase.

Web config

Public browser settings such as API key, auth domain, project ID, and app ID.

Service account JSON

Private backend key saved only on the RTX PC so Python can verify login tokens.

  1. Create or open the Firebase project, then enable Authentication and Google sign-in.
  2. Add the GitHub Pages domain, for example buicongnguyen.github.io, to Firebase authorized domains.
  3. Create a Firebase Web app and copy its public config values into GitHub Actions variables such as FIREBASE_API_KEY and FIREBASE_PROJECT_ID.
  4. Download the Firebase Admin SDK service account JSON and save it outside the repo, for example C:\Users\n\secrets\firebase-service-account.json.
  5. Start the protected backend with .\start-protected-https.ps1 -FirebaseProjectId "your-firebase-project-id" -AdminEmails "your-email@gmail.com" so your email becomes admin.
  6. Approve other users from the web admin panel after they sign in once.
Never commit the Firebase Admin service account JSON. Only the Firebase Web app config is safe to deploy to GitHub Pages.
3 ngrok: public HTTPS/WSS URL for the home RTX PC Use this for free testing from another browser without installing Tailscale.
Tunnel

An outbound connection from your PC to ngrok that gives the browser a public HTTPS URL.

HTTPS/WSS

Secure HTTP and secure WebSocket. The microphone page needs these for real live audio.

Backend origin

The ngrok URL you paste into the website, without /api/health or /ws.

  1. Install or update ngrok and add your ngrok authtoken once on the RTX PC.
  2. Start the protected local backend on https://127.0.0.1:8443.
  3. Run ngrok http https://127.0.0.1:8443 --host-header=rewrite.
  4. Copy the forwarding URL, for example https://alone-catalog-rejoice.ngrok-free.dev.
  5. Paste that URL into the app's Backend origin box and press Connect backend.
Paste only the origin, for example https://abc123.ngrok-free.app. Do not paste /api/health or /ws.
$ngrok="$env:LOCALAPPDATA\Microsoft\WinGet\Links\ngrok.exe"
& $ngrok version
& $ngrok http https://127.0.0.1:8443 --host-header=rewrite
4 Windows RTX backend: start, stop, and status Use this on the Windows 11 Pro RTX 4080 Super host PC.
FastAPI backend

The Python server that receives microphone audio and returns live translation events.

Uvicorn

The Python web server process that runs FastAPI on port 8443.

Stack scripts

PowerShell helpers that start the backend, start ngrok, show status, or stop everything.

Before running the stack script, confirm the Python virtual environment, HTTPS certificate files, Firebase Admin JSON, ngrok install, and local translator-stack.local.psd1 config are already present on the RTX PC.
  1. Open PowerShell 7 on the RTX PC.
  2. Run Set-Location C:\Users\n\source\repos\Transcribe_translate.
  3. Copy translator-stack.local.example.psd1 to translator-stack.local.psd1, then edit the local file with your Firebase project ID and admin email.
  4. Start everything with .\start-translator-stack.ps1.
  5. Check the public link with .\status-translator-stack.ps1.
  6. Restart after code changes with .\start-translator-stack.ps1 -RestartBackend.
  7. Stop public access and backend with .\stop-translator-stack.ps1.
Set-Location C:\Users\n\source\repos\Transcribe_translate
Copy-Item .\translator-stack.local.example.psd1 .\translator-stack.local.psd1
notepad .\translator-stack.local.psd1
.\start-translator-stack.ps1
.\status-translator-stack.ps1
5 Safety settings: users, stale audio, and GPU heat Use this before allowing more than one person to test.
MAX_ACTIVE_SESSIONS=4

Allows four connected live translation sessions by default. This is reasonable when not everyone talks at the same time.

IDLE_TIMEOUT_SECONDS=300

Disconnects a browser after five minutes without microphone audio.

MAX_TRANSLATION_QUEUE_SEGMENTS=2

Drops older queued speech when the GPU falls behind, keeping live translation current.

GPU_MAX_TEMPERATURE_C=85

Blocks new sessions if nvidia-smi reports the GPU at or above 85C.

These are backend startup settings. GitHub Pages only shows the UI; the RTX PC enforces session limits, idle timeout, queue drops, and GPU temperature checks.
  1. Keep the default MAX_ACTIVE_SESSIONS=4 for normal use.
  2. Try -MaxActiveSessions 8 only for mostly idle users after latency, queue drops, and GPU temperature stay stable.
  3. Use the web admin panel to watch active users, last audio time, queue size, dropped segments, and GPU temperature.
  4. Keep the RTX PC ventilated and avoid heavy games or GPU work while translating.
.\start-translator-stack.ps1 -RestartBackend -MaxActiveSessions 8
nvidia-smi
Definitions first

The pieces in plain words

Read these terms first. Most setup problems become easier once you know which part is the AI server, which part is the browser client, and why HTTPS matters for a phone microphone.

Term Meaning Example in this project
Host PC / AI server The Windows PC that runs Python, FastAPI, and the Whisper model on the GPU. Your RTX 4080 Super PC at 192.168.0.20.
Client device The browser device that opens the website and sends microphone audio. A smartphone, laptop, tablet, or the host PC browser.
Backend The Python service that receives audio and returns transcript/translation events. http://127.0.0.1:8000/api/health and /ws.
Frontend / web app The HTML, CSS, and JavaScript page the user sees. The page with source text, English translation, and Start mic.
LAN Your local Wi-Fi/router network. Phone and PC must be on the same Wi-Fi unless you use a public HTTPS host.
HTTPS / WSS Secure web page and secure WebSocket. Required for smartphone or second-laptop microphone access.
Caddy / reverse proxy A small HTTPS server that forwards browser traffic to FastAPI. https://192.168.0.20:8443 forwards to http://127.0.0.1:8000.
Whisper model The local speech model that transcribes Korean and translates to English. medium for laptop tests, large-v3 for the RTX server.
VAD Voice activity detection. It decides when a speech sentence starts and ends. Prevents silence from becoming fake translation text.
Native Android app An app installed on the phone instead of a browser page. Galaxy S25 Kotlin app with local ASR, translation, and two transcript boxes.
NPU Neural processing unit: phone hardware for supported AI workloads. Useful only when the model, quantization, runtime, and delegate can target it.
LiteRT / TFLite Android-friendly model runtime for smaller on-device AI models. The right class of runtime for Galaxy S25 phone-only experiments.
Deploy process

Recommended order to deploy and test

Use this order when you want the RTX PC to host the website and a smartphone or another laptop to use its microphone.

01

Run locally on the host PC first

Start the backend and open http://127.0.0.1:8000 on the same PC. This confirms Python, CUDA, the model, and microphone capture work before adding network complexity.

python -m venv .venv
.\.venv\Scripts\Activate.ps1
pip install -r requirements.txt
python main.py
02

Bind the backend to the LAN

Restart FastAPI on 0.0.0.0 so other devices can reach it, then test the health URL from the host PC and from another device.

$env:APP_HOST="0.0.0.0"
$env:APP_PORT="8000"
$env:WHISPER_MODEL="large-v3"
$env:WHISPER_DEVICE="cuda"
$env:WHISPER_COMPUTE_TYPE="float16"
python main.py
03

Open firewall ports

Allow TCP 8000 for direct health checks and TCP 8443 for the HTTPS website. Run this from an Administrator PowerShell window on the host PC.

New-NetFirewallRule -DisplayName "Live Translator 8000" -Direction Inbound -Action Allow -Protocol TCP -LocalPort 8000 -Profile Private
New-NetFirewallRule -DisplayName "Live Translator HTTPS 8443" -Direction Inbound -Action Allow -Protocol TCP -LocalPort 8443 -Profile Private
04

Add HTTPS for phone and laptop microphones

Browsers usually block microphone access on plain LAN HTTP. Use Caddy or another reverse proxy so the client opens https://192.168.0.20:8443 while FastAPI stays on http://127.0.0.1:8000.

https://192.168.0.20:8443 {
  tls ./translate-local.pem ./translate-local-key.pem
  reverse_proxy 127.0.0.1:8000
}
05

Open from the smartphone

Put the phone on the same Wi-Fi, open https://192.168.0.20:8443, accept or trust the certificate, press Start mic, and allow microphone permission. The phone sends audio; the RTX PC returns Korean transcript and English translation.

GitHub Pages can show the guide and demo UI, but it cannot run the Python GPU backend. For real live translation, keep the backend on the RTX PC and connect to it over HTTPS/WSS.
Public access

GitHub Pages login with the RTX 4080 backend

GitHub Pages can be the public website, login screen, and microphone UI. It still cannot run the GPU model or forward live traffic by itself. The browser connects from github.io to a separate HTTPS/WSS backend URL that reaches the RTX 4080 Super PC.

Public flow
GitHub Pages UI
Firebase Google/Facebook login
Approved email check
ngrok or DuckDNS backend URL
RTX 4080 Super WebSocket
Piece Where it lives Secret?
Firebase web config Generated into docs/firebase-config.js during GitHub Pages deployment. No private key, but restrict Firebase authorized domains.
Firebase Admin service account RTX PC only, for example C:\Users\n\secrets\firebase-service-account.json. Yes. Never commit it.
Admin email ADMIN_EMAILS environment variable on the RTX PC. Keep it out of the repo.
User approvals Local SQLite database data/auth-users.sqlite3 on the RTX PC. Local-only state, ignored by Git.
Backend public URL Start with ngrok http https://127.0.0.1:8443 --host-header=rewrite; later use DuckDNS + Caddy. The URL can be shared, but the backend still requires approved login.
01

Deploy Firebase web config from GitHub variables

Add FIREBASE_API_KEY, FIREBASE_AUTH_DOMAIN, FIREBASE_PROJECT_ID, and FIREBASE_APP_ID as GitHub Actions variables. The workflow writes the public browser config during Pages deployment.

02

Start the protected backend on the RTX PC

Set-Location C:\Users\n\source\repos\Transcribe_translate
.\start-protected-https.ps1 `
  -FirebaseProjectId "your-firebase-project-id" `
  -AdminEmails "your-email@gmail.com" `
  -FirebaseCredentialsFile "C:\Users\n\secrets\firebase-service-account.json"
03

Forward the backend with HTTPS/WSS

For the first free test, run ngrok http https://127.0.0.1:8443 --host-header=rewrite and paste the HTTPS ngrok origin into the GitHub Pages backend box. Later, use DuckDNS + Caddy for a stable no-monthly-cost URL.

04

Approve users from the web admin panel

Unknown users become pending. Your admin account can refresh users, approve trusted emails, block abuse, and let approved users reconnect to use the GPU.

Decision

Choose between two app shapes

Both versions use the same core pipeline. The difference is where the model runs and how browsers reach the audio backend.

Option A: LAN GPU server + web app

Best quality

The RTX 4080 Super or RTX 5090 PC runs FastAPI and the AI model. Laptops, phones, or tablets open the web app from the local network and stream microphone audio to the server.

Use this when you want the best Korean recognition and more stable translation with a larger model such as large-v3.

Option B: Local PC + browser interface

Small app

The laptop runs the backend and model locally. The browser UI opens at http://127.0.0.1:8000, captures the mic, and shows subtitles without another server.

Use this for portable offline translation. Start with small on weaker laptop GPUs, then move to medium only after checking VRAM and thermals.
Shared pipeline
Audio input
16 kHz mono stream
VAD speech chunks
Whisper translate
English subtitles
Requirements

Minimum and recommended setup

These numbers separate official software minimums from practical live-translation recommendations. The app may start on weaker hardware, but live Korean-to-English subtitles need spare CPU, RAM, VRAM, and thermal headroom.

Case Minimum to start Recommended for useful live translation Notes and source
Browser client Modern Chrome, Edge, Firefox, or Safari; microphone permission; HTTPS or localhost. Headset or close microphone, quiet room, and same LAN as the server when using Option A. MDN documents that getUserMedia() requires a secure context such as HTTPS or localhost.
Galaxy S25 phone-only native app Android 14+, Kotlin app, microphone permission, downloaded ASR/translation models, and battery/thermal headroom. Use the S25 as a browser client to the RTX server first; then prototype native ASR with Android APIs or WhisperKit Tiny/Base plus ML Kit Translation. Samsung lists the S25 series with Snapdragon 8 Elite for Galaxy and stronger NPU performance, but NPU use still depends on mobile runtimes such as LiteRT/TFLite and supported delegates.
A1000-class local laptop NVIDIA driver, CUDA-capable GPU, 4 GB VRAM practical floor, Python 3.11/3.12 recommended, 8 GB system RAM. 8 GB VRAM, 16 GB system RAM, plugged-in power mode, small first, then medium if stable. OpenAI lists small at about 2 GB VRAM and medium at about 5 GB; leave extra room for Windows, browser, and buffers.
CPU fallback laptop x86-64 CPU with SSE 4.1 or ARM64, 8 GB RAM, base with CPU int8. 8+ CPU threads, 16 GB RAM, base or small; expect slower subtitle updates. CTranslate2 lists x86-64 SSE 4.1 and ARM64 CPU support; faster-whisper can run CPU int8.
RTX 4080 Super LAN server 16 GB VRAM GPU, 16 GB system RAM, NVIDIA driver, Python, LAN access, and HTTPS for laptop microphone clients. 32 GB system RAM, Ethernet, large-v3, CUDA float16, Caddy HTTPS reverse proxy. NVIDIA lists RTX 4080 Super with 16 GB GDDR6X; OpenAI lists large-class Whisper at about 10 GB VRAM.
RTX 5090 LAN server NVIDIA GPU with enough VRAM for large-v3; 16 GB system RAM; wired or strong Wi-Fi LAN. RTX 5090, 32 GB system RAM, Ethernet, large-v3, CUDA float16, HTTPS reverse proxy. NVIDIA lists RTX 5090 with 32 GB GDDR7; OpenAI lists large-class Whisper at about 10 GB VRAM.
Meeting/system audio helper Windows PC, microphone mode first, then WASAPI loopback for system audio. Desktop helper that captures Zoom, Teams, YouTube, or browser audio and sends PCM to the same backend. Microsoft's WASAPI loopback sample is the reference path for Windows system-audio capture.
Whisper model Official approximate VRAM Use in this project Practical guidance
base About 1 GB CPU fallback or very weak GPU testing. Fastest fallback, but Korean-to-English quality is limited.
small About 2 GB Default safe preset for A1000-class laptops. Best first test for low latency and low VRAM pressure.
medium About 5 GB Quality mode for 8 GB laptop GPUs. Use int8_float16, beam_size=1, and watch nvidia-smi.
large-v3 Large-class reference is about 10 GB Best fit for the RTX 5090 LAN server. Use on the server for better Korean recognition and translation stability.
turbo About 6 GB Not recommended for this Korean-to-English translation app. OpenAI notes turbo is not trained for translation tasks.
Minimum VRAM is not the same as smooth live translation. If the model barely fits, subtitles may lag, the GPU may throttle, or the app may fail when the browser and Windows also use GPU memory.
Install resources

What each download is for

Use official links first. Install the base tools before tuning models, because most setup failures come from missing Python, CUDA libraries, or the NVIDIA driver. FFmpeg is useful optional tooling, but this repo's live path sends WAV/PCM data directly to faster-whisper.

Resource Official link Why it matters Check command
Python 3.11 or 3.12 python.org Windows downloads Runs the FastAPI backend and the AI inference package. python --version
Git for Windows git-scm.com/download/win Downloads the project and keeps the GitHub Pages guide updated. git --version
FFmpeg ffmpeg.org/download Optional helper for decoding, converting, and inspecting audio files outside the live browser stream. ffmpeg -version
NVIDIA driver NVIDIA official drivers Makes the A1000, RTX 4080 Super, or RTX 5090 visible to CUDA software. nvidia-smi
CUDA runtime CUDA Windows install guide Provides GPU libraries such as cuBLAS used by CTranslate2. where.exe cublas64_12.dll
cuDNN cuDNN Windows install guide Provides neural network kernels needed by current GPU builds. where.exe cudnn64_9.dll
faster-whisper SYSTRAN/faster-whisper Runs Whisper models faster through the CTranslate2 engine. pip show faster-whisper
Caddy or mkcert Caddy HTTPS / mkcert Creates trusted HTTPS for LAN microphone use from other devices. https://translate.local
For the laptop-only app, HTTPS is not required because http://127.0.0.1 counts as a browser secure context. For another phone or laptop on the LAN, use HTTPS and wss://.
Terminology

Vocabulary for this setup

These terms appear in commands and error messages. Knowing them makes it much easier to decide whether a problem is audio, network, model quality, or GPU setup.

Term Plain meaning In this project
ASR Automatic speech recognition: speech into text. Whisper can transcribe Korean when task=transcribe.
Speech translation Speech in one language directly into text in another language. Whisper uses task=translate for Korean speech to English text.
Native Android app An APK installed on the phone, normally written in Kotlin or Java. A Galaxy S25 app can capture audio with Android APIs and show the same Korean/English text layout.
NPU Phone AI accelerator hardware, separate from CPU and GPU. It is not automatic. The model must use a compatible runtime, quantization, operators, and device delegate.
LiteRT / TFLite Mobile inference runtime for Android AI models. Use this class of runtime for phone-sized Whisper or translation models, not desktop Python inference.
ML Kit Translation Google on-device text translation API for Android and iOS. Good fit after ASR produces Korean text; translate ko to en.
Qualcomm AI Hub Qualcomm tools and examples for optimized on-device AI models. WhisperKit Android provides a Kotlin/C++ TFLite starting point for Whisper Tiny/Base ASR.
VAD Voice activity detection: deciding when someone is speaking. This repo uses WebRTC VAD to stop silence from being sent to the model and decide when a subtitle line is final.
WebSocket A long-running browser-to-server connection. The browser streams audio chunks and receives subtitle updates over /ws.
HTTPS / WSS Encrypted web page and encrypted WebSocket. Needed when a phone or another laptop opens the app from the LAN.
localhost / 127.0.0.1 The same computer you are using. Use this for the local laptop app: http://127.0.0.1:8000.
LAN Local area network: devices on your home or office Wi-Fi/router. The RTX server might be 192.168.1.50; clients connect to it.
Reverse proxy A small web server that forwards browser traffic to the backend. Caddy can expose https://translate.local while FastAPI stays on port 8000.
CUDA / cuDNN NVIDIA GPU runtime libraries for AI inference. Missing DLLs here usually mean the model cannot run on the GPU yet.
CTranslate2 The inference engine used by faster-whisper. It decides whether cuda, int8_float16, or CPU fallback is available.
VRAM GPU memory. A1000 laptops should start with small; RTX 5090 can use large-v3.
compute_type The math precision used by the model. int8_float16 saves memory on laptop GPUs; float16 fits better on the RTX server.
beam_size How many decoding paths the model compares. 1 is faster; 3 can improve text quality with more latency.
WASAPI loopback Windows system-audio capture. Needed later for Zoom, Teams, YouTube, or meeting audio without using speakers.
Models

Recommended model presets

Whisper direct translation is the simplest first version: Korean speech goes straight into English text. Add a separate Korean transcript and text translator later if you need better meaning preservation for difficult speech. On A1000-class laptops, pick the model by available VRAM first, then tune for quality.

Target Model Runtime Preset
A1000 conservative mode small faster-whisper cuda, int8_float16, beam_size=1, source transcript off
A1000 quality mode medium faster-whisper cuda, int8_float16, beam_size=1-3, only when VRAM is stable
CPU fallback base or small faster-whisper CPU int8 or whisper.cpp Lower quality and slower, useful when CUDA is unavailable
RTX 4080 Super LAN server large-v3 faster-whisper cuda, float16, beam_size=1-3, HTTPS endpoint for laptop clients
RTX 5090 LAN server large-v3 faster-whisper cuda, float16, beam_size=1-3
Avoid turbo for the first Korean-to-English translation build. OpenAI's Whisper documentation notes that turbo is not trained for translation tasks.
Some A1000 laptops ship with less VRAM than desktop/workstation A1000 cards. Run nvidia-smi first and choose small when the GPU has 4 GB or when other apps are already using memory.
Modern options

Better model research for smoother live translation

For this project, "better" means two different things. One is better Korean-to-English translation quality. The other is a smoother live subtitle feel, where text appears quickly but does not change too much after it is shown. The latest research points to improving the streaming policy first, then testing new model branches.

Option What it improves Fit for your hardware Recommendation
faster-whisper + large-v3 Best practical direct Korean speech to English text path in this repo. Excellent on RTX 4080 Super; use small or medium on A1000. Keep as the default server model. Use beam_size=1 for latency, 3 for quality.
SimulStreaming or Whisper-Streaming policy Live smoothness: stable partial captions, less awkward chunking, lower perceived delay. Good match for RTX 4080 Super server. Also usable with smaller A1000 models. Best next upgrade. It changes how audio chunks are committed, not only which model is loaded.
SeamlessM4T v2 Large Translation-native speech-to-text translation model with Korean speech and text support. Test on RTX 4080 Super only. It is heavier than the current faster-whisper stack. Research branch. Good candidate to compare quality, but check license and latency before using it broadly.
Voxtral Mini 4B Realtime + text translator Very low-latency Korean transcription, then a second model translates Korean text to English. RTX 4080 Super has the right class of VRAM; A1000 is not the right first target. Research branch for smooth captions. Use only if you are comfortable adding vLLM or Transformers 5.
Qwen3-ASR + OPUS-MT or NLLB Modern Korean ASR plus separate Korean-to-English machine translation. Possible on RTX 4080 Super; maybe test 0.6B ASR on stronger A1000 laptops. Useful experiment if direct Whisper translation misses Korean details, but it adds pipeline latency.
NVIDIA Parakeet / Canary family Strong modern ASR and speech models in supported languages. Good NVIDIA stack, but Korean-to-English coverage is the issue. Do not use as the main Korean translator today unless a specific Korean translation model card supports the exact task.
Best current plan: keep large-v3 on the RTX 4080 Super server, then add SimulStreaming-style commit logic. After that, benchmark SeamlessM4T v2 and Voxtral/Qwen ASR cascades against the same Korean test clips.
ASR-only models are not a drop-in replacement for task=translate. They first produce Korean text, then need a text translation model such as OPUS-MT Korean-to-English or NLLB. This can improve meaning, but every extra model adds latency and another place for errors.
Galaxy S25

Using the S25 as a client or native translator

The Galaxy S25 is strong enough to be part of this system in two different ways. The best quality path is still using the phone as the microphone client while the RTX 4080 Super PC runs large-v3. A phone-only native app is possible too, but it should use Android-sized models and runtimes.

Recommended: S25 as microphone client

Best quality

Open the translator website from the Galaxy S25, allow microphone permission, and let the RTX server do the heavy AI work. This keeps the phone cool and gives better Korean recognition than a tiny phone model.

For LAN, open https://192.168.0.20:8443. For outside the house, use Cloudflare Tunnel plus Cloudflare Access login instead of router port forwarding.

Experimental: S25 native app

Phone only

Build a Kotlin Android app that captures the microphone, transcribes Korean locally, translates Korean text to English, and renders the same two scrollable text boxes.

Start with Android on-device speech recognition or ML Kit GenAI Speech Recognition where available. For a custom ASR model, test Qualcomm AI Hub WhisperKit Android with Whisper Tiny or Base, then use ML Kit Translation for Korean-to-English text.
Decision Use on Galaxy S25 Why
Need best accuracy Use S25 browser + RTX 4080 Super server. The server can run large-v3 on CUDA while the phone only streams audio.
Need offline travel mode Build native Kotlin app with phone-sized ASR and on-device translation. No home server required, but quality and latency depend on mobile model size.
Want to use the NPU Use LiteRT/TFLite, Qualcomm AI Hub assets, and supported delegates. The NPU is not a direct replacement for desktop CUDA; unsupported models may fall back to CPU or GPU.
Want quick comparison Compare against Samsung Live Translate or Interpreter. Samsung supports Korean and English translation features on S25, but those features are benchmarks rather than this app's backend API.
Phone-only native flow
S25 microphone
Kotlin AudioRecord
WhisperKit Tiny/Base or Android ASR
ML Kit ko -> en
Two transcript boxes
01

Keep the server path as the quality baseline

First test the S25 as a browser client against the RTX server. Record sample Korean phrases and save the output so the native app has a real comparison target.

02

Prototype native ASR before optimizing the NPU

Build the Android UI and microphone pipeline first. Test Android SpeechRecognizer.createOnDeviceSpeechRecognizer() or ML Kit GenAI Speech Recognition on the actual S25. If availability or Korean accuracy is not good enough, move to WhisperKit Android.

03

Add on-device Korean-to-English text translation

Once Korean text appears reliably, use ML Kit Translation for ko to en. Download models before travel and test in airplane mode.

04

Profile acceleration last

After the app works, test LiteRT/TFLite GPU or NPU delegates and Qualcomm AI Hub optimized models. Keep CPU and GPU fallbacks because Android NPU support is not plug-and-play for every model.

Practical recommendation: use the Galaxy S25 as the remote client for the RTX server when quality matters, and build the native app as a second portable/offline track with Whisper Tiny/Base or Android-recognizer ASR.
The standalone planning note is saved as docs/galaxy-s25-native.md.
A1000 laptop path

Setup for weaker local GPUs

The local laptop build should be conservative by default. The browser, Python server, VAD, and Whisper model all run on the same PC, so spare VRAM and heat matter more than peak benchmark speed.

01

Check the GPU before choosing a model

Confirm the NVIDIA driver is visible, note total VRAM, and close heavy GPU apps before testing live translation.

nvidia-smi
python --version
02

Use the current faster-whisper CUDA path

Current faster-whisper/CTranslate2 GPU builds expect CUDA 12 libraries, including cuBLAS for CUDA 12 and cuDNN 9. If Python cannot load CUDA DLLs, fix the CUDA runtime before changing app code. For this stack, follow the faster-whisper README when it differs from general CTranslate2 installation notes.

python -m pip install --upgrade pip
pip install -r requirements.txt
python -c "import ctranslate2; print(ctranslate2.get_cuda_device_count())"
03

Start with the safe A1000 preset

This keeps latency reasonable while still showing the Korean transcript above the English translation. If the laptop is too slow, temporarily set SHOW_SOURCE_TEXT=false to skip the extra Korean transcription pass.

$env:WHISPER_MODEL="small"
$env:WHISPER_DEVICE="cuda"
$env:WHISPER_COMPUTE_TYPE="int8_float16"
$env:WHISPER_BEAM_SIZE="1"
$env:SHOW_SOURCE_TEXT="true"
python main.py
04

Upgrade to medium only after a stable test

If small is stable for 10 to 15 minutes and translation quality is not enough, try medium with the same quantized compute type. Increase WHISPER_BEAM_SIZE only if latency is still acceptable.

$env:WHISPER_MODEL="medium"
$env:WHISPER_DEVICE="cuda"
$env:WHISPER_COMPUTE_TYPE="int8_float16"
$env:WHISPER_BEAM_SIZE="1"
python main.py
05

Fallback when CUDA is not available

CPU mode is useful for installation checks and emergency offline use. It will usually feel slower than GPU mode, so use base first.

$env:WHISPER_MODEL="base"
$env:WHISPER_DEVICE="cpu"
$env:WHISPER_COMPUTE_TYPE="int8"
$env:WHISPER_CPU_THREADS="8"
python main.py
If you see errors such as missing cublas64_12.dll or cuDNN DLLs, install the CUDA 12/cuDNN 9 runtime libraries or use a faster-whisper-compatible Windows runtime package. For older CUDA/cuDNN combinations, the faster-whisper README documents CTranslate2 downgrade pins.
RTX 4080 Super LAN guide

Server PC opens the website, laptop uses its microphone

This is the exact home-network setup: the RTX 4080 Super PC runs the model and hosts the web app, while another laptop opens the site, grants microphone permission, and streams Korean speech to the server for English subtitles.

Local network flow
Laptop microphone
HTTPS page on LAN
WebSocket audio stream
RTX 4080 Super server
English subtitles
01

Prepare the RTX 4080 Super server

Install the NVIDIA driver, Python, Git, CUDA 12 runtime, and cuDNN 9. FFmpeg is optional for file conversion tests. The RTX 4080 Super has enough VRAM for large-v3, but keep other GPU-heavy apps closed during live translation.

nvidia-smi
python --version
git --version
ffmpeg -version
02

Install and test the translator backend

Run the Python backend on the server first. This command binds FastAPI to every network interface, so other computers can reach it after the firewall allows the port.

git clone https://github.com/buicongnguyen/ko-en-live-translator.git
cd ko-en-live-translator
python -m venv .venv
.\.venv\Scripts\Activate.ps1
pip install -r requirements.txt

$env:APP_HOST="0.0.0.0"
$env:APP_PORT="8000"
$env:WHISPER_MODEL="large-v3"
$env:WHISPER_DEVICE="cuda"
$env:WHISPER_COMPUTE_TYPE="float16"
$env:WHISPER_BEAM_SIZE="1"
python main.py
03

Find the server LAN address and open the firewall

Give the server a stable address in the router, or note its current IPv4 address. Allow TCP port 8000 for the backend and 443 or 8443 for HTTPS. Run the firewall commands in PowerShell as Administrator.

ipconfig
netsh advfirewall firewall add rule name="KO Translator Backend 8000" dir=in action=allow protocol=TCP localport=8000
netsh advfirewall firewall add rule name="KO Translator HTTPS 8443" dir=in action=allow protocol=TCP localport=8443
04

Add HTTPS for the laptop microphone

A laptop opening http://192.168.x.x:8000 is not the same as localhost, so browser microphone access may be blocked. Use HTTPS with a LAN hostname such as translate.local and reverse proxy to the FastAPI backend.

# Example Caddyfile on the server
https://translate.local:8443 {
  tls internal
  reverse_proxy 127.0.0.1:8000
}
With tls internal, install or trust Caddy's local root certificate on the client laptop. Otherwise the browser will still treat the page as unsafe for microphone capture.
05

Make the laptop resolve the server hostname

Use your router's local DNS if it supports custom hostnames. For a quick Windows test, add a hosts-file entry on the client laptop that points translate.local to the server IP.

# Run PowerShell as Administrator on the client laptop
Add-Content -Path "C:\Windows\System32\drivers\etc\hosts" -Value "192.168.1.50 translate.local"
ping translate.local
06

Open the website from the other laptop

On the client laptop, open the HTTPS address, allow microphone permission, and speak Korean near that laptop. The audio should stream to the RTX 4080 Super server and the browser should receive English subtitle lines.

https://translate.local:8443
https://translate.local:8443/api/health
07

Tune the server for latency or quality

Start with beam_size=1. If subtitles are fast but translation is rough, try beam_size=3. If the server is shared with other GPU work, step down to medium.

# Faster
$env:WHISPER_MODEL="large-v3"
$env:WHISPER_COMPUTE_TYPE="float16"
$env:WHISPER_BEAM_SIZE="1"
$env:SHOW_SOURCE_TEXT="true"

# More careful decoding
$env:WHISPER_MODEL="large-v3"
$env:WHISPER_COMPUTE_TYPE="float16"
$env:WHISPER_BEAM_SIZE="3"
$env:SHOW_SOURCE_TEXT="true"

# Lighter fallback
$env:WHISPER_MODEL="medium"
$env:WHISPER_COMPUTE_TYPE="int8_float16"
$env:WHISPER_BEAM_SIZE="1"
$env:SHOW_SOURCE_TEXT="true"
If the health URL works but microphone permission does not appear, the client browser is probably not treating the page as a trusted secure context. Fix HTTPS certificate trust first; changing the AI model will not solve that browser security issue.
Option A

Local-network self-hosted GPU server

This version makes an RTX 4080 Super or RTX 5090 PC the translation appliance. Every device on the network can open the web interface and send audio to the stronger model.

01

Prepare the server PC

Install current NVIDIA drivers, Python 3.11 or 3.12, Git, CUDA 12, and cuDNN 9. FFmpeg is optional for file conversion tests. Give the PC a stable LAN address such as 192.168.1.50.

02

Create the Python backend

Use the repo's requirements file so the backend matches the app code, including faster-whisper and WebRTC VAD. FastAPI's WebSocket guide explains the browser-to-server connection pattern.

python -m venv .venv
.\.venv\Scripts\Activate.ps1
pip install -r requirements.txt
03

Run the server on the LAN interface

Binding to 0.0.0.0 lets other devices on the network reach the backend. Uvicorn documents this through its --host setting.

$env:WHISPER_MODEL="large-v3"
$env:WHISPER_DEVICE="cuda"
$env:WHISPER_COMPUTE_TYPE="float16"
uvicorn live_translate.app:app --host 0.0.0.0 --port 8000
04

Add HTTPS for browser microphones

Browsers allow microphone capture only in secure contexts such as HTTPS or localhost. For phones and other laptops on the LAN, place Caddy, nginx, or another TLS reverse proxy in front of FastAPI and expose wss://. Caddy is a convenient first choice because it can handle local HTTPS.

https://translate.local
  -> FastAPI health:  http://127.0.0.1:8000/api/health
  -> FastAPI socket:  ws://127.0.0.1:8000/ws
05

Connect the web app

Open the GitHub Pages or local static frontend, enter the backend origin such as https://translate.local, then start the microphone.

Option B

Local PC app with browser interface

This is the smallest useful version. The backend, model, and UI all run on one laptop. It is easier to install, easier to debug, and works even without a network server.

01

Install the local runtime

Use the same Python backend, but start with a lighter model on laptop hardware.

python -m venv .venv
.\.venv\Scripts\Activate.ps1
pip install -r requirements.txt
02

Start in safe laptop mode

Use small first on an A1000-class laptop. Move to medium only after the safe preset is stable.

$env:WHISPER_MODEL="small"
$env:WHISPER_DEVICE="cuda"
$env:WHISPER_COMPUTE_TYPE="int8_float16"
$env:WHISPER_BEAM_SIZE="1"
python main.py
03

Open the browser UI

Because the app is on the same machine, localhost is a secure browser context for microphone access.

http://127.0.0.1:8000
04

Tune for speed or quality

Use base on CPU when CUDA fails. Use medium with WHISPER_BEAM_SIZE=1 when small is too rough and the GPU has headroom.

# Fast preset
$env:WHISPER_MODEL="small"
$env:WHISPER_COMPUTE_TYPE="int8_float16"
$env:WHISPER_BEAM_SIZE="1"

# Quality preset
$env:WHISPER_MODEL="medium"
$env:WHISPER_COMPUTE_TYPE="int8_float16"
$env:WHISPER_BEAM_SIZE="1"
Audio capture

Microphone first, meeting audio second

Microphone capture is the right MVP because browser APIs handle it cleanly. Capturing Zoom, Teams, YouTube, or system audio needs desktop-level capture.

Microphone mode

Works from the browser. Best for in-person translation, a speaker near the laptop, or a meeting played through speakers.

System audio mode

On Windows, use WASAPI loopback capture in a small desktop helper. That helper can stream PCM audio to the same backend used by the browser app.

A good product path is browser MVP first, then a Windows helper for system audio and an always-on-top subtitle window.
Verification

Test checklist

Use this checklist before comparing the app against Transync AI or another polished commercial translator.

  • Audio: microphone permission opens, waveform level changes, and silence does not trigger translation.
  • Noise hallucination: leave the room quiet for 20 seconds; the transcript should not repeat phrases like Thanks for watching or subscribe.
  • Latency: normal Korean speech produces English within about 1.5 to 3 seconds on laptop mode.
  • Accuracy: compare small, medium, and server large-v3 with the same Korean sample.
  • Network: another device can open the HTTPS web app and connect to the WebSocket without mixed-content errors.
  • Recovery: unplugging the mic or losing the server connection shows a readable error and can reconnect.
  • Thermals: run for 15 minutes and watch GPU memory, fan noise, and whether latency drifts upward.
Balanced default: MIN_SPEECH_MS=500 skips very short voice bursts, while MIN_AUDIO_RMS=0.0025 lets quieter speech reach Whisper.
If silence still creates fake text, tighten the runtime filters: MIN_AUDIO_RMS=0.005, NO_SPEECH_THRESHOLD=0.45, END_SILENCE_MS=900, and MIN_SPEECH_MS=650. Whisper-style models can hallucinate common internet phrases on noisy or very short audio, so the best fix is to reject weak chunks before they reach the UI.
Official links

References and setup pages

These are the main public references and download pages behind the setup choices.