# CLAUDE.md & AGENTS.md Generator: Verified Commands

> Writes a short CLAUDE.md or AGENTS.md for any repo with every command actually run first, so coding agents stop guessing how to test, lint and build your project.

CLAUDE.md & AGENTS.md Generator: Verified Commands is a free AI agent skill on Agensi by Abhineet Sharma. It loads into your AI agent through the Agensi MCP server, always in its latest approved version.

- Price: Free
- Creator: [Abhineet Sharma](https://www.agensi.io/creators/abhineet-sharma)
- Version: 1.0
- Last updated: 2026-11-28
- Security: scan passed (2026-11-28); every new listing is also reviewed by a person
- Listing: https://www.agensi.io/skills/claude-md-agents-md-generator-verified-commands
- Tags: prompt-skill-engineering, technical-documentation, agents-orchestration

## What it does

- Checks every command by running it first to ensure they actually work in your environment
- Writes a short checklist for your AI agent to follow before it says a task is finished
- Identifies specific project gotchas like folders the AI should never edit or hidden settings
- Creates a verification table so you can see which tests passed and which were skipped
- Cleans up old instruction files by removing generic fluff and fixing broken scripts

## Who it's for

- **Founders with a new coding project:** Make sure your AI helper knows exactly how to test and build your app without you explaining it every time. Try: "Create a CLAUDE.md for my new Next.js project so I can start coding with you."
- **Teams managing large codebases:** Keep AI instructions up to date even as your folder structure and commands change over time. Try: "Update the AGENTS.md in this repo and remove any stale commands that don't work anymore."
- **Freelance developers using AI agents:** Stop wasting time fixing AI errors caused by it using the wrong build or lint commands. Try: "Scan this repo and write a .cursorrules file with verified commands for testing."

## About this skill

Most agent instruction files are either missing or 400 lines of "write clean code" plus commands nobody checked. This skill writes the short, specific kind that actually helps: what an agent can't work out on its own and will get wrong without.

**How it works**
1. A read-only scanner (`repo_facts.py`, stdlib only) collects what the repo can prove: languages, package managers from lockfiles, every `package.json` and `pyproject.toml` (monorepo subfolders included), Makefile / justfile / Taskfile targets, the commands your CI actually runs (multi-line `run:` blocks included), env var **names** from `.env.example` (values are never read), test locations, layout and existing agent files. It outputs a candidate command list with where each one came from.
2. The agent **runs each command** (install, dev, test, single test, lint, typecheck, build) and records works / fails / skipped. Unverified commands don't go in, or get marked.
3. It reads a few real source files and recent commits to find conventions the linter doesn't enforce, plus the gotchas: run-from-this-folder, generated files not to touch, services that must be up for tests.
4. It writes a 40-120 line file with a clear "before you say it's done" checklist, and shows you a verification table before writing anything.

**Also handles**
- AGENTS.md vs CLAUDE.md (one source of truth via `@AGENTS.md` import, or both), Cursor rules and Copilot instructions.
- Monorepos: root file plus small per-package files only where they differ.
- **Refreshing stale files**: keeps what's still true, fixes renamed scripts, cuts generic filler, shows a diff.

Free, no API keys, no network.

## Requires

- Python 3.9+
- Optional: Git
- Optional: The project's own toolchain (to verify commands)

## Known limitations

Can only verify commands your environment can run: anything needing a database, paid API key or secret gets marked skipped. Doesn't write READMEs or user docs. Doesn't set up missing tooling (linters, CI), though it notes gaps.

## How to use this skill

1. Connect your AI agent to Agensi once: add the MCP server https://mcp.agensi.io/mcp/auth and sign in with your Agensi account (OAuth, no API key). Steps for Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and other agents: https://www.agensi.io/docs/mcp-setup
2. Ask your agent: "Use the CLAUDE.md & AGENTS.md Generator: Verified Commands skill from Agensi" and describe your task.
3. Your agent loads the skill from Agensi when it needs it. Nothing is downloaded.

## Frequently asked questions

### CLAUDE.md or AGENTS.md?

AGENTS.md is the cross-tool convention; Claude Code reads CLAUDE.md. The skill can write AGENTS.md as the single source of truth with a CLAUDE.md that imports it, or both files, whichever you prefer.

### Will it run my commands?

Yes, your project's own test, lint, typecheck, build and dev commands, so it only writes down ones that work. It asks before installing dependencies and never runs deploys, migrations against real databases, or anything that costs money without your go-ahead.

### Can it fix an existing file?

Yes. It checks every line against the repo, keeps what's true, fixes stale commands, cuts generic filler, and shows a diff before writing.

### Why is it so short?

The file is loaded into the agent's context on every task, so every line costs tokens every time. Short and specific beats long and generic.

---

Source: [Agensi](https://www.agensi.io), the marketplace of skills for AI agents. Any MCP-compatible agent (Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and more) connects at https://mcp.agensi.io/mcp/auth and signs in with an Agensi account; setup for every agent: https://www.agensi.io/docs/mcp-setup. Append .md to any skill, guide or docs address on agensi.io for its markdown version.
