> For the complete documentation index, see [llms.txt](https://wong-coupon.gitbook.io/flutter/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://wong-coupon.gitbook.io/flutter/my-ai/ai-editing.md).

# AI Editing

Review AI diffs, validate proposals, resolve conflicts, and edit documents or Canvas through explicit contracts.

Review AI diffs, validate proposals, resolve conflicts, and edit documents or Canvas through explicit contracts.

## Articles

* [Render AI Diffs Safely in TipTap](/flutter/my-ai/ai-editing/tiptap-prosemirror-decoration-ai-diff.md) — Project AI diffs into decorations with local identities, post-mapping review states, and explicit lifecycle cleanup.
* [A Safe State Machine for AI Edits](/flutter/my-ai/ai-editing/apply-reject-focus-undo-state-machine.md) — Fence Apply, Reject, Focus, and Undo with finite states, durable receipts, reconciliation, and exact revision ownership.
* [Safely Rebase AI Suggestions](/flutter/my-ai/ai-editing/rebase-ai-suggestions-conflict-detection.md) — Normalize coordinate spaces, build a conflict graph, and apply independent subsets only when commutativity is proven.
* [Stale AI Proposals: Path, Before, and Revision](/flutter/my-ai/ai-editing/stale-ai-proposal-path-before-revision.md) — Bind proposals to resource capabilities, exact snapshots, and backend CAS while preserving recovery proof when server and local state diverge.
* [Compile Preview Before Keep](/flutter/my-ai/ai-editing/compile-preview-before-keep.md) — Compile proposals into read-only fixed-point artifacts with generation-bound render proof and a one-use Keep permit before backend CAS.
* [Proposal vs. Change Identity in Batches](/flutter/my-ai/ai-editing/proposal-change-identity-batches.md) — Separate proposals, members, and batches with local capabilities, then bind replay, replacement, exact accounting, and terminal state to generation-correct receipts.
* [Versioned Contracts for AI Update, Insert, and Delete Operations](/flutter/my-ai/ai-editing/versioned-ai-update-insert-delete-contract.md) — Version typed operations, atomic batch preflight, and exact revocation without turning AI data into editing authority.
* [Edit Canvas with Typed AI Commands](/flutter/my-ai/ai-editing/typed-canvas-commands-ai-edit.md) — Keep AI out of renderer state with finite commands, compiler capabilities, disposable asset leases, and exactly-once handoff ownership.
* [Render Citations, Charts, and Follow-up Questions](/flutter/my-ai/ai-editing/render-citations-charts-followups.md) — Turn final answers into typed blocks, isolate failures per block, and bind citations, charts, caches, and follow-ups to generation-correct capabilities.

[Buy Me a Coffee](https://buymeacoffee.com/ducmng12g) | [Support Me on Ko-fi](https://ko-fi.com/I2I81AEJG8)
