✨ Bound agent visual context#316
Merged
Merged
Conversation
Give agents one reviewable evidence queue with API-backed status, assets, review state, and Honeydiff context. Keep raw context lossless and make deeper inspection explicit through executable CLI commands.
Document why the evidence queue preserves server authority, selects across groups, distinguishes failed captures, and keeps raw diagnostics opt-in.
Robdel12
marked this pull request as ready for review
July 22, 2026 03:20
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
The compact build handoff could still overwhelm an agent with duplicated group trees while also hiding the render and Honeydiff facts needed to explain a visual change. Worse, it filled missing status and summary fields with client-authored booleans and zeroes, so unknown API state could look authoritative.
Approach
This makes the compact contract one bounded, 10-record evidence queue. Failed captures come first, then comparison variants are selected breadth-first in API order so one screenshot cannot crowd out the rest. Each record keeps its small group summary, review state, current/baseline/diff URLs, render metadata, and compact Honeydiff projection. Raw region geometry remains opt-in through
--include diffs.The API remains the source of truth for status, summaries, review facts, and analysis values. Raw JSON and
--agent --fullstill return the API response unchanged. The compact request asks fordetails=summaryby default anddetails=diffsonly when requested.This deliberately replaces generic
next_actionsprose with executablesuggested_commandsfor comparison context, screenshot history, raw diff diagnostics, and the full build when evidence was truncated.Evidence
Coverage exercises grouped and legacy response shapes, reviewed groups, failed captures, explicit includes, raw/full pass-through, and bounded breadth-first selection. A real CLI process talks to a loopback API to verify the requested detail level and confirms that raw Honeydiff regions only appear on the explicit diff path. The full 2,312-test suite, lint, formatting, type definitions, and production build are clean.
Risk
The compact agent JSON contract changes by removing
next_actions. That is intentional: these consumers can follow concrete CLI commands, and keeping both fields would preserve vague client-authored guidance we no longer want.