An ADHD-friendly AI file organizer that helps manage complex document workflows with semantic search, interactive classification, and complete safety rollbacks.
Core Philosophy: Make finding and organizing files as effortless as having a conversation with an intelligent librarian who knows your work.
-
Control Center (v2) โ Served on Port 8000 (
http://localhost:8000)- System State strip is the canonical status view.
- Primary UI: system status, Recent Activity, triage, orchestrator visibility.
-
Legacy (v1) โ Served on Port 5173 (
http://localhost:5173)- Kept for historical search/triage flows. Will be folded into v2 over time.
Recommended: Use Virtual Environment
git clone https://github.com/user/ai-file-organizer
cd ai-file-organizer
# Create and activate virtual environment
python3 -m venv venv
source venv/bin/activate # On macOS/Linux
# OR: venv\Scripts\activate # On Windows
# Install dependencies
pip install -r requirements.txt
# Start the system
python main.pyQuick Start (without venv)
git clone https://github.com/user/ai-file-organizer
cd ai-file-organizer
pip install -r requirements.txt
python main.pyNavigate to http://localhost:8000 for the modern web interface with:
- ๐ Natural language search - "find client contract terms"
- ๐ Triage center - review AI classifications with confidence scores
- ๐ One-click file opening - click any result to open files directly
- ๐ง Real-time status - live system stats and file counts
- Python 3.8+ with pip
- Git for version control
- (Optional) TruffleHog, detect-secrets for security scanning
- Clone and setup virtual environment:
git clone https://github.com/user/ai-file-organizer
cd ai-file-organizer
# Create virtual environment (recommended)
python3 -m venv venv
source venv/bin/activate # macOS/Linux
# OR: venv\Scripts\activate # Windows- Install Python dependencies:
pip install -r requirements.txt
pip install pytest pytest-asyncio httpx # For testing
pip install detect-secrets # For PII/secrets scanning- Configure environment variables:
# Copy example environment file
cp .env.example .env
# Edit .env to set your paths (optional)
# AUTO_MONITOR_PATHS=~/Downloads,~/Desktop
# AUTO_MONITOR_INTERVAL=5- Verify installation:
# Run comprehensive validation suite
./scripts/run_all_tests.sh
# This runs:
# - Integration tests (pytest)
# - PII/secrets scan (detect-secrets)
# - Python syntax checks- Start the server:
python main.py
# Navigate to http://localhost:8000One-Command Validation:
./scripts/run_all_tests.shThis validation script automatically runs:
- Integration tests for all API endpoints
- PII/secrets scanning with detect-secrets
- Python syntax validation
- Git pre-push hooks verification
Security Tools (Optional but Recommended):
# Install TruffleHog for verified secrets detection
brew install trufflesecurity/trufflehog/trufflehog
# Install git-secrets for additional protection
brew install git-secretsPre-Push Hooks: The repository includes git pre-push hooks that automatically scan for:
- Verified secrets (TruffleHog)
- Personal identifiers (detect-secrets)
- Sensitive data patterns (git-secrets)
These hooks run automatically on git push to prevent accidental exposure.
Based on verified codebase analysis (October 31, 2025):
- โ
FastAPI V3 Backend - Verified operational web server (
main.py) - โ
Modern React Web Interface - Search, Triage, and Organize pages (
frontend_v2/) - โ Hierarchical Organization - 5-level deep folder structure (Project โ Episode โ Media Type)
- โ Search Page - Full natural language semantic search with example queries
- โ Triage Center - Fixed infinite spinner, manual scan trigger, hierarchical inputs
- โ
Easy Rollback System - Complete file operation safety net (
easy_rollback_system.py) - โ Phase 1 Core Intelligence - Universal adaptive learning system (7,154 lines of production code)
- โ
Phase 2a Vision Integration - Gemini Computer Vision for images/videos (
vision_analyzer.py) - โ Phase 2b Vision System Integration - Full integration with classifier and learning system
- โ
Phase 2c Audio Analysis - BPM detection, mood analysis, spectral features (
audio_analyzer.py) - โ
Phase 3a VEO Prompt Builder - Video to VEO 3.1 JSON transformation (
veo_prompt_generator.py) - โ
Unified Classification - Content-based intelligent file categorization (
unified_classifier.py) - โ
Google Drive Integration โ Hybrid cloud architecture (
gdrive_integration.py) - โ Bulletproof Deduplication โ SHA-256 duplicate detection with full UI group display
- โ
Fusion Brain โ Multi-modal signal fusion for high-confidence classification (
unified_classifier.py) - โ Review Queue โ Intelligent queue for ambiguous or low-confidence cases
- โ UI Path Truncation โ Aggressive truncation for cleaner display of long Drive paths
| Endpoint | Purpose |
|---|---|
/health |
System health check |
/api/system/status |
Real-time system status |
/api/search?q={query} |
Semantic search with natural language |
/api/triage/scan |
Trigger manual triage scan (returns files immediately) |
/api/triage/files_to_review |
Files requiring manual review (cached results) |
/api/triage/classify |
Confirm file categorization with optional project/episode |
/api/upload |
Upload and classify file |
/api/open_file |
Open file in default application |
CRITICAL FEATURE: Never fear AI file operations again. One-click undo for any operation that went wrong.
# See what the AI did recently
python easy_rollback_system.py --list
# Undo a specific operation
python easy_rollback_system.py --undo 123
# Emergency: Undo ALL today's operations
python easy_rollback_system.py --undo-todayVisual Protection:
๐ด [123] 14:32:15
๐ Original: 'Client_Contract_2024_Final.pdf'
โก๏ธ Renamed: 'random_filename_abc123.pdf' โ OOPS!
๐ด Confidence: 45.2% (Low confidence = likely wrong)
๐ง Rollback: python easy_rollback_system.py --undo 123
Revolutionary adaptive learning system that learns from your file movements and decisions. Phase 1 has been successfully implemented, tested, and independently verified with 7,154 lines of production-ready code.
Gemini Vision API integration for advanced image/video analysis, plus comprehensive audio analysis pipeline. Phase 2 adds visual and audio understanding capabilities to the intelligent file organizer.
- โ
Universal Adaptive Learning (
universal_adaptive_learning.py) - 1,087 lines - Learns from all user interactions - โ
4-Level Confidence System (
confidence_system.py) - 892 lines - NEVER/MINIMAL/SMART/ALWAYS modes - โ
Adaptive Background Monitor (
adaptive_background_monitor.py) - 1,456 lines - Observes and learns from manual file movements - โ
Emergency Space Protection (
emergency_space_protection.py) - 987 lines - Proactive disk management - โ
Interactive Batch Processor (
interactive_batch_processor.py) - 1,529 lines - Multi-file handling - โ
Automated Deduplication Service (
automated_deduplication_service.py) - 1,203 lines - Intelligent duplicates with UI group support
- ๐ฏ 85% confidence threshold - Only acts when genuinely certain
- ๐ค Interactive questioning - Asks clarifying questions until confident
- ๐ Visual confidence indicators - Color-coded trust levels (๐ข๐ก๐ด)
- ๐ Learning from corrections - Remembers your decisions and improves over time
- โก Background learning - Observes your manual file movements automatically
- ๐ก๏ธ Proactive protection - Prevents disk space emergencies before they happen
- Start server:
python main.py - Open browser:
http://localhost:8000 - Search naturally: "client contract terms"
- Review suggestions in triage center
- One-click to open or organize files
# Search files semantically
python enhanced_librarian.py search "client contract terms" --mode semantic
# Organize files interactively
python interactive_organizer.py organize --live
# Check recent AI operations
python easy_rollback_system.py --today๐ AI File Organizer v3.1/
โโโ ๐ FastAPI Web Server (main.py)
โโโ ๐ง Phase 1 Core Intelligence (7,154 lines)
โโโ ๐ก๏ธ Easy Rollback System
โโโ โ๏ธ Google Drive Hybrid Integration
โโโ ๐ Enhanced Semantic Search
โโโ ๐ Content-Based Classification
โโโ ๐ฏ ADHD-Friendly Interactive Design
Core Files:
main.py- FastAPI web serveruniversal_adaptive_learning.py- Main intelligence systemeasy_rollback_system.py- Safety rollback systemunified_classifier.py- Content-based classificationenhanced_librarian.py- Semantic searchgdrive_integration.py- Google Drive hybrid storage
โ
Reduces decision paralysis - 4 confidence modes let you choose cognitive load
โ
Natural language search - "Find client payment terms" vs folder navigation
โ
Learning system - Reduces questions over time as it learns patterns
โ
Visual feedback - Clear confidence scores and progress indicators
โ
Complete safety - Easy rollback prevents organization anxiety
โ
Background operation - Works while you sleep, 7-day grace period for active files
- Eliminate filing anxiety - Smart confidence modes prevent overwhelming decisions
- Reduce search frustration - Semantic search finds things with imprecise queries
- Professional organization - Entertainment industry-specific workflows
- Build knowledge effortlessly - Automatic learning creates searchable library
- Documents: PDF, DOCX, Pages, TXT, MD
- Emails: macOS Mail (.emlx files)
- Code: Python, JavaScript, Jupyter notebooks
- Images/Video: PNG, JPG, MP4, MOV (Gemini Vision analysis)
- Audio: MP3, WAV, M4A, FLAC, OGG (BPM, mood, spectral analysis)
- Semantic Search: ChromaDB with sentence-transformers
- Content Analysis: Intelligent text extraction and chunking
- Learning System: Pickle-based pattern discovery
- Classification: Confidence-based categorization
- Search Speed: < 2 seconds for semantic queries
- Classification: ~1-2 seconds per file
- Memory Usage: ~2-3GB during active processing
- System Reliability: 99%+ uptime in testing
Base Root: ~/Documents/AI_METADATA_SYSTEM
| Component | Path | Source File |
|---|---|---|
| Authentication | .../config/ |
google_drive_auth.py |
| Rollback Database | .../databases/rollback.db |
easy_rollback_system.py |
| Learning Database | .../databases/adaptive_learning.db |
universal_adaptive_learning.py |
| Learning Config | .../.AI_LIBRARIAN_CORPUS/03_ADAPTIVE_FEEDBACK |
universal_adaptive_learning.py |
| Vector DB | .../chroma_db/ |
main.py |
| File Caches | .../caches/drive_files/ |
gdrive_streamer.py |
| Temp Storage | .../temp/ |
gdrive_streamer.py |
- FastAPI V4 Backend โ Optimized endpoints and stable Pydantic V2 models.
- Control Center (v2) UI โ Stable Rollback Center, Search, Triage, and Duplicates with aggressive path truncation.
- Fusion Brain โ Standardized evidence bundles and decision fusion logic.
- Emergency Protection โ Verified disk space recovery and snapshot management.
- Hierarchical Organization โ 5-level deep folder structure operational.
- Universal Adaptive Learning โ Real-time event logging and pattern matching.
- Manual Organization Support โ Background monitor now treats manual Drive movements as "Verified Examples" for training.
December 26, 2025 - Sprint 3.3: UI Polish & Duplicates Fix:
- UI Path Truncation: Aggressive path truncation logic in
Recent Activity,Search, andDuplicatespages. - Duplicates Fix: Resolved
TypeErrorcrash and updated backend to return full duplicate group data. - Taxonomy Refactor: Removed Material UI dependencies from
TaxonomySettings.tsxin favor of Tailwind CSS and Lucide icons. - Workflow Validation: Verified manual folder organization in Google Drive as a primary training source for the AI.
November 3, 2025 - Sprint 2.5: Learning Stats API & UI Integration:
- Backend API: GET
/api/settings/learning-statsendpoint with 10 key metrics - Frontend Dashboard: Dynamic Settings page with animated learning statistics
- Comprehensive Testing: 9/9 tests passing (100% success rate)
- Real-time Metrics: Total events, media type breakdown, category distribution, confidence scores
- ADHD-Friendly UI: Visual indicators, loading states, empty state handling
October 31, 2025 - Web Interface Improvements:
- New Search Page: Full-featured semantic search interface with natural language queries
- Triage Bug Fixes: Resolved infinite spinner from expensive auto-refresh, manual scan trigger
- Hierarchical Organization: Project โ Episode โ Media Type folder structure
- API Improvements: Updated classification endpoints with hierarchical parameters
- Data Structure Fixes: Resolved frontend/backend data format mismatches
- Performance Optimization: Scan results caching, no expensive auto-refreshes
January 2, 2026 - System Hardening & Monitoring:
- Adaptive Monitor Status Tracking: Enhanced visibility into emergency checks and pattern discovery cycles.
- Enforced Local SQLite: Critical safety fix prohibiting database files on Google Drive to prevent sync corruption.
- Metadata Compliance: Strict enforcement of local storage for all system state databases.
- Video to VEO 3.1 JSON transformation operational
- Shot type, camera movement, lighting, mood detection
- 8/8 comprehensive tests passing with real video files
- Database integration for VEO prompt library
- Confidence scoring: 0.95 with full AI analysis
- Phase 3b: Batch VEO processing, continuity detection, web interface
- Enhanced hierarchical organization with project templates
- Mobile interface development (API ready)
- Team collaboration features (foundation exists)
- User testing and feedback collection
This is a specialized tool built for complex document workflows and ADHD accessibility.
Questions or Issues:
- Open an issue
- Email: user@example.com
Development Priorities:
- Enhanced entertainment industry templates
- Advanced content analysis
- Mobile companion app
- Team collaboration features
MIT License - Built with โค๏ธ for creative minds and anyone managing complex content workflows with ADHD.
From document chaos to intelligent organization. An AI librarian that learns your work patterns and keeps your files safely organized.