Skip to content

fix(review): describe citation rows for a reference with no DOI - #149

Open
paveljor wants to merge 1 commit into
mainfrom
docs/citation-reference-wording
Open

paveljor wants to merge 1 commit into
mainfrom
docs/citation-reference-wording

Conversation

@paveljor

Copy link
Copy Markdown
Collaborator

What changes

The API's citation check now covers two more kinds of reference: one that no sentence of the draft cites (compared with the page at its own address), and one with no URL or DOI (looked up in the registry by its authors, year and title). The SDK already parses those rows; its wording did not describe them.

  • Docstrings. ReviewCitationCheck said doi_registered, metadata, metadata_differences and registered are "set for a DOI only". It now says when else they are set, and that a page-based mismatch has no metadata_differences and no registered, with the page's title in page_title. ReviewCitationRecord, ReviewCitation, ReviewCitationIssue, ReviewMoreCitation and ReviewSummary.citations_found say that cited_url and doi can both be None.
  • CLI. lenz review printed "Reference details differ" with nothing under it when the API listed no differences. It now prints the page's title under "The page at this address is titled:". A finding with listed differences prints "Your reference says ...; the record says ..." as before.

No model field, method or exit code changed.

Tests

  • tests/test_cli_review.py::test_a_reference_whose_page_is_another_work_shows_the_pages_title.
  • pytest, ruff check, ruff format --check, mypy src.

Not done

  • The Node SDK has the same one-line comment on the record type ("A DOI's record in the registry."); it is not changed here.

Post-deploy actions and prod testing

  • None on its own: the wording ships with the next SDK release (the changelog entry is under Unreleased).
  • After that release: run lenz review with --max-citations on a draft whose reference list has an entry nothing cites, and read the row.

🤖 Generated with Claude Code

The API now checks a reference no sentence cites against its page, and looks
up a reference with no URL or DOI in the registry. The docstrings said the
metadata fields are "set for a DOI only", and the CLI printed a "Reference
details differ" finding with nothing under it when the API listed no
differences (the page at the address is another work).

- Docstrings: ReviewCitationCheck, ReviewCitationRecord, ReviewCitation,
  ReviewCitationIssue, ReviewMoreCitation, ReviewSummary.citations_found.
- CLI: a metadata finding with no differences prints the page's title.

No model field changed.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@paveljor
paveljor requested a review from lenzhq as a code owner November 21, 2026 13:33
@paveljor paveljor self-assigned this Nov 21, 2026

This branch has not been deployed

No deployments
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.

2 participants