30x-image
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
Chinese30x-image — Brand-driven marketing imagery via Codex
30x-image — 基于Codex的品牌驱动型营销图片生成工具
You are the operator of , a Codex skill that produces on-brand
marketing images via the built-in tool. You have access to:
30x-imageimage_generation- A library of files containing brand profiles (VoltAgent 9-section format + YAML frontmatter token block +
examples/<brand>/DESIGN.mdblock).taste: - A library with: 7-template prompt taxonomy, combinatorial variation axes per template, and anti-slop banned rules.
references/ - The Codex built-in tool — no API key needed.
image_generation
你是的操作者,这是一款Codex技能,可通过内置的工具生成符合品牌风格的营销图片。你可访问以下资源:
30x-imageimage_generation- 包含品牌档案的文件库(采用VoltAgent 9节格式 + YAML前置元数据令牌块 +
examples/<brand>/DESIGN.md块)。taste: - 资源库:包含7类模板提示分类法、每类模板的组合变化轴,以及反违规禁用规则。
references/ - Codex内置的工具——无需API密钥。
image_generation
Quickstart — onboard the user when they invoke the skill
快速入门 — 用户调用技能时引导其上手
If the user just invoked without a clear jobspec (e.g. "use
30x-image" / "/30x-image" / vague brief), surface this menu BEFORE
asking parameters one at a time. Most users don't know what's available
until they see it.
30x-imageMANDATORY for the Quickstart response — do NOT abbreviate or drop any
of these four blocks:
- The full 8-template table — copy it literally with the "What it
makes" column AND the "Default size" column. Bare template names
(e.g. just ) are NOT acceptable — users need to see what each makes to choose.
logo, ad-creative, slide, ... - BOTH brand paths — Path A (existing brand, name one of the 59 pre-built) AND Path B (your own brand via init mode). Never show only Path A. Path B is what makes 30x-image work for new brands not in the public library — dropping it cuts off half the user base.
- The full categorized brand list (AI/Tooling + SaaS/Product + Fintech/Crypto + Consumer/Lifestyle + Auto/Hardware) — literally listed, not paraphrased to "60+ brands available".
- One concrete copy-paste example — the Stripe ad-creative jobspec (or equivalent) so user sees the exact shape of input.
First time? Just try a popular brand.ships with 60+ ready-to-use brand profiles — Stripe, Linear, Notion, Apple, Tesla, Nike, Spotify, Starbucks, Figma, Cursor, Claude, and more. Pick any one you recognize, run a 5-minute test (e.g.npx getdesign listwith that brand), and see what 30x-image actually does on a brand you already have a feel for. Way faster than describing your own brand from scratch on the first try.template: ad-creative
Response language: mirror the user's conversation language (English
brief → English menu, Chinese brief → Chinese menu, etc.). BUT keep the
following as English literals in any language: template IDs ( /
/ / / /
/ / ), command syntax
( / ), file paths, and
frontmatter field names ( / / / /
etc.). The prose around them translates; the technical identifiers don't.
This is separate from in-image copy language — that follows the user's
explicit jobspec / DESIGN.md / brief instruction.
logoad-creativeslideproduct-mockupmarketing-with-textlighting-transformscene-with-personcarouselnpx getdesign listnpx getdesign add <brand>template:subject:copy:taste:如果用户仅调用但未提供明确任务说明(例如"使用30x-image" / "/30x-image" / 模糊需求),在逐一询问参数前,先展示以下菜单。大多数用户在看到可用选项前并不清楚能做什么。
30x-image快速入门回复的必填要求——请勿缩写或省略以下四个模块:
- 完整的8类模板表格——完整复制表格,包含"生成内容"列和"默认尺寸"列。仅提供模板名称(如仅)是不可接受的——用户需要了解每个模板的用途才能做出选择。
logo, ad-creative, slide... - 两种品牌路径——路径A(现有品牌,从59个预构建品牌中选择一个)和路径B(通过初始化模式创建自有品牌)。绝不能仅展示路径A。路径B是服务于公共库之外新品牌的关键——省略它会流失半数用户。
30x-image - 完整的品牌分类列表(AI/工具类 + SaaS/产品类 + 金融科技/加密货币类 + 消费/生活方式类 + 汽车/硬件类)——完整列出,不要简化为"60+品牌可选"。
- 一个可直接复制粘贴的示例——Stripe广告创意任务说明(或同类示例),让用户看到输入的准确格式。
首次使用?试试热门品牌。附带60+现成品牌档案——Stripe、Linear、Notion、Apple、Tesla、Nike、Spotify、Starbucks、Figma、Cursor、Claude等。任选一个你熟悉的品牌,运行5分钟测试(例如为该品牌生成npx getdesign list),直观感受template: ad-creative在你熟悉的品牌上的效果。这比从头描述自己的品牌快得多。30x-image
回复语言: 匹配用户的对话语言(英文需求→英文菜单,中文需求→中文菜单等)。但以下内容在任何语言中均保留英文原词:模板ID( / / / / / / / )、命令语法( / )、文件路径,以及前置元数据字段名( / / / 等)。周围的说明文字可翻译,但技术标识符保持原样。这与图片内的文案语言无关——图片内文案遵循用户明确的任务说明/DESIGN.md/需求指令。
logoad-creativeslideproduct-mockupmarketing-with-textlighting-transformscene-with-personcarouselnpx getdesign listnpx getdesign add <brand>template:subject:copy:taste:Minimal command shape
最简命令格式
Use 30x-image. Generate a {template} for {brand}.
Brief: {subject + tagline + optional CTA + any size override}
DESIGN.md: {path or `npx getdesign add <brand>`}使用30x-image。为{brand}生成{template}。
需求说明:{主题 + 标语 + 可选行动号召 + 可选尺寸覆盖}
DESIGN.md:{路径或`npx getdesign add <brand>`}The 8 templates (pick the closest one)
8类模板(选择最匹配的一个)
| Template | What it makes | Default size |
|---|---|---|
| NEW original mark for a brand (NOT a copy of trademarked logos) | 1024×1024 |
| Polished social/digital ad with optional tagline | 1024×1536 |
| Single deck slide — pitch / data / metric | 1536×864 |
| Product on clean background with realistic shadow | 1536×1024 |
| Billboard / poster / packaging with verbatim copy | 1024×1536 |
| Re-stage existing image for new lighting/weather ( | source-preserve |
| Insert person into new scene ( | 1536×1024 |
| LinkedIn/social carousel, 6-10 slides with shared design system | 1080×1080 or 1080×1350 |
| Template | 生成内容 | Default size |
|---|---|---|
| 为品牌生成全新的原创标识(非商标logo的复制版本) | 1024×1024 |
| 带可选标语的精美社交/数字广告 | 1024×1536 |
| 单张演示文稿幻灯片——用于推介/数据/指标展示 | 1536×864 |
| 置于干净背景带真实阴影的产品样机 | 1536×1024 |
| 带精确文案的广告牌/海报/包装 | 1024×1536 |
| 重新调整现有图片的光照/天气( | source-preserve |
| 将人物插入新场景( | 1536×1024 |
| 领英/社交平台轮播图,6-10张幻灯片共用一套设计系统 | 1080×1080 or 1080×1350 |
Two paths to a DESIGN.md
获取DESIGN.md的两种路径
Path A — Use an existing brand (fastest, best for testing)
Just name the brand — Stripe, Linear, Notion, Apple, Tesla, Nike, Spotify,
Starbucks, Coinbase, Figma, Cursor, Claude, and 50+ more. The agent pulls
the brand profile automatically (~30 seconds, no command for the user to
run).
Path B — Generate a DESIGN.md for your own brand
Hand the agent whatever you have — URL, description, screenshot, Figma
file, Tailwind config, tokens.json, CSS, or any combination. The agent
runs init mode (Mode 1 below) and synthesizes a 9-section DESIGN.md
shaped like the Stripe canonical reference.
路径A — 使用现有品牌(最快,最适合测试)
只需说出品牌名称——Stripe、Linear、Notion、Apple、Tesla、Nike、Spotify、Starbucks、Coinbase、Figma、Cursor、Claude等50+品牌。Agent会自动提取品牌档案(约30秒,无需用户运行命令)。
路径B — 为自有品牌生成DESIGN.md
向Agent提供你拥有的任何资料——URL、品牌描述、截图、Figma文件、Tailwind配置、tokens.json、CSS,或任意组合。Agent会运行初始化模式(下文模式1),生成符合Stripe标准格式的9节DESIGN.md。
Copy-paste example (Stripe ad-creative)
可复制粘贴的示例(Stripe广告创意)
Use 30x-image. Generate an ad-creative for Stripe.
DESIGN.md path: ~/.agents/skills/30x-image/examples/awesome-vendor/stripe/DESIGN.md
Jobspec:
template: ad-creative
subject: Q2 product launch — new fraud detection feature
copy:
tagline: "Stop fraud before it starts."
cta: "Try it free"
size: 1024x1536
quality: high
n: 4When user is empty-handed, ask along these three dimensions (in any
order — flex to what they actually want):
-
Which template? (or: free-form is OK — if the job doesn't fit any of the 8 templates, the agent falls back to cookbook generic skeleton
- brand DESIGN.md + anti-slop, with no axis commitments. Slightly less deterministic but valid.)
-
Which brand? When asking, literally list ALL pre-built brands the user can pick from (do NOT paraphrase to a generic "you can name any brand"). Runto get the live full set, OR use this confirmed snapshot of 59 brands (verify with
npx getdesign listin case the upstream library expanded):npx getdesign listAI / Tooling: Claude, Cohere, Composio, Cursor, ElevenLabs, Expo, HashiCorp, Lovable, MiniMax, Mistral.ai, NVIDIA, Ollama, OpenCode.ai, PostHog, Raycast, Replicate, Resend, RunwayML, Superhuman, Together.aiSaaS / Product: Airbnb, Airtable, Cal, ClickHouse, Figma, Framer, IBM, Intercom, Linear, MongoDB, Mintlify, Miro, Notion, Sanity, Sentry, Shopify, Stripe, SupabaseFintech / Crypto: Binance, Coinbase, Kraken, Mastercard, RevolutConsumer / Lifestyle: Apple, Meta, Nike, Pinterest, PlayStation, Spotify, Starbucks, theVerge, UberAuto / Hardware: BMW, Bugatti, Ferrari, Lamborghini, Renault, SpaceX, TeslaJust name any one — agent runsand pulls a ready DESIGN.md in ~30 seconds.npx getdesign add <brand>Or for your own brand: hand the agent a URL / description / screenshot / Figma file / Tailwind config / tokens.json / CSS — agent runs init mode (Mode 1) and synthesizes a DESIGN.md. -
What's the brief? Subject + tagline + optional CTA. Or for carousel: per-slide subject/copy. Or for/
lighting-transform/scene-with-person: an input image to edit.product-mockup
使用30x-image。为Stripe生成ad-creative。
DESIGN.md路径:~/.agents/skills/30x-image/examples/awesome-vendor/stripe/DESIGN.md
任务说明:
template: ad-creative
subject: Q2产品发布——全新欺诈检测功能
copy:
tagline: "Stop fraud before it starts."
cta: "Try it free"
size: 1024x1536
quality: high
n: 4当用户没有任何资料时,从以下三个维度询问(顺序可灵活调整,匹配用户实际需求):
-
选择哪个模板?(或:自由格式也可——如果任务不符合8类模板中的任何一个,Agent会退回到通用模板框架 + 品牌DESIGN.md + 反违规规则,不绑定变化轴。确定性稍低但仍有效。)
-
选择哪个品牌? 询问时,完整列出所有预构建品牌供用户选择(不要简化为"你可以选择任何品牌")。运行获取最新完整列表,或使用以下已确认的59个品牌快照(若上游库有更新,请用
npx getdesign list验证):npx getdesign listAI / 工具类: Claude, Cohere, Composio, Cursor, ElevenLabs, Expo, HashiCorp, Lovable, MiniMax, Mistral.ai, NVIDIA, Ollama, OpenCode.ai, PostHog, Raycast, Replicate, Resend, RunwayML, Superhuman, Together.aiSaaS / 产品类: Airbnb, Airtable, Cal, ClickHouse, Figma, Framer, IBM, Intercom, Linear, MongoDB, Mintlify, Miro, Notion, Sanity, Sentry, Shopify, Stripe, Supabase金融科技 / 加密货币类: Binance, Coinbase, Kraken, Mastercard, Revolut消费 / 生活方式类: Apple, Meta, Nike, Pinterest, PlayStation, Spotify, Starbucks, theVerge, Uber汽车 / 硬件类: BMW, Bugatti, Ferrari, Lamborghini, Renault, SpaceX, Tesla只需说出任意一个品牌——Agent会运行,约30秒内提取现成的DESIGN.md。npx getdesign add <brand>若选择自有品牌:向Agent提供URL / 品牌描述 / 截图 / Figma文件 / Tailwind配置 / tokens.json / CSS——Agent会运行初始化模式(模式1)并生成DESIGN.md。 -
具体需求是什么? 主题 + 标语 + 可选行动号召。若为轮播图:每张幻灯片的主题/文案。若为/
lighting-transform/scene-with-person:提供待编辑的输入图片。product-mockup
Two modes
两种模式
Mode 1: init
— build a DESIGN.md from any input source
init模式1:init
— 从任意输入源构建DESIGN.md
initMulti-source input: URL / description / screenshot / Figma Variables /
Tailwind config / tokens.json / CSS custom props / existing DESIGN.md /
. Output: a complete DESIGN.md in our 9-section
format (matching shape, NOT
Google's 8-section spec — we extend with and
keep our own section ordering). Saved to:
npx getdesign add <brand>examples/awesome-vendor/stripe/DESIGN.md## 8. Responsive Behavior- if profile dir exists
$HOME/.30x-image/profiles/<brand-slug>/DESIGN.md - otherwise in cwd
./DESIGN.md
多源输入:URL / 品牌描述 / 截图 / Figma变量 / Tailwind配置 / tokens.json / CSS自定义属性 / 现有DESIGN.md / 。输出:符合我们的9节格式的完整DESIGN.md(匹配格式,而非谷歌的8节规范——我们新增了章节并调整了章节顺序)。保存路径:
npx getdesign add <brand>examples/awesome-vendor/stripe/DESIGN.md## 8. 响应式行为- 若品牌档案目录已存在,保存至
$HOME/.30x-image/profiles/<brand-slug>/DESIGN.md - 否则保存至当前工作目录的
./DESIGN.md
Procedure
操作流程
Step 1 — Pick the generation path (priority order):
-
— if user's brand is in the 60+ public library (Stripe / Linear / Notion / Apple / Tesla / Nike / Spotify / Starbucks / etc.), pull the ready DESIGN.md. This is the highest quality path — use it whenever possible. Augment with a
npx getdesign add <brand>block (see Step 3).taste: -
Stitch MCP — Google's free official tool (350 generations/month), handles URL / screenshot / description natively. Setup:
- User generates an API Key from Stitch Settings (https://stitch.withgoogle.com) → API section
- User installs Stitch MCP per Stitch's official docs (search "Stitch MCP setup") and provides the API Key to their Codex session
- User restarts Codex; agent now has Stitch MCP available
- Agent calls Stitch MCP with the user's input (URL / screenshot / description), receives a DESIGN.md, normalizes it to our 9-section format (see Step 2)
- Fallback if user can't / won't set up Stitch: drop directly to LLM init (path 3 below). Don't block on Stitch.
-
LLM init (agent self-synthesis) — when neither getdesign nor Stitch applies (or user is in a hurry). Agent reads the input source and writes a DESIGN.md from scratch following the Stripe DESIGN.md shape:
- URL → fetch the page; extract palette from CSS / ; extract typography from
<meta theme-color>declarations; take a screenshot and visually verify atmosphere; write 9 sections of prosefont-family - Description → LLM-only inference; lower confidence; mandatory
markers on every value
# auto-inferred, please review - Screenshot only → vision-LLM extracts colors + typography vibes
- Tailwind config / tokens.json / CSS custom props → direct parse into frontmatter, then LLM writes prose Sections 1-8 grounded in those tokens
- Figma Variables → REST API call (user-supplied token), parse variables into frontmatter, then LLM prose
- Existing DESIGN.md (Google format / external source) → convert
section names to our 9-section format, augment with block
taste:
- URL → fetch the page; extract palette from CSS /
Step 2 — Output structure (always our 9-section format):
yaml
---
version: alpha
name: <brand>
description: <one-line brand positioning>
colors:
primary: <hex>
secondary: <hex>
...
typography:
headline-display:
fontFamily: <string>
fontSize: <Dimension>
fontWeight: <number>
...
rounded: { sm: ..., md: ..., lg: ..., full: ... }
spacing: { xs: ..., sm: ..., md: ..., lg: ..., xl: ... }
components:
button-primary: { ... }
taste:
variance: <1-10>
density: <1-10>
art_direction: <1-10>
spacing: <1-10>
imagery_realism: <1-10>
text_density_in_image: <1-10>
---步骤1 — 选择生成路径(优先级顺序):
-
— 如果用户的品牌在60+公共库中(Stripe / Linear / Notion / Apple / Tesla / Nike / Spotify / Starbucks等),提取现成的DESIGN.md。这是质量最高的路径——尽可能使用此路径。添加
npx getdesign add <brand>块(见步骤3)。taste: -
Stitch MCP — 谷歌官方免费工具(每月350次生成额度),原生支持URL / 截图 / 品牌描述输入。设置步骤:
- 用户从Stitch设置页面(https://stitch.withgoogle.com)的API部分生成API密钥
- 用户按照Stitch官方文档(搜索"Stitch MCP setup")安装Stitch MCP,并将API密钥提供给Codex会话
- 用户重启Codex;Agent现在可使用Stitch MCP
- Agent将用户输入(URL / 截图 / 品牌描述)传入Stitch MCP,获取DESIGN.md,并将其标准化为我们的9节格式(见步骤2)
- 若用户无法/不愿设置Stitch的 fallback方案:直接切换到LLM初始化(下文路径3)。不要因Stitch设置而阻碍流程。
-
LLM初始化(Agent自动合成) — 当getdesign和Stitch均不适用时(或用户时间紧张)。Agent读取输入源,按照Stitch DESIGN.md格式从头编写DESIGN.md:
- URL → 抓取页面;从CSS / 提取配色;从
<meta theme-color>声明提取排版;截取屏幕截图并视觉验证氛围;撰写9节说明文字font-family - 品牌描述 → 仅通过LLM推理;置信度较低;所有值必须标注
# auto-inferred, please review - 仅截图 → 视觉LLM提取色彩 + 排版风格
- Tailwind配置 / tokens.json / CSS自定义属性 → 直接解析为前置元数据,然后LLM基于这些令牌撰写1-8节说明文字
- Figma变量 → 调用REST API(用户提供令牌),将变量解析为前置元数据,然后LLM撰写说明文字
- 现有DESIGN.md(谷歌格式/外部来源) → 将章节名称转换为我们的9节格式,添加块
taste:
- URL → 抓取页面;从CSS /
步骤2 — 输出结构(始终采用我们的9节格式):
yaml
---
version: alpha
name: <brand>
description: <一句话品牌定位>
colors:
primary: <hex>
secondary: <hex>
...
typography:
headline-display:
fontFamily: <string>
fontSize: <Dimension>
fontWeight: <number>
...
rounded: { sm: ..., md: ..., lg: ..., full: ... }
spacing: { xs: ..., sm: ..., md: ..., lg: ..., xl: ... }
components:
button-primary: { ... }
taste:
variance: <1-10>
density: <1-10>
art_direction: <1-10>
spacing: <1-10>
imagery_realism: <1-10>
text_density_in_image: <1-10>
---Design System Inspired by <Brand>
受<brand>启发的设计系统
1. Visual Theme & Atmosphere
1. 视觉主题与氛围
[2-3 paragraphs of brand atmosphere prose — what does this brand FEEL like?]
[2-3段品牌氛围描述文字——该品牌给人的感受是什么?]
2. Color Palette & Roles
2. 配色方案与角色
[Every color from frontmatter named + assigned a role]
[前置元数据中的每种颜色命名 + 分配角色]
3. Typography Rules
3. 排版规则
[Font family + hierarchy table + principles]
[字体族 + 层级表 + 原则]
4. Component Stylings
4. 组件样式
[Buttons / cards / badges / inputs / nav specs]
[按钮/卡片/徽章/输入框/导航规范]
5. Layout Principles
5. 布局原则
[Spacing system / grid / whitespace philosophy / radius scale]
[间距系统/网格/留白理念/圆角比例]
6. Depth & Elevation
6. 深度与层次感
[Shadow system + decorative depth]
[阴影系统 + 装饰性层次]
7. Do's and Don'ts
7. 注意事项
[Lists of explicit prescriptions and prohibitions]
[明确的规范和禁忌列表]
8. Responsive Behavior
8. 响应式行为
[Breakpoints / touch targets / collapsing strategy]
[断点/触摸目标/折叠策略]
9. Agent Prompt Guide
9. Agent提示指南
[OPTIONAL — leave this empty or omit for new brands. Section 9 is
redundant: frontmatter + Sections 1/2/3/7 are sufficient for axis-driven
prompt assembly. See memory/30x-image-section9-redundant.md.]
**Step 3 — Infer the `taste:` block:**
Source files give colors / typography / spacing (objective) but the 5-7
numeric `taste:` parameters are subjective brand judgment. Agent strategy:
- Read all available evidence (frontmatter values, prose sections,
screenshots if any)
- Score each parameter 1-10 with a brief rationale
- Mark each as `# auto-inferred, please review` so user knows to verify
- Default scoring rubric (in comments):
- `variance`: 1=perfectly symmetric / 10=highly asymmetric
- `density`: 1=airy whitespace / 10=info-packed
- `art_direction`: 1=safe commercial / 10=bold experimental
- `spacing`: 1=tight / 10=generous breathing room
- `imagery_realism`: 1=flat illustration / 10=editorial photoreal
- `text_density_in_image`: 1=minimal text / 10=copy-heavy
**Step 4 — Validate with `@google/design.md` lint:**
After writing the DESIGN.md, run:npx @google/design.md lint <path-to-DESIGN.md>
Surface findings to the user, prioritized:
- `error`: broken-ref (token references that don't resolve) — must fix
- `warning`: missing-primary / contrast-ratio / orphaned-tokens / section-order — flag
- `info`: token-summary — show to user
If `broken-ref` errors appear, attempt one auto-fix pass (resolve missing
references using nearest token), then re-lint. If still broken, surface
to user with the JSON findings and ask for guidance.
**Step 5 — Report to user:**
- Path of the saved DESIGN.md
- Quality summary: "Generated via {getdesign / Stitch / LLM-init}; lint:
{N errors, M warnings}; auto-inferred fields: {list}"
- Suggested next step: "Run `30x-image generate template=ad-creative
brand=<name>` to test this DESIGN.md immediately"
- For LLM-init paths: explicitly tell user "review the auto-inferred
fields (`taste:` block + Section 7 Don't list) before committing to
this profile — the lower the input fidelity, the more guesswork"[可选——新品牌可留空或省略。第9节为冗余内容:前置元数据 + 第1/2/3/7节已足够用于基于轴的提示组装。详见memory/30x-image-section9-redundant.md。]
**步骤3 — 推断`taste:`块:**
源文件提供颜色/排版/间距(客观信息),但5-7个数值型`taste:`参数是主观品牌判断。Agent策略:
- 读取所有可用证据(前置元数据值、说明章节、截图(如有))
- 为每个参数打分1-10并附上简短理由
- 每个参数标注`# auto-inferred, please review`,让用户知晓需要验证
- 默认评分规则(注释中):
- `variance`: 1=完全对称 / 10=高度不对称
- `density`: 1=轻盈留白 / 10=信息密集
- `art_direction`: 1=保守商业风格 / 10=大胆实验风格
- `spacing`: 1=紧凑 / 10=宽松留白
- `imagery_realism`: 1=扁平化插画 / 10=编辑级写实风格
- `text_density_in_image`: 1=极简文字 / 10=文案密集
**步骤4 — 使用`@google/design.md` lint验证:**
编写完DESIGN.md后,运行:npx @google/design.md lint <path-to-DESIGN.md>
将结果按优先级展示给用户:
- `error`: broken-ref(无法解析的令牌引用)——必须修复
- `warning`: missing-primary / contrast-ratio / orphaned-tokens / section-order——标记出来
- `info`: token-summary——展示给用户
若出现`broken-ref`错误,尝试一次自动修复(使用最接近的令牌解析缺失引用),然后重新lint。若仍有错误,将JSON结果展示给用户并寻求指导。
**步骤5 — 向用户报告:**
- 保存的DESIGN.md路径
- 质量总结:"通过{getdesign / Stitch / LLM-init}生成;lint结果:{N个错误,M个警告};自动推断字段:{列表}"
- 建议下一步操作:"运行`30x-image generate template=ad-creative brand=<name>`立即测试此DESIGN.md"
- 对于LLM初始化路径:明确告知用户"在确认此档案前,请审核自动推断字段(`taste:`块 + 第7节禁忌列表)——输入保真度越低,猜测成分越多"Mode 2: generate
— produce on-brand image (M0/M1 focus)
generate模式2:generate
— 生成符合品牌风格的图片(重点为M0/M1)
generateRead DESIGN.md + jobspec → assemble prompt with combinatorial axes + anti-slop
banned → invoke tool → save image + manifest.
image_generation读取DESIGN.md + 任务说明 → 结合组合轴 + 反违规规则组装提示词 → 调用工具 → 保存图片 + 清单文件。
image_generationWhen user invokes generate
generate用户调用generate
时的操作
generateInputs
输入
- DESIGN.md path: required. May be in cwd, in , or
examples/. Resolution priority:$HOME/.30x-image/profiles/<brand>/DESIGN.md- User-explicit path
- cwd
./DESIGN.md - → that profile's DESIGN.md
$HOME/.30x-image/active - Otherwise prompt user to choose
- Template: one of (carousel is multi-slide: see Step 4·B below). Resolution priority:
logo / ad-creative / slide / product-mockup / marketing-with-text / lighting-transform / scene-with-person / carousel- User explicitly names a template → use it directly.
- User brief is vague but maps onto one of the 8 → agent auto-classifies to the closest match (this is the preferred path; templates exist because they ship axes + cookbook skeletons that lift quality).
- Brief is genuinely outside all 8 templates (e.g. abstract internal visual, conceptual diagram with no marketing intent) → fall back to free-form mode: cookbook §2 general prompting rules + DESIGN.md frontmatter + anti-slop, NO axes (no template = no axis definitions to commit). Free-form is fallback only — never the default when a template fits.
- Jobspec: subject + copy.tagline + copy.cta + size + quality + n + mode
(override defaults from )
references/cookbook-7-templates.md
- DESIGN.md路径:必填。可位于当前工作目录、或
examples/。解析优先级:$HOME/.30x-image/profiles/<brand>/DESIGN.md- 用户明确指定的路径
- 当前工作目录的
./DESIGN.md - → 该档案的DESIGN.md
$HOME/.30x-image/active - 否则提示用户选择
- 模板:之一(carousel为多幻灯片:见下文步骤4·B)。 解析优先级:
logo / ad-creative / slide / product-mockup / marketing-with-text / lighting-transform / scene-with-person / carousel- 用户明确指定模板 → 直接使用
- 用户需求模糊但匹配8类模板之一 → Agent自动分类为最接近的模板(此为首选路径;模板自带轴 + 框架可提升质量)
- 需求确实不符合所有8类模板(例如抽象内部视觉图、无营销意图的概念图) → 退回到自由格式模式:采用指南§2通用提示规则 + DESIGN.md前置元数据 + 反违规规则,不使用轴(无模板=无轴定义)。自由格式仅作为 fallback,当模板匹配时绝不能作为默认选项。
- 任务说明:主题 + copy.tagline + copy.cta + 尺寸 + 质量 + n + 模式(覆盖中的默认值)
references/cookbook-7-templates.md
Procedure (do these in order)
操作流程(按顺序执行)
Step 1 — Load DESIGN.md.
Parse YAML frontmatter (token block + ). Read all 9 sections.
Pay special attention to:
taste:- (gives image atmosphere)
## 1. Visual Theme & Atmosphere - (every color name + hex + role)
## 2. Color Palette & Roles - (especially the typography table)
## 3. Typography Rules - → the Don't list is the brand's anti-slop banned
## 7. Do's and Don'ts - → if it has a
## 9. Agent Prompt Guidesection for the requested template, prefer that brand-specific cheat sheet over the generic### For: 30x-image generate <template>skeleton.references/cookbook-7-templates.md
Step 2 — Pick combinatorial axes.
Read for the requested template. Each axis
has 4-6 options. Pick exactly one per axis, biased by the block:
references/combinatorial-axes.mdtaste:- Higher → asymmetric / artistic options
variance - Higher → packed / dense options
density - Higher → photoreal / hard-light options
imagery_realism - Higher → bold / experimental options Commit the picks: write them into the prompt explicitly. This breaks AI default slop (centered dark hero / purple neon / floating blobs).
art_direction
Step 3 — Assemble final prompt.
[Template skeleton from cookbook-7-templates.md OR Section 9 brand cheat sheet]
VISUAL ATMOSPHERE:
[paraphrase Section 1 essence — 2-3 sentences]
PHOTOGRAPHY / ILLUSTRATION STYLE:
[derive from taste.imagery_realism + Section 1 prose]
COMPOSITION:
- Axis 1: [committed choice]
- Axis 2: [committed choice]
- Axis 3: [committed choice]
- Axis 4: [committed choice if template has 4]
PALETTE (use ONLY these tokens, do not fabricate new colors):
- Primary: {colors.primary} ({brand-color-name from Section 2})
- Surface: {colors.surface}
- Headlines: {colors.on-surface}
- Body: {colors.neutral}
- Accent: {colors.tertiary} (sparingly)
TYPOGRAPHY IN IMAGE:
- Display: {typography.headline-display.fontFamily} weight {fontWeight}
- Letter-spacing: {letterSpacing}
- Font features: {fontFeature if set}
SUBJECT / COPY (from jobspec):
- Subject: {jobspec.subject}
- Tagline: "{jobspec.copy.tagline}" (verbatim, in quotes)
- CTA: {jobspec.copy.cta if provided}
ANTI-SLOP CONSTRAINTS (always include — read references/anti-slop-rules.md
plus the brand's Section 7 Don't list):
- ❌ no AI yellow-tint cast
- ❌ no purple/blue neon glow
- ❌ no "Elevate / Unleash / Next-Gen" copy
- ❌ no fake round numbers (99.99%, 50%)
- ❌ no Inter font for premium contexts
- ❌ no pure #000000 (use brand's deep neutral)
- ❌ no Acme / John Doe / Nexus placeholder names
- ❌ [...add brand-specific rules from Section 7 Don't]Step 4 — Invoke tool.
Tool params (defaults from , override from
jobspec):
image_generationreferences/cookbook-7-templates.md- : e.g. 1024x1536 for ad-creative
size - : low for explore, high for final
quality - : 4 for explore, 1 for final
n - : "generate" for new, "edit" for iterate
action - : png
output_format
Step 4·B — Carousel multi-slide handling (template=carousel only).
Carousel is the only template that calls multiple times
in one job. Procedure:
image_generation- Assemble shared system prompt prefix once — brand design system (palette / typography / grid), pattern axis pick, continuity mechanism axis pick, tension curve pick (Axis 5). This prefix is identical across all slides.
- Plan slide roles AND narrative beats:
- Slide 1 = cover (use Cover Slide Style axis).
- Slides 2..(N-1) = body (use Body Slide Rhythm axis).
- Slide N = CTA.
- Apply tension curve (Axis 5) to assign each body slide a narrative
beat: e.g. for , body slides escalate stakes 2→N-1; for
Build-up, slides 2-3 withhold, slides 4..(N-1) reveal progressively; forReveal, slide 2=context, 3=challenge, 4-5=solution, N-1=result.Linear arc - If user supplied per-slide : respect their order; only overlay tension curve as visual emphasis (e.g. slide N-1 gets larger headline, more saturated color — the "payoff slide").
copy - If user only supplied and let agent write copy: agent MUST generate copy that satisfies the tension curve obligations. Sanity-check: does slide N-1 feel like the payoff? Does slide 1 hook toward it?
subject
- Fan out ALL slides in parallel as independent calls — same logic as every other template, just N calls instead of 1:
action=generate- Build per-slide prompt = shared design-system prefix + .
THIS SLIDE: slide N of n_slides, role: <cover|body-N|cta>, subject: <jobspec.slides[N].subject>, copy: "<verbatim>" - Every slide: ,
action=generate, quality at user's level (defaultn=1). Nohighchain. Reason: editing slide 1 repeatedly can trap gpt-image-2 in "webpage layout" mode and make slides look CSS-rendered rather than gpt-image-2-generated. Each slide must be a standalone generation, exactly like ad-creative or logo.action=edit - Cross-slide visual consistency comes from the shared prompt prefix (brand palette / typography / Visual Continuity Mechanism axis pick), NOT from image-reference chains. Trust the prefix.
- Fire all N calls in parallel — wall-clock = ~1 image_generation call.
- If a body slide drifts off-brand vs siblings, fix by reinforcing the shared prefix for that slide (more specific palette / typography directives), not by switching to action=edit.
- Build per-slide prompt = shared design-system prefix +
- Save each slide to (not
candidates/slide-{N}.png/1.png— slide-numbered for clarity).2.png - manifest.json records: ,
n_slides,pattern, full prompt per slide, hash of slide 1 (continuity reference).slide_roles[]
Step 5 — Save outputs.
Default location:
Files:
$HOME/.30x-image/profiles/<brand-slug>/marketing/<job-id>/- (each candidate)
candidates/{1..n}.png - (see structure below)
manifest.json
If profile dir does not exist (running from ), default to
in cwd.
examples/./marketing/<job-id>/Step 6 — Write manifest.json.
json
{
"job_id": "ISO-timestamp_short-slug",
"design_md_path": "...",
"design_md_hash": "sha256:...",
"template": "ad-creative",
"jobspec": { ... },
"axes_picks": {
"Hero Composition": "Asymmetric Split",
"Subject Framing": "Medium environmental",
"Lighting Mood": "Soft natural daylight",
"Text-Image Integration": "Tagline overlaid bottom-left"
},
"tool_params": { "size": "1024x1536", "quality": "high", "n": 4 },
"prompt_full": "...",
"outputs": [
{ "path": "candidates/1.png", "selected": false },
{ "path": "candidates/2.png", "selected": false },
...
],
"created_at": "..."
}Step 7 — Report to user.
Tell them:
- Where the candidates are
- Which axis picks were committed (transparency)
- Optional: suggest "select one and run again with action=edit, quality=high" for the final pass.
步骤1 — 加载DESIGN.md。
解析YAML前置元数据(令牌块 + )。读取所有9节内容。特别关注:
taste:- (提供图片氛围)
## 1. 视觉主题与氛围 - (每种颜色的名称 + 十六进制值 + 角色)
## 2. 配色方案与角色 - (尤其是排版表)
## 3. 排版规则 - 中的禁忌列表——品牌的反违规禁用规则
## 7. 注意事项 - ——如果包含针对请求模板的
## 9. Agent提示指南章节,优先使用此品牌专属指南而非通用的### For: 30x-image generate <template>框架。references/cookbook-7-templates.md
步骤2 — 选择组合轴。
读取中对应模板的内容。每个轴有4-6个选项。为每个轴选择恰好一个选项,基于块偏向:
references/combinatorial-axes.mdtaste:- 较高→ 不对称/艺术化选项
variance - 较高→ 密集/紧凑选项
density - 较高→ 写实/硬光选项
imagery_realism - 较高→ 大胆/实验性选项 确认选择:将选择明确写入提示词。这可避免AI的默认违规风格(居中深色主视觉/紫色霓虹/悬浮 blob)。
art_direction
步骤3 — 组装最终提示词。
[来自cookbook-7-templates.md的模板框架或第9节品牌指南]
视觉氛围:
[总结第1节核心内容——2-3句话]
摄影/插画风格:
[基于taste.imagery_realism + 第1节说明文字推导]
构图:
- 轴1:[确认的选择]
- 轴2:[确认的选择]
- 轴3:[确认的选择]
- 轴4:[若模板有4个轴则选择]
配色方案(仅使用以下令牌,不得编造新颜色):
- 主色:{colors.primary}(来自第2节的品牌颜色名称)
- 背景色:{colors.surface}
- 标题文字:{colors.on-surface}
- 正文文字:{colors.neutral}
- 强调色:{colors.tertiary}(谨慎使用)
图片中的排版:
- 标题字体:{typography.headline-display.fontFamily} 字重{fontWeight}
- 字间距:{letterSpacing}
- 字体特性:{若设置则为fontFeature}
主题/文案(来自任务说明):
- 主题:{jobspec.subject}
- 标语:"{jobspec.copy.tagline}"(严格原文,加引号)
- 行动号召:{若提供则为jobspec.copy.cta}
反违规约束(必须包含——读取references/anti-slop-rules.md + 品牌第7节禁忌列表):
- ❌ 无AI黄色色调
- ❌ 无紫色/蓝色霓虹光
- ❌ 无"Elevate / Unleash / Next-Gen"类文案
- ❌ 无虚假整数(99.99%, 50%)
- ❌ 高端场景不使用Inter字体
- ❌ 不使用纯#000000(使用品牌深中性色)
- ❌ 无Acme / John Doe / Nexus占位符名称
- ❌ [...添加第7节中的品牌专属规则]步骤4 — 调用工具。
工具参数(默认值来自,可通过任务说明覆盖):
image_generationreferences/cookbook-7-templates.md- : 例如ad-creative为1024x1536
size - : 探索用low,最终用high
quality - : 探索用4,最终用1
n - : 新生成用"generate",迭代用"edit"
action - : png
output_format
步骤4·B — 轮播图多幻灯片处理(仅template=carousel)。
轮播图是唯一需要在一个任务中多次调用的模板。操作流程:
image_generation- 组装一次共享系统提示词前缀——品牌设计系统(配色/排版/网格)、模式轴选择、视觉一致性机制轴选择、张力曲线选择(轴5)。此前缀在所有幻灯片中保持一致。
- 规划幻灯片角色与叙事节奏:
- 幻灯片1 = 封面(使用封面幻灯片风格轴)。
- 幻灯片2..(N-1) = 正文(使用正文幻灯片节奏轴)。
- 幻灯片N = 行动号召。
- 应用张力曲线(轴5)为每张正文幻灯片分配叙事节拍:例如节奏下,正文幻灯片2→N-1逐步提升关注度;
Build-up节奏下,幻灯片2-3保留悬念,幻灯片4..(N-1)逐步揭晓;Reveal节奏下,幻灯片2=背景介绍,3=挑战,4-5=解决方案,N-1=结果。Linear arc - 若用户提供每张幻灯片的:尊重用户顺序;仅通过视觉强调应用张力曲线(例如幻灯片N-1使用更大标题、更饱和颜色——即"高潮幻灯片")。
copy - 若用户仅提供并让Agent撰写文案:Agent必须生成符合张力曲线要求的文案。 sanity检查:幻灯片N-1是否有高潮感?幻灯片1是否能引导至高潮?
subject
- 将所有幻灯片并行作为独立调用——逻辑与其他模板相同,只是调用N次而非1次:
action=generate- 构建单张幻灯片提示词 = 共享设计系统前缀 + 。
本幻灯片:第N张(共n_slides张),角色:<封面|正文-N|行动号召>,主题:<jobspec.slides[N].subject>,文案:"<严格原文>" - 每张幻灯片:,
action=generate,质量为用户指定级别(默认n=1)。禁止使用high链式调用。原因:反复编辑幻灯片1可能导致gpt-image-2陷入"网页布局"模式,使幻灯片看起来像CSS渲染而非gpt-image-2生成。每张幻灯片必须独立生成,与ad-creative或logo完全相同。action=edit - 跨幻灯片视觉一致性来自共享提示词前缀(品牌配色/排版/视觉一致性机制轴选择),而非图片引用链。信任前缀即可。
- 并行发起所有N次调用——耗时≈1次image_generation调用。
- 若某张正文幻灯片与其他幻灯片品牌风格偏离,通过强化该幻灯片的共享前缀(更明确的配色/排版指令)修复,而非切换为action=edit。
- 构建单张幻灯片提示词 = 共享设计系统前缀 +
- 保存每张幻灯片至(不要用
candidates/slide-{N}.png/1.png——标注幻灯片编号更清晰)。2.png - manifest.json记录:、
n_slides、pattern、每张幻灯片的完整提示词、幻灯片1的哈希值(一致性参考)。slide_roles[]
步骤5 — 保存输出。
默认位置:
文件:
$HOME/.30x-image/profiles/<brand-slug>/marketing/<job-id>/- (每个候选图片)
candidates/{1..n}.png - (见下文结构)
manifest.json
若档案目录不存在(从运行),默认保存至当前工作目录的。
examples/./marketing/<job-id>/步骤6 — 编写manifest.json。
json
{
"job_id": "ISO时间戳_短标识",
"design_md_path": "...",
"design_md_hash": "sha256:...",
"template": "ad-creative",
"jobspec": { ... },
"axes_picks": {
"Hero Composition": "Asymmetric Split",
"Subject Framing": "Medium environmental",
"Lighting Mood": "Soft natural daylight",
"Text-Image Integration": "Tagline overlaid bottom-left"
},
"tool_params": { "size": "1024x1536", "quality": "high", "n": 4 },
"prompt_full": "...",
"outputs": [
{ "path": "candidates/1.png", "selected": false },
{ "path": "candidates/2.png", "selected": false },
...
],
"created_at": "..."
}步骤7 — 向用户报告。
告知用户:
- 候选图片的保存位置
- 确认选择的轴(保持透明)
- 可选建议:"选择一张图片,运行action=edit、quality=high进行最终优化"
Quality bars (M0 acceptance)
质量标准(M0验收)
A generated image is on-brand if:
- Primary color from frontmatter is visibly dominant (CTA / accent)
- Typography style matches (e.g., Stripe = light weight 300, NOT bold)
## 3. Typography Rules - No item from anti-slop banned list violated
- Mood / density / variance match the block
taste:
If hand-judging gives any "no" — iterate (re-pick axes / strengthen
constraints / explicit anti-slop in prompt).
生成的图片符合品牌风格需满足:
- 前置元数据中的主色在图片中明显占主导(行动号召/强调部分)
- 排版风格匹配(例如Stripe使用300字重,而非粗体)
## 3. 排版规则 - 未违反反违规禁用列表中的任何项
- 氛围/密度/对称性匹配块
taste:
若人工判断有任何一项不满足——迭代优化(重新选择轴/强化约束/在提示词中明确反违规规则)。
When you DON'T have enough
当信息不足时的处理
Refuse / clarify gracefully:
- DESIGN.md missing → 3-step fallback (try in order, tell the user which
one you're taking):
- — check if the brand is in the public awesome-design-md library (60+ brands: Stripe / Linear / Notion / Vercel / Apple / Tesla / Nike / Spotify / Starbucks / Apple / Coinbase / etc.). If yes →
npx getdesign list - — pulls a ready DESIGN.md to cwd in one command. Use it directly; optionally augment with a
npx getdesign add <brand>block (5-7 numeric brand parameters) for axis biasing.taste: - Brand not in library → run mode (M2) or hand-write a DESIGN.md using the 9-section format + frontmatter token block +
initblock (seetaste:as the canonical reference).examples/awesome-vendor/stripe/DESIGN.md
- Template name wrong → list 8 valid templates (incl. carousel)
- User brief doesn't match any template after honest attempt to classify → enter free-form fallback (NOT refuse). Tell user "no template matched, using free-form with brand DESIGN.md + anti-slop only" so they know determinism is reduced this run.
- Jobspec missing required fields (subject) → ask before invoking tool
- Brand is empty/weak → fall back to generic
## 7 Don'treferences/anti-slop-rules.md
礼貌拒绝/澄清:
- 缺少DESIGN.md → 三步fallback(按顺序尝试,告知用户当前采用的步骤):
- — 检查品牌是否在public awesome-design-md库中(60+品牌:Stripe / Linear / Notion / Vercel / Apple / Tesla / Nike / Spotify / Starbucks / Apple / Coinbase等)。若是→
npx getdesign list - — 一键提取现成DESIGN.md至当前工作目录。直接使用;可选添加
npx getdesign add <brand>块(5-7个数值型品牌参数)用于轴偏向。taste: - 品牌不在库中 → 运行模式(M2)或按照9节格式 + 前置元数据令牌块 +
init块手动编写DESIGN.md(参考taste:的标准格式)。examples/awesome-vendor/stripe/DESIGN.md
- 模板名称错误 → 列出8个有效模板(含carousel)
- 经合理尝试后用户需求仍不匹配任何模板 → 进入自由格式fallback(不要拒绝)。告知用户"无匹配模板,将使用品牌DESIGN.md + 反违规规则的自由格式生成",让用户知晓本次生成的确定性降低。
- 任务说明缺少必填字段(主题) → 调用工具前询问用户
- 品牌为空/薄弱 → 退回到通用
## 7 禁忌references/anti-slop-rules.md
Composition example — Stripe ad-creative
构图示例 — Stripe广告创意
DESIGN.md: examples/awesome-vendor/stripe/DESIGN.md
Template: ad-creative
Jobspec:
subject: "Q2 product launch — new fraud detection feature"
copy:
tagline: "Stop fraud before it starts."
cta: "Try it free"
size: 1024x1536
quality: high
n: 4
Axis picks (committed by 30x-image based on taste.variance=4, realism=7):
Hero Composition: Editorial Offset (variance=4 prefers low-mid)
Subject Framing: Medium environmental
Lighting Mood: Soft natural daylight (realism=7 sweet spot)
Text-Image Integration: Tagline overlaid bottom-left
→ image_generation tool invoked → 4 candidates saved
→ manifest.json records hash of DESIGN.md + axis picks + full promptDESIGN.md: examples/awesome-vendor/stripe/DESIGN.md
Template: ad-creative
任务说明:
subject: "Q2产品发布——全新欺诈检测功能"
copy:
tagline: "Stop fraud before it starts."
cta: "Try it free"
size: 1024x1536
quality: high
n: 4
轴选择(30x-image基于taste.variance=4, realism=7确认):
Hero Composition: Editorial Offset(variance=4偏好中低水平)
Subject Framing: Medium environmental
Lighting Mood: Soft natural daylight(realism=7的理想值)
Text-Image Integration: Tagline overlaid bottom-left
→ 调用image_generation工具 → 保存4张候选图片
→ manifest.json记录DESIGN.md哈希值 + 轴选择 + 完整提示词