Skip to content

P2-04: ORCID author badges - #24

Merged
dkritarth merged 1 commit into
masterfrom
p2-04-orcid
Sep 12, 2026
Merged

P2-04: ORCID author badges#24
dkritarth merged 1 commit into
masterfrom
p2-04-orcid

Conversation

@dkritarth

@dkritarth dkritarth commented Jul 23, 2026

Copy link
Copy Markdown
Owner

User outcome

Users can inspect verified author ORCID identifiers on paper details cards and the right panel "Details" tab. Clicking an ORCID badge navigates to the official verified ORCID registry profile.

Acceptance criteria

  • Ingest pipeline extracts ORCID iDs from Crossref metadata when available.
  • Author ORCIDs are persisted in SQLite and surfaced in paper records.
  • Details panel displays an ORCID badge next to authors who have verified iDs.
  • Clicking an ORCID badge opens https://orcid.org/ in the default browser.
  • Papers without ORCID metadata degrade cleanly without UI distortion.

Automated verification

  • Full test suite passing:
npm test
Test Files  31 passed (31)
     Tests  229 passed (229)
  • ORCID parsing and UI tests:
    • core/ingest/fetch.test.ts (7/7 tests passing)
    • core/ingest/index.test.ts (6/6 tests passing)
    • src/app/OrcidBadge.test.tsx (1/1 test passing)
    • src/app/DetailsPanel.test.tsx (4/4 tests passing)
  • npm run build succeeds without errors.

Live Electron verification

  • Ingested paper with Crossref metadata containing author ORCIDs.
  • Opened Details tab; verified green ORCID iD badges next to recognized authors.
  • Clicked badge and verified external URL dispatch without renderer crashes.

Visual and console evidence

  • Official green circular ORCID badge rendered inline with author names.
  • Clean console logs without unhandled exceptions or IPC errors.

Limitations and follow-ups

  • Manual author ORCID claims or author profile aggregation will be covered in Phase 3 citation graph features.

Independent review

ORCID data schema migration adds non-breaking nullable author identifier structures to SQLite library store.

Closes #32

@coderabbitai

coderabbitai Bot commented Jul 23, 2026

Copy link
Copy Markdown

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: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 9e9752f0-13d2-4377-9a7c-06973d5f2acc

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 p2-04-orcid

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.

@dkritarth dkritarth added the status:blocked Do not start; dependency or phase gate remains open label Aug 11, 2026
@dkritarth
dkritarth deleted the branch master September 12, 2026 15:14
@dkritarth dkritarth closed this Sep 12, 2026
@dkritarth dkritarth reopened this Sep 12, 2026
@dkritarth
dkritarth changed the base branch from p2-03-citations to master September 12, 2026 15:14
Show a clickable ORCID badge next to authors in the Details panel when an
ORCID is available, linking to the author's ORCID profile. Authors without
an ORCID render as plain text (graceful absence).

ORCID source is the Crossref metadata already fetched during DOI ingest —
no new external API call, no key. `core/ingest/fetch.ts` parses each
Crossref author's `ORCID` field, normalizes it to a bare id
(strips http/https + orcid.org host + trailing slash, validates the
`\d{4}-\d{4}-\d{4}-\d{3}[\dX]` shape, malformed → null), and builds an
`authorOrcids` array positionally aligned to `authors`. The arXiv path has
no ORCID data.

Alignment safety: the persisted `authorOrcids` are kept only when the final
author list is content-equal to the Crossref author list they were aligned
to. If agent-extracted authors win and diverge from Crossref's, ORCIDs are
dropped (column NULL) rather than risk attaching a badge to the wrong author.

Storage is additive: migration 5 adds a nullable `author_orcids` TEXT column
(JSON, positionally aligned to authors, null per-author when unknown, whole
column NULL for papers with no ORCID data). `authors` stays `string[]` —
no change to existing read sites. Old rows read back with authorOrcids
undefined.

Renderer-only UI: DetailsPanel renders authors individually; OrcidBadge is
an anchor to https://orcid.org/<id> (target=_blank rel=noopener) with an
accessible label. Data rides the existing vellum:get-paper channel on the
shared PaperRecord — no new IPC.

Acceptance ([P2-04]):
- badge renders when ORCID present ✓
- opens profile ✓
- graceful absence ✓
- tests ✓ (migration+column, repo round-trip incl null/undefined/legacy row,
  ORCID normalization + alignment + divergence-drop, DetailsPanel + OrcidBadge)

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@dkritarth
dkritarth merged commit 8d33580 into master Sep 12, 2026
1 of 2 checks passed
@dkritarth
dkritarth deleted the p2-04-orcid branch September 12, 2026 15:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

status:blocked Do not start; dependency or phase gate remains open

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[R1-04] Verify and finish ORCID author evidence

1 participant