GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - LeanBitLab/LeanType-OCR-Plugin: Standalone Offline OCR / Text Recognition Plugin for LeanType keyboard

BranchesTags
Open more actions menu

Latest commit

 

History

12 Commits
12 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
app
app
 
 
gradle/wrapper
gradle/wrapper
 
 
.gitignore
.gitignore
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
build.gradle
build.gradle
 
 
gradle.properties
gradle.properties
 
 
gradlew
gradlew
 
 
gradlew.bat
gradlew.bat
 
 
settings.gradle
settings.gradle
 
 

Repository files navigation

LeanType OCR Plugin

License: GPL v3 Android ML Kit

An offline Optical Character Recognition (OCR) plugin for LeanType (and HeliBoard), enabling instant on-device text recognition directly from your keyboard.


✨ Features

  • 🔒 100% Offline & Private: Zero network permissions. All vision and neural models run entirely on-device with zero data telemetry.
  • ⚡ Bundled ML Kit V2 Engines: Uses Google ML Kit's bundled offline models for high-accuracy recognition across multiple scripts:
    • Latin (English, Spanish, French, German, etc.)
    • Devanagari (Hindi, Marathi, Sanskrit, etc.)
    • Chinese (Simplified & Traditional)
    • Japanese (Kanji, Hiragana, Katakana)
    • Korean (Hangul)
  • 🧩 Lightweight Plugin Architecture: Dynamically loaded on demand via Android DexClassLoader with zero background battery or memory overhead when idle.
  • 📱 Multi-Architecture Support: Pre-configured ABI splits (arm64-v8a, armeabi-v7a, x86, x86_64) for minimal download and install sizes.

🚀 Installation & Usage

1. Download & Install

Download the latest APK matching your device's CPU architecture (typically arm64-v8a for modern Android devices) from the Releases section and install it.

2. Enable in LeanType Keyboard

  1. Open LeanType Settings.
  2. Navigate to Advanced $\to$ Plugins.
  3. Select OCR Plugin and verify the status shows Active / Connected.
  4. Use the OCR action from the keyboard toolbar or long-press action to scan and insert text anywhere.

🛠️ Building from Source

Prerequisites

  • Android Studio Ladybug or later / Android SDK Platform 34
  • JDK 17
  • Gradle 8.2+

Build Commands

# Clone the repository
git clone https://github.com/LeanBitLab/LeanType-OCR-Plugin.git
cd LeanType-OCR-Plugin

# Build Debug APKs for all ABIs
./gradlew assembleDebug

# Build Release APKs (configured with ProGuard/R8 optimization)
./gradlew assembleRelease

Generated APKs will be located in:

app/build/outputs/apk/{debug,release}/ocr_plugin-{abi}.apk

📐 Architecture & Plugin Interface

LeanType loads this plugin dynamically at runtime through a standardized interface contract:

package helium314.keyboard.latin.ocr

interface ITextRecognizer {
    suspend fun recognizeText(bitmap: Bitmap): String
}

Implementation is managed by TextRecognizerImpl in helium314.keyboard.ocr.plugin, which initializes the bundled TextRecognition clients on demand and processes image frames asynchronously using Kotlin Coroutines.


📄 License

This project is licensed under the GNU General Public License v3.0 (GPL-3.0) - see the LICENSE file for details.

About

Standalone Offline OCR / Text Recognition Plugin for LeanType keyboard

Resources

Readme
GPL-3.0 license
Activity

Stars

18 stars

Watchers

1 watching

Forks

2 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.