internetarchive / internetarchive/openlibrary

Warn librarians when a proposed author merge could refer to different people

Open
#10,501 1 comment 0 reactions 0 assignees View on GitHub
Lead: @cdrini Module: Authors Module: Merge Queue Module: Merging Needs: Breakdown Needs: Response Priority: 3 Type: Feature Request
Dominant language
Python
Stars
6.7k
Forks
2k
Avg merge
2d 19h
Merged PRs (30d)
138

Description

### Feature Request

### Problem / Opportunity
There's many cases where authors who are different people have the same name. When an author merge is proposed, there should be a warning that tells the librarian when this might possibly be the case.

### Proposal
Build an automatic Wikidata search into the author merge page that finds authors by name. If there is more than one hit, display a message on the page to warn the librarian that there's a possibility that the merge request could merge different individuals.

Caveats:
- Authors with multiple names/aliases
- Wikidata rate limiting. (Only librarians will have access to this page, so it's unlikely, but firing too many WD queries in quick succession is something we have to account for. See the wikisource import script for an example of how it is handled there)

### Breakdown

### Related files
TBD

### Requirements Checklist
Checklist of requirements that need to be satisfied in order for this issue to be closed:
* An author merge request page should always show a warning when the author in question could refer to one of several people. This warning is triggered by a Wikidata search returning more than one row.

### Stakeholders
@cdrini
@Spaarsh
@Freso
@seabelis
@pidgezero-one


### Instructions for Contributors

* **Before** [creating a new branch](https://github.com/internetarchive/openlibrary/wiki/Git-Cheat-Sheet#making-changes-and-creating-a-pull-request) or pushing up changes to a PR, please first [run these commands](https://github.com/internetarchive/openlibrary/wiki/Git-Cheat-Sheet#working-on-your-branch) to ensure your repository is up to date, as the pre-commit bot may add commits to your PRs upstream.

Contributor guide

Open the contributing guide

Research direction

Start at the author merge page and locate the existing Wikidata lookup pattern in the wikisource import script, including its handling of rate limiting. Define the search behavior for author names and aliases, then display a warning when the Wikidata search returns more than one row. Done means the merge page consistently warns librarians about possible identity collisions without firing excessive queries.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
backend, frontend
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.