CAP-SKILL-004
Skill100 starsChanged 2 months agoMITView on GitHub
, make, cargo build | Array of build commands with source file and line | | Test commands | npm test, pytest, go test | Array of test commands with source file and line | | Lint commands | eslint, ruff, clippy | Array of lint commands with source file and line | | Security boundaries | "do not commit", "must validate", "must hash", "never expose" | Array of security rules with source file | | Coding conventions | naming,…
- Reads credentials
In this repository15 other files it gives its agents.
- AGENTS.mdAGENTS.md
- harness/AGENTS.mdAGENTS.md
- i-test-target/AGENTS.mdAGENTS.md
- anti-overengineeringSkill
- app-type-classifierSkill
- auth-permission-securitySkill
- backend-api-designSkill
- CAP-SKILL-013Skill
- CAP-SKILL-014Skill
- CAP-SKILL-015Skill
- database-schema-designSkill
- frontend-ui-systemSkill
- mobile-miniapp-patternsSkill
- product-architectureSkill
- webapp-preview-testingSkill
The file
We split this skill into the rules it gives an agent
5 rules. About 0 are common, 4 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- could be automatic: a setting could enforce it
- Distinctive: line 27
When two AGENTS.md files conflict on the same rule:
- Distinctive: line 30
Do NOT silently merge or resolve — surface to the human
- Distinctive: line 41
If current user instructions contradict an AGENTS.md rule, flag the conflict — do not follow AGENTS.md silently
- Very specific: line 42
If AGENTS.md says "use TypeScript strict" and the user says "use plain JavaScript", generate: CONFLICT: AGENTS.md requires TypeScript …
- Distinctive: line 43
Never override explicit user instructions with AGENTS.md defaults
≈ “Common” is an estimate: at least 1 in 5 of the 364,980 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
AGENTS.md Ecosystem Skill
Trigger
This skill activates when working in a project that contains AGENTS.md files at any directory level. It applies to agents involved in project analysis, architecture, implementation planning, and contract generation.
Purpose
Parse and apply AGENTS.md instructions from a project's directory tree. AGENTS.md files provide scoped rules for agents — build commands, coding conventions, security boundaries, handoff requirements, and architectural constraints.
Core Rules
1. AGENTS.md Discovery
Walk the project directory tree from root to leaves. Collect all AGENTS.md files. Record their directory paths to establish rule scopes. The root-level AGENTS.md has the widest scope; nested AGENTS.md files override parent rules within their subtree.
2. Content Extraction
Parse each AGENTS.md and extract:
| Category | Pattern | Output |
| Build commands | `npm run build`, make, cargo build | Array of build commands with source file and line |
| Test commands | npm test, pytest, go test | Array of test commands with source file and line |
| Lint commands | eslint, ruff, clippy | Array of lint commands with source file and line |
| Security boundaries | "do not commit", "must validate", "must hash", "never expose" | Array of security rules with source file |
| Coding conventions | naming, formatting, architecture rules | Array of convention rules with source file |
| Handoff requirements | handoff format, required fields | Handoff specification map |
3. Scope Resolution
When two AGENTS.md files conflict on the same rule:
- More-deeply-nested AGENTS.md takes precedence
- Report the conflict as a
scopeConflictwarning - Do NOT silently merge or resolve — surface to the human
4. Contract Input Generation
Translate extracted AGENTS.md rules into contract fragments:
- Build/test/lint commands → Project Intent Contract (PIC) inputs
- Architecture rules → Architecture Contract (AC) inputs
- Security boundaries → Security boundary for all contracts
- Directory scope rules → Feature Contract (FC) scope annotations
5. User Instruction Priority
AGENTS.md rules are advisory, NOT absolute authority:
- If current user instructions contradict an AGENTS.md rule, flag the conflict — do not follow AGENTS.md silently
- If AGENTS.md says "use TypeScript strict" and the user says "use plain JavaScript", generate:
CONFLICT: AGENTS.md requires TypeScript strict, user requests JavaScript — escalate to human - Never override explicit user instructions with AGENTS.md defaults
6. Tool Restrictions
- This skill may READ AGENTS.md files and EXTRACT structured information
- This skill may NOT execute build/test/lint commands from AGENTS.md
- This skill may NOT modify AGENTS.md files
- This skill may NOT write project files based on AGENTS.md content
- Execution of extracted commands is reserved for IMPL and VER agents under separate permission
Output Format
{
"agentsMdSummary": {
"filesFound": ["/AGENTS.md", "/src/api/AGENTS.md"],
"totalRules": 15,
"scopeConflicts": 0
},
"buildCommands": [
{ "command": "npm run build", "source": "/AGENTS.md", "line": 42 }
],
"testCommands": [
{ "command": "npm test", "source": "/AGENTS.md", "line": 45 }
],
"lintCommands": [
{ "command": "eslint src/", "source": "/AGENTS.md", "line": 48 }
],
"securityBoundaries": [
{ "rule": "All API routes must validate JWT", "source": "/src/api/AGENTS.md" }
],
"conventions": [
{ "rule": "Use kebab-case for filenames", "source": "/AGENTS.md" }
],
"directoryRules": {
"/": { "scope": "global", "rules": ["kebab-case filenames", "TypeScript strict"] },
"/src/api/": { "scope": "api-layer", "rules": ["JWT validation", "rate limiting"] }
},
"contractInputs": {
"pic": ["build: npm run build", "test: npm test"],
"ac": ["TypeScript strict mode", "kebab-case naming"],
"security": ["JWT validation on all API routes"]
},
"conflictWarnings": [],
"caveats": [
"AGENTS.md rules are advisory — user instructions take precedence",
"Command extraction is pattern-based — verify commands before execution"
]
}Example: Fixture AGENTS.md
# AGENTS.md
## Build
Run `npm run build` to compile.
## Test
Run `npm test` for all tests.
## Lint
Run `eslint src/` before committing.
## Security
- Do not commit .env files
- All API routes must validate JWT
## Conventions
- Use kebab-case for filenames
- Component files in src/components/
- API handlers in src/api/
## Handoff
- Implementer must handoff to Verifier with build PASS evidenceExpected extraction: 3 commands (build/test/lint), 2 security rules, 2 conventions, 2 directory patterns, 1 handoff rule.
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.

