generate-AGENTS-file

generate-AGENTS-file is a command for Claude Code from TechNickAI/ai-coding-config. It costs 24 tokens per session (2,342 once invoked), scanned A, original, MIT.

A project-context command that creates or updates AGENTS.md, a file describing project-specific facts and constraints for AI coding assistants such as Claude Code, Cursor, and Copilot.

In plain words
What is it for?
Use it to record important project context and always-applied rules without duplicating ordinary commands, generic advice, or information already clear from the code.
Why use it?
It prevents assistants from repeating mistakes caused by missing domain knowledge, architectural decisions, or rules that are not obvious from the code. References keep detailed rules in their original files.

Command for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: model in frontmatter; names the AskUserQuestion tool; mentions Claude Code.

Part of the ai-coding-config plugin — 15 skills, 21 commands, 28 agents, 3 hooks shipped together

Good fit Use it to record important project context and always-applied rules without duplicating ordinary commands, generic advice, or information already clear from the code.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/technickai/ai-coding-config/generate-agents-file
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.

Clone the repo
git clone --depth 1 https://github.com/TechNickAI/ai-coding-config

Made for: Claude Code.

Or install ai-coding-config, the plugin that ships this one along with the rest of its 15 skills, 21 commands, 28 agents, 3 hooks.

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 generate-AGENTS-file

README.md
[![agentmods](https://agentmods.dev/badge/commands/technickai/ai-coding-config/generate-agents-file/github.svg)](https://agentmods.dev/commands/technickai/ai-coding-config/generate-agents-file)
Your own site
<a href="https://agentmods.dev/commands/technickai/ai-coding-config/generate-agents-file"><img src="https://agentmods.dev/badge/commands/technickai/ai-coding-config/generate-agents-file/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 generate-AGENTS-file

Your own site · 80×15
<a href="https://agentmods.dev/commands/technickai/ai-coding-config/generate-agents-file"><img src="https://agentmods.dev/badge/commands/technickai/ai-coding-config/generate-agents-file.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 24 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 2,342 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.00024 $0.02342
Opus 5.5 $0.00010 $0.00937
Sonnet 5.5 $0.00005 $0.00468
Haiku 4.5 $0.00002 $0.00234

Measured 25d ago against content hash abcddb90d593, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

generate-AGENTS-file 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 25d 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.

plugins/core/commands/generate-AGENTS-file.md · 307 lines

How it starts

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

Generate AGENTS.md

Creates or updates AGENTS.md - a universal project context file for AI coding assistants (Claude Code, Cursor, GitHub Copilot, etc.).

Purpose: Prevent mistakes by providing context the AI would otherwise lack.

What belongs in AGENTS.md:

  • Domain knowledge that isn't obvious from code structure
  • Constraints that cause silent failures if violated
  • Architectural decisions that affect how code should be written
  • References to detailed rules via @ imports

What does NOT belong:

  • Commands (LLMs know how to run pnpm, npm, pytest, etc.)
  • Generic best practices (LLMs already know these)
  • Project descriptions (that's what README is for)
  • Anything an LLM would figure out from reading the code

The test: "Would an AI make a mistake without this specific piece of context?" If no, cut it.

Add an "Always Apply Rules" section at the top with @ references:

## Always Apply Rules

Core project rules that apply to all tasks:

@rules/git-interaction.mdc @rules/typescript-coding-standards.mdc

Why use @ references instead of extraction:

  • AI coding assistants load the full rule when they see @path/to/rule.mdc
  • Ensures rules stay up-to-date without AGENTS.md edits
  • No token overhead from duplicating rule content
  • Single source of truth for all conventions

When to still extract (rare):

  • Only if a rule has a specific command or constraint worth highlighting elsewhere
  • Don't duplicate - reference in "Always Apply Rules" section instead

From README.md:

  • Project tech stack and versions (be specific: "Next.js 14" not just "Next.js")
  • Key commands (dev, build, test)
  • Skip: Project description, installation steps for end users, contributing guides

From .claude/context.md (if exists):

  • Identity or personality instructions (if project uses custom personality)
  • Any project-specific AI behavior guidelines

From recent git commits (last 10):

  • Observe commit message style and conventions
  • Identify patterns (emoji usage, conventional commits, etc.)
# Project Context for AI Assistants

## Always Apply Rules

Core project rules that apply to all tasks:

[@ references to your alwaysApply: true rules]

## Project Overview

Brief description of what this project is.

## Tech Stack

- Framework/language with specific versions
- Key dependencies that affect how code should be written
- Build tools and their commands

## Project Structure

- `dir/` - Brief purpose (only if non-obvious)
- Focus on where AI should look for specific types of files

## Code Conventions

DO:

- Specific patterns to follow
- Required practices unique to this project
- Non-obvious constraints that prevent mistakes

DON'T:

- Specific anti-patterns to avoid
- Project-specific constraints
- Explicitly forbidden practices (like --no-verify if that's a rule)

## Git Workflow

- Commit message format (if specific convention exists)
- Important: Include critical git constraints from always-apply rules
- Skip generic emoji lists - one example is enough
- Skip restating the full commit format if it's standard

## Important Notes

- Non-obvious gotchas or warnings
- Critical context that prevents mistakes
- Dependencies between systems
- Unique aspects of this project that AI must understand

Read the full file on GitHub · 307 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. 25d ago First seen · 307 lines · 24 tokens per session scan A abcddb90d593

Subscribe to this mod's changes

generate-AGENTS-file is a command published in the GitHub repository TechNickAI/ai-coding-config (24 stars, last pushed 26d ago), licensed MIT. It adds 24 tokens to every session and 2,342 once invoked, about $0.0001 per session on Opus 5.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-09-22.