Oma Image 标志

Oma Image

组织热门
first-fluke
oma-image

支持多供应商 AI 图像生成,并根据身份验证状态并行分发请求。可路由至 Codex(通过 ChatGPT OAuth 使用 gpt-image-2)和 Pollinations(flux/zimage,注册后免费使用)。Gemini 提供方已包含在内,但默认禁用(需要付费)。适用于图像生成、视觉素材制作和 AI 艺术创作。

Add to TypingMind

概览

发布者first-fluke
代码仓库oh-my-agent
技能名称oma-image
星标数
1.4K
复刻数
151
附带文件
5
许可协议MIT
链接
  • Markdown 格式的指令

    模型按需加载 SKILL.md 文件,因此只有在请求确实与该技能匹配时才会消耗 Token。

  • 兼容任何大语言模型

    AI 技能采用纯 Markdown,而非特定提供商的代码,因此可搭配 GPT、Claude、Gemini、Grok 或本地模型使用。

  • 5 个附带文件

    模型执行任务时可读取的脚本、模板和参考资料。这些文件为只读文件,绝不会被执行。

  • 开源

    由 first-fluke 发布于 GitHub。请在安装前查看技能的源文件。

安装

在 TypingMind 中安装 Oma Image AI 技能,即可搭配任意大语言模型使用;也可以将其放入其他支持读取 SKILL.md 的智能体中。

1

安装到 TypingMind

TypingMind 可直接从 GitHub 文件夹安装技能:读取 SKILL.md,打包资源文件,并将结果保存在本地。

  1. 打开应用,前往“插件 → 技能”。
  2. 选择“从 GitHub 安装”。
  3. 粘贴下方的技能文件夹 URL 并确认。
    https://github.com/first-fluke/oh-my-agent/tree/main/benchmarks/runs/oma/.agents/skills/oma-image
  4. 请在每个需要使用该技能的聊天中启用它。
依次选择“插件 → 技能 → 添加技能 → 从 GitHub URL 导入”,然后粘贴文件夹 URL 并点击“继续”。
2

安装到其他智能体

任何支持 Agent Skills 格式的智能体都可以使用此技能,只需将文件夹复制到该智能体的技能目录中。

Claude Code — .claude/skills
git clone --depth 1 https://github.com/first-fluke/oh-my-agent.git /tmp/oh-my-agent
mkdir -p .claude/skills
cp -r /tmp/oh-my-agent/benchmarks/runs/oma/.agents/skills/oma-image .claude/skills/oma-image
复制后,请重启 Claude Code,以加载新技能。

在 TypingMind 中使用此技能

在任意 TypingMind 聊天中启用 Oma Image,后续即可交由模型处理。技能的名称和描述会放在系统提示词中,一旦请求匹配,模型就会自动加载完整指令,无需您手动调用,且在实际使用前不会消耗 Token。

一旦请求与技能匹配,模型就会自动加载 Oma Image。

兼容任何 AI 模型

AI 技能是纯 Markdown 指令,而非特定提供商的代码,因此 Oma Image 不局限于最初适配的模型。只需在 TypingMind 中安装一次,即可搭配 GPT-5、Claude、Gemini、Grok、DeepSeek、Mistral、Llama 或您自行运行的本地模型使用,全程使用您自己的 API 密钥。

  • 仅在需要时加载

    系统提示词中仅包含技能名称和描述。首次遇到匹配的请求时才会加载完整指令,因此技能未使用时,这些指令不会消耗 Token。

  • 在聊天中切换模型

    技能是指令而非代码,因此切换模型不会导致技能失效,新模型会读取同一个 SKILL.md。

技能指令

这是模型会加载的 SKILL.md 内容。请在安装前阅读,因为技能就是模型将遵循的指令。

Image Agent - Multi-Vendor Image Router

Scheduling

Goal

Generate images and visual assets through authenticated multi-vendor routing while preserving prompt clarity, reference-image handling, cost controls, and reproducible output manifests.

Intent signature

  • User asks to generate images, visual assets, illustrations, product photos, concept art, mockups, or AI art.
  • Another skill needs shared image-generation infrastructure.
  • User provides reference images or asks for vendor comparison.

When to use

  • Generating images, visual assets, illustrations, product photos, concept art
  • Comparing output between multiple image models for the same prompt
  • Producing images from prompts within editor workflows (Claude Code, Codex, Gemini CLI)
  • Other skills needing image generation infrastructure (shared invocation)

When NOT to use

  • Editing an existing image or photo manipulation -> out of scope
  • Generating videos or audio -> out of scope
  • Inline vector art / SVG composition from structured data -> use a templating skill
  • Simple asset resizing or format conversion -> use a dedicated image library

Expected inputs

  • Image prompt or creative brief
  • Optional vendor, size, quality, count, output directory, and reference images
  • Authentication/environment state for Codex, Pollinations, or Gemini

Expected outputs

  • Generated image files under .agents/results/images/ or requested output directory
  • manifest.json with prompt, vendor, model, and reproducibility metadata
  • Vendor comparison outputs when --vendor all is used

Dependencies

  • oma image generate CLI and vendor authentication
  • Codex image generation, Pollinations API, or Gemini API/CLI strategy
  • resources/vendor-matrix.md, resources/prompt-tips.md, and config/image-config.yaml

Control-flow features

  • Branches by prompt ambiguity, vendor auth, cost threshold, reference-image support, path safety, and safety/timeout exit codes
  • Calls external vendor APIs/CLIs
  • Reads reference images and writes generated images plus manifests

Structural Flow

Entry

  1. Validate that the request contains enough subject, setting, style, usage, and aspect-ratio signal.
  2. Detect attached/reference images and vendor support.
  3. Check authentication, cost guardrails, output path, and count limits.

Scenes

  1. PREPARE: Clarify or amplify prompt and choose vendor strategy.
  2. ACQUIRE: Validate auth, references, output path, and provider availability.
  3. ACT: Invoke oma image generate with selected vendor(s), prompt, references, and options.
  4. VERIFY: Check manifest, output files, exit code, and provider result.
  5. FINALIZE: Return output paths and relevant warnings.

Transitions

  • If prompt lacks required signal, clarify or show amplified prompt before generation.
  • If --vendor all is requested, require every requested vendor to be available.
  • If reference path is supported by selected vendor, pass it automatically.
  • If estimated cost exceeds guardrail, require confirmation unless bypassed.

Failure and recovery

  • If auth is missing, report vendor-specific authentication requirement.
  • If reference support is unavailable for the selected vendor, reject with actionable guidance.
  • If local CLI is outdated, ask user to run oma update.
  • If generation times out or is blocked, surface exit code and provider status.

Exit

  • Success: images and manifest exist in the output directory.
  • Partial success: some vendors fail in comparison mode and failures are reported.
  • Failure: no image is produced and the route/cost/auth/safety blocker is explicit.

Logical Operations

Actions

ActionSSL primitiveEvidence
Validate prompt completenessVALIDATEClarification protocol
Select vendor strategySELECTVendor matrix and auth state
Read reference imagesREAD--reference paths
Call generation CLI/APICALL_TOOLoma image generate
Write image outputsWRITEImage files and manifest
Validate resultVALIDATEExit code, manifest, files
Report outputNOTIFYFinal path summary

Tools and instruments

  • oma image generate, oma image doctor, oma image list-vendors
  • Codex, Pollinations, and Gemini provider paths
  • Prompt tips, vendor matrix, and image config

Canonical command path

bash
oma image doctor
oma image generate "<prompt>" --vendor auto --size auto --quality auto --format json

With reference images:

bash
oma image generate --reference "<absolute-path>" --vendor codex "<prompt>"

Resource scope

ScopeResource target
LOCAL_FSReference images, generated images, manifests
PROCESSProvider CLIs and image router commands
NETWORKPollinations/Gemini or provider APIs
CREDENTIALSProvider auth and API keys

Preconditions

  • Prompt is sufficiently specified or user approves amplification.
  • Required vendor auth and output permissions exist.
  • Reference paths are accessible when used.

Effects and side effects

  • Creates image files and manifests.
  • May call paid or rate-limited provider APIs.
  • May read attached/reference images.

Guardrails

  1. Clarify before invoking — if the user's request is ambiguous about subject, style, composition, or usage context, ask the user first or amplify the prompt explicitly (showing the user the expanded version for approval). Do NOT silently generate from a vague prompt. See Clarification Protocol below.
  2. Authentication-aware dispatch — detect which vendor CLIs are authenticated and run only those; with --vendor all, every requested vendor must be available (strict).
  3. Cost guardrail — confirm before executing runs whose estimated cost is ≥ $0.20 (configurable). --yes / OMA_IMAGE_YES=1 bypass. Default vendor pollinations (flux/zimage) is free, so auto-triggering on keywords is safe.
  4. Path safety — output paths outside $PWD require --allow-external-out.
  5. Cancellable — SIGINT/SIGTERM aborts in-flight provider calls and the orchestrator.
  6. Deterministic outputs — every run writes manifest.json next to the images for reproducibility.
  7. Max n = 5 — wall-time bound.
  8. Exit codes align with oma search fetch (0, 1, 2=safety, 3=not-found, 4=invalid-input, 5=auth-required, 6=timeout).

Clarification Protocol

Before invoking oma image generate, the calling agent runs this checklist against the user's request. If any answer is "no / unknown", clarify with the user first.

Required signal (must be present or inferable):

  • Subject — what is the primary thing in the image? (object, person, scene)
  • Setting / backdrop — where is it? (context, environment)

Strongly recommended (ask if absent AND not inferable from context):

  • Style — photorealistic, illustration, 3D render, oil painting, concept art, flat vector, …?
  • Mood / lighting — bright vs moody, warm vs cool, dramatic vs minimal
  • Usage context — hero image, icon, thumbnail, product shot, poster? (dictates aspect ratio + composition)
  • Aspect ratio — square (1024x1024), portrait (1024x1536), landscape (1536x1024)?

Amplification shortcut. For brief prompts (e.g. "a red apple"), do not pop clarifying questions if the request is genuinely that simple — instead amplify inline and show the user the expanded version before invoking:

User: "a red apple" Agent: "I'll generate this as: a single glossy red apple centered on a clean white background, soft studio lighting, photorealistic, shallow depth of field, 1024×1024. Shall I proceed, or would you like a different style/composition?"

Skip both clarification and amplification when the user has clearly authored a full creative brief (≥ 2 of: subject + style + lighting + composition). Respect their prompt verbatim.

Category-specific briefs (app mockup, poster, thumbnail, infographic, comic panel, avatar): consult resources/prompt-tips.md → External Prompt Libraries.

Output language. Generation prompts are sent to the provider in English (image models are trained predominantly on English captions). Translate the user's request if they wrote in another language, and show them the translated version during amplification so they can correct misreadings.

Vendors

This skill follows oh-my-agent's CLI-first concept: whenever a vendor's native CLI can drive generation (and return raw bytes), the subprocess path is preferred over direct API keys. Direct API is only used as a fallback for vendors whose CLI can't yet emit raw image bytes.

VendorStrategyModelsTrigger
codexCLI-first — codex exec via ChatGPT OAuth (codex login), built-in image_gengpt-image-2Logged in via Codex CLI (no API key)
pollinationsDirect HTTP — gen.pollinations.ai/v1/images/generations (free signup for key)Free: flux, zimage. Credit-gated: qwen-image, wan-image, gpt-image-2, klein, kontext, gptimage, gptimage-largePOLLINATIONS_API_KEY set (free at https://enter.pollinations.ai). No native CLI exists.
geminiCLI-first fallback → direct API. gemini -p (stream) is the preferred path but currently disabled at precheck (CLI's agentic loop does not return raw inlineData bytes on stdout as of Gemini CLI 0.38). Until the CLI exposes a non-agentic image surface, the provider falls back to the direct generativelanguage.googleapis.com API.gemini-2.5-flash-image, gemini-3.1-flash-image-previewPreferred: gemini auth login. Fallback: GEMINI_API_KEY + billing.

Invocation

Standalone
/oma-image a red apple on white background
/oma-image --vendor all --size 1536x1024 jeju coastline at sunset
/oma-image -n 3 --quality high --out ./hero "minimalist dashboard hero illustration"
Shell CLI
oma image generate "<prompt>" [--vendor auto|codex|pollinations|gemini|all] [-n 1..5] \
                             [--size 1024x1024|1024x1536|1536x1024|auto] \
                             [--quality low|medium|high|auto] \
                             [--out <dir>] [--allow-external-out] \
                             [-r <path>]... \
                             [--timeout 180] [-y] [--no-prompt-in-manifest] \
                             [--dry-run] [--format text|json]
oma image doctor
oma image list-vendors

Gemini-only escalation flag: --strategy mcp,stream,api (overrides vendors.gemini.strategies).

Reference Images (-r, --reference)

Attach up to 10 reference images (PNG/JPEG/GIF/WebP, ≤ 5MB each) to guide style, subject identity, or composition. Repeatable or comma-separated.

oma image generate -r ~/Downloads/otter.jpeg "same otter in dramatic lighting"
oma image generate -r a.png -r b.png "blend these two styles"

Supported vendors:

VendorSupportHow
codex (gpt-image-2)✅Passes -i <path> to codex exec
gemini (2.5-flash-image)✅Inlines base64 inlineData parts in request
pollinations❌Rejected with exit code 4 (requires URL hosting; see PR #2 roadmap)

Paths: absolute or relative to $CWD. Host CLIs usually expose attached images via:

  • Claude Code: ~/.claude/image-cache/<session>/N.png (surfaced in system messages as [Image: source: <path>])
  • Antigravity: workspace upload directory (exact path shown in IDE)
  • Codex CLI as host: user must pass the filesystem path explicitly; in-conversation attachments are not forwarded
Agent Behavior: Auto-forward Attached References (MANDATORY)

When ALL of the following are true, the calling agent MUST pass the attached image via --reference <path> automatically. Never describe the image in prose as a workaround.

  1. The user asks to generate or edit an image (referencing the attached one by phrases like "이거", "this image", "same style as this", "이 수달", etc.).
  2. A host-surfaced attached image is visible to the agent — e.g. a Claude Code system message with [Image: source: <path>], or an Antigravity workspace upload path, or an explicit filesystem path in the user's message.
  3. The selected vendor supports references (codex or gemini).

Required action: invoke oma image generate --reference <absolute-path> --vendor <codex|gemini> "<prompt>". If the user didn't specify a vendor, default to codex (CLI-first, widest availability). Do NOT:

  • Fall back to prose description ("I'll describe the otter's appearance...").
  • Ask the user to re-type or re-attach the path.
  • Claim the CLI doesn't support references without first running oma image generate --help to verify.

If the local CLI is outdated (--reference is missing from --help): tell the user to run oma update once, then retry. Do not silently degrade to prose.

If the reference path is from Claude Code's image-cache: note to the user that the path is session-scoped and suggest copying the file to a durable location if they want to reuse it later. Still proceed with the generation.

Shared Infrastructure (from other skills)

Other skills call oma image generate --format json and parse the JSON manifest from stdout.

Output Layout

.agents/results/images/
├── 20260424-143052-ab12cd/                    # single-vendor run
│   └── pollinations-flux.jpg
│       (or codex-gpt-image-2.png)
│       manifest.json
└── 20260424-143122-7z9kqw-compare/            # --vendor all run
    ├── codex-gpt-image-2.png
    ├── pollinations-flux.jpg
    └── manifest.json

References

Follow resources/execution-protocol.md step by step. See resources/vendor-matrix.md for strategy precheck rules. Use resources/prompt-tips.md for writing effective prompts. Before submitting, run resources/checklist.md.

Configuration

Project-specific settings: config/image-config.yaml. Env vars: OMA_IMAGE_DEFAULT_VENDOR, OMA_IMAGE_DEFAULT_OUT, OMA_IMAGE_YES, POLLINATIONS_API_KEY, GEMINI_API_KEY, OMA_IMAGE_GEMINI_STRATEGIES.

  • Execution steps: resources/execution-protocol.md
  • Vendor matrix: resources/vendor-matrix.md
  • Prompt tips: resources/prompt-tips.md
  • Checklist: resources/checklist.md
  • Context loading: ../_shared/core/context-loading.md

附带文件

技能加载后,模型会按需读取这些文件。它们仅作为可读文件提供,绝不会被执行。

常见问题

Oma Image AI 技能有什么作用?

支持多供应商 AI 图像生成,并根据身份验证状态并行分发请求。可路由至 Codex(通过 ChatGPT OAuth 使用 gpt-image-2)和 Pollinations(flux/zimage,注册后免费使用)。Gemini 提供方已包含在内,但默认禁用(需要付费)。适用于图像生成、视觉素材制作和 AI 艺术创作。

为什么在 TypingMind 中使用 Oma Image?

因为您只需安装一次,就能搭配任何模型使用。Oma Image 采用纯 Markdown 格式,而非特定提供商专用的代码,因此同一技能可用于 GPT-5、Claude、Gemini、Grok 或本地模型。您甚至可以在聊天中途切换模型,而不会影响技能的正常使用。TypingMind 使用您自己的 API 密钥,因此您直接向提供商付费,而不是按席位订阅;您的技能和聊天记录也都保留在您自己的存储空间中。

如何在 TypingMind 中安装 Oma Image?

在 TypingMind 中打开“插件 → 技能 → 从 GitHub 安装”,然后粘贴 https://github.com/first-fluke/oh-my-agent/tree/main/benchmarks/runs/oma/.agents/skills/oma-image。TypingMind 会读取其中的 SKILL.md,打包相关文件,并将其安装为技能,供您在各个聊天中按需启用。

哪些 AI 模型可以使用 Oma Image?

您在 TypingMind 中连接的任何模型都可以。AI 技能采用纯 Markdown 指令,而非特定提供商专用的代码,因此 GPT、Claude、Gemini、Grok 和本地模型都能在请求匹配时加载此技能。

Oma Image 可以搭配多少个 AI 模型使用?

数量不限。只要模型支持技能,您就可以将它与 Oma Image 搭配使用。GPT、Claude、Gemini、Grok、DeepSeek、Mistral、Llama 等模型都可以通过您自己的 API 密钥接入 TypingMind。

Oma Image AI 技能免费吗?

是的。first-fluke 已在 GitHub 上根据 MIT 许可证发布了该技能。您只需向自己的 AI 提供商支付所用 Token 的费用。

什么是 AI 技能?

AI 技能是一组可复用的指令,用于教会 AI 模型完成某项特定任务。它遵循开放的 Agent Skills 格式:包含名称和描述的 SKILL.md 文件,以及模型可能需要的脚本、模板或参考文件。模型仅在您的请求与技能匹配时才会读取这些指令,因此已安装的技能在使用前不会产生任何费用。

AI 技能与插件或 MCP 服务器有何不同?

插件或 MCP 服务器为模型提供可调用的新工具,也就是在某处运行并返回结果的代码。AI 技能则为模型提供知识和流程:如何处理任务、遵循哪些步骤,以及怎样的输出才算优质。技能采用纯 Markdown 格式,因此不需要服务器、API 密钥或运行时环境,并且适用于任何模型。

查看全部

立即创建您自己的 AI 工作区

订阅我们的电子简报,获取新功能和后续赠奖活动的通知 👇