No. 136 Instruction files

Services/payments/AGENTS.override.md

Use when later sessions should inherit a written instruction

  • Claude Code
  • Codex
  • Cursor
  • Instruction files

Prompt

# services/payments/AGENTS.override.md

## Payments service rules

- Use `make test-payments` instead of `npm test`.
- Never rotate API keys without notifying the security channel.

When to use

“Services/payments/AGENTS.override.md” fits when later sessions should inherit a written instruction, because it says “services/payments/AGENTS.override.md”, and it is written to stay in force on later turns rather than to finish one task.

With “Services/payments/AGENTS.override.md” loaded, the user message can be as small as “fix the empty-cart total in src/cart.js and do not touch the test runner”, because “services/payments/AGENTS.override.md” is already in force.

When not to use

Leave “Services/payments/AGENTS.override.md” unused when you are fixing one bug tonight and you do not want tomorrow's session to inherit the words, because “services/payments/AGENTS.override.md” points the other way

How to run it

Claude Code

Claude Code loads “Services/payments/AGENTS.override.md” from .claude/rules on later sessions, so “services/payments/AGENTS.override.md” survives a new chat, which a one-off paste does not.

Codex

Codex keeps “Services/payments/AGENTS.override.md” only if you put “services/payments/AGENTS.override.md” in AGENTS.md, or in AGENTS.override.md beside the directory that should inherit it. A paste that is not saved is gone next thread.

Cursor

Cursor keeps “Services/payments/AGENTS.override.md” by saving “services/payments/AGENTS.override.md” as .cursor/rules. The chat transcript alone will not reload it tomorrow.

Comparison

对比待补

This before-and-after was not run on this machine.

Related

来源:OpenAI · https://developers.openai.com/codex/guides/agents-md · 2026-12-01