agents-md
Scannednpx machina-cli add skill pantheon-org/tekhne/agents-md --openclawAGENTS.md Management
When to Use
- "Create AGENTS.md for this repo."
- "Update agent documentation for this monorepo."
- "Set up hierarchical AGENTS.md files by package."
When Not to Use
- Pure code implementation work with no documentation update.
- One-off prompts where repository guidance files are unnecessary.
Principles
- Keep instructions concise, concrete, and path-specific.
- Prefer references and indices over duplicated prose.
- Optimize for nearest-file relevance in hierarchical layouts.
Workflow
- Discover repository shape and technologies. Output: simple vs hierarchical documentation strategy.
- Select structure (single root file or root + sub-files). Output: file layout plan.
- Generate AGENTS.md content with concrete commands and paths. Output: actionable docs with JIT indexing.
- Validate command correctness and duplication boundaries. Output: clean, copy-paste-safe instruction files.
- Re-check after major repo changes. Output: synchronized documentation.
Structure Decision
- Simple project: one AGENTS.md when stack and patterns are uniform.
- Complex monorepo: root AGENTS.md + scoped subdirectory AGENTS.md files.
Quick Commands
# Discovery baseline
rg --files
# Detect core config/tooling
rg -n "workspaces|nx|turbo|pnpm|yarn|packageManager|tsconfig|pytest|playwright" .
# Locate existing AGENTS files
find . -name AGENTS.md -o -name AI-DOCS.md
Anti-Patterns
NEVER assume a technology stack without discovery
WHY: incorrect assumptions produce unusable instructions. BAD: generate React/Jest guidance without evidence. GOOD: run discovery commands and map docs to detected stack.
NEVER dump encyclopedic content into root AGENTS.md
WHY: oversized docs increase token cost and reduce usability. BAD: embed full framework manuals. GOOD: keep root concise and link to scoped files/references.
NEVER duplicate the same instructions across root and sub-files
WHY: duplication creates drift and maintenance overhead. BAD: copy/paste identical conventions in every file. GOOD: keep universal rules at root and package-specific rules locally.
NEVER provide unverified commands
WHY: broken commands erode trust and block contributors. BAD: include hypothetical commands. GOOD: include only validated copy-paste commands.
Quick Reference
| Topic | Reference |
|---|---|
| Repository discovery commands | references/discovery-commands.md |
| What to avoid | references/anti-patterns.md |
| API package template | references/api-template.md |
| Design-system template | references/design-system-template.md |
| Database package template | references/database-template.md |
| Testing package template | references/testing-template.md |
| Troubleshooting | references/troubleshooting.md |
Verification
bunx markdownlint-cli2 "**/AGENTS.md" "skills/agents-md/**/*.md"
sh skills/agentic-harness/skill-quality-auditor/scripts/evaluate.sh agents-md --json
Source
git clone https://github.com/pantheon-org/tekhne/blob/main/skills/agentic-harness/agents-md/SKILL.mdView on GitHub Overview
This skill helps you create and maintain AGENTS.md documentation for both simple projects and complex monorepos. It emphasizes deterministic discovery, scoped instruction files, and low token navigation to standardize AI facing guidance and streamline updates.
How This Skill Works
Start with repository shape discovery to choose simple versus hierarchical structure. Generate AGENTS.md content with concrete commands and paths, validate for correctness and duplication, and re-check after major repo changes to stay synchronized.
When to Use It
- Create AGENTS.md for a new repository.
- Update agent documentation in a monorepo.
- Set up hierarchical AGENTS.md files by package.
- Standardize AI-facing project guidance across teams.
- Audit and re-sync AGENTS.md after major repo changes.
Quick Start
- Step 1: Discover repository shape and technologies. Output: simple vs hierarchical documentation strategy.
- Step 2: Select structure (single root file or root + sub-files). Output: file layout plan.
- Step 3: Generate AGENTS.md content with concrete commands and paths. Output: actionable docs with JIT indexing.
Best Practices
- Write concise, path specific instructions.
- Keep the root AGENTS.md brief and link to scoped files.
- Prefer references and indices over duplicated prose.
- Validate every command before documenting it.
- Avoid duplicating the same conventions across root and sub-files.
Example Use Cases
- Simple project with a single root AGENTS.md.
- Monorepo with root AGENTS.md and per package AGENTS.md files.
- Discovery driven approach mapping docs to detected stack.
- Validated commands via markdownlint and copy paste safety checks.
- Synchronized documentation after a major repo refactor.