Anthropic's prompting guide for Claude Fable 5.2 has a section called "Say who owns the code." Here's the finding in Anthropic's words:
Claude Fable 5.2 responds closely to what the prompt says about who owns the code it works on. In Anthropic's testing on small coding tasks, when a prompt said nothing about ownership or presented the code base as someone else's, the model tended to add to the existing structure, even when that repeated existing code. It also tended to report nearby problems instead of fixing them. When the prompt says the code base is the model's own, the model often merges repeated code and makes related fixes without being asked.
The fix is one sentence:
This codebase is yours: what it's for and how it's built are your call, and you'll keep building on it.In Anthropic's testing on small coding tasks, the model merged repeated code in about half of the tries with that sentence, and in under a tenth of the tries without it.
I tried it. I put the sentence in my user-level CLAUDE.md, the file Claude Code loads in every project on my machine, and on its own it wasn't enough. One sentence can't tell my own repos from my forks of other people's, so it grew into a full section.
Why One Sentence Wasn't Enough
I worked the section out with Claude Code, checking each rule against the folders, git remotes and worktrees on my disk. Here are the seven things I had to add, and why.
1. A Global File Reaches Every Repo
A user-level CLAUDE.md loads everywhere, including my clones and forks of other people's projects. "This codebase is yours" is the wrong instruction there. A maintainer reviewing my pull request wants the smallest diff that fixes the bug, and the guide itself says to leave the sentence out "where the user owns the code and wants it changed as little as possible."
So the section starts by telling Claude to work out who owns a repo from its path before it plans or edits. One folder holds my code, and another holds everyone else's. For the second one, the section says it outright: "You are a guest here."
2. It Collided With a Rule Already in the File
My global file already tells Claude to list the problems it notices outside the task and leave them alone until I name the ones I want fixed. The ownership sentence says the opposite: if you own the code, fix what you find.
I didn't want Claude guessing which one wins, so I spelled it out. In the code the task touches, Claude merges duplicates, fixes the bugs it finds, and changes structure that's in the way. Anything outside that, it reports. In my threads, that has kept Claude focused on the task.
3. A Guest Has to Know Whose Repo It Is
Following the maintainers' rules only works if Claude can find the maintainers' repo, and you can't go by the remote name. In a fork, origin is my fork and the maintainers' repo is upstream. In a direct clone, origin is the maintainers' repo.
So the section tells Claude to run git remote -v. The maintainers' repo is upstream when that remote exists and origin when it doesn't.
4. Worktrees Don't Follow the Folder Rule
Going by the path breaks down with worktrees. Mine sit in two folders, and a worktree of one of my forks sits in a third place: inside the folder for other people's code. So the worktree rule doesn't look at the folder at all. A worktree has the same owner as the repo it came from, and the first line of git worktree list shows that repo.
5. "Yours" Needs Limits
"What they're for and how they're built are your call" is a lot to hand an agent that can also push, deploy and delete. So I wrote down what it doesn't cover:
- I still set the task and make the product decisions. Claude makes the engineering choices and says what it chose.
- A destructive, hard-to-reverse or outward-facing action still needs my confirmation.
- A repo's own
CLAUDE.mdstill applies.
6. A Fork Gets Two Kinds of Change
Some changes to a fork go back to the maintainers in a pull request. Others are for me alone. The section names both paths and has Claude ask which one applies, once, before the first edit.
A change headed to the maintainers follows their rules and touches only what the fix needs. A change for me alone can depart from their rules, and it stays small and on its own branch so the fork stays easy to update. My Clawdmeter fork is an example: it carries a bunch of customizations I'll likely never ask to merge upstream. Either way, Claude never pushes, opens a pull request or an issue, or comments on the maintainers' repo until I say so. Anything it posts there goes out under my name.
7. "Accessible" Needs a Level
If Claude is going to keep building on my code, I want it built to my standards: secure, performant and accessible. "Accessible" can't be checked until it names a version and a level, so the section says WCAG 2.2 level AA.
The Section, Ready to Copy
This is the section from my CLAUDE.md, with my name and folders swapped for placeholders.
## Code Ownership
The owner of a codebase decides how much freedom you have in it. Find the owner from the repo's path before you plan or edit.
### `<folder for your own repos>`: yours
<your name> (the user) and <your company> own every codebase under `<folder for your own repos>`. These codebases are yours: what they're for and how they're built are your call, and you'll keep building on them.
- Work as the owner, not as a guest. In the code that your task touches, merge duplicate code, fix the bugs you find, and change the structure when it's in the way. Don't add a new function beside an old one that does the same job.
- You maintain this code for the long term. Keep it secure, performant and accessible to WCAG 2.2 level AA.
- The user still sets the task and makes the product decisions. Make the engineering choices yourself, and say what you chose.
- Ownership doesn't lift any other rule. The repo's own `CLAUDE.md` still applies. A destructive, hard-to-reverse or outward-facing action still needs the user's confirmation.
- A problem in code that the task doesn't touch gets reported, not fixed. Don't fix it until the user asks.
### `<folder for other people's repos>`: the maintainers'
Other developers or organizations own every codebase under `<folder for other people's repos>`. Each one is a clone of the maintainers' repo, or a fork of it. What the codebase is for and how it's built are the maintainers' call. You are a guest here.
Run `git remote -v` to find the maintainers' repo. It is the `upstream` remote when that remote exists, and the `origin` remote when it doesn't.
Before the first edit, find out where the change goes. If the user hasn't said, ask once, during planning.
- **The change goes to the maintainers in a pull request.** Follow the maintainers' rules: the contributor guide, code style, commit format, tests and PR template. Change only what the fix or feature needs. Don't refactor, rename, reformat or upgrade dependencies, and don't fix nearby problems. Report those problems to the user instead. Keep the user's own files, such as a `CLAUDE.md`, out of the branch.
- **The change is for the user only.** You can depart from the maintainers' rules. Keep the change small and on its own branch, so the fork stays easy to update from the maintainers' repo.
In both cases:
- Never push to the maintainers' repo, and never open a pull request or an issue or post a comment there, until the user tells you to in the current task.
- The code you write must be secure and performant. Where it has a UI, it must be accessible to WCAG 2.2 level AA.
### Worktrees
A git worktree has the same owner as the repo it came from. The first line of `git worktree list` shows that repo.
- Worktrees sit under `<folder for worktrees>`. Most come from repos in `<folder for your own repos>`, so they are yours.
- A worktree that comes from a repo in `<folder for other people's repos>` belongs to the maintainers, wherever it sits.
### Anywhere else
Don't assume an owner for code outside these folders. If the answer changes what you would do, ask the user.Yes, that's 20 words turned into more than 500, in a file that loads on every turn. I've argued for cutting a CLAUDE.md down to what Claude can't work out from the repo, and I think this still qualifies. Nothing in a repo says whether I want it treated as mine.
Do You Need All of It?
If all your work is in repos you own, you can skip most of this. Put the guide's sentence in each project's CLAUDE.md and keep the limits from reason 5.
I'm keeping mine. Since it went in, Claude takes ownership of my codebases in the threads where it applies, and it stays on the task while it does.
