- Free and Generic Renaming: This method provides basic renaming functionality without the need for any external APIs.
- Ideal for: Users who need simple file renaming based on content without any additional cost.
- Base64 Encoding: This method encodes file content using Base64 and sends it to OpenAI's API for smart renaming.
- Utilizes: OpenAI API for intelligent and context-aware renaming.
- Ideal for: Users who require advanced renaming capabilities with an emphasis on privacy, using local encoding before processing.
- Cloudinary Integration: This method uploads files to Cloudinary and then uses OpenAI’s API to analyze and rename files based on their content.
- Utilizes: Cloudinary for image management and OpenAI API for content analysis.
- Ideal for: Users who manage large media libraries and require cloud-based storage and processing.
The Smart Screenshots project is continuously evolving. Here's what's in the pipeline:
- 📂 Other Format Support: Expanding support to include additional file formats such as PDFs, videos, and more.
- 📏 Larger Image Size Support: Improving the system to handle and process larger image files efficiently.
- 🖥️ Mac App (In Progress): Developing a native Mac application for a more seamless and integrated experience.
To get started with Smart File Renamer, follow these steps:
-
Clone the Repository:
git clone https://github.com/Pranav-Karra-3301/smart-screenshots.git cd smart-screenshots
-
Install Dependencies:
pip install -r requirements.txt
-
Install Tesseract OCR:
- macOS:
brew install tesseract
- Ubuntu:
sudo apt-get install tesseract-ocr
- Windows: Download from the official site.
- macOS:
-
Download the spaCy model:
python -m spacy download en_core_web_sm
- Set Up Configuration:
- Create a
config.json
file in the root directory with the following keys:
{ "openai_api_key": "your-openai-api-key", "cloudinary_cloud_name": "your-cloudinary-cloud-name", "cloudinary_api_key": "your-cloudinary-api-key", "cloudinary_api_secret": "your-cloudinary-api-secret" }
- Create a
Follow the steps below to use each method:
- Dependencies: None required beyond basic Python packages.
- Command:
python basic.py --input_folder <path-to-folder>
- Dependencies: Requires OpenAI API key.
- Command:
python rename_files_base64.py --input_folder <path-to-folder> --config config.json
- Dependencies: Requires both OpenAI API key and Cloudinary credentials.
- Command:
python rename_files_cloudinary.py --input_folder <path-to-folder> --config config.json
This project is licensed under the MIT License - see the LICENSE file for details.
Enjoy smart file renaming with advanced content recognition! 🎉
Contributions, issues, and feature requests are welcome! Feel free to check the issues page for open issues or to start a discussion.
For any inquiries, suggestions, or issues, please open an issue or contact me directly.