How to give an AI coding agent visual feedback it can act on
You look at the page your agent built and something is off. The headline sits too close to the paragraph. You type "add more space under the headline" and get back a page where every heading on the site moved. The agent did what you said. It could not see what you meant.
Why words fail for visual changes
A sentence about a layout leaves out almost everything the agent needs. Which headline, on which page, at which screen size? How much is "more"? Is the space a margin on the heading, a margin on the paragraph, a gap on their parent, or padding somewhere above? An agent reading your sentence has to guess every one of those, then guess where in the code the value lives.
Designers already solved this problem once, for human developers. We stopped writing "tighten this up" in tickets and started handing over redlines and specs. The same fix works for agents, with one change: the spec has to be text.
The five things a visual note needs
- Which element. A selector, its classes, and a few words of its text. "The h1 in the hero that starts 'Write it down'" beats "the headline".
- Which property, before and after. "margin-top on the paragraph, 24px to 48px" leaves nothing to interpret.
- Where the value lives today. If the 24px comes from
.leadinsite.css, or from a Tailwind class, say so. This is the line that stops the agent adding an inline style on top of the real rule. - Scope. Is this for one element, or for every element that shares the class? One-off tweaks that rewrite a shared rule are the most common way a small fix breaks three other pages.
- The screen it was judged on. A change that looks right at 1440 pixels wide can be wrong on a phone. Name the width.
A note that works
Here is the shape of an instruction that an agent can apply without asking a question:
## p.lead, "Fieldnote keeps survey notes, photos and sketches"
- Selector: body > main > section.hero > p
- Applies to: this one element only
| Property | Before | After | Currently set by |
| margin-top | 24px | 48px | .lead in site.css |
Nobody wants to write that by hand for nine changes. That is the reason Site Tuner exists: you make the change on the live page with a design panel, and the Copy for agent button writes this note for every change you made, including the rule that sets each value today.
When a number is the wrong tool
Some feedback is not a property change. "These cards feel cramped next to the pricing table" is a judgement, and the right fix might be a new layout. For that, pin a comment to the element and let the agent work out the how. A good hand-off carries both kinds: exact changes where you know the answer, and pinned notes where you only know the problem.
A short routine
- Open the site on localhost and fix what you can with your hands: spacing, size, colour, type.
- Pin a comment on anything that needs thought.
- Check the page at a phone width before you hand anything over.
- Give the agent one message with everything in it, and review the diff.
One round trip with a complete note is faster than six with vague ones, and it leaves your design tokens intact.