How to Get an AI Agent to Read Review Comments and Update the Document
Display is our product. An artifact is one HTML or Markdown file that Display publishes at its own link. We checked the vendor facts on each vendor's own pages on 16 October 2026.
Display is our product. An artifact is one HTML or Markdown file that Display publishes at its own link. We checked the vendor facts on each vendor's own pages on 16 October 2026.
The loop in five steps
Your agent does these steps through the Display MCP server. The tool name is in each step. Details: Review comments and MCP tools.
1. List the open discussions. The agent calls list_comments with subject_type: "artifact" and short_id. The default status is open. The agent can also ask for resolved threads, or only for threads with new activity since a date.
2. Read the current version and find the passage. The agent calls get_metadata, search and read. get_metadata returns the current version number and the open threads. The agent needs the version number for step 3.
3. Change the exact passage. The agent calls edit with short_id, base_version, old_text and new_text. The old text must occur exactly once. The call publishes a new version at the same link. For a larger change, the agent calls the MCP publish tool with the same short_id and the base_version. You can tell it: "Update the page at the same link."
If someone else updated the artifact first, the call stops with a version conflict. The agent reads the newer version, applies the change to it and tries again.
4. Reply to the discussion. The agent calls add_comment with parent_id set to the root comment ID. A reply uses the anchor of the root comment, so the agent sends no anchor.
5. Resolve the thread. The agent calls resolve_thread with comment_id. It uses the root comment ID from step 1. Any signed-in person with view access can reopen a resolved thread. The agent uses reopen_thread for that.
The prompt
This prompt from Review comments does all five steps:
Find the Display.dev artifact named Quarterly plan. Review its open discussions, make
the requested changes when they are clear, reply with what changed, and resolve only
the discussions you addressed. Return the updated link and list anything that still
needs my decision.What the agent must leave open
Give the agent a rule for what it must not resolve. Add these lines to the prompt:
- A comment that asks a question the agent cannot answer from the document.
- Two comments that ask for opposite changes.
- A change to a number, a price, a date, a name or a legal statement that the agent cannot check.
- A comment about tone or design that has more than one valid answer.
For these, the agent replies with what it found and what it needs. It does not resolve the thread. The person who owns the decision resolves it.
Get notified about new comments
A signed-in person selects the eye icon (Watch this artifact) in the Discussions panel to get comment notifications. The MCP tool is watch. Watches are for each user. They work for people and for agents with a user credential. An organization-scoped service key cannot watch, and the only comment tool it can use is list_comments. Use a user credential for the full loop.
How other tools do the same loop
| Tool | Who can comment | Agent can read comments | Comments tied to a version |
|---|---|---|---|
| Vercel preview comments | Team members. Pro and Enterprise can invite external users. All commenters need a Vercel account | Vercel documents a CLI for comments | Each comment is on a preview deployment |
| Stacktree client feedback | Clients, without an account | Yes. Its agent can read the feedback and resolve it | Yes |
| Display | Organization members with access. Invited outside guests cannot comment yet | Yes. MCP tools read, reply and resolve | Yes. Each discussion records its starting version |
Google Docs and Notion also have comments that you can resolve.
The limit for outside guests
Outside guests can view but cannot comment.
You can invite a client by email. The client opens the artifact with a one-time password and reads it. The client cannot leave a comment. Collect client feedback in a call or a message, and ask a colleague to post it as a comment. Guest comments are on the roadmap. On Pro and Enterprise, an Owner can also restrict outside sharing for the whole organization.
When another tool is better
- The reader edits the text in a word processor. Google Docs has co-editing and suggestions. Display comments do not replace them.
- You review a design, not a document. Figma comments are on the design file. Anyone with view access to a Figma file can comment.
- The prototype is a running app. Vercel preview comments are on the running preview.
FAQ
Which MCP tools does the agent need?
list_comments, add_comment, resolve_thread, get_metadata, read, search, and edit or publish. The authenticated server is at https://api.display.dev/v1/mcp. On Claude, add Display from Claude's connector directory. For other agents, read Publish with your agent.
Does an update erase the comments?
No. Each discussion records the passage and the version where it started. If the passage is not in the current version, the reader selects Open that version to see the original context.
Can the agent post a new comment on a passage?
Yes. A new root comment needs an anchor: the quoted text with the text around it, and a CSS path. Most agent loops need only replies. Read the add_comment input in MCP tools.
Can a person fix a small error without the agent?
Yes. Anyone who can edit the artifact can fix a line in the page in the browser. Read Edit an artifact in your browser.
Does the agent resolve a thread by itself?
Only if you tell it to. The prompt above tells it to resolve only the discussions that it addressed.
How long can a comment be?
Through MCP, a comment body can hold up to 10,000 characters. In the browser, a text selection for a new comment can hold up to 1,024 characters.
Free tier. No credit card. One-time password auth for viewers on free, Google + Microsoft SSO on Pro (€49/month flat).