← Blog

Claude fixed a meal by deleting it. Here's what we changed.

One of our testers asked Claude to correct a logged meal. It deleted the entry, logged it again, and sent her to an edit screen the app didn't have. The fix was a new tool, a short list of what the app can really do, and a rule about where instructions belong.

On Nov 9th, one of our testers asked Claude to fix a meal she had logged through Macroline. Claude did what it could with the tools it had. There was no tool for changing an entry, so it deleted hers and logged the meal again. Then it told her she could adjust it on the entry’s edit screen in the app.

That screen didn’t exist yet.

Nothing in that exchange was malicious, and none of it was hard to understand once we read it. Claude was being helpful with an incomplete toolbox, and it filled the gap in its knowledge of our app with a plausible guess. We think both problems were ours, so here is what we changed.

1. Give it the tool it was missing

The next day we shipped update_log_entry. It changes an entry in place: the servings, the time, the meal, the name, which food it points at, or the nutrition numbers themselves. The app’s own edit screen, which reached the iPhone app later in November, calls the same code on our server, so a fix made in a chat and a fix made with your thumb do exactly the same thing.

Two details matter more than the tool itself:

  • An edited number loses its source. If you, or Claude on your behalf, change an entry’s calories or protein, that entry stops claiming the food’s verified tier. It shows “Edited by you”, and the original numbers are kept so you can reset it. Every number in Macroline says where it came from, and “you typed it” is a real answer.
  • A correction is never a delete and a re-log. Deleting loses the entry’s history and its original time, and re-logging can double-count if anything goes wrong in between.

2. Tell it what the app can actually do

The second problem was the invented screen. Claude can’t see our app. Anything it says about where a button lives is either something we told it or a guess.

The MCP protocol has a place for this. When a client connects, the server can return a block of instructions that the client reads once, before it sees any tool. Ours now opens with a short list of what the Macroline app can do, and a rule: don’t describe a screen, tab or button unless the step is on that list, and if you’re not sure the app can do something, say you’re not sure. If no tool does what you asked, Claude is told to say so plainly rather than offer a workaround.

We wrote that list so it stays true as the app grows. It says you can open a logged entry to change its servings, meal or time. For anything beyond that, the instructions tell Claude to offer to make the change itself instead of pointing at a screen. That’s true today and it will still be true after the next release.

3. Put the rules in one place

In March we wrote that a tool description should be a small persuasive essay: what the tool does, when to use it, when not to. We’ve changed our minds about half of that.

By this month, 29 of our 32 tool descriptions contained instructions. “Say so if the numbers don’t add up.” “Don’t log it a second time.” “Pass the id to the edit tool.” Each one was there for a reason, usually a mistake we had watched happen. Together they made a strange document: rules about honesty scattered across dozens of tool descriptions, some repeating each other, a few quietly disagreeing.

So this week we split them. Every tool description now says only what the tool does and what it returns. Every rule about behaviour lives in the server instructions from step 2: how the tools fit together, how to fix a logged meal, how to talk about a number’s source, and the medication rules (log what the user says they took; never recommend a dose or a change). A test on our server reads every tool and every field description and fails if one tells the model what to do or names another tool.

The practical effect is that the rules are now readable in one place, in about 3,000 characters, and a person auditing our connector can read exactly what Claude is told.

What this doesn’t fix

Claude can still misread a request, pick the wrong food, or round a number in its reply. The instructions make the honest path the obvious one; they don’t make mistakes impossible. That’s why every entry carries its source tier and every edit is marked and reversible: when something does go wrong, you can see it and undo it.

If you use Macroline with Claude and you see it guess about the app, or fix something by deleting it, please tell us at info@macroline.app. That report is exactly how this one started.