gpt-image-skill
Installation
SKILL.md
GPT Image Skill
Generate or edit images using OpenAI's GPT Image models through a bundled Python script.
Resolve the skill directory
Before running any command, resolve the absolute directory containing this SKILL.md and refer to it as <skill-dir>. Never assume the current working directory is the Skill directory. Keep user input and output paths relative to the user's working directory unless the user requests another location.
Requirements
- OPENAI_API_KEY: Must be configured in
~/.gpt-image.envorexport OPENAI_API_KEY=<your-key> - OPENAI_API_BASE (optional): Custom API base URL for compatible endpoints (e.g. Azure OpenAI, proxies). Set in
~/.gpt-image.envor export it. - Python3 with dependencies: openai, httpx, python-dotenv. Install via
python3 -m pip install -r "<skill-dir>/requirements.txt"if not installed yet. - Executable:
<skill-dir>/gpt_image.py