docs: plan precise text-range review anchors

This commit is contained in:
Valdemar Lorenzen
2026-10-16 14:39:02 +02:00
parent 2376a37e5d
commit 9a24302b4e
+7
View File
@@ -6,6 +6,13 @@
- save and reopen reviews using local files that coding agents can read; no server or client/server protocol.
- anchor comments to immutable revision IDs, paths, sides, and source line ranges, never screen coordinates or mutable file indices.
- preserve original anchors and mark comments stale when the reviewed snapshot no longer matches; defer automatic reanchoring.
- [ ] diff view: attach local review comments to arbitrary contiguous text ranges, not only containing lines.
- preserve exact start/end source positions in grapheme coordinates with an exclusive end, including partial-line and multiline selections on either diff side.
- characterwise Visual (`v`) anchors the exact selected text; Visual Line (`V`) anchors whole selected lines; no selection retains current-line behavior.
- retain gutter markers for discovery and highlight the exact anchored text when its comment is selected.
- preserve immutable snapshot identity and existing stale detection; never silently reanchor comments after source changes.
- persist precise ranges in SQLite and JSON import/export; migrate existing line-only anchors without losing comments.
- future GitHub publishing may map precise local anchors to supported line ranges without reducing precision in the local review.
- [ ] persist local reviews automatically in a local SQLite database using rusqlite; no server, hosted storage, or synchronization.
- keep one database under $XDG_DATA_HOME/vamp/reviews/, falling back to ~/.local/share/vamp/reviews/; allow a configurable review_directory.
- key reviews by repository identity and persistent review ID, preserving reviews and stale comments across revision changes.