brand-gen-phase-contract-audit

brand-gen-phase-contract-audit is a skill for Claude Code, Codex from velinussage/brand-gen. It costs 180 tokens per session (1,953 once invoked), scanned A, original, MIT.

An audit workflow for checking the contracts between phases of the brand-generation pipeline. It compares the fields each phase expects with the fields defined by the pipeline’s typed data structures.

In plain words
What is it for?
Use it to review the route, plan, validation, execution, review, and evolution phases. It helps locate unsafe field access, missing handoffs, and places where tests may hide contract errors.
Why use it?
A pipeline can silently lose data when phases pass loosely shaped objects or ignore unknown fields. This audit finds mismatched and phantom fields before they cause incorrect results.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to review the route, plan, validation, execution, review, and evolution phases. It helps locate unsafe field access, missing handoffs, and places where tests may hide contract errors.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/velinussage/brand-gen/brand-gen-phase-contract-audit
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add velinussage/brand-gen --skill brand-gen-phase-contract-audit
Clone the repo
git clone --depth 1 https://github.com/velinussage/brand-gen

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for brand-gen-phase-contract-audit

README.md
[![agentmods](https://agentmods.dev/badge/skills/velinussage/brand-gen/brand-gen-phase-contract-audit/github.svg)](https://agentmods.dev/skills/velinussage/brand-gen/brand-gen-phase-contract-audit)
Your own site
<a href="https://agentmods.dev/skills/velinussage/brand-gen/brand-gen-phase-contract-audit"><img src="https://agentmods.dev/badge/skills/velinussage/brand-gen/brand-gen-phase-contract-audit/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for brand-gen-phase-contract-audit

Your own site · 80×15
<a href="https://agentmods.dev/skills/velinussage/brand-gen/brand-gen-phase-contract-audit"><img src="https://agentmods.dev/badge/skills/velinussage/brand-gen/brand-gen-phase-contract-audit.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 180 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,953 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00180 $0.01953
Opus 5 $0.00090 $0.00977
Sonnet 5 $0.00036 $0.00391
Haiku 4.5 $0.00018 $0.00195

Measured 11d ago against content hash cea04ca57f73, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

brand-gen-phase-contract-audit scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 11d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/brand-gen-phase-contract-audit/SKILL.md · 145 lines

How it starts

The opening of the file, as written. The whole thing — 145 lines — stays where its author put it; the contents beside it link to each section on GitHub.

For Sage brand work in Pi, use the paste-ready prompt at docs/prompts/pi-sage-brand-gen-full-pipeline.md. Keep this link instead of copying the full prompt into skill bodies.

Brand-Gen Phase Contract Audit

Risk addressed: the in-process contract between pipeline phases is argparse.Namespace. There are 426 getattr(args, ...) call sites across 16 modules. PipelineRequest.build_scratchpad_namespace (pipeline_request.py:332) hand-builds a Namespace with ~30 fields just to pass typed data between in-process stages. getattr(args, "field", None) swallows typos, so renames silently zero out values. New fields require parallel updates in PIPELINE_MCP_PROPERTIES, PipelineRequest, from_mapping, build_scratchpad_namespace, the CLI builder, and per-phase getattr calls. Tests pass argparse.Namespace() so phantom fields slip through.

PlanDraft and GenerationScratchpad dataclasses exist but _run_scratchpad operates on the dict payload and converts at the end via scratchpad_from_dict. The _filter_fields helper (pipeline_types.py:386) silently drops unknown keys.

What this skill produces

{
  "summary": {
    "total_getattr_sites": 426,
    "phantom_fields": 17,
    "phases_with_drift": 4,
    "fields_declared_but_unused": 8,
    "namespace_fields_total": 73,
    "typed_request_fields_total": 41
  },
  "phases": [
    {
      "phase": "route",
      "consumed_fields": ["route_brief", "material_type", "render_backend", ...],
      "declared_in": ["PipelineRequest"],
      "phantom_in_phase": [],
      "untyped_via_namespace_only": ["route_force"]
    },
    {
      "phase": "plan",
      "consumed_fields": [...],
      "declared_in": ["MaterialPlan", "PipelineRequest"],
      "phantom_in_phase": ["legacy_inspiration_seed"],
      "untyped_via_namespace_only": ["accept_inspiration_recommendations"]
    }
    /* ... per-phase ... */
  ],
  "phantom_fields_detail": [
    {
      "field": "legacy_inspiration_seed",
      "read_at": ["plan_builder.py:412"],
      "never_written_at": "no PipelineRequest entry, no Namespace builder line",
      "default_returned": "None",
      "blast_radius": "silent — production has never set this; renames break nothing but the field is dead"
    }
  ],
  "filter_fields_drift": [
    {
      "field": "branch_id",
      "declared_in": "MaterialPlan, GenerationScratchpad",
      "missing_from": "scratchpad_from_dict input shape",
      "behavior": "silently dropped at deserialization"
    }
  ],
  "duplicate_field_routing": [
    {
      "field": "design_variance",
      "paths": ["PipelineRequest.design_variance", "Namespace.design_variance", "scratchpad payload.design_variance"],
      "consistency": "ok"
    }
  ]
}

Read the full file on GitHub · 145 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 11d ago First seen · 145 lines · 180 tokens per session scan A cea04ca57f73

Subscribe to this mod's changes

brand-gen-phase-contract-audit is a skill published in the GitHub repository velinussage/brand-gen (0 stars, last pushed 3mo ago), licensed MIT. It adds 180 tokens to every session and 1,953 once invoked, about $0.0009 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

debug-optimize-lcp

Guides debugging and optimizing Largest Contentful Paint (LCP) using Chrome DevTools MCP tools. Use this skill whenever the user asks about LCP performance, slow page loads, Core Web Vitals optimization, or wants to understand why their page's main content takes too long to appear. Also use when the user mentions…

ChromeDevTools/chrome-devtools-mcp · 99 tokens

systematic-debugging

Use when debugging a failing test, build error, or runtime issue that isn't immediately obvious. Guides a 4-phase root cause analysis instead of random fix attempts.

open-metadata/OpenMetadata · 37 tokens

diagnose

Trace from a reproduced symptom to the source code that causes it. Pin the specific file and approximate line, rate confidence in the cause and clarity of the fix independently, and always propose a concrete fix.

emdash-cms/emdash · 43 tokens

repro-admin

Reproduce an EmDash admin UI bug. Attach a container, start the demo dev server, drive the admin with agent-browser using the dev-bypass session, and capture the reproduction as screenshots plus a replayable transcript.

emdash-cms/emdash · 48 tokens

log-error-digest

Analyze log files to troubleshoot errors, identify peak error periods, and produce error clustering, frequency statistics, and time distribution reports. Supports JSON, syslog, and Nginx formats with automatic detection. Use when a user uploads a .log file and asks to analyze errors, find patterns, debug issues, or…

zebbern/claude-code-guide · 71 tokens

byted-util-volcengine-detect-retry

An orchestration workflow for Volcengine Cloud Detect, a service that checks websites or network endpoints from test locations.

bytedance/agentkit-samples · 101 tokens