<!--
ROBOTS ON PAYROLL / THE VAULT
What this is: a global AGENTS.md starter for Zed that sets lean working-style rules for every agent thread in every project.
How to use it: download this file and give it to your AI (Claude, ChatGPT,
Cursor, Lovable chat) as a reference. Say: "Use this as my playbook for
configuring Zed's agent."
Latest version + full guide: https://robotsonpayroll.com/resources/zed-agent-cockpit
-->

# Global AGENTS.md for Zed

Save as `~/.config/zed/AGENTS.md`. Zed prepends this to every agent thread
in every project. A project-level AGENTS.md overrides it, so keep this file
lean: only rules that are true in ALL of your projects. Everything reusable
but situational belongs in a Skill instead (~/.agents/skills/).

---

## Working style

- Make the smallest change that solves the task. No drive-by refactors, no reformatting untouched code.
- Before editing, read the file you are changing and at least one caller/usage of the code you touch.
- If the task is ambiguous, ask one clarifying question instead of guessing. One, not five.
- When a task needs more than ~3 files changed, state a short plan first (files + what changes in each), then execute.

## Code rules

- Match the existing style of each file. Do not introduce a new pattern when the codebase already has one for the same job.
- No new dependencies without asking. If a stdlib or existing-dependency solution exists, use it.
- Handle the failure path of every external call you add (HTTP, DB, filesystem). No empty catch blocks.
- Never hardcode secrets, tokens, or URLs with credentials. Use env vars with a placeholder like KEY_HERE in examples.

## Terminal rules

- Prefer read-only commands. Ask before anything destructive (rm, drop, force-push, migrations).
- Run the project's own scripts (package.json scripts, Makefile, justfile) instead of raw tool invocations when they exist.

## Output style

- Answers short and concrete. Lead with the change made or the answer, not a preamble.
- When you finish a multi-file change, end with a bullet list: file -> what changed.
- If you are not sure something works, say so and state how to verify it. Do not present guesses as facts.
