How to Install Skills for Claude Code or Codex in awesome-gpt-image-2
TLDR: Run node scripts/install-style-skill.mjs [target] from the repository root to copy the GPT-Image2 style library to ~/.claude/skills, ~/.codex/skills, or all supported agent directories, then restart your agent session to activate it.
The awesome-gpt-image-2 repository packages a reusable agent skill that exposes the complete GPT-Image2 style library to Claude Code, Codex, and compatible AI agents. Installing this skill requires executing a single Node.js script that maps the skill files to each agent's expected directory structure. This guide details the installation process based on the implementation in scripts/install-style-skill.mjs.
Skill Location and Structure
The skill bundle resides in agents/skills/gpt-image-2-style-library. This directory contains the SKILL.md descriptor, the master style data in data/style-library.json, and rendering logic that agents consume automatically upon startup.
The installation script treats this folder as an atomic unit, copying it wholesale to the target agent's skills directory without modification.
Installation Steps
Install for All Agents
To install the skill for every supported agent (Codex, Claude Code, and shared agents) simultaneously, run the install script without arguments:
node scripts/install-style-skill.mjs
The script defaults to the all target, which copies the skill to ~/.codex/skills, ~/.claude/skills, and ~/.agents/skills in sequence.
Install for Claude Code Only
To restrict installation to Claude Code, pass the claude-code argument:
node scripts/install-style-skill.mjs claude-code
This command copies agents/skills/gpt-image-2-style-library to ~/.claude/skills/gpt-image-2-style-library (or $CLAUDE_HOME/skills if the environment variable is set).
Install for Codex Only
To install exclusively for Codex, specify the codex target:
node scripts/install-style-skill.mjs codex
The script deploys the skill to ~/.codex/skills/gpt-image-2-style-library, respecting the $CODEX_HOME environment variable if defined.
How the Installation Script Works
Understanding the mechanics of scripts/install-style-skill.mjs ensures you can troubleshoot path issues or customize the deployment.
Target Directory Resolution
The script defines a targetDefinitions map (lines 10–21) that resolves default paths using os.homedir():
- Codex:
~/.codex/skillsor$CODEX_HOME/skills - Claude Code:
~/.claude/skillsor$CLAUDE_HOME/skills - Shared Agents:
~/.agents/skillsor$AGENTS_HOME/skills
If the environment variables exist, they override the home-directory defaults.
CLI Argument Parsing
Lines 31–48 handle argument validation. The script accepts a space-separated list of targets (all, codex, claude-code, agents). Invalid arguments trigger an error message listing valid options. When invoked without arguments, the script defaults to all.
Skill Deployment Logic
For each valid target, the script (lines 51–56):
- Creates the target skills root directory if missing.
- Removes any existing
gpt-image-2-style-libraryfolder to prevent stale data. - Recursively copies the source directory
agents/skills/gpt-image-2-style-libraryto the target location. - Prints a confirmation message indicating the final installation path.
Activating the Skill
After installation, restart your agent session (e.g., exit and relaunch Claude Code or Codex). The agent scans its skills folder on startup and loads the new gpt-image-2-style-library automatically. No additional configuration edits are required; the SKILL.md descriptor provides the metadata the agent needs to expose the style templates and categories.
Summary
- The awesome-gpt-image-2 repository distributes a portable skill in
agents/skills/gpt-image-2-style-library. - Run
node scripts/install-style-skill.mjsto deploy to all agents, or specifyclaude-code,codex, oragentsfor selective installation. - The script respects
$CLAUDE_HOME,$CODEX_HOME, and$AGENTS_HOMEenvironment variables for custom directory paths. - Installation simply copies the skill folder; agents discover it automatically after a restart.
Frequently Asked Questions
What file path does Claude Code use for skills?
Claude Code looks for skills in ~/.claude/skills by default. If you define the $CLAUDE_HOME environment variable, it uses $CLAUDE_HOME/skills instead. The install script handles this resolution automatically according to the logic in scripts/install-style-skill.mjs.
Can I override the default installation directories?
Yes. Set the appropriate environment variable before running the script: CLAUDE_HOME for Claude Code, CODEX_HOME for Codex, or AGENTS_HOME for shared agents. The script checks these variables before falling back to the default home-directory paths.
Do I need to restart the agent after installing the skill?
Yes. Claude Code, Codex, and similar agents scan their skills folders only during initialization. You must restart the agent process to load the newly copied gpt-image-2-style-library and access the style templates defined in data/style-library.json.
What data is included in the gpt-image-2-style-library skill?
The skill includes a SKILL.md file describing its capabilities, the master data/style-library.json containing templates, categories, styles, and scenes, plus rendering logic used by the agent to format style references. This replaces or supplements the agent's built-in knowledge of GPT-Image2 parameters.
Have a question about this repo?
These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:
curl -s "https://instagit.com/install.md" Maintain an open-source project? Get it listed too →