agents-md-generator
Skill106 starsChanged 7 months agoMITView on GitHub
Create, generate, update, repair, trim, or split minimal AGENTS.md files for repository roots and confirmed nested modules using progressive disclosure. Use for missing, bloated, contradictory, or outdated agent instructions, monorepos, services, packages, module context, and portable agent guidance without assuming any fixed agent folder structure.
7 other projects use a version of this.
Adopted by
Most recently taken up by
- n-n-code/n-n-code-skillstheir own version, first seen Nov 1, 2026
- zhengwenxuan1991/skillstheir own version, first seen Sep 19, 2026
- Eriemon/agents-md-generatortheir own version, first seen Aug 26, 2026
- slogsdon/skills-workflowstheir own version, first seen Aug 4, 2026
- thienanblog/awesome-ai-agent-skillstheir own version, first seen May 3, 2026
- jleivo/skillstheir own version, first seen Mar 9, 2026
Other versions7 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 7
- thienanblog/awesome-ai-agent-skills★ 68same name
- Eriemon/agents-md-generator★ 14same name
- n-n-code/n-n-code-skills★ 4same name
- jleivo/skills★ 1same name
- zhengwenxuan1991/skills★ 1same name
- slogsdon/skills-workflows★ 0same name
- uts58/my-random-skills★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository10 other files it gives its agents.
- dart-driftSkill
- flutter-adaptive-uiSkill
- flutter-animationsSkill
- flutter-architectureSkill
- flutter-driftSkill
- flutter-duit-bduiSkill
- flutter-internationalizationSkill
- flutter-navigationSkill
- flutter-networkingSkill
- flutter-testingSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
16 rules. 0 are common, 14 are distinctive, and 2 are very specific to this project.
0
Common
Most of the 6 edited versions we read keep these.
14
Distinctive
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 18
Use progressive disclosure: keep AGENTS.md concise.
- Distinctive: line 27
If referencing local skills, use only an existing skill root already used by the project or an existing project path already mentioned by …
- Distinctive: line 29
If no local skill directory exists — reference skills by name only (external).
- Distinctive: line 36
Use templates as skeletons, not literal output:
- Very specific: line 38
Read references/AGENTS_TEMPLATE_ROOT.md only when creating or updating the root AGENTS.md.
- Very specific: line 40
Read references/AGENTS_TEMPLATE_MODULE.md only after a directory is confirmed as a nested module that needs its own AGENTS.md.
- Distinctive: line 48
Run this skill when:
- Distinctive: line 74
Create nested AGENTS.md if directory:
- Distinctive: line 81
Do not create a nested AGENTS.md that only repeats the root instructions.
- Distinctive: line 116
Do not embed style guides, CI policies, or architecture details.
- Distinctive: line 117
Prefer links to existing docs and external or local skills.
- Distinctive: line 121
Avoid “always/never” rules unless critical for correctness/security.
- Distinctive: line 139
Create or update only:
- Distinctive: line 150
When adding skill references inside AGENTS.md:
- Distinctive: line 162
Never assume filesystem paths.
- Distinctive: line 170
Only root/module AGENTS.md files were created or updated.
“Common” is measured: kept by at least 6 in 10 of the 6 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
AGENTS.md Generator (Root + Nested, Portable)
Goal
Maintain small, high-signal AGENTS.md files:
- Root AGENTS.md — purpose of repository, navigation, universal toolchain, canonical commands, links to docs and skills.
- Nested AGENTS.md — module/package purpose, local commands, module references.
Use progressive disclosure: keep AGENTS.md concise; push details to docs or skills.
Skill location (agent-specific)
- Do NOT assume
.agents/or any fixed directory exists. - Skills may live:
- inside the repository (embedded),
- or in an external/global skill library (external).
- If referencing local skills, use only an existing skill root already used by the project or an existing project path already mentioned by repo docs.
- If no local skill directory exists — reference skills by name only (external).
- Never create hidden agent directories just to store skills.
Resource Routing
Use templates as skeletons, not literal output:
- Read
references/AGENTS_TEMPLATE_ROOT.mdonly when creating or updating the rootAGENTS.md. - Read
references/AGENTS_TEMPLATE_MODULE.mdonly after a directory is confirmed as a nested module that needs its ownAGENTS.md. - Replace or remove every placeholder. Final
AGENTS.mdfiles must not contain unresolved<...>template markers.
When to run
Run this skill when:
- AGENTS.md is missing, bloated, contradictory, or outdated.
- AGENTS.md needs to be generated, repaired, trimmed, split, or updated.
- A new package/service/module appears.
- Repository structure changes (monorepo growth or split).
- Teams want consistent agent context across diverse stacks.
Workflow (Deterministic)
1. Discover repository shape
- Identify repository root (git root if available).
- Detect language/tool markers:
package.json,pnpm-workspace.yamlgo.mod,go.workpyproject.tomlCargo.tomlpubspec.yamlpom.xml,build.gradle
- Locate
docs/,README.md, existingAGENTS.md.
2. Detect module boundaries
Create nested AGENTS.md if directory:
- Contains independent build/package manifest
- OR represents deployable/service unit (
apps/,services/,packages/) - AND adds distinct commands, docs, ownership, deployment notes, or toolchain guidance compared with parent scope.
Do not create a nested AGENTS.md that only repeats the root instructions.
3. Generate/Update Root AGENTS.md
Constraints:
- Ideal size: ≤ 60 lines
- Must include:
- One-sentence repository purpose
- Primary toolchain/package manager
- Canonical commands (if non-standard)
- Links to docs
- Instruction to read nested AGENTS.md when inside modules
- Optional skill references (adaptive: local or external)
- Preserve verified commands, docs, security/secrets/deployment warnings, and
important local rules from any existing root
AGENTS.md.
4. Generate/Update Nested AGENTS.md
Constraints:
- Ideal size: ≤ 40 lines
- Must include:
- One-sentence module purpose
- Module-specific commands
- Local documentation references
- Optional skill references (adaptive)
- Preserve verified module warnings, ownership, deployment notes, and local
rules from any existing nested
AGENTS.md.
5. Progressive Disclosure Rules
- Do not embed style guides, CI policies, or architecture details.
- Prefer links to existing docs and external or local skills.
- Include only links that exist or are explicitly cited as the source for commands or policy.
- Replace stale long-form sections with links when an authoritative doc exists.
- Avoid “always/never” rules unless critical for correctness/security.
6. Safety / Correctness Gates
- Never invent commands.
- Infer commands from:
- package scripts
- Makefile
- CI configuration
- README
- If uncertain → write:
“Known commands: see
<existing file>” - Preserve critical warnings (security, secrets, deployment).
Output Contract
Create or update only:
<repo_root>/AGENTS.md<module_dir>/AGENTS.md
Do not create agent configuration folders.
Skill Referencing Strategy
When adding skill references inside AGENTS.md:
- If local skill directory detected
See: <detected-skill-root>/<skill-name>/SKILL.md - If no local directory exists
Skill: agents-md-generator (external)
Never assume filesystem paths.
Validation
Before finishing, verify:
- Only root/module
AGENTS.mdfiles were created or updated. - Final
AGENTS.mdfiles contain no unresolved<...>placeholders. - Relative documentation links exist or clearly point to a source file for commands/policy.
- Commands are supported by package scripts, Makefile, CI configuration, or
README. If no command is verified, use
Known commands: see <existing file>. - Line budgets are respected: root ≤ 60 lines, nested module ≤ 40 lines.
- Nested files exist only for confirmed module boundaries.
- Critical warnings from existing
AGENTS.mdfiles are preserved.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

