Documentation Index
Fetch the complete documentation index at: https://mintlify.com/soymatudev/Pokedex-Fleek/llms.txt
Use this file to discover all available pages before exploring further.
Overview
PokéDex Fleek combines computer vision and machine learning to create an intelligent Pokémon detection system. The app uses TensorFlow.js for object classification and react-native-vision-camera for high-performance frame processing.Unlike traditional Pokédex apps that rely on manual search, PokéDex Fleek acts as a field research tool that analyzes real-world objects through your camera.
Technology Stack
| Component | Technology | Purpose |
|---|---|---|
| ML Framework | TensorFlow.js | Object detection and classification |
| Camera Library | react-native-vision-camera V4 | Native camera access and frame capture |
| Frame Processing | react-native-worklets-core | 60fps real-time processing |
| Color Analysis | react-native-image-colors | Dominant color extraction |
| Model Format | TensorFlow Lite | Optimized mobile inference |
TensorFlow.js Role
Vision Pipeline
The AI detection system follows a multi-stage pipeline:Current Implementation
The project is structured to support TensorFlow.js integration, with the foundation already in place:Camera Setup
High-performance camera interface using Vision Camera V4 with frame processor support
Color Detection
Dominant color extraction using
react-native-image-colors for instant analysisWorklets Integration
Frame processors run on separate threads for 60fps performance
ML Roadmap
TensorFlow Lite models planned for object classification (Person, Animal, Plant, Object)
Camera Integration
Vision Camera Setup
TheScannerScreen uses react-native-vision-camera V4 for native camera access:
src/features/scanner/ScannerScreen.js
Key Features
Permission Handling
Permission Handling
The app requests camera permissions on mount and handles denied/blocked states:
Focus Management
Focus Management
Camera only activates when the screen is focused, saving battery:
Photo Capture
Photo Capture
High-quality photo capture for color analysis:
Frame Processing Architecture
Worklets for Real-Time Analysis
Worklets are JavaScript functions that run on a separate thread, enabling 60fps frame processing without blocking the UI:Current Frame Capture Flow
While full frame processing is planned, the current implementation uses QR code scanning and manual photo capture:src/features/scanner/ScannerScreen.js
Object Detection Strategy
Classification Categories
The planned TensorFlow model will classify objects into four categories:Person
Human subjects detected via pose estimation or facial recognition
Animal
Living creatures with distinct shapes and movement patterns
Plant
Vegetation, flowers, and organic structures
Object
Inanimate items, tools, and manufactured goods
Detection + Color Matching
The AI system will combine object classification with color analysis for more accurate results:Performance Considerations
Mobile Optimization
Running ML models on mobile devices requires careful optimization:TensorFlow Lite Conversion
Full TensorFlow models are converted to TensorFlow Lite format, reducing size by 75% and inference time by 3-4x
Quantization
Model weights are quantized from 32-bit floats to 8-bit integers, trading minimal accuracy for massive speed gains
Benchmarks (Projected)
| Metric | Target | Notes |
|---|---|---|
| Inference Time | < 50ms | MobileNet V2 on modern devices |
| Frame Rate | 30-60 fps | Depends on device GPU |
| Battery Impact | < 5% per min | With GPU acceleration |
| Model Size | < 10MB | TFLite quantized model |
Future Roadmap
The ML integration is planned in phases:Phase 1: Foundation (Current)
- ✅ Camera integration with Vision Camera V4
- ✅ Color extraction pipeline
- ✅ Worklets setup for frame processing
- ✅ Basic Pokémon matching algorithm
Phase 2: ML Integration (Planned)
- ⏳ TensorFlow Lite model integration
- ⏳ Object classification (Person/Animal/Plant/Object)
- ⏳ Frame processor implementation
- ⏳ Real-time inference pipeline
Phase 3: Advanced Features (Future)
- 🔮 Shape/silhouette detection
- 🔮 Multiple object tracking
- 🔮 AR overlay for detected Pokémon
- 🔮 Custom model training for Gen 2+ Pokémon
The roadmap is defined in the source README under “Roadmap de Desarrollo” and is actively being worked on by the development team.
Code Example: Manual Scan
Here’s the current implementation for manual photo capture and analysis:src/features/scanner/ScannerScreen.js
User Experience Details
- Haptic Feedback: Vibration confirms scan start and result
- Loading State: Button shows
ActivityIndicatorwhile processing - Error Handling: Graceful fallback with user-friendly messages
- Navigation: Auto-navigate to detail screen on successful match
Integration with Color Matching
The AI detection system enhances the color matching algorithm:Resources & References
TensorFlow.js
Official documentation for TensorFlow.js
Vision Camera
react-native-vision-camera V4 docs
Worklets
react-native-worklets-core for frame processing
TFLite
TensorFlow Lite for mobile optimization
Next Steps
Color Matching
Learn how Euclidean distance powers Pokémon identification
Project Architecture
Explore the feature-based folder structure and navigation