Skip to content

J-Akiru5/prism-organizer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

58 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

๐Ÿ”ฎ Prism Organizer

A portable, beautiful CLI tool that scans, analyzes, and organizes files on Windows.

Python 3.8+ Platform: Windows License: MIT npm v1.2.2

Features

  • ๐Ÿ” Scan & Analyze โ€” Detailed reports with file type breakdown, largest files, duplicates, junk, and more
  • ๐Ÿ“ Sort by Type โ€” Organize files into category folders (Images, Documents, Videos, Code, etc.)
  • ๐Ÿ“… Sort by Date โ€” Organize files into YYYY/Month/ folders
  • ๐Ÿ”Ž Duplicate Detection โ€” 3-phase detection (size โ†’ partial hash โ†’ SHA-256) finds exact duplicates fast
  • ๐Ÿ–ผ๏ธ Near-Duplicate Images โ€” Perceptual hashing finds visually similar images
  • ๐Ÿงน Cleanup โ€” Remove temp files, lock files, incomplete downloads, large installers
  • โ˜๏ธ Cloud Drive Detection โ€” Auto-detects OneDrive, Google Drive, Dropbox, etc. and skips them
  • ๐Ÿ“ Custom Rules โ€” Define your own rules in YAML to organize files your way
  • ๐Ÿค– AI Classification โ€” AI-powered category suggestions with interactive setup wizard
  • ๐Ÿ”„ Undo โ€” Every operation is logged and fully reversible
  • ๐Ÿ‘๏ธ Dry-Run Preview โ€” Always previews before making changes
  • โšก Parallel Processing โ€” Multi-threaded scanning and hashing
  • ๐ŸŽจ Beautiful Terminal UI โ€” Rich tables, panels, progress bars with a cyan/purple theme
  • ๐ŸŽฎ Interactive TUI Dashboard โ€” Arrow-key menus, checkboxes, live panels (prism-organizer tui)
  • ๐Ÿ‘€ Watch Mode โ€” Real-time directory monitoring with auto-organization
  • ๐Ÿ“… Scheduled Tasks โ€” Windows Task Scheduler integration

Quick Start

No Python required. The npm installer auto-downloads a standalone binary on first run.

Installation

# โ”€โ”€ NPM (Recommended โ€” zero setup) โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€
npm install -g prism-organizer
# On first run, a ~30MB standalone binary is downloaded automatically.
# After that: no Python, no pip, no dependencies needed.

# โ”€โ”€ Pip (for Python users) โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€
pip install git+https://github.com/J-Akiru5/prism-organizer.git

# โ”€โ”€ Clone & Develop โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€
git clone https://github.com/J-Akiru5/prism-organizer.git
cd prism-organizer && pip install -e .

Uninstall

# Remove the npm package
npm uninstall -g prism-organizer

# Remove cached data (logs, backups, binary)
rm -rf ~/.prism-organizer

Note: The npm package installs a Node.js wrapper that manages Python automatically. If Python is not installed at npm install time, the package will install successfully and show instructions for installing Python separately.

Verify Installation

prism-organizer --version
prism-organizer --help

Get Help

# Full help system with quick-start, command ref, safety, AI setup
prism-organizer help

# Specific topics
prism-organizer help --topic quickstart
prism-organizer help --topic tui
prism-organizer help --topic config
prism-organizer help --topic safety
prism-organizer help --topic ai
prism-organizer help --topic commands

Screenshots of the TUI dashboard and scan reports are available on the GitHub Releases page.

---> PATH Troubleshooting: If the command isn't recognized, run: python -m prism_organizer --help

Usage

Scan a Directory

prism-organizer scan ~/Downloads
prism-organizer scan ~/Downloads --verbose -w 8

Sort Files

prism-organizer sort ~/Downloads                  # Sort by type (default)
prism-organizer sort ~/Downloads --by date        # Sort by modification date

Find Duplicates

prism-organizer dupes ~/Downloads                 # Report only
prism-organizer dupes ~/Downloads --clean          # Report + prompt to remove
prism-organizer dupes ~/Downloads --perceptual     # Also find visually similar images
prism-organizer dupes ~/Downloads --clean --perceptual

Clean Junk Files

prism-organizer clean ~/Downloads

Custom Rules

prism-organizer rules ~/Downloads

Undo

prism-organizer undo            # Undo last operation
prism-organizer undo --list     # List recent operations

AI Classification

prism-organizer ai-setup                            # ๐Ÿ†• Interactive AI setup wizard
prism-organizer ai-classify ~/Downloads             # Suggest categories
prism-organizer ai-classify ~/Downloads --rename     # Also suggest filenames

Watch Mode

prism-organizer watch ~/Downloads                    # Auto-sort new files
prism-organizer watch ~/Downloads --action clean     # Auto-clean new files
prism-organizer watch ~/Downloads --action all       # Sort + clean

Scheduled Tasks

prism-organizer schedule add ~/Downloads --command sort --interval daily --at 09:00
prism-organizer schedule list
prism-organizer schedule remove

Interactive TUI Dashboard

Launch the full interactive dashboard with arrow-key menus and live panels:

prism-organizer tui

The TUI provides:

  • Arrow-key navigation โ€” select directories, commands, and options with arrow keys
  • Live panels โ€” activity log, quick stats, and menu side-by-side
  • Keyboard shortcuts โ€” every function is a single keystroke away
  • Zero subcommand memorization โ€” discover all features from the menu
โ•”โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•—
โ•‘  ๐Ÿ”ฎ  Prism Organizer v1.2.0                         โ•‘
โ•‘  scan  |  sort  |  dupes  |  clean  |  rules  |  ai โ•‘
โ• โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•ฆโ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•ฃ
โ•‘  ๐Ÿ“‹  Main Menu           โ•‘  ๐Ÿ“Š  Quick Stats         โ•‘
โ•‘  ๐Ÿ” [1]  Scan directory  โ•‘  Downloads: 247 files    โ•‘
โ•‘  ๐Ÿ“ [2]  Sort files      โ•‘  Desktop: 89 files       โ•‘
โ•‘  ๐Ÿ”Ž [3]  Find duplicates โ•‘                          โ•‘
โ•‘  ๐Ÿงน [4]  Clean junk      โ•‘  ๐Ÿ“œ  Activity Log        โ•‘
โ•‘  ๐Ÿ“ [5]  Apply rules     โ•‘  12:34 Sorted 15 files   โ•‘
โ•‘  ๐Ÿค– [6]  AI classify     โ•‘  12:30 Cleaned 3 items   โ•‘
โ•‘  ๐Ÿ‘€ [7]  Watch mode      โ•‘  12:25 Dupe check: 2 grp โ•‘
โ•‘  โ†ฉ๏ธ [8]  Undo last       โ•‘                          โ•‘
โ•‘  โš™๏ธ [9]  Setup AI        โ•‘                          โ•‘
โ•‘  [S] Schedule  [H] Help  [Q] Quit                   โ•‘
โ•šโ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•ฉโ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

Use --no-interactive to disable arrow-key prompts and use plain text input:

prism-organizer sort ~/Downloads --no-interactive

๐Ÿค– AI Integration

Prism Organizer supports three AI providers. Set up in seconds with the interactive wizard:

prism-organizer ai-setup
Provider Cost Privacy Setup
OpenAI Pay-per-use Cloud API key required
Ollama Free 100% Local ollama pull llama3.2
LM Studio Free 100% Local Download + GUI

๐Ÿ“– Full guide: docs/AI_SETUP.md

Quick Config Example (Ollama)

ai:
  enabled: true
  provider: "ollama"
  model: "llama3.2"
  # No api_key needed โ€” runs entirely on your machine

Configuration

Config stored at ~/.prism-organizer/config.yaml. Auto-created on first run.

Key Settings

Setting Description Default
default_paths Directories to organize Downloads, Desktop
categories Extension-to-category mappings 13 categories
junk_patterns Patterns for auto-cleanup ~$*, *.crdownload, etc.
duplicates.perceptual_threshold Hamming distance for near-dupes 5
ai.enabled Enable AI classification false
ai.provider LLM provider (openai, ollama, lmstudio) openai
ai.min_confidence Minimum confidence to apply suggestions 0.7
watcher.cooldown_seconds Min time between watch actions 10
watcher.min_file_age_seconds Wait before acting on new files 5

Safety Features

  • ๐Ÿ”’ Dry-run by default โ€” Every command shows a preview before executing
  • ๐Ÿ“ฆ Backups before delete โ€” Files go to .prism-organizer_backup/ first
  • ๐Ÿ“ Full operation logs โ€” Every action logged to ~/.prism-organizer/logs/
  • โ†ฉ๏ธ Undo support โ€” Reverse any operation with prism-organizer undo
  • โ˜๏ธ Cloud drive protection โ€” Auto-skips synced folders
  • ๐Ÿค– AI always suggests, never acts โ€” Classifications go through preview/confirm

๐Ÿ›ก๏ธ Privacy & Data Handling

Prism Organizer is designed to be local-first, respecting your privacy and secure data processing:

  • Zero Remote Telemetry: No usage stats, error reports, or telemetry leave your machine.
  • Local Operational Logs: Full undo-history transaction logs contain absolute file paths, stored entirely locally under ~/.prism-organizer/logs/.
  • AI Privacy Guardrails:
    • Local AI Providers (Ollama, LM Studio) run fully offline on your own hardware.
    • Cloud AI Providers (OpenAI) only receive filenames, extensions, and optionally short text previews (first 500 characters). Full binary/media files are never read or transmitted.
    • AI Preview Opt-Out: Set disable_previews: true in your config to prevent reading/sending file contents entirely, or pass the --no-ai flag to disable all AI-powered suggestions.
  • For complete policy and data handling details, see SECURITY.md.

Troubleshooting

npm install fails / Python not found

The npm package will install successfully even without Python. You'll see a warning:

โš  Python 3.8+ is not found on your PATH.
โ„น   Install Python from: https://python.org/downloads/

Install Python, then run the tool normally. The pip package will be installed automatically on first use.

Command not found after install

# Try running directly with Python:
python -m prism_organizer --help

# Or reinstall globally:
pip install git+https://github.com/J-Akiru5/prism-organizer.git

Permission errors on scanned directories

Run as administrator, or target directories you own (Downloads, Desktop, Documents).

Project Structure

prism_organizer/
โ”œโ”€โ”€ cli.py           # CLI commands and argument parsing
โ”œโ”€โ”€ config.py        # Configuration loader
โ”œโ”€โ”€ scanner.py       # Filesystem analyzer (parallel)
โ”œโ”€โ”€ sorter.py        # Sort by type/date
โ”œโ”€โ”€ duplicates.py    # 3-phase + perceptual duplicate detection
โ”œโ”€โ”€ rules.py         # Custom rule engine
โ”œโ”€โ”€ cleaner.py       # Junk file cleanup
โ”œโ”€โ”€ cloud_drives.py  # Cloud drive detection
โ”œโ”€โ”€ preview.py       # Dry-run preview UI
โ”œโ”€โ”€ executor.py      # File operations + logging
โ”œโ”€โ”€ undo.py          # Undo/rollback
โ”œโ”€โ”€ display.py       # Rich-themed display layer
โ”œโ”€โ”€ interactive.py   # Arrow-key menus, checkboxes, wizards
โ”œโ”€โ”€ tui.py           # Interactive TUI dashboard
โ”œโ”€โ”€ ai.py            # AI-powered classification & renaming
โ”œโ”€โ”€ ai_setup.py      # Interactive AI setup wizard
โ”œโ”€โ”€ watcher.py       # Real-time watcher + scheduler
โ””โ”€โ”€ utils.py         # Shared utilities
docs/
โ””โ”€โ”€ AI_SETUP.md      # Complete AI setup guide

Changelog

v1.2.0 (Stable)

  • Fixed: npm install no longer fails when Python is missing (exits cleanly with instructions)
  • Fixed: Binary download from GitHub Releases now handles HTTP redirects
  • Fixed: Version mismatch between setup.py, package.json, and init.py
  • Fixed: {counter} placeholder in rename rules no longer causes KeyError
  • Fixed: Rich markup tags no longer render as literal text in TUI input prompts
  • Fixed: Archive operations no longer silently overwrite existing zip files
  • Fixed: Perceptual duplicate sorting no longer crashes if files are deleted mid-scan
  • Added: Interactive AI setup wizard (prism-organizer ai-setup / TUI key [9])
  • Added: AI setup documentation (docs/AI_SETUP.md)
  • Added: Test step in CI/CD pipeline (runs before build/publish)
  • Improved: Removed unused imports across multiple modules
  • Improved: Added watcher defaults to config

v1.1.0

  • Initial public release with full feature set

License

MIT License ยฉ 2026 Syntaxure Labs

About

No description, website, or topics provided.

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Packages

 
 
 

Contributors