Write or update a README from facts in the repository's manifest, scripts and docs, leaving TODOs instead of invented badges, features or install commands.
---
name: readme-generator
description: Writes or updates a project README.md from facts found in the repository - package manifest, scripts, entry points, existing docs, license and examples - and marks anything it could not verify as a TODO instead of inventing it. Use when asked to create a README, improve or refresh the README, or document how to install and use a project.
compatibility: Needs read access to the repository; writing README.md needs write access.
metadata:
version: "1.3.0"
---
# README Generator
Produces a README a newcomer can follow. Every command, badge and feature in it must trace back to something in the repository. Where the repo does not say, the README says `TODO` and the summary lists it for the user.
## Inputs to collect
- Repository root. If a README already exists, whether to rewrite it or update specific sections (default: update, preserving the author's wording where still correct).
- Audience: library users, CLI users, or contributors.
- Any facts the repo cannot reveal (hosted URL, support channel, roadmap) - ask, or leave TODO.
## Workflow
1. **Gather facts (read-only).**
- Manifest: `package.json` (name, description, private, bin, main/exports, scripts, engines, license, repository), `pyproject.toml`, `Cargo.toml`, `go.mod`, `composer.json` as relevant.
- Lockfile type to pick the package manager (`package-lock.json` npm, `pnpm-lock.yaml` pnpm, `yarn.lock` yarn, `bun.lock` or `bun.lockb` bun, `uv.lock` uv, `poetry.lock` poetry).
- Entry points and examples: `bin/`, `src/index.*`, `examples/`, tests that show usage.
- Existing docs: current `README.md`, `docs/`, `CONTRIBUTING.md`, `CHANGELOG.md`, `LICENSE` file, `.env.example`.
- CI: `.github/workflows/*.yml` (only to name the workflow for a badge, if one exists).
2. **Decide what can be stated.**
- Install command only if the package is published or the repo documents installing from source. A `"private": true` package gets clone-and-install-from-source instructions, not `npm install <name>`. If you cannot tell whether it is published, say so rather than checking the registry silently.
- Commands only from `scripts` (or Makefile/justfile targets) that exist.
- Features only from code, tests or existing docs; describe them in plain terms, no superlatives.
- Badges only for things that exist: a CI workflow file, a published package, a license file. No placeholder `[](link)` lines.
- Configuration only from `.env.example`, config schemas or code that reads environment variables (`process.env.X`, `os.environ["X"]`).
3. **Draft the README** using the sections that apply: title and one-line description; what it does; requirements (from `engines`, `python_requires`, toolchain files); installation; quick start (one real, minimal example); usage/CLI reference; configuration; development (test/lint commands from scripts); contributing (link `CONTRIBUTING.md` if present); license (from the `license` field or `LICENSE` file). Omit sections with nothing true to say.
4. **Check it.** Every command in the README appears in the manifest or docs; every relative link points to a file that exists; code samples use real exported names. If cheap and safe, run the documented test command once and report the result.
5. **Show the diff and the TODO list** before writing over an existing README.
## Output format
1. The README (or a diff against the existing one).
2. A short list: facts used (file → section), TODOs needing the user, and checks run.
## Example
`package.json`: name `csv-tidy`, description "Normalize headers and trim whitespace in CSV files", `bin: {"csv-tidy": "bin/csv-tidy.js"}`, scripts `test` and `lint`, `engines.node >=20`, license MIT, no LICENSE file, no CI workflows.
Result: title and description from the manifest; Requirements "Node.js 20 or later"; Usage shows `csv-tidy` as the CLI name with a TODO for its options (read from `bin/csv-tidy.js` if present); Development lists `npm test` and `npm run lint`; License "MIT (declared in package.json; no LICENSE file in the repo - TODO)"; no CI badge because no workflow exists. Install: `npm install -g csv-tidy` only if the user confirms it is published, otherwise install from source.
## Limitations
- Does not verify that a package is published or that external links resolve unless asked to check.
- Does not invent screenshots, benchmarks, user counts or compatibility claims.
Illustrative input and expected result. This example is a verification guide, not a recorded model run.
Content reviewed .
A small Node CLI has no README, and its author wants one that matches what the package really does before sharing the repo.
Write a README for this repo. package.json: name csv-tidy, description "Normalize headers and trim whitespace in CSV files", bin csv-tidy -> bin/csv-tidy.js, scripts test (node --test) and lint (eslint .), engines node >=20, license MIT. There is no LICENSE file and no .github/workflows.
A README with: '# csv-tidy' and the manifest description; Requirements: Node.js 20 or later; Usage built around the csv-tidy command (options from bin/csv-tidy.js, or TODO); Development: npm test, npm run lint; License: MIT with a TODO to add a LICENSE file. No CI or coverage badges, no invented features. A closing list maps each fact to its source and lists TODOs, including whether csv-tidy is published to npm before an `npm install -g csv-tidy` line is kept.
AI Agent Skills are reusable workflow packages that extend your AI coding assistant with multi-step capabilities. Install readme-generator by following these steps.
SKILL.md inside, in the location documented by your client. Do not assume every AI application reads the same directory.Requires an Agent Skills-compatible client; supported locations and activation vary by version. Read the SKILL.md setup guide. MCP connects tools and data and does not, by itself, install a skill.