AGENTS.md is the onboarding note for Codex. Put your project's working agreements in it: the test command, the package manager, when to ask before adding a dependency, how things are named. Codex reads it before every task.
Files can sit at several levels. One in your Codex home folder carries your personal preferences everywhere; one in the project root sets the project rules; files deeper in the folder tree add specific rules for that part. The closer file wins. In the CLI, /init writes a first draft.
