namemyimage
v0.1.1
Published
AI-powered image renaming tool – generate semantic, human-readable filenames
Downloads
187
Maintainers
Readme
nmimage
AI-powered image renaming tool – Generate semantic, human-readable filenames automatically.
One image. One good name. Zero thinking.
Features
- ✨ AI-powered semantic naming
- 🔄 Batch processing support
- 🌍 Multi-language output
- 🎨 Provider-agnostic (OpenAI, OpenRouter, Gemini)
- 🔒 Safe collision handling
- 🧪 Dry-run mode
Installation
npm install -g namemyimageOr use with npx:
npx namemyimage ./imagesUsage
Basic Usage
nmimage ./imagesWith Options
nmimage ./images \
--provider openai \
--max-words 6 \
--lang en \
--context "marketing hero images" \
--dry-runCLI Options
| Option | Description | Default |
|--------|-------------|---------|
| --provider | AI provider (openai | openrouter) | openai |
| --model | Model name (provider-specific) | Provider default |
| --max-words | Maximum words in filename | 6 |
| --lang | Output language (en | sk | cs) | en |
| --context | Additional context for naming | - |
| --dry-run | Preview without making changes | false |
Environment Variables
Set your API key based on the provider:
export OPENAI_API_KEY=sk-...
# or
export OPENROUTER_API_KEY=sk-or-...Examples
Before
PN0001.png
IMG_2847.jpg
DSC_4821.pngAfter
hero-woman-walking-in-rain.png
team-meeting-in-office.jpg
sunset-over-mountains.pngNaming Rules
Generated filenames follow these rules:
- Format: kebab-case (lowercase with dashes)
- Focus: main subject → action → environment
- Removes: filler words, unnecessary colors, camera terms
- Safe: automatic collision handling with
-2,-3suffixes
Supported Formats
.jpg/.jpeg.png.gif.webp
Development
# Install dependencies
npm install
# Run in dev mode
npm run dev
# Build
npm run build
# Type check
npm run typecheckLicense
Apache-2.0
