Skip to content

๐ŸŽจ imgpt v0.3.0 Release Notes

Latest

Choose a tag to compare

@JacobFV JacobFV released this 04 Jun 05:53

๐ŸŽจ imgpt v0.3.0 Release Notes

Release Date: December 26, 2024
Repository: https://github.com/JacobFV/imgpt

๐Ÿš€ Major New Features

๐Ÿ”ง Persistent Configuration System

We've added a comprehensive persistent configuration system that allows you to save your preferences and avoid repeating command-line options:

  • API Key Storage - Store your OpenAI API key securely in configuration
  • Default Settings - Set default models, sizes, quality, and other generation parameters
  • Directory Preferences - Configure default prompt and output directories
  • Cross-Platform - Configuration stored in appropriate OS-specific directories
# Set your API key once
imgpt config set openai_api_key "your-key-here"

# Set default preferences
imgpt config set default_model "dall-e-3"
imgpt config set default_size "1024x1024"
imgpt config set default_quality "hd"
imgpt config set default_output_dir "/path/to/images"

# View current configuration
imgpt config show

# Reset to defaults
imgpt config reset

๐ŸŽจ Enhanced CLI with Typer

Complete rewrite of the CLI using Typer for a better user experience:

  • Rich Output - Beautiful colored output with progress indicators
  • Better Help - Comprehensive help system with examples
  • Subcommands - Organized command structure (imgpt generate, imgpt config)
  • Auto-completion - Shell completion support for commands and options
  • Validation - Better input validation with helpful error messages
# New command structure
imgpt generate "A beautiful sunset"           # Direct prompt
imgpt generate --dir ./prompts               # Batch processing
imgpt config show                            # Configuration management
imgpt version                                 # Version information

๐Ÿ“ Smart Configuration Management

The configuration system intelligently handles defaults and overrides:

  • Precedence Order: Command-line options โ†’ Configuration file โ†’ Built-in defaults
  • Validation: All configuration values are validated before saving
  • Platform-Aware: Uses OS-appropriate configuration directories
    • macOS: ~/Library/Application Support/imgpt/
    • Linux: ~/.config/imgpt/
    • Windows: %APPDATA%/imgpt/

๐Ÿ›ก๏ธ Enhanced Validation & Error Handling

Smart Input Validation

  • Model-Size Compatibility: Automatic validation of size/model combinations
  • Configuration Validation: Pydantic-based validation for all settings
  • Directory Validation: Checks for directory existence and permissions
  • API Key Handling: Secure storage and retrieval with fallback to environment

Better Error Messages

$ imgpt generate "test" --model dall-e-2 --size 2048x2048
โŒ Error: Size '2048x2048' is not valid for model 'dall-e-2'
Valid sizes for dall-e-2: 256x256, 512x512, 1024x1024

๐Ÿ“– Configuration Options

API Settings

  • openai_api_key - Your OpenAI API key

Generation Settings

  • default_model - Default model (gpt-image-1, dall-e-2, dall-e-3)
  • default_size - Default image size (e.g., 1024x1024, 1536x1024)
  • default_quality - Default quality (auto, high, medium, low, hd, standard)
  • default_style - Default style for DALL-E 3 (vivid, natural)
  • default_format - Default output format (png, jpeg, webp)

Directory Settings

  • default_prompts_dir - Default directory for prompt files
  • default_output_dir - Default directory for generated images

Processing Settings

  • default_delay - Default delay between API calls (seconds)
  • skip_existing - Default setting for skipping existing images

๐Ÿ”„ Breaking Changes

Command Structure Changes

The CLI now uses subcommands for better organization:

Old (v0.2.0):

imgpt "A sunset" --output sunset.png
imgpt --dir ./prompts --output ./images

New (v0.3.0):

imgpt generate "A sunset" --output sunset.png
imgpt generate --dir ./prompts --output ./images

Removed Options

  • --version flag moved to imgpt version command
  • Direct execution requires generate subcommand

๐Ÿ”ง Technical Improvements

Dependencies

  • Added: typer[all] for enhanced CLI experience
  • Added: pydantic for configuration validation
  • Added: rich for beautiful terminal output
  • Added: tomli-w for TOML configuration file writing

Code Quality

  • Type Safety: Enhanced type hints throughout codebase
  • Validation: Pydantic models for configuration validation
  • Testing: Comprehensive test suite for configuration system
  • Documentation: Extensive inline documentation and examples

Performance

  • Configuration Caching: Configuration loaded once and cached
  • Lazy Loading: Configuration only loaded when needed
  • Efficient Validation: Fast validation with detailed error messages

๐Ÿ“‹ Usage Examples

First-Time Setup

# Install imgpt
pipx install imgpt

# Set up your API key
imgpt config set openai_api_key "your-openai-api-key"

# Set your preferences
imgpt config set default_model "dall-e-3"
imgpt config set default_quality "hd"
imgpt config set default_output_dir "~/Pictures/AI-Generated"

# Generate your first image
imgpt generate "A majestic dragon flying over a medieval castle"

Advanced Configuration

# Set up for batch processing
imgpt config set default_prompts_dir "~/Documents/Prompts"
imgpt config set default_output_dir "~/Pictures/Generated"
imgpt config set default_delay 1.0
imgpt config set skip_existing true

# Now batch processing is simple
imgpt generate --dir ~/Documents/Prompts

Configuration Management

# View all settings
imgpt config show

# Update specific settings
imgpt config set default_model "gpt-image-1"
imgpt config set default_size "1536x1024"

# Reset everything to defaults
imgpt config reset

# Find your config file
imgpt config path

๐Ÿ› Bug Fixes

  • Fixed output format handling for different models
  • Improved prompt length validation and truncation
  • Enhanced file extension handling for custom output formats
  • Better error handling for configuration file corruption

๐Ÿš€ Performance Improvements

  • Reduced startup time through lazy configuration loading
  • Optimized validation pipeline
  • Improved memory usage for large batch operations
  • Better error recovery and retry logic

๐Ÿ“ฆ Installation & Upgrade

New Installation

# Install with pipx (recommended)
pipx install imgpt

# Install with pip
pip install imgpt

Upgrade from v0.2.0

# Upgrade with pipx
pipx upgrade imgpt

# Upgrade with pip
pip install --upgrade imgpt

# Note: First run will create new configuration file
imgpt config show

๐Ÿ”ฎ Migration Guide

From v0.2.0 to v0.3.0

  1. Update Commands: Add generate subcommand to existing scripts
  2. Set Configuration: Use imgpt config set to save frequently used options
  3. Update Scripts: Replace --version with imgpt version

Example Migration:

# Old
imgpt "A sunset" --model dall-e-3 --quality hd --output sunset.png

# New - one-time setup
imgpt config set default_model "dall-e-3"
imgpt config set default_quality "hd"

# New - simplified usage
imgpt generate "A sunset" --output sunset.png

๐Ÿ™ Acknowledgments

  • Typer team for the excellent CLI framework
  • Pydantic team for robust data validation
  • Rich team for beautiful terminal output
  • Community feedback that drove these improvements

๐Ÿ”ฎ What's Next?

  • Configuration profiles for different use cases
  • Batch operation optimization
  • Integration with popular design tools
  • Advanced prompt templating system
  • Configuration import/export functionality

Full Changelog: v0.2.0...v0.3.0
Download: https://github.com/JacobFV/imgpt/releases/tag/v0.3.0

Made with โค๏ธ by Jacob Valdez


๐ŸŽจ imgpt v0.2.0 Release Notes

Release Date: May 26, 2025
Repository: https://github.com/JacobFV/imgpt

๐Ÿš€ Major New Features

๐Ÿค– Multi-Model Support

We've added support for all OpenAI image generation models:

  • gpt-image-1 (default) - OpenAI's latest and most advanced image model
  • dall-e-3 - High-quality artistic images with style controls
  • dall-e-2 - Fast and cost-effective image generation
# Use different models
imgpt "A sunset" --model dall-e-3
imgpt "Quick sketch" --model dall-e-2

๐Ÿ“ Multiple Image Dimensions

Generate images in various aspect ratios and sizes:

gpt-image-1:

  • Square: 1024x1024
  • Landscape: 1536x1024
  • Portrait: 1024x1536

dall-e-3:

  • Square: 1024x1024
  • Landscape: 1792x1024
  • Portrait: 1024x1792

dall-e-2:

  • Small: 256x256
  • Medium: 512x512
  • Large: 1024x1024
# Generate in different orientations
imgpt "Landscape photo" --size 1792x1024
imgpt "Portrait painting" --size 1024x1536
imgpt "Thumbnail" --model dall-e-2 --size 256x256

๐ŸŽจ Quality & Style Controls

Fine-tune your image generation:

  • Quality levels: auto, high, medium, low, hd, standard
  • Style options: vivid, natural (DALL-E 3 only)
  • Output formats: PNG, JPEG, WebP (gpt-image-1 only)
# High-quality artistic image
imgpt "Abstract art" --model dall-e-3 --quality hd --style vivid

# Web-optimized JPEG
imgpt "Website banner" --format jpeg --quality medium

๐Ÿ›ก๏ธ Enhanced Validation & Intelligence

Smart Model Validation

  • Automatic validation of size compatibility with each model
  • Model-specific prompt length limits (32K for gpt-image-1, 4K for dall-e-3, 1K for dall-e-2)
  • Intelligent default sizes based on selected model

Better Error Messages

$ imgpt "test" --model dall-e-2 --size 2048x2048
โŒ Error: Size '2048x2048' is not valid for model 'dall-e-2'
Valid sizes for dall-e-2: 256x256, 512x512, 1024x1024

๐Ÿ“– Comprehensive Documentation Updates

Updated CLI Help

$ imgpt --help
Options:
  --model {gpt-image-1,dall-e-2,dall-e-3}    Model to use (default: gpt-image-1)
  --size SIZE                                 Image dimensions (e.g., 1024x1024)
  --quality {auto,high,medium,low,hd,standard} Image quality (default: high)
  --style {vivid,natural}                     DALL-E 3 style options
  --format {png,jpeg,webp}                    Output format (default: png)

Enhanced README

  • Detailed model comparison table
  • Comprehensive usage examples
  • Best practices for each model
  • Cost optimization tips

๐Ÿ”ง Technical Improvements

API Integration

  • Full support for OpenAI's latest image generation API parameters
  • Model-specific parameter handling
  • Proper response format handling for each model

Code Quality

  • Enhanced type hints and documentation
  • Improved error handling and validation
  • Extended test coverage for new features
  • Backward compatibility maintained

๐Ÿ“‹ Usage Examples

Single Image Generation

# Default high-quality generation
imgpt "A majestic eagle in flight"

# Artistic style with DALL-E 3
imgpt "Surreal landscape" --model dall-e-3 --style vivid --quality hd

# Fast generation for prototyping
imgpt "Logo concept" --model dall-e-2 --size 512x512

# Custom format and quality
imgpt "Web image" --format jpeg --quality medium --size 1536x1024

Batch Processing

# High-quality art generation
imgpt --dir ./art_prompts --model dall-e-3 --quality hd --style natural

# Thumbnail generation
imgpt --dir ./thumbnails --model dall-e-2 --size 256x256

# Web-optimized batch processing
imgpt --dir ./web_images --format webp --quality medium

๐Ÿ”„ Breaking Changes

None - This release maintains full backward compatibility. All existing commands will continue to work exactly as before.

๐Ÿ› Bug Fixes

  • Fixed output format handling for different models
  • Improved prompt length validation
  • Enhanced file extension handling for custom output formats

๐Ÿš€ Performance Improvements

  • Optimized API parameter building
  • Reduced unnecessary API calls through better validation
  • Improved error handling reduces retry overhead

๐Ÿ“ฆ Installation & Upgrade

New Installation

# Install with pipx (recommended)
pipx install imgpt

# Install with pip
pip install imgpt

Upgrade from v0.1.0

# Upgrade with pipx
pipx upgrade imgpt

# Upgrade with pip
pip install --upgrade imgpt

๐Ÿ™ Acknowledgments

  • OpenAI for their comprehensive image generation API
  • Community feedback that drove these feature requests
  • Contributors who helped test the new functionality

๐Ÿ”ฎ What's Next?

  • Batch size optimization for faster processing
  • Image editing and variation capabilities
  • Integration with popular design tools
  • Advanced prompt templating system

Full Changelog: v0.1.0...v0.2.0
Download: https://github.com/JacobFV/imgpt/releases/tag/v0.2.0

Made with โค๏ธ by Jacob Valdez


๐ŸŽจ imgpt v1.0.0 Release Notes

Release Date: May 26, 2025
Repository: https://github.com/JacobFV/imgpt

๐Ÿš€ Features

  • Generate images from text prompts using OpenAI's image-gpt model
  • Supports direct prompt input and batch processing of prompt files
  • Output images in PNG format
  • Simple CLI interface

๐Ÿ› Bug Fixes

  • Initial release, no known bugs

๐Ÿ“ฆ Installation

pip install imgpt