Diff-view toggle: see the operator's own changes vs a coauthoring baseline #17

Closed
opened 2026-06-11 06:44:21 +00:00 by benstull · 1 comment
Owner

Summary

An easy toggle between the current document view and a diff view of the
operator's own changes
against a meaningful coauthoring baseline.

Problem / pain

While coauthoring, the operator can't easily see their own changes as a
diff. The editor shows who owns what text (F3 attribution tinting) and shows
machine changes as diffs before they land (F4 proposals), but the operator's
own contribution is only visible as final text. Git's built-in diff is
against HEAD — the wrong baseline mid-coauthoring-session, where the
meaningful "before" is something like the start of a turn or the last
accepted proposal, not the last commit.

Who feels it

The inner-loop coauthor (PP-1) — first felt by the operator while playing
with the plugin after F5 shipped.

Desired outcome / value

The operator can flip into a diff perspective of their changes and back with
one gesture, making their own contribution as reviewable as Claude's already
is — so that self-review during coauthoring is cheap and the "what did I
actually change?" question never requires git archaeology.

Acceptance — "done right"

A coauthor in a tracked document can toggle (command and/or keybinding)
between the normal editor and a diff of their changes against a baseline
that makes sense for coauthoring, and back, without losing editor state.
What the baseline is — and how it's chosen or shown — is for the design to
settle.

Scope / non-goals

Deliberately vague — scope is the brainstorming session's job. Open
questions parked there rather than answered here:

  • What is the baseline? (turn start · last accepted proposal · last save ·
    session start · operator-pinned moment — or several, selectable?)
  • Where does the baseline snapshot live? (sidecar? gitignored cache?
    in-memory only?) — interacts with the cross-rung contract (INV-14/15) if
    it touches the sidecar.
  • Whose changes does the diff show — just the operator's, or any author's,
    filtered? (F3 attribution knows ownership but is state-not-history.)
  • Relationship to git's own diff/timeline features — complement, not
    duplicate.

Non-goals (firm): replacing git history; a general-purpose diff tool;
changing how proposals render (F4 already shows machine diffs).

Assumptions · constraints · dependencies

  • Builds on the shipped inner loop (F2 #4 · F3 #6 · F4 #12 · F5 #14); Epic
    #1 is closed, so this is the first post-epic UX feature.
  • F3 attribution is state, not history — it cannot reconstruct
    before-text on its own; some form of baseline snapshot is implied.
  • If any persisted artifact touches .threads/, it must conform to the
    cross-rung contract (additive, INV-15/16).

Source / signal

Operator request while playing with the plugin at the end of session 0015
(transcript sessions/0015/, "Operator question (open)"); sketch recorded in
project memory f5-cross-rung-shipped. Filed from capture session
vscode-cowriting-plugin-0016.

Priority (WSJF)

Value M · Time-criticality L · Opportunity M ÷ Size M → provisional P2
(UX improvement, nothing blocked on it).

Solution notes (optional — NOT a design)

Non-binding sketch from the originating conversation: baseline snapshot +
virtual-document provider + a cowriting.toggleDiffView command flipping
vscode.diff ↔ normal editor. All of it up for grabs in the design.

<!-- Set the type/* label: type/feature --> ## Summary An easy toggle between the current document view and a **diff view of the operator's own changes** against a meaningful coauthoring baseline. ## Problem / pain While coauthoring, the operator can't easily *see* their own changes as a diff. The editor shows who owns what text (F3 attribution tinting) and shows machine changes as diffs before they land (F4 proposals), but the operator's own contribution is only visible as final text. Git's built-in diff is against HEAD — the wrong baseline mid-coauthoring-session, where the meaningful "before" is something like the start of a turn or the last accepted proposal, not the last commit. ## Who feels it The inner-loop coauthor (PP-1) — first felt by the operator while playing with the plugin after F5 shipped. ## Desired outcome / value The operator can flip into a diff perspective of their changes and back with one gesture, making their own contribution as reviewable as Claude's already is — so that self-review during coauthoring is cheap and the "what did I actually change?" question never requires git archaeology. ## Acceptance — "done right" A coauthor in a tracked document can toggle (command and/or keybinding) between the normal editor and a diff of their changes against a baseline that makes sense for coauthoring, and back, without losing editor state. What the baseline is — and how it's chosen or shown — is for the design to settle. ## Scope / non-goals **Deliberately vague — scope is the brainstorming session's job.** Open questions parked there rather than answered here: - What is the baseline? (turn start · last accepted proposal · last save · session start · operator-pinned moment — or several, selectable?) - Where does the baseline snapshot live? (sidecar? gitignored cache? in-memory only?) — interacts with the cross-rung contract (INV-14/15) if it touches the sidecar. - Whose changes does the diff show — just the operator's, or any author's, filtered? (F3 attribution knows ownership but is state-not-history.) - Relationship to git's own diff/timeline features — complement, not duplicate. **Non-goals (firm):** replacing git history; a general-purpose diff tool; changing how proposals render (F4 already shows machine diffs). ## Assumptions · constraints · dependencies - Builds on the shipped inner loop (F2 #4 · F3 #6 · F4 #12 · F5 #14); Epic #1 is closed, so this is the first post-epic UX feature. - F3 attribution is **state, not history** — it cannot reconstruct before-text on its own; some form of baseline snapshot is implied. - If any persisted artifact touches `.threads/`, it must conform to the cross-rung contract (additive, INV-15/16). ## Source / signal Operator request while playing with the plugin at the end of session 0015 (transcript `sessions/0015/`, "Operator question (open)"); sketch recorded in project memory `f5-cross-rung-shipped`. Filed from capture session vscode-cowriting-plugin-0016. ## Priority (WSJF) Value M · Time-criticality L · Opportunity M ÷ Size M → provisional **P2** (UX improvement, nothing blocked on it). ## Solution notes (optional — NOT a design) Non-binding sketch from the originating conversation: baseline snapshot + virtual-document provider + a `cowriting.toggleDiffView` command flipping `vscode.diff` ↔ normal editor. All of it up for grabs in the design.
benstull added the type/featurepriority/P2 labels 2026-06-11 06:44:21 +00:00
Author
Owner

Shipped in PR #18 (session 0018): diff-view toggle against a machine-landing-anchored baseline (INV-18), pin gesture, baseline in workspace storage not the repo (INV-19). Unit (BaselineStore) + host E2E green, no LLM in CI. Spec: vscode-cowriting-plugin-content/specs/coauthoring-diff-view.md.

Shipped in PR #18 (session 0018): diff-view toggle against a machine-landing-anchored baseline (INV-18), pin gesture, baseline in workspace storage not the repo (INV-19). Unit (BaselineStore) + host E2E green, no LLM in CI. Spec: vscode-cowriting-plugin-content/specs/coauthoring-diff-view.md.
Sign in to join this conversation.