generating-code-standards

A workflow for creating project engineering standards in CLAUDE.md, a file that gives an AI coding assistant repository-specific instructions. It selects guidance based on the project's technology, domain, team, data, and CI system.

In plain words
What is it for?
Use it when starting a project, onboarding a repository without CLAUDE.md, or setting up engineering rules for a particular stack and team.
Why use it?
It prevents a new or undocumented repository from relying on generic instructions. Tailored rules help the assistant follow the project's actual development and compliance needs.

Skill for Claude CodeCodex

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.

agentmods
npx agentmods add skills/brandonm/ai-code-standards/generating-code-standards
Any agent
npx skills add brandonm/ai-code-standards --skill generating-code-standards
Clone the repo
git clone --depth 1 https://github.com/brandonm/ai-code-standards

Made for: Claude Code, Codex.

Per session 70 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,641 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00070 $0.01641
Opus 5 $0.00035 $0.00821
Sonnet 5 $0.00014 $0.00328
Haiku 4.5 $0.00007 $0.00164

Measured 2d ago against content hash 1bec7983771e, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

generating-code-standards 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 2d 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/generating-code-standards/SKILL.md · 158 lines

How it starts

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

Generating Project Standards

Generate tailored CLAUDE.md files by composing modular fragments based on project inputs (stack, domain, team size, regulated data, CI system).

When to Use

  • Starting a new project that needs a CLAUDE.md
  • Onboarding an existing repo that lacks engineering standards
  • User explicitly asks to generate or create project standards
  • Replacing a generic/copy-pasted CLAUDE.md with a tailored one

Do NOT use when:

  • User wants to edit a single rule in an existing CLAUDE.md (just edit it directly)
  • Auditing compliance against existing standards (use audit-standards instead)
  • Updating standards to match a newer template version (use upgrade-standards instead)

Workflow

digraph workflow {
    rankdir=TB;
    gather [label="1. Gather inputs\n(questionnaire.md)" shape=box];
    detect [label="2. Auto-detect what you can\n(package.json, build.gradle, etc.)" shape=box];
    confirm [label="3. Confirm inputs with user" shape=diamond];
    select [label="4. Select fragments" shape=box];
    assemble [label="5. Assemble CLAUDE.md\nfrom template + fragments" shape=box];
    existing [label="Existing CLAUDE.md?" shape=diamond];
    merge [label="6a. Diff/merge\n(preserve user additions)" shape=box];
    write [label="6b. Write new file" shape=box];
    review [label="7. Show output for review" shape=box];

    gather -> detect -> confirm;
    confirm -> gather [label="missing info"];
    confirm -> select [label="complete"];
    select -> assemble -> existing;
    existing -> merge [label="yes"];
    existing -> write [label="no"];
    merge -> review;
    write -> review;
}

Step 1: Gather Inputs

Read questionnaire.md and ask the user each question. Auto-detect answers where possible (Step 2) and present them for confirmation.

Step 2: Auto-Detect

Before asking, try to infer:

Signal Look for
Language + build tool package.json, build.gradle, pom.xml, go.mod, Cargo.toml, pyproject.toml, requirements.txt, Gemfile
Framework Dependencies in manifest files
CI system .github/workflows/, .gitlab-ci.yml, Jenkinsfile, .circleci/, bitbucket-pipelines.yml, .woodpecker/, .woodpecker.yml
Project type Directory structure, entry points
Existing conventions .editorconfig, .eslintrc, .prettierrc, linter configs

Read the full file on GitHub · 158 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. 2d ago First seen · 158 lines · 70 tokens per session scan A 1bec7983771e

Subscribe to this mod's changes

generating-code-standards is a skill published in the GitHub repository brandonm/ai-code-standards (2 stars, last pushed 3mo ago), licensed MIT. It adds 70 tokens to every session and 1,641 once invoked, about $0.0003 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

ring:adopting-lib-commons-huma-wrapper

Adopting the lib-commons/v5 shared Huma (OAS 3.1) OpenAPI wrapper + RFC 9457 problem model (commons/net/http/{openapi,problem}) in a Lerian Go service: wire openapi.New/ServeSpec + problem.Install (central >=500 scrub) on BOTH runtime and spec-gen paths, the per-rail problem.MapError flex seam, and rename-only spec…

LerianStudio/ring · 142 tokens

ring:applying-composition-patterns

React composition patterns that scale. Avoid boolean prop proliferation by using compound components, lifting state, and composing internals. Use when refactoring components with boolean prop proliferation, building flexible component libraries, or during architecture review. Skip for simple components with 1-2 props…

LerianStudio/ring · 68 tokens

ring:searching-code

Forensic code search and analysis with optional Chain of Draft (CoD) ultra-concise mode. Five-phase methodology (clarification, planning, execution, analysis, synthesis) with severity assessment. Use for targeted investigation of specific patterns, bugs, or vulnerabilities. Skip for broad architecture mapping (use…

LerianStudio/ring · 74 tokens

ring:exploring-codebases

Exploring a codebase across phases: scopes the target, detects architecture, components, and layers, deep-dives each discovered perspective, then synthesizes findings into actionable guidance with file:line evidence. Use to understand how a feature or system works before planning changes, or to orient on an unfamiliar…

LerianStudio/ring · 91 tokens

ring:opening-pull-requests

Open a GitHub Pull Request with automatic base branch detection, scope allowlist enforcement, PR template filling, and post-create base verification. Replaces ring:generating-pr-descriptions. Use after pushing a branch when ready to open a PR. Skip if the branch is not yet pushed or there are uncommitted changes …

LerianStudio/ring · 83 tokens

ring:cleaning-comments

Cleaning redundant and obvious comments following clean code principles while preserving meaningful documentation. Supports git scope filtering (staged, unstaged, branch, commit-range). Use when code has excessive comments, during code review, or post-refactor cleanup. Skip when reviewing documentation files or…

LerianStudio/ring · 64 tokens