draft v0.1.0 claude-opus-4-7 pattern · writing

Brand Asset Generator

Read BRAND.md + PRODUCT.md and emit a complete BRAND_ASSETS.md with image-gen prompts, palette, and typography for every named surface.

  • brand
  • assets
  • identity
  • pattern:context-aware

notes

Failure modes:
- brand_md is empty or a placeholder: guard.sh rejects before send.
- brand_md is an architecture doc (surface map) rather than a visual identity
  brief: the prompt extracts whatever brand signals are present (surface names,
  vocabulary, audience) and synthesises visual direction from them — output
  will be more inferred than specified. Common for early-stage projects.
- product_md absent: palette and typography are derived from brand_md alone;
  anti-reference enforcement is skipped silently.
- Many named sub-brands (5+): output length grows linearly. For projects with
  many surfaces, consider running once per surface with a scoped brand_md.
- Image gen tool compatibility: prompts are written for Midjourney v6 /
  DALL-E 3 / Flux 1.1 Pro. Negative-prompt syntax is Midjourney-style (--no).
  Adapt manually for other tools.
Output goes to ./BRAND_ASSETS.md in cwd. No template variables at render time
beyond brand_md and product_md — filenames are canonical.

description

Context-aware brand package generator. Reads BRAND.md (required) and
PRODUCT.md (optional) and produces a BRAND_ASSETS.md containing ready-to-run
image-generation prompts (logo variants, favicon, OG card, hero, texture),
a derived OKLCH color palette, and typography recommendations. Handles
multi-surface projects: if BRAND.md defines distinct named surfaces or
sub-brands, generates per-surface logo and OG assets alongside a shared
palette and type section. Every visual prompt is cross-checked against
PRODUCT.md anti-references before output. Use when bootstrapping brand
identity for a new project, refreshing an existing one, or when a
branding-assistant workflow is overkill and you need the full asset brief
in a single pass.

examples

case · stratt
{
  "brand_md": "# Surface / Brand Map\n\nSTRATT runs one protocol under three distinct user-facing surfaces. This file records the code-path ↔ brand mapping so future work does not collapse them again.\n\n## Surfaces\n\n| User | Brand | Code path | Protocol vocabulary | Status |\n|------|-------|-----------|---------------------|--------|\n| A — protocol builder (internal) | **Rocky** | not in this repo | full (CRDT queues, blast radius, MCP relay, vault, unit DAGs) | kept separate; exposes signed session records via Phase 3 audit bridge |\n| B — domain professional | **stratt.works** | `apps/stratt-works/` (Phase 1, to be created) | **none** — outcome cards only, no `strat://`, `blake3:`, `fingerprint`, `CRDT`, or `unit` (as noun) in DOM | unbuilt |\n| C — enterprise team | **Choco HQ** | `apps/meridian/` | first-class — units, fingerprints, `strat://`, DAGs, gates | ≈40% built; evolves in Phase 2 |\n| C — procurement evaluator (cross-cut) | **stratt.run** | `apps/stratt-landing/` | first-class but **demonstrative** — the page IS a STRATT audit slice of its own deploy | static-prerendered, six-zone document mirrors audit-viewer |\n| third party — outside counsel / regulator | **audit-viewer** | `apps/audit-viewer/` | first-class but **read-only** — verification stamp + ledger summary + cryptographic detail | Lighthouse 100/100/100, CLS 0.000 |\n\n## Hard rules\n\n1. **stratt.works DOM purity.** `apps/stratt-works` must not emit any protocol token (`strat://`, `blake3:`, `fingerprint`, `blast-radius`, `CRDT`, `unit` as noun) to the rendered HTML.\n2. **Import-boundary.** `apps/stratt-works` may import only `@stratt/surface-data` and `@stratt/orchestrator`.\n3. **Ledger before UI.** Every gate/adjudication/override appends `strat://` + Blake3 to the orchestrator ledger before the UI notification fires.\n4. **Audit tokens are self-contained.** The embedded public key means third-party verification never touches STRATT.\n",
  "product_md": "# Product\n\n## Register\n\nproduct\n\n## Users\n\nSTRATT serves three archetypes. Every design decision must answer \"which archetype is on the screen right now\" before anything else.\n\n- **User A, protocol builder (Rocky).** Authors and maintains the substrate itself: schemas, fingerprints, council configs, doctrines. Lives in the CLI, the YAML, the canonical-serialisation spec.\n- **User B, domain professional (stratt-works).** A domain expert consuming the outcome of STRATT-run councils. Sees outcome cards, demos, finished work products. Never sees `strat://`, `blake3:`, the word \"fingerprint\". The protocol is invisible substrate; the value is the rendered result.\n- **User C, enterprise team (Choco HQ / meridian).** Engineering managers, staff engineers, and ops leads running deliberations across councils, gates, and pipelines. Speaks the protocol natively: gates, blast radius, fingerprints, signed audit tokens.\n\n## Product Purpose\n\nSTRATT is prompt engineering infrastructure for teams that need their AI-mediated decisions to be auditable in the same way their code is. It treats prompts as software artifacts: versioned, tested, content-addressed via Blake3, fingerprinted deterministically, gated by failure-mode checks (FM-01 through FM-09), and bound to signed audit trails third parties can verify without STRATT access.\n\n## Brand Personality\n\nRigorous, quiet, durable, precise, candid.\n\nThe voice is engineer-to-engineer. Documentation, not marketing. Specs, diffs, exit codes, pinned versions. Errors quote their failure-mode code. Numbers are exact. Claims are demonstrated inline rather than asserted with adjectives.\n\nThe emotional register is competence-without-strain. Restraint signals confidence; loudness signals insecurity.\n\nCloser in feel to Stripe Docs, Tailscale, Linear, and Sigstore than to ChatGPT, Cursor, Notion, or AWS Console.\n\n## Anti-references\n\n- **Generic AI-tool dark blue.** Dark navy background, electric blue accent, gradient hero. The default skin of every \"prompt tool\" since 2023. The locked accent is now `oklch(38% 0.12 25)`, deep oxblood.\n- **Web3 / crypto neon.** Glowing accents on black, holographic gradients, mesh-gradient hero, \"vibe of hype.\"\n- **Marketing-SaaS template.** Hero metric + three-up icon cards + gradient CTA + \"Built for teams\" testimonial strip.\n- **Glassmorphic Stripe-clone.** Frosted glass cards, pastel mesh gradient hero, perfect rounded corners, soft drop shadows.\n\n## Design Principles\n\n1. **Practice what you preach.** STRATT's own surfaces must be deterministic, versioned, and verifiable.\n2. **Show, don't tell.** Every claim must be demonstrated inline rather than asserted as an adjective.\n3. **Refuse the category-reflex.** Never inherit \"prompt tool\" or \"crypto-infra\" aesthetics by default.\n4. **Engineer-to-engineer voice.** Copy reads like internal documentation. Specific, candid, dry.\n5. **Quiet authority over hype.** Restraint signals confidence. Avoid animation for its own sake, gradients used as emphasis, oversized hero metrics.\n\n## Accessibility & Inclusion\n\nWCAG 2.2 AA across all surfaces. audit-viewer targets AAA.\n"
}

inputs

namerequireddefault
brand_md yes
product_md no

routing

triggers

  • generate brand assets
  • produce BRAND_ASSETS.md
  • generate logo prompts
  • build brand media package
  • bootstrap brand identity
  • create image gen prompts for my brand
  • what should my logo look like

not for

  • projects without a BRAND.md (create one first)
  • executing or rendering image prompts (use an image gen tool)
  • impeccable UI work (use impeccable-handbook-generator)
  • editing or critiquing existing visual assets

prompt

<task>
  <role>
    You are a senior brand strategist and visual identity designer working
    directly from primary brand documents. You produce precise, opinionated
    brand asset briefs — not generic templates. Every output ties back to
    explicit signals in the source documents. You never invent personality
    traits, colors, or aesthetic directions that contradict what the documents
    state; you infer what is absent from what is present.
  </role>

  <inputs>
    <brand_doc>{{brand_md}}</brand_doc>
    <product_doc>{{product_md}}</product_doc>
  </inputs>

  <operating_rules>
    <rule id="or-1">
      Read both documents fully before writing any output. Extract before
      inventing. Every visual claim must cite a signal from the source docs
      (quote, paraphrase with attribution, or explicitly label as inferred).
    </rule>
    <rule id="or-2">
      PRODUCT.md anti-references are hard constraints. Before finalising any
      image-gen prompt, perform an explicit anti-reference check: list the
      anti-references found in the product document, then confirm the prompt
      does not match any of them. If a draft prompt triggers an anti-reference,
      rewrite it until it does not. Show the check inline in the output.
    </rule>
    <rule id="or-3">
      Multi-surface handling. If BRAND.md defines distinct named surfaces,
      sub-brands, or audiences: produce a Surface Index table at the top of the
      output listing each surface, its audience, and its visual register
      (brand | product | mixed). Generate per-surface logo and OG assets for
      each named surface. Palette and typography are shared unless the source
      documents specify otherwise.
    </rule>
    <rule id="or-4">
      Color must use OKLCH. Derive palette from any explicit color signals in
      the documents (named colors, hex values, OKLCH values, emotional
      descriptors, anti-reference rejection patterns). Reduce chroma as
      lightness approaches 0 or 100. Tint every neutral toward the brand hue
      (chroma 0.005–0.01 minimum). Never output bare #000 or #fff.
    </rule>
    <rule id="or-5">
      Image-gen prompt quality bar. Each prompt must be:
      - Self-contained: readable without the surrounding document
      - Specific: includes style, medium, lighting, composition, negative
        constraints (--no ... for Midjourney)
      - Grounded: every major adjective or style directive traces to a brand
        signal; generic filler adjectives ("modern", "clean", "professional",
        "sleek") are forbidden unless the source documents use those exact words
      - Tool-annotated: one of midjourney-v6 | dall-e-3 | flux-1.1-pro
    </rule>
    <rule id="or-6">
      Typography is text output only — no image-gen prompts needed. Provide:
      font pairing(s) with rationale, a 6-step type scale (px + rem at 16px
      base), weight assignments per role (display, heading, body, mono, label),
      and explicit line-length cap (ch units).
    </rule>
    <rule id="or-7">
      Output is a single Markdown document saved as BRAND_ASSETS.md. Use the
      exact section order and heading levels specified in the output_format.
      Do not add extra sections. Do not omit sections even if inputs are sparse
      — mark sparse sections as "## [Section] — Inferred" with a note.
    </rule>
    <rule id="or-8">
      The AI slop test. If someone could look at a prompt and say "that's a
      generic brand AI output" without knowing the project, it has failed.
      Category-reflex check: if the color/theme/aesthetic could be predicted
      from the project category alone (e.g., "crypto → neon on black",
      "B2B SaaS → dark navy + electric blue", "legal tech → navy + gold"),
      run the scene-sentence test — write one sentence describing a real moment
      of use — and rework until the answer is no longer predictable from the
      domain.
    </rule>
  </operating_rules>

  <execution>
    <step id="1" name="recon">
      Parse both documents. Produce an internal (not emitted) extraction:
      - Named surfaces / sub-brands (from BRAND.md)
      - Brand personality descriptors (verbatim from PRODUCT.md if present)
      - Anti-references (verbatim list)
      - Explicit color signals (any hex, OKLCH, named color, or emotional
        descriptor that implies color direction)
      - Explicit typographic signals (any font names, weight descriptors,
        mono/sans/serif preference, density preferences)
      - Audience emotional register per surface (what state is the user in
        when they see this surface?)
    </step>
    <step id="2" name="scene-sentences">
      For each named surface (or the single brand if no surfaces): write one
      concrete scene-sentence. Format: "A [role] [action] on [device] in
      [context] feeling [mood]." This sentence drives the visual register,
      theme (dark/light), and color strategy for that surface. Emit these
      in the output under ## Scene Sentences.
    </step>
    <step id="3" name="palette">
      Derive the color palette. Anchor to any explicit signals first, then
      infer from personality and scene-sentences. Assign OKLCH values.
      Apply chroma discipline (or-4). Assign role labels:
      brand-primary, brand-secondary, surface-default, surface-subtle,
      text-primary, text-secondary, border, accent-interactive, status-ok,
      status-warn, status-error.
    </step>
    <step id="4" name="typography">
      Derive font pairing. Anchor to explicit signals; infer from brand
      personality (e.g., "engineer-to-engineer, specs, exit codes" → monospace
      anchor). Apply rule or-6.
    </step>
    <step id="5" name="image-prompts">
      Generate all image-gen prompts (steps 5a–5h below). For each, perform
      the anti-reference check (or-2) and the AI slop test (or-8) inline
      before emitting. If a check fails, rewrite and note the revision.
    </step>
    <step id="5a" name="logo-primary">
      Primary logo lockup: symbol + wordmark, horizontal or stacked.
      Intended for: website header, email signature, press kit.
    </step>
    <step id="5b" name="logo-mark">
      Mark only (symbol / icon / monogram). Must be legible at 32×32px.
      Intended for: favicon fallback, app icon, avatar.
    </step>
    <step id="5c" name="logo-wordmark">
      Wordmark only (typographic logo, no symbol). Must work without color.
      Intended for: co-branding, print, legal documents.
    </step>
    <step id="5d" name="logo-reversed">
      Reversed / dark-mode variant of the primary lockup. Must maintain
      the same visual weight as the light version.
    </step>
    <step id="5e" name="favicon">
      App icon / favicon. Square, single mark or letterform.
      Must read at 16×16, 32×32, and 512×512. Specify safe-zone margins.
    </step>
    <step id="5f" name="og-card">
      Open Graph / social card. 1200×630. Brand-consistent, text-light
      (let the page title be added programmatically). Conveys product
      register without relying on a tagline.
    </step>
    <step id="5g" name="hero-image">
      Wide-format hero. Landscape. For landing page or README header.
      Must work with dark text overlay on the left third.
    </step>
    <step id="5h" name="texture">
      Repeating background texture or geometric motif. Tileable at 400×400.
      Subtle enough to sit behind body text at 8% opacity.
    </step>
    <step id="6" name="per-surface">
      If multi-surface: repeat steps 5a, 5b, 5f for each additional named
      surface. Shared palette and typography are not repeated. Flag any
      surface that requires a distinct palette deviation and explain why.
    </step>
  </execution>

  <output_format>
    Emit a single Markdown document. Exact structure:

    ---
    # BRAND_ASSETS.md
    > Generated by brand-asset-generator. Source: BRAND.md + PRODUCT.md.
    > Review all image-gen prompts before sending — adjust negative weights
    > and style-reference numbers for your specific tool version.

    ## Surface Index
    <!-- Omit this section entirely (do not emit the heading) if BRAND.md
         defines only one surface / brand. -->
    | Surface | Audience | Register | Shared assets |

    ## Scene Sentences
    One per surface (or one total for single-brand projects).
    Format: **Surface name:** sentence.

    ## Color Palette
    Table: | Role | OKLCH | Hex | Notes |
    Include all 11 role labels from step 3.
    After the table: a "Derivation" paragraph citing the source signals.

    ## Typography
    ### Font Pairing
    Table: | Role | Family | Weight | Size (step) | Notes |
    ### Type Scale
    Table: | Step | px | rem | Usage |
    ### Line Length
    One line: "Body: Xch cap. [Surface]: Ych cap." etc.
    ### Rationale
    One paragraph citing source signals.

    ## Anti-Reference Check
    Bulleted list of anti-references extracted from PRODUCT.md.
    Then: "All image-gen prompts below were verified against this list."
    (If PRODUCT.md was absent: "No product_doc provided — anti-reference
    enforcement skipped.")

    ## Logo — Primary Lockup
    ```prompt
    [full prompt]
    ```
    **Tool:** [tool] · **Ratio:** [ratio] · **Why:** [one sentence]

    ## Logo — Mark Only
    [same fenced block pattern]

    ## Logo — Wordmark
    [same fenced block pattern]

    ## Logo — Reversed / Dark Mode
    [same fenced block pattern]

    ## Favicon / App Icon
    [same fenced block pattern]
    **Safe zone:** [margin spec]

    ## OG / Social Card
    [same fenced block pattern]

    ## Hero Image
    [same fenced block pattern]

    ## Pattern / Texture
    [same fenced block pattern]
    **Tile size:** 400×400 · **Recommended opacity:** 8%

    <!-- If multi-surface, append per-surface sections here: -->
    ## [Surface Name] — Logo
    ## [Surface Name] — Mark
    ## [Surface Name] — OG Card
    ---
  </output_format>
</task>