Skip to main content

AGENTS.md

AGENTS.md files give Ante persistent instructions that are separate from auto-memory. Use them for stable rules the agent should follow every time it works in a project.

Locations

Ante reads two instruction files when the first user message in a session is submitted:

LocationScope
~/.ante/AGENTS.mdGlobal instructions for all projects
<project>/AGENTS.mdProject instructions checked into the codebase

The global path follows ANTE_HOME, so if you set ANTE_HOME=/path/to/ante-home, the global file is /path/to/ante-home/AGENTS.md.

CLAUDE.md fallback

For zero-setup compatibility with Claude Code, each level falls back to a CLAUDE.md when no AGENTS.md exists — one file per level, never both:

  • Project: Ante walks up from the working directory; in each ancestor it checks AGENTS.md, then CLAUDE.md. The first directory containing either wins, and a directory with both reads only AGENTS.md.
  • Global: ~/.ante/AGENTS.md, falling back to ~/.claude/CLAUDE.md only when the Ante file doesn't exist. An existing (even empty) ~/.ante/AGENTS.md suppresses the fallback.

How Ante applies instructions

If both files exist, Ante includes them in one reminder block, with the global file first and the project file second. Empty files are ignored. If the global and project paths resolve to the same file, Ante includes it once.

Project instructions are intended for repository-specific rules such as build commands, coding conventions, and architectural constraints. Global instructions are better for personal preferences that apply everywhere, such as response format or language style.

Example

~/.ante/AGENTS.md
# Global preferences

- Keep responses concise.
- Prefer actionable explanations over background.
AGENTS.md
# Project rules

- Run `cargo test --workspace` before changing Rust code.
- Keep public protocol changes backward compatible.
- Update docs when CLI flags or config files change.

AGENTS.md vs MEMORY.md

AGENTS.md is authored guidance. Ante reads it as instructions for how to behave.

MEMORY.md is generated project memory. Ante uses it to carry learned context across sessions.

Use AGENTS.md for rules you want to enforce. Use memory for observations that may change as the agent learns the codebase.