Skip to content
Alejandro ArandaAlejandro Aranda
Back to projects
1 min readProjects

CardLens: a 100% on-device Pokémon TCG card scanner

Source code

CardLens points your camera (or uploads a photo) and identifies a Pokémon TCG card in about 0.3 seconds, 100% on your device: no cloud, no accounts, no Python at runtime.

CardLens

Recognition in Rust, zero training

The runtime is 100% Rust. The pipeline detects and crops the card with classic computer vision, computes the visual embedding with MobileCLIP2-S0 (ONNX Runtime), reads the name via OCR (ocrs/rten) and searches by cosine similarity; OCR reinforces the result to disambiguate look-alike artworks. Everything uses pretrained models: zero training.

One codebase for desktop and Android

It is built with Tauri 2 and a React + Vite frontend. On desktop the API ships as a sidecar binary that starts and stops with the app; on Android (which can't spawn a sidecar) the same API runs in-process. Recognition is on-device on both.

Collection and prices

You can save cards (no duplicates) with tags and filters (set, rarity, type, language, search) and JSON import/export. It shows per-card market prices (Cardmarket in EUR and TCGplayer in USD) via TCGdex, cached for 24 h. The catalog is multilingual (ES/EN) and your photos never leave your device.

Unofficial, non-commercial project. Not affiliated with or endorsed by Nintendo, The Pokémon Company, Creatures or GAME FREAK; card names and images are trademarks and © of their respective owners, used solely for identification purposes.

Source on GitHub.