r/aipromptprogramming • • Oct 08 '26

Giving coding agents visual context from the app they are editing

I’m building Monad Design to reduce a recurring prompt-engineering problem in UI work: a screenshot plus “move this a little” rarely tells an agent which runtime element, source file, hierarchy, or state is actually involved.

The tool lets you select or annotate UI in a running native app, packages that visual/runtime context for the coding agent, and keeps the implementation loop in the real Xcode or Expo project: edit source, rebuild, compare.

Repo: https://github.com/Monadix-AI/monad-design Video preview: https://watchclueso.com/embed/pio8jqfcg4ivj0r1

Disclosure: I’m building it. What visual context do you currently add to prompts when an agent gets the layout almost right but not quite?

2 Upvotes

4 comments sorted by

•

u/endofthread-bot Oct 08 '26

To bridge the gap between visual intent and code, include the relevant component's computed style properties or the specific layout constraints alongside your screenshot. This provides the agent with the precise technical parameters needed to resolve layout discrepancies.

Writing prompts that actually work is easier when you can compare notes with people who have tested them across real tasks. Trade techniques, get feedback on your approach, and see what is working for others in our Discord.

Self-promotion is now allowed on Sundays with the appropriate flair, for all regular contributing members. Contribute during the week, and promote on Sunday.

1

u/[deleted] Oct 08 '26

[removed] — view removed comment

1

u/ivanzhaowy Oct 08 '26

I’m using Accessibility IDs, it has a tree but not as accurate as the component tree. In theory, this approach isn’t perfect in terms of either accuracy or efficiency, but in practice, mobile UI hierarchies tend to be relatively simple, so it works well enough for modern models, they are smart enough to find the right code.

I’m also considering introducing an SDK that would instrument views with additional metadata in debug builds to get real component identifies and tree sturcture. That said, I’d prefer to start with a non-invasive solution, let people try it, and gather feedback first.