Repository navigation
feat(ingest): cited-by-me seed — stage the works a researcher's own papers cite (#122) - #124
Merged
Merged
Conversation
…apers cite (#122) arjev ingest --cited-by-me <own-papers.bib>: each own paper (eprint, doi, arXiv id in any field, else an exact-title Semantic Scholar match) has its reference list read from the S2 Graph API (paced, paginated, 429/5xx backoff, optional ARJEV_S2_KEY_FILE). Every cited work with an arXiv id or DOI becomes one staged note (seed: cited) whose why names the citing paper(s); own papers stage as seed: authored. Works already in any root (by arXiv id or DOI) are skipped; unresolved papers and identifier-less works are reported. inspect gains fold cited-by-me.
jacktrnr
force-pushed
the
feat/122-cited-by-me
branch
from
November 6, 2026 02:18
641b614 to
b137532
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #122.
What this does
arjev ingest --cited-by-me <own-papers.bib>seeds the vault from what the researcher's own papers cite.@article,@phdthesis, …). Ids are read fromeprint,doi(URL forms stripped), or anarXiv:<id>printed in any field. Scholar's export puts arXiv ids injournaland rarely includes a DOI.ARXIV:<id>orDOI:<doi>. A paper with no id falls back topaper/search/match, accepted only on an exact normalized-title match; a near miss is rejected and reported.paper/{ref}/referencesis paginated. Requests are paced at about 1/s, 429 and 5xx responses get backoff, and an optionalARJEV_S2_KEY_FILEsetsx-api-key. Every network call goes through an injectedhttp_transport.seed: cited), itswhy:naming the citer:Cited in your paper “…” — seeded <date>.seed: authorednotes.doi:notes, which the fold already treats as identity-bearing.arjev inspectgainsfold cited-by-me: <n> (<a> authored, <c> cited), printed only when the seed has written notes, so existing exact-line tests are unchanged.Why Semantic Scholar: its reference rows carry
externalIds(ArXiv and DOI) per cited work. OpenAlex returns emptyreferenced_worksfor arXiv preprints (checked live on arXiv:2210.10982). AGENTS.md "External behavior" records this.Live check (not in CI)
Run against my 4 Google Scholar papers (two journal articles without a DOI in the export, the Nonlinearity paper, and the arXiv preprint) into a temp vault:
On the re-run, 0 were seeded and 176 were already in the vault, and the file count was unchanged.
Acceptance criteria (#122)
seed: authored/seed: cited).rerun_new_notes == 0, tested across a date change).unreported_unresolved == 0). API failures fail open per paper.inspectreports the seed's identity-bearing count.Tests
tests/test_cited.pyhas 17 tests using a recorded-shapehttpx.MockTransport, with no network. The full suite andruff check .are green, with one exception:test_init_template::test_no_lab_name_anywhere_in_the_templatefails locally because my clone path contains "harmoniqs". It passes from a neutral path, and CI is unaffected.Notes for review
status: stagedwith a provenancewhy:, the same "touched" contract the BibTeX, PDF and Slack seeds use. ADRs 0001 and 0002 are unaffected.PaperNotegains an optionalseedfield read from frontmatter. Persisted state schemas are untouched.## UnreleasedCHANGELOG section. Whichever merges second needs a trivial conflict resolution there.