Getting Started

Introduction

High-Performance Pure Rust OCR Library & Multi-Platform Toolkit
Crates.iodocs.rsPyPInpm (node)pub.dev (dart)pub.dev (flutter)NuGetnpm (react-native)CocoaPodsJitPackLibrary CIDocs CIBuild & ReleaseLicenseKnown Vulnerabilities

RustO! is a high-performance Optical Character Recognition (OCR) engine and cross-platform toolkit written in pure Rust. Based on RapidOCR and powered by PaddleOCR deep learning models with pure-Rust RTen lightweight inference backend (and pluggable custom engine architecture), RustO! delivers sub-second inference speeds, ultra-low memory overhead, zero OpenCV runtime dependencies, and 99.3%+ accuracy parity with native C++ OpenCV implementations.

🎯 Architecture Pipeline

RustO! orchestrates an end-to-end OCR and layout analysis pipeline optimized for edge devices and high-throughput servers:

Rendering diagram...

⚡ Key Highlights & Advantages

  • 🚀 100% Pure Rust Core: Zero OpenCV runtime dependency. Binarization, contour tracing, polygon clipping, and affine transformations are implemented in memory-safe Rust with SIMD acceleration.
  • 📦 Ultra-Small Footprint: Core binaries are ~5 MB (self-contained) compared to 50+ MB for traditional OpenCV + ONNX runtime stacks.
  • 📄 Human-Readable Spatial Layouts: Native support for reconstructing invoices, receipts, multi-column tables, and forms directly into visually formatted text.
  • 🧠 Supported Model Ecosystem: Built-in support for PP-OCRv6 (Tiny, Small, Medium), PP-OCRv5 (Mobile, Server), and PP-OCRv4 (Mobile, Server) architectures.
  • 🌐 50+ Languages in One Model: PP-OCRv6 uses a unified dictionary supporting Latin, Cyrillic, CJK, Devanagari, Arabic, and more simultaneously.
  • 📱 Universal Multi-Platform SDKs: First-class support for Rust, .NET / C#, React Native, iOS (Swift), Android (Kotlin), and C FFI.

📦 Supported Platforms & Ecosystem

PlatformTarget Package / RegistrySupport Matrix
Rustcargo add rusto-rs (crates.io)Linux, macOS, Windows, Android (NDK), iOS
Node.js (N-API)npm install @rustors/node (npm)Node.js 18+ (Linux, macOS, Windows)
Pythonpip install rusto (PyPI)Python 3.9+ (x86_64, aarch64, Apple Silicon)
Golanggo get github.com/byrizki/rusto-rs/packages/goGo 1.21+ via Cgo (embedded rpath)
Java (JVM)com.github.byrizki.rusto-rs:rusto-java (JitPack)Java 17+, Kotlin, Scala via JNA
Dartdart pub add rusto (pub.dev)Dart 3.0+ on Desktop & Server
Flutterflutter pub add rusto_flutter (pub.dev)Android, iOS, Desktop
Web (WASM)npm install @rustors/webModern Browsers, Cloudflare Workers, WASM
Reactnpm install @rustors/reactReact 18+, Next.js, Vite
React Nativenpm install @rustors/react-native (npm)React Native 0.70+ (New Arch & Legacy)
iOSPackage.swift / pod 'RustO' (CocoaPods)iOS 13.0+, Mac Catalyst (SPM & CocoaPods)
Androidcom.github.byrizki.rusto-rs:rusto-android (JitPack)Android API 21+ (ARM64-v8a, ARMv7a, x86_64, x86)
.NET / C#dotnet add package RustODotnet (NuGet).NET 6.0+, .NET 8.0+, .NET Standard 2.0+
C / Nativelibrusto.so / librusto.dylib / rusto.dllC99 / C++11 and any foreign runtime with C FFI
CLIrusto binaryStandalone command-line tool for desktop & CI pipelines

📊 Performance & Parity Comparison

Benchmarks conducted on standard document scans (A4 invoice, 150 DPI) on an AMD Ryzen 7 / Apple M-series CPU:

MetricRustO! (Pure Rust + RTen)Traditional OpenCV + C++ PipelineAdvantage
Detection Speed~80 ms~85 ms⚡ 6% faster
Recognition Speed~120 ms~125 ms⚡ 4% faster
Accuracy Parity99.3%+Baseline (100%)🎯 Identical bounding boxes
Binary Footprint~5 MB~55 MB+ (libopencv, onnxruntime)📦 90% reduction
Peak Memory (RAM)~120 MB~260 MB+🔒 54% lower memory
SafetyMemory-safe (Rust guarantees)Manual pointers / potential leaks🛡️ Zero memory bugs

🛡️ Security & Continuous Monitoring

RustO! is actively monitored and protected with the support of the Snyk Open Source Program. Snyk provides automated developer security tooling that continuously tests our pure Rust core engine, dependencies, container images, and multi-platform packages for known vulnerabilities.

For details on our vulnerability disclosure policy, see our Security Policy.


Next Steps