Skip to main content

Comprehensive AI-powered file processing and organization tool

Project description

CleanupX - Comprehensive File Processing Tool

Version 2.0.0 - Reorganized & Production Ready

A powerful, AI-enhanced file organization and processing framework with comprehensive capabilities for code analysis, image processing, file deduplication, and privacy utilities.

๐ŸŽฏ What's New in v2.0

  • ๐Ÿ—๏ธ Complete Reorganization: Clean modular structure with core functionality separated from storage
  • ๐Ÿš€ Enhanced Performance: Streamlined imports and optimized processing
  • ๐Ÿ”„ Backward Compatibility: All existing commands continue to work
  • ๐Ÿ“ฆ Unified Architecture: Consolidated scattered functionality into organized modules
  • ๐Ÿ”’ SSL Ready: Full HTTPS support with proper certificate configuration

๐Ÿ“ Project Structure

cleanupx/
โ”œโ”€โ”€ cleanupx.py                 # Main CLI interface
โ”œโ”€โ”€ cleanupx_core/              # Core functionality
โ”‚   โ”œโ”€โ”€ api/                    # XAI API integration  
โ”‚   โ”œโ”€โ”€ processors/
โ”‚   โ”‚   โ”œโ”€โ”€ integrated/         # New comprehensive processing
โ”‚   โ”‚   โ””โ”€โ”€ legacy/             # Backward compatibility
โ”‚   โ””โ”€โ”€ utils/                  # Common utilities
โ”œโ”€โ”€ storage/                    # Non-core functionality archive
โ”‚   โ”œโ”€โ”€ legacy_methods/         # Original processing methods
โ”‚   โ”œโ”€โ”€ dev_tools/              # Development utilities
โ”‚   โ””โ”€โ”€ documentation/          # Archive documentation
โ””โ”€โ”€ test/                       # Test files

๐Ÿš€ Quick Start

Installation

# Clone the repository
git clone <repository-url>
cd cleanupx

# Install dependencies
pip install -r requirements.txt

# Set up environment (optional for AI features)
echo "XAI_API_KEY=your-xai-api-key" > .env

Basic Usage

# Check system status
python3 cleanupx.py --help

# Run file deduplication
python3 cleanupx.py deduplicate --dir test

# Process images for accessibility
python3 cleanupx.py images --dir test  

# Comprehensive processing with all features
python3 cleanupx.py comprehensive --dir test

# Privacy: scramble filenames
python3 cleanupx.py scramble --dir test

๐Ÿ› ๏ธ Features

Core Processing

  • File Deduplication: Smart duplicate detection and organization
  • Code Analysis: Extract and analyze code snippets
  • File Organization: Categorize and organize files by type and content
  • Citation Processing: Extract and format citations from documents

AI-Powered Features

  • X.AI Integration: Advanced AI processing with retry logic
  • Image Alt Text: Generate accessibility descriptions for images
  • Content Analysis: AI-powered content understanding and categorization
  • Smart Deduplication: Intelligent duplicate detection beyond simple hashing

Privacy & Utility

  • Filename Scrambling: Randomize filenames for privacy/testing
  • Rename Logging: Track and reverse filename changes
  • Rich CLI Interface: Beautiful terminal output with progress bars
  • Comprehensive Logging: Detailed operation logs

๐Ÿ“‹ Available Commands

Primary Commands

comprehensive    # Full processing with all features
images          # AI-powered image processing and alt text generation  
scramble        # Privacy-focused filename scrambling

Legacy Commands (Backward Compatible)

deduplicate     # Find and process duplicate files
extract         # Extract important code snippets  
organize        # Organize and rename files
all             # Run all legacy processing steps

๐Ÿ”ง Configuration

Environment Variables

# Required for AI features
XAI_API_KEY=your-xai-api-key

# Optional configurations
CLEANUP_OUTPUT_DIR=custom_output_directory
CLEANUP_LOG_LEVEL=INFO

Dependencies

Core Requirements

requests>=2.31.0        # HTTP requests
rich>=13.7.0           # Beautiful console output  
inquirer>=3.4.0        # Interactive prompts
pillow>=10.0.0         # Image processing
PyPDF2>=3.0.1          # PDF processing
python-docx>=1.1.2     # Word document processing

Optional Dependencies

openai                 # OpenAI API fallback
PyHEIF                # HEIC/HEIF image support
rarfile               # RAR archive processing

๐Ÿ—๏ธ Architecture

Modular Design

CleanupX is built with a clean, modular architecture:

  • cleanupx_core/: Core functionality with stable APIs
  • storage/: Non-essential functionality for experimentation
  • Processors: Specialized processing modules for different file types
  • API Layer: Unified interface for AI service integration

Key Benefits

  1. Clean Separation: Core vs. experimental functionality
  2. Backward Compatibility: Legacy commands continue to work
  3. Extensible: Easy to add new processors and features
  4. Production Ready: Robust error handling and logging
  5. Organized Output: Centralized output management

๐Ÿ“Š Supported File Types

  • Images: .jpg, .jpeg, .png, .gif, .webp, .bmp, .tiff
  • Code: .py, .js, .html, .css, .md, .txt, .json, .yaml
  • Documents: .pdf, .doc, .docx, .rtf, .pptx
  • Archives: .zip, .tar, .gz (with optional RAR support)
  • All Others: Categorized and processed appropriately

๐Ÿšฆ Status Check

# Verify module status
python3 -c "import cleanupx_core; cleanupx_core.print_status()"

Expected output:

CleanupX Core v2.0.0
  Integrated Processors: โœ“
  XAI API Support: โœ“  
  Legacy Processors: โœ“
  Module Path: /path/to/cleanupx_core

๐Ÿ” Examples

Basic File Organization

# Organize a downloads directory
python3 cleanupx.py organize --dir ~/Downloads

# Find duplicates in a project
python3 cleanupx.py deduplicate --dir ~/Projects/MyProject

AI-Enhanced Processing

# Generate alt text for all images
python3 cleanupx.py images --dir ./photos

# Comprehensive AI analysis
python3 cleanupx.py comprehensive --dir ./documents

Privacy & Testing

# Scramble filenames for privacy
python3 cleanupx.py scramble --dir ./sensitive_data

# Note: Scrambling creates a log file to reverse changes

๐Ÿ› ๏ธ Development

Module Status

The reorganized architecture provides:

  • Stable Core: cleanupx_core/ for production functionality
  • Experimental Storage: storage/ for development and testing
  • Clear APIs: Well-defined interfaces between modules
  • Easy Testing: Modular design enables easy unit testing

Contributing

  1. Core functionality goes in cleanupx_core/
  2. Experimental features start in storage/dev_tools/
  3. All changes must maintain backward compatibility
  4. Add comprehensive tests for new features

๐Ÿ“ License & Credits

MIT License by Luke Steuber

Support the Project:

๐ŸŽฏ What's Next

  1. Performance Optimization: Profile and optimize processing speeds
  2. Enhanced AI Features: More sophisticated content analysis
  3. Web Interface: Browser-based processing dashboard
  4. API Server: REST API for remote processing
  5. Plugin System: Custom processor plugins

Version: 2.0.0 - Reorganized & Production Ready
Last Updated: June 6, 2025
Status: โœ… Fully Functional with Clean Architecture

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cleanupx-2.0.0.tar.gz (61.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cleanupx-2.0.0-py3-none-any.whl (66.0 kB view details)

Uploaded Python 3

File details

Details for the file cleanupx-2.0.0.tar.gz.

File metadata

  • Download URL: cleanupx-2.0.0.tar.gz
  • Upload date:
  • Size: 61.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.12

File hashes

Hashes for cleanupx-2.0.0.tar.gz
Algorithm Hash digest
SHA256 2fa8761df448b429184a3d7e03cc08585a24f523e469ec99f5701d7862e5e46f
MD5 2e7ae043db65f0c1b0133f07e49a72ad
BLAKE2b-256 50c65c549004cf718ebb6d7128b041571cd651eb4bb1ecc2e92614fb3526144f

See more details on using hashes here.

File details

Details for the file cleanupx-2.0.0-py3-none-any.whl.

File metadata

  • Download URL: cleanupx-2.0.0-py3-none-any.whl
  • Upload date:
  • Size: 66.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.12

File hashes

Hashes for cleanupx-2.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f5256f19de90848f661cd9eee1988f9942f0eda52eab51d6807e8e45e7435c47
MD5 a4ac2de0b86d8b5634cc5e1c6dfe230c
BLAKE2b-256 aa076dfc8ae56e47a94136b2305e60c5d63b890594c58eb0cb741a89c4efe7e8

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page