Skip to content

Comments and annotations

Notes are hunk-specific and render beside the rows they explain. Hunk intentionally keeps them in the review flow rather than in a separate comments screen.

Terminal window
hunk session comment add \
--repo . \
--file README.md \
--new-line 103 \
--summary "Tighten this wording"

Choose exactly one --old-line or --new-line target. Add --focus only when the new note should move the user's viewport.

Terminal window
printf '%s\n' '{"comments":[{"filePath":"README.md","newLine":103,"summary":"Tighten this wording"}]}' \
| hunk session comment apply --repo . --stdin

Every item needs filePath, summary, and exactly one target: hunk, hunkNumber, oldLine, or newLine. Hunk validates the complete batch before changing the live session.

Terminal window
hunk session comment list --repo .
hunk session comment list --repo . --type all
hunk session comment rm --repo . <comment-id>
hunk session comment clear --repo . --file README.md --yes

Use --all --yes to clear both live agent comments and human notes. Destructive clears require confirmation.

In the TUI, select a hunk and press c or click an add-note affordance. Human and agent notes are labeled by source. Use { and } to move through annotated hunks across the review stream.