Skip to content

feat(web): flag Ask citations whose code changed since the answer#1399

Merged
whoisthey merged 3 commits into
whoisthey/pin-citation-commit-shafrom
whoisthey/ask-citation-staleness-hint
Jun 30, 2026
Merged

feat(web): flag Ask citations whose code changed since the answer#1399
whoisthey merged 3 commits into
whoisthey/pin-citation-commit-shafrom
whoisthey/ask-citation-staleness-hint

Conversation

@whoisthey

@whoisthey whoisthey commented Jun 29, 2026

Copy link
Copy Markdown
Contributor

Stacked on #1397. Adds a per-citation freshness hint: /api/source/freshness compares a pinned commit to the repo's current default-branch tip (file-level blob comparison), and the evidence panel shows a badge when the cited file has changed / removed / pinned_unavailable, with a "View latest" link. Also resolves a citation to a pinned source when multiple tools sourced the same file in one turn.

Scope: panel-only (no inline-chip dots or answer rollup yet); list_tree/get_diff remain unpinned.

(removed the "view latest" button from these two, but here's what the badges look like for the other two statuses (not included in the screenrecording)

Screenshot 2026-06-29 at 2 19 13 PM Screenshot 2026-06-29 at 2 19 27 PM
Screen.Recording.2026-06-29.at.2.37.11.PM.mov

Adds a per-citation freshness check: a `/api/source/freshness` endpoint
compares a pinned commit against the repo's current default-branch tip
(file-level blob comparison) and the evidence panel renders a badge when the
cited file has changed, was removed, or its pinned commit is gone, with a
link to the latest version. Also resolves citations to a pinned source when
multiple tools sourced the same file in one turn.

Co-authored-by: Cursor <cursoragent@cursor.com>
@coderabbitai

coderabbitai Bot commented Jun 29, 2026

Copy link
Copy Markdown
Contributor

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 5f28c471-b453-45ed-b25a-04447c61ed87

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch whoisthey/ask-citation-staleness-hint

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Co-authored-by: Cursor <cursoragent@cursor.com>
@whoisthey whoisthey marked this pull request as ready for review June 29, 2026 21:47
@whoisthey whoisthey merged commit cbfcfa4 into whoisthey/pin-citation-commit-sha Jun 30, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant