Analyze images using OpenAI's Vision API. Use bash command to execute the vision script like 'bash <base_dir>/scripts/vision.sh <image> <question>'. Can understand image content, objects, text, colors, and answer questions about images.
View on GitHubFebruary 3, 2026
Select agents to install to:
npx add-skill https://github.com/zhayujie/chatgpt-on-wechat/blob/cb303e6109c50c8dfef1f5e6c1ec47223bf3cd11/skills/openai-image-vision/SKILL.md -a claude-code --skill openai-image-visionInstallation paths:
.claude/skills/openai-image-vision/# OpenAI Image Vision Analyze images using OpenAI's GPT-4 Vision API. The model can understand visual elements including objects, shapes, colors, textures, and text within images. ## Setup This skill requires an OpenAI API key. If not configured: 1. Get your API key from https://platform.openai.com/api-keys 2. Set the key using: `env_config(action="set", key="OPENAI_API_KEY", value="your-key")` Optional: Set custom API base URL (default: https://api.openai.com/v1): ```bash env_config(action="set", key="OPENAI_API_BASE", value="your-base-url") ``` ## Usage **Important**: Scripts are located relative to this skill's base directory. When you see this skill in `<available_skills>`, note the `<base_dir>` path. **CRITICAL**: Always use `bash` command to execute the script: ```bash # General pattern (MUST start with bash): bash "<base_dir>/scripts/vision.sh" "<image_path_or_url>" "<question>" [model] # DO NOT execute the script directly like this (WRONG): # "<base_dir>/scripts/vision.sh" ... # Parameters: # - image_path_or_url: Local image file path or HTTP(S) URL (required) # - question: Question to ask about the image (required) # - model: OpenAI model to use (default: gpt-4.1-mini) # Options: gpt-4.1-mini, gpt-4.1, gpt-4o-mini, gpt-4-turbo ``` ## Examples ### Analyze a local image ```bash bash "<base_dir>/scripts/vision.sh" "/path/to/image.jpg" "What's in this image?" ``` ### Analyze an image from URL ```bash bash "<base_dir>/scripts/vision.sh" "https://example.com/image.jpg" "Describe this image in detail" ``` ### Use specific model ```bash bash "<base_dir>/scripts/vision.sh" "/path/to/photo.png" "What colors are prominent?" "gpt-4o-mini" ``` ### Extract text from image ```bash bash "<base_dir>/scripts/vision.sh" "/path/to/document.jpg" "Extract all text from this image" ``` ### Analyze multiple aspects ```bash bash "<base_dir>/scripts/vision.sh" "image.jpg" "List all objects you can see and describe the overall scene" ``` ## Supported Image Format