Escape-hatch documentation for the agent-caret/highlight/review slice (grilled 2026-07-08), so it can be cleanly reverted if the character-exact application or the review gate causes trouble. Commits on feature-collab-with-agents will be listed here once shipped.
What the change does (and what a revert restores)
| Area |
With this change |
After revert |
Agent md edit application (@aep/collab-doc) |
y-prosemirror updateYFragment minimal diff; inserted ranges formatted with the agentInsertion mark; caret relative-position returned |
Whole-fragment reparse (delete-all + markdownToFragment), no marks, no caret — the #128 v1 behavior |
Agent presence (services/agents room peer) |
Publishes awareness cursor at its last insertion (CollaborationCaret renders it) |
Avatar-only presence, no caret |
Committer (services/collab) |
Interim flushes SKIP md files with pending agentInsertion marks; forced flush on beforeUnloadDocument commits regardless (accept-by-default) |
Every flush commits all changed files immediately (#133 behavior) |
Console (SpecMdEditor) |
Registers the shared mark + highlight styling; review bar (Accept all / Reject all) + per-range bubble menu |
Plain editor; unknown-mark content in a live doc would ERROR in the editor schema — see revert order below |
Schema (@aep/collab-doc markdown manager) |
AgentInsertion mark in the shared schema; markdown serializer passes it through (committed md stays clean) |
Mark absent from schema |
Revert procedure
- Revert the commits listed below (they will be scoped to this slice;
git revert in reverse order).
- Ordering caveat: live rooms may still hold docs containing
agentInsertion attributes. Reverting the console/schema first would make the editor/serializer meet unknown marks. Safe sequence: restart collab-server AFTER the revert deploy (rooms die, docs reseed from clean git markdown — marks never persist to git by design, so a reseed is always clean).
- Nothing to migrate in git history: committed markdown never contains marks; the review gate only delays flushes, so at most one pending session's edits flush late.
Why it might need reverting (watch for)
updateYFragment diff pathologies (structure-heavy edits producing bad merges or duplicated nodes).
- The review hold-out starving commits (a file stuck unreviewed for a whole session while other edits pile up behind the gate).
- Markdown serializer mishandling the passthrough mark (marks leaking into committed markdown, or serialization errors in the committer).
Related: #86 (design comments: agent-edit application + reviewable additions), #133 (committer semantics this modifies), #130 (chat panel that triggers agent edits).
Escape-hatch documentation for the agent-caret/highlight/review slice (grilled 2026-07-08), so it can be cleanly reverted if the character-exact application or the review gate causes trouble. Commits on
feature-collab-with-agentswill be listed here once shipped.What the change does (and what a revert restores)
@aep/collab-doc)y-prosemirrorupdateYFragmentminimal diff; inserted ranges formatted with theagentInsertionmark; caret relative-position returnedmarkdownToFragment), no marks, no caret — the #128 v1 behaviorservices/agentsroom peer)cursorat its last insertion (CollaborationCaret renders it)services/collab)agentInsertionmarks; forced flush onbeforeUnloadDocumentcommits regardless (accept-by-default)SpecMdEditor)@aep/collab-docmarkdown manager)AgentInsertionmark in the shared schema; markdown serializer passes it through (committed md stays clean)Revert procedure
git revertin reverse order).agentInsertionattributes. Reverting the console/schema first would make the editor/serializer meet unknown marks. Safe sequence: restartcollab-serverAFTER the revert deploy (rooms die, docs reseed from clean git markdown — marks never persist to git by design, so a reseed is always clean).Why it might need reverting (watch for)
updateYFragmentdiff pathologies (structure-heavy edits producing bad merges or duplicated nodes).Related: #86 (design comments: agent-edit application + reviewable additions), #133 (committer semantics this modifies), #130 (chat panel that triggers agent edits).