AGENT SKILL

gpt-image-cli

Use GPT-Image2-Skill and the gpt-image-cli package for OpenAI GPT Image 2 CLI/API workflows, prompt-gallery guidance, and repository maintenance.

License 许可
MIT
最近更新
2026-09-03
Stars
★ 351
Forks
27

01 前言 Front Matter

name
gpt-image-cli
license
MIT
metadata
{ "disco-role": "operating" }
description
Use GPT-Image2-Skill and the gpt-image-cli package for OpenAI GPT Image 2 CLI/API workflows, prompt-gallery guidance, and repository maintenance.
disable-model-invocation
true

02 资源文件 4

03 SKILL.md 正文

gpt-image-cli

Use this repo skill when a task names GPT-Image2-Skill, gpt-image-cli, gpt-image, GPT Image 2 / gpt-image-2, OpenAI image generation/editing, image prompt galleries, or maintenance of this package's CLI/agent-skill surfaces.

This skill is a self-contained operating guide for the repo. It does not import itself into any live router, does not export to Codex/Claude, and does not run billable OpenAI Images API calls by default.

Start with the task route

User task Read
Build, preflight, or troubleshoot gpt-image commands; map CLI flags to OpenAI SDK calls; handle reference edits, masks, output files, formats, size, quality, or exit codes sub-skills/cli-and-api/SKILL.md
Choose/adapt gallery prompts; create prompt skeletons for research figures, UI mockups, posters, typography, photography, anime/game/product styles, diagrams, or edit instructions sub-skills/prompt-gallery/SKILL.md
Edit the repository itself: add gallery entries, update README/docs/plugin metadata, change CLI flags, review PR readiness, or keep public mirrors aligned sub-skills/repo-maintenance/SKILL.md

Package facts

  • Distribution/package name: gpt-image-cli.
  • Import package: gpt_image_cli.
  • Console script: gpt-image.
  • Python requirement: Python 3.11 or newer.
  • Runtime dependencies: openai and python-dotenv.
  • Current verified package version for this skill: 0.2.0.
  • Default model in the CLI: gpt-image-2.

Minimal import and CLI checks:

python - <<'PY'
import gpt_image_cli
from gpt_image_cli import cli
print(cli.DEFAULT_MODEL)
print(cli.resolve_size("portrait"))
PY

gpt-image --help

If the package is not installed, install from the public package source for the target environment, then re-run gpt-image --help. Do not create or overwrite API-key files during setup.

Safety and cost boundary

Real generation or edit calls require OPENAI_API_KEY, network access, and may bill the user's OpenAI account. Ask before running real API calls unless the user has already made the execution request and accepted the credential/cost boundary. Never print secret values. For dry-run checks, use scripts/check_install.py and the CLI sub-skill helper instead of calling the API.

Shared references

Shared script

  • scripts/check_install.py: safe no-network package/CLI inspection; use it before deeper CLI/API troubleshooting or after installing the package.

Non-goals

  • Do not use this skill to bypass a host runtime's native image-generation tool when the user explicitly wants that native path.
  • Do not run full image generation/editing as verification; use help, parser, import, and file-validation checks unless the user requests live API execution.
  • Do not import this generated repo skill automatically; this production run was requested with not import.

04 同仓库更多 Skills

VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-triton-opt

Make a single PassNet Triton kernel fast AND numerically faithful: performance model (when a replacement can win at all), block/grid/warp tuning, autotune policy, launch overhead, and per-op numeric recipes to pass the dtype baseline tolerances. Use when a pass matches and is correct but speedup below expected, or when correctness fails by small numeric margins.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-solve

END-TO-END playbook for solving one PassNet sample: analyze the computation graphs, decide the optimization strategy (what to fuse, what to replace, what to leave alone), drive the iteration loop, and maximize the sample score. This is the ENTRY skill — invoke it first for any PassNet optimization task; it tells you when to use passnet-pattern-fusion, passnet-triton-opt and passnet-feedback.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-skill

PassNet GPU kernel optimization via compiler passes. Design and implement Triton-based optimization passes, create pass files under ./pass_dir/, self-evaluate with pass_evaluator, and iterate to maximize GPU speedup.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-pattern-fusion

Author PassNet pass files: write patterns that actually MATCH the FX graph, pick fusion regions (which ops to absorb into one Triton kernel), and structure multi-pass submissions with the mandatory shared-dispatch architecture. Use when creating or fixing pattern()/replacement_args()/replacement_func() files, when a pass "failed to match", or when deciding how to fuse multiple kernels/ops.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-orchestrate

Round/batch planning and decision support for PassNet graph optimization. Use for multi-sample triage, worker allocation, eval-budget policy, and post-eval keep/revert decisions. For solving one concrete sample end to end, use passnet-solve as the entry skill; consult this skill only when you need broader planning or a specific decision gate.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-feedback

Fast, deterministic feedback for PassNet work: pre-flight pattern/match verification WITHOUT burning a GPU evaluation, per-node bottleneck analysis of a sample's graphs, and eval-log parsing into per-variant status + estimated score + failure classification. Use BEFORE every GPU evaluation (check_pattern), at the START of a sample (analyze_graph), and AFTER every evaluation (parse_eval_log).

★ 351