Featured Mobile App 2024

Cat'aloge

AI-powered mobile app that finds and organizes all your pet photos — entirely on-device, no cloud, no privacy trade-offs.

An AI-powered mobile app that automatically scans your phone gallery and organizes pet photos using TensorFlow Lite inference running fully on-device.

#ai#flutter#on-device-ml#privacy#photo-organization#tensorflow-lite

Cat'aloge is a cross-platform AI-powered mobile application that automatically detects and organizes pet photos directly on-device using TensorFlow Lite. No photo is ever uploaded to a server — the entire ML inference pipeline runs locally on the device.

The app uses EfficientDet Lite2, a lightweight object detection model optimized for mobile, to scan through a user's gallery image by image and identify photos containing pets. Detected photos are displayed with their confidence score, and users can favorite, preview, and share them.

The engineering challenge was making this performant across thousands of photos without freezing the UI or draining the battery. This required building a custom Dart isolate worker pool so ML inference runs in parallel background threads, a two-tier caching system (in-memory LRU + Hive disk persistence), and a batched scanning pipeline with backpressure control for low-end devices.

The architecture follows Clean Architecture with Riverpod async notifiers streaming results to the UI as inference completes — giving a live, progressively-revealing gallery experience.

Key Features

🧠

On-device ML — Zero Cloud

EfficientDet Lite2 runs directly on the device. No internet connection required. No photos ever leave your phone.

Parallel Isolate Worker Pool

A custom pool of Dart isolates processes photos in parallel background threads, keeping the UI thread completely free.

💾

Two-tier Caching System

Detection results are cached in memory during the session and persisted to disk via Hive, so reopening the app is instant with no re-scanning.

📊

Confidence Score Display

Every detected pet photo is shown with its ML confidence score, letting users see and trust what the model found.

🔒

Privacy by Design

The ML model is bundled with the app at build time. Zero network requests for inference. Your gallery never touches a server.

Tech Stack

FlutterDartTensorFlow LiteRiverpodHive

Architecture

The detection pipeline is entirely on-device. Photos are fetched from the device gallery in batches and dispatched to a custom isolate worker pool. Each isolate runs its own EfficientDet Lite2 interpreter instance independently — isolates in Dart don't share memory, so each one lazily initializes its own model on first use to avoid spiking memory at startup.

Results flow back to the main isolate via SendPort and are written to a two-tier cache: an in-memory LRU cache for the current session and a Hive disk cache for persistence across launches. Riverpod async notifiers stream cache updates directly to the gallery UI as each batch completes.

Challenges & Solutions

The hard problems — and how I solved them.

Running ML inference without freezing the UI

A single EfficientDet inference call on the main thread caused visible frame drops immediately. The solution was moving all inference to a pool of background Dart isolates. The tricky constraint is that TensorFlow Lite interpreters cannot be shared across isolates — each one needs its own model instance. I used lazy initialization per isolate so the model only loads when that worker first receives a job, avoiding a memory spike at startup.

Scanning thousands of photos on low-end devices

Loading all gallery photos into memory at once caused crashes on devices with limited RAM. I implemented a batched scanning pipeline processing photos in chunks of 20, with backpressure control that pauses dispatch when the isolate pool queue is full, preventing memory from growing unbounded.

Cache invalidation between app launches

The disk cache could go stale if the user deleted photos between sessions. On each launch, I do a lightweight diff that compares cached asset IDs against the current gallery state and evicts stale entries — without re-scanning everything from scratch.

More Projects

ExtMig

An open-source developer tool designed to improve migration workflows and productivity for modern development teams.

TypeScriptNode.js

Masroufi

A full-featured mobile recruitment platform built with Flutter using Clean Architecture and BLoC, supporting three distinct user roles.

FlutterDartBLoCDio +2

Accident Risk Navigator

A full-stack AI platform that predicts accident risk based on road conditions and weather, and visualizes high-risk zones on interactive maps.

ReactTypeScriptPythonTensorFlow +4

Interested in working together?

I'm always open to discussing new projects and opportunities.

Jihed Mrouki

Mobile & Flutter Developer specializing in scalable architectures and intelligent mobile solutions.

Connect

© 2026 Jihed Mrouki. All rights reserved.

Built with SvelteKit & TailwindCSS