AWS Builder Center
CleanMate: Your Smart AI Assistant for a Clutter-Free Digital Life - Powered by Amazon Q Developer

CleanMate: Your Smart AI Assistant for a Clutter-Free Digital Life - Powered by Amazon Q Developer

CleanMate, a smart file organiser and summariser built using the Amazon Q Developer. CleanMate is a CLI automation solution that acts as your personal digital assistant, helping you reclaim your digital workspace and boost your productivity.

AWS Cloud Clubs Captain
Hey there, fellow developers and productivity enthusiasts! Are you tired of drowning in a sea of digital files? Do you spend more time searching for documents than actually working on them? If so, you're not alone. Digital clutter is a common problem for remote workers and students, leading to disorganization, reduced productivity, and wasted time.
That's why I created CleanMate, a smart file organizer and summarizer built for the AWS Q Developer Challenge #1. CleanMate is a CLI automation solution that acts as your personal digital assistant, helping you reclaim your digital workspace and boost your productivity.

What it Does ๐Ÿงน

CleanMate is more than just a file organizer. It's an intelligent tool that understands your files and organizes them in a way that makes sense for you. Here's what CleanMate can do:
  • Automatic File Organization: CleanMate automatically scans your messy Desktop and Downloads folders and moves files into neatly organized folders based on their type (e.g., "Documents," "Images," "Videos," "Code").
  • Content-Based Intelligence: This is where the magic happens! CleanMate uses the power of Amazon Q to analyze the content of your files (PDFs, TXT, and DOCX). It then intelligently suggests or creates subfolders with meaningful names like "Project Reports," "Assignments," or "Bills," making it incredibly easy to find what you need.
  • Cleanup Tracking: CleanMate keeps a detailed log of every cleanup, including timestamps and a summary report of the files organized.
  • Scheduled Cleaning: With a single command, you can schedule CleanMate to run daily or weekly, ensuring your digital space stays tidy without you having to lift a finger.

How it Works โš™๏ธ

CleanMate follows a simple yet powerful four-step process to bring order to your digital chaos:
  1. Scanning: CleanMate starts by scanning the source directories you specify in the configuration file. By default, it targets the usual suspects: your Desktop and Downloads folders.
  2. Categorization: Next, it categorizes each file based on its extension. For example, all .pdf files go into the "PDFs" folder, and all .jpg and .png files go into the "Images" folder.
  3. Content Analysis: For supported file types (.pdf, .txt, .docx), CleanMate uses the Amazon Q CLI to generate a concise summary of the file's content.
  4. Smart Organization: Based on the content summary, CleanMate suggests appropriate folder names and organizes the files accordingly. For example, a PDF containing an invoice might be moved to a folder named "Invoices."
  5. Reporting: After each run, CleanMate generates a detailed report with statistics on the number of files processed, organized, and summarized.

How Amazon Q Helped ๐Ÿค–

Amazon Q was the cornerstone of this project. Here's how it helped bring CleanMate to life:
  • Content Summarization: Amazon Q's ability to analyze file content and generate summaries is the core of CleanMate's intelligence.
  • Intelligent Folder Naming: Amazon Q suggests relevant and intuitive folder names based on the file content, which is a huge step up from traditional file organizers.
  • Code Development: I used Amazon Q to help me write efficient and robust Python code, handle edge cases, and implement features like error handling and logging.
  • Error Handling: Amazon Q was instrumental in implementing robust error handling and logging, ensuring that CleanMate runs smoothly and reliably.

Get Started with CleanMate ๐Ÿš€

Ready to give CleanMate a try? Here's how to get started:

Installation

  1. Clone the repository:
1
2
git clone https://github.com/rahulkothuri/cleanmate-ai-files-organiser.git
cd cleanmate-ai-files-organiser
  1. Make sure you have Python 3.6+ installed.
  2. Install the required dependencies:
1
pip install -r requirements.txt
  1. Make sure you have the Amazon Q CLI installed and configured.
  2. Make the scripts executable:
1
chmod +x src/cleanmate.py src/schedule_cleanmate.py

Basic Usage

To organise your Desktop and Downloads folders into the ~/CleanMate/Organized directory, simply run:
1
python src/cleanmate.py
Advanced Options
  • Use a custom configuration file:
1
python src/cleanmate.py --config /path/to/custom_config.json
  • Specify a source folder to organize:
1
python src/cleanmate.py --source ~/Downloads
  • Specify both source and destination folders:
1
python src/cleanmate.py --source ~/Downloads --dest ~/Organized_Files

Scheduling Regular Cleanups

You can use the included scheduling helper to set up regular cleanups:
  • Schedule daily cleanup:
1
python src/schedule_cleanmate.py add daily
  • Schedule weekly cleanup:
1
python src/schedule_cleanmate.py add weekly
  • List scheduled cleanups:
1
python src/schedule_cleanmate.py list
  • Remove scheduled cleanups:
1
python src/schedule_cleanmate.py remove

Configuration โš™๏ธ

You can customize CleanMate's behavior by modifying the ~/CleanMate/config/config.json file. Here are some of the key options:
  • source_directories: A list of directories to scan for files.
  • destination_directory: The directory where organized files will be placed.
  • file_categories: A dictionary of file extensions and their corresponding categories.
  • summarize_extensions: The file types that should be summarized.
  • organize_by_content: A boolean to enable or disable smart organization based on file content.
  • smart_rename: A boolean to enable or disable smart folder naming based on content.

Images ๐Ÿ“ท

Before file organisation of Downloads folder

terminal image
Output logs after running CleanMate

After file organisation using CleanMate

Sample Report ๐Ÿ—‚๏ธ

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
CleanMate - File Organization Report
========================================

Date: 2025-07-21 11:05:57

Source Directories:
- /Users/rahulkothuri/Downloads

Destination Directory: /Users/rahulkothuri/Downloads

Statistics:
- Total files processed: 66
- Files organized: 64
- Files summarized: 27
- Smart folders created: 27
- Errors encountered: 0

CleanMate completed successfully!

Future Enhancements ๐Ÿ”ฎ

CleanMate is just getting started! Here are some of the features I'm planning to add in the future:
  • Integration with cloud storage services like Google Drive and Dropbox.
  • A machine learning model to improve folder suggestions over time.
  • A GUI for easier configuration and use.
  • Support for more file types and languages.

Conclusion โœจ

CleanMate is a powerful and intelligent tool that can help you conquer digital clutter and reclaim your productivity. By leveraging the power of Amazon Q, CleanMate goes beyond simple file organisation to provide a truly smart and personalised solution.
I hope you find CleanMate as useful as I do. Give it a try and let me know what you think!
Any opinions in this article are those of the individual author and may not reflect the opinions of AWS.
Enjoyed reading this content? Let the author know!

Your likes, comments, shares, and saves help creators reach more builders.

Loading recommendations

Loading article