A powerful tool for reading, extracting, and removing AI generation metadata from image files. Specifically designed to handle metadata from AI image generation tools like ComfyUI, Stable Diffusion, SwarmUI, InvokeAI, and more.
- Read EXIF/Metadata: Extract and display comprehensive metadata from images
- AI Metadata Detection: Automatically identify and highlight AI generation metadata
- Metadata Removal: Strip AI generation metadata while preserving image quality
- Batch Processing: Handle multiple files with wildcard patterns
- Cross-Platform: Works on Windows, macOS, and Linux
- ComfyUI: Detects and extracts workflow JSON data
- Stable Diffusion: Identifies prompts, parameters, and generation settings
- SwarmUI/StableSwarmUI: Handles JSON-formatted metadata
- Midjourney, DALL-E, NovelAI: Recognizes generation signatures
- Automatic1111, InvokeAI: Extracts generation parameters
- Clipboard Copy: Copy metadata directly to clipboard (ComfyUI workflows can be pasted directly)
- File Export: Save metadata as JSON or TXT files
- Workflow Preservation: ComfyUI workflows saved as importable JSON files
- Context Menu: Right-click integration for Windows Explorer
- Easy Installation: Automated installer with dependency checking
- Administrator Support: Proper permission handling for system integration
- Python 3.6+
- PIL (Pillow) - Image processing
- ExifRead - EXIF data extraction
- pyperclip (cross-platform)
- win32clipboard (Windows)
- Download all files to a folder
- Run as Administrator:
install.bat - Follow prompts to complete installation ( Windows )
- Right-click any image to access PromptSniffer options
- Clone or download this repository
- Install Python dependencies:
pip install Pillow ExifRead
- Optional clipboard support:
pip install pyperclip
# View metadata for a single image
python PromptSniffer.py image.jpg
# Process multiple images with wildcards
python PromptSniffer.py *.png
# Process all images in a folder
python PromptSniffer.py folder/*.jpg# Show only AI generation metadata
python PromptSniffer.py --ai-only generated_image.png
# Remove metadata from images (creates backups)
python PromptSniffer.py --remove *.jpg
# Save metadata to separate files
python PromptSniffer.py --save-metadata ai_artwork.png
# Copy metadata to clipboard (single file only)
python PromptSniffer.py --copy workflow_image.png
# Verbose output
python PromptSniffer.py --verbose *.tiffAfter installation, right-click any supported image file and select:
- PromptSniffer β View MetaData: Display metadata in command window
- PromptSniffer β Copy MetaData: Copy metadata to clipboard
- PromptSniffer β Extract MetaData: Save metadata to separate files
- PromptSniffer β Remove MetaData: Remove metadata from file and save original as .backup
- JPEG (.jpg, .jpeg)
- PNG (.png)
- TIFF (.tiff, .tif)
files: Image file(s) or wildcard patterns to process-r, --remove: Remove AI generation metadata from images-s, --save-metadata: Save AI generation metadata to separate files-c, --copy: Copy AI generation metadata to clipboard (single file only)-v, --verbose: Show verbose output--ai-only: Only display potential AI generation metadata
- stable diffusion, midjourney, dall-e, dalle
- ai generated, artificial intelligence
- neural network, gan, diffusion
- automatic1111, invokeai, comfyui
- novelai, swarmui, stableswarmui
- Software, ImageDescription, UserComment
- Artist, Copyright, ProcessingSoftware
- PNG text chunks (parameters, prompt, workflow)
- JSON-formatted generation data
- ComfyUI Workflows: Automatically detected and exported as importable JSON
- JSON Metadata: Pretty-formatted when copied to clipboard
- Long Descriptions: Automatically flagged as potential prompts
# Save metadata from all AI-generated images
python PromptSniffer.py --save-metadata --ai-only AI_outputs/*.png# Extract ComfyUI workflow for reuse
python PromptSniffer.py --copy comfyui_image.png
# Then Ctrl+V in ComfyUI to load workflow
# Save Stable Diffusion parameters
python PromptSniffer.py --save-metadata sd_output.jpg
# Creates sd_output.txt with generation parametersRun as Administrator: uninstall.bat
This removes all context menu entries from Windows Explorer.
"Required libraries not installed"
pip install Pillow ExifRead"Failed to copy to clipboard"
- Windows: Install
pip install pywin32 - Linux: Install
xcliporxsel - macOS: Should work by default
Made with β€οΈ by Mohsyn
For support or questions, please open an issue on GitHub.
