Skip to content
Back to prompts
Engineering

Write useful AGENTS.md instructions

Create or update repository instructions from the project’s real commands, structure, and conventions.

  • AGENTS.md
  • Repositories
  • Documentation

Before you use it

Replace the text in [brackets] with your own context. Review the response before using it.

Create or update AGENTS.md for [repository or project]. The goal is to help a coding agent make correct changes without repeating instructions that already exist elsewhere.

Project context:
[Purpose, important constraints, and any instructions I want preserved]

Before writing, read applicable agent instructions and inspect the README, package or build configuration, test setup, and a few representative source files. Use the repository’s actual structure and commands. Do not invent scripts, dependencies, deployment steps, or conventions from the framework alone.

Preserve useful existing instructions. Explain conflicts or outdated guidance and identify the evidence for a correction. Include the essentials: how to run and check the project, where important code and content live, conventions contributors should follow, and actions that require explicit authorization. Keep secrets and personal local paths out of the file.

Prefer concise instructions with links to maintained documentation. Avoid duplicating long guides or adding rules for hypothetical future features.

Return the proposed file, the sources you checked, and any unresolved questions. If you can edit the repository, apply the update and summarize what changed. Do not commit or publish unless I ask.