sourcelens
The latest research on any topic, in one catalogue.
Give it a topic. It searches PubMed, Europe PMC, arXiv and OpenAlex, downloads the open-access full texts with their figures and supplementary files, finds the code the papers link to, and keeps everything in one table, oldest first. Run it again later and it adds only what is new.
Install
pip install sourcelensor the Go binary for this computer, on Linux and macOS:
curl -fsSL https://raw.githubusercontent.com/bhagesh-h/sourcelens/main/install.sh | shon Windows, in PowerShell:
irm https://raw.githubusercontent.com/bhagesh-h/sourcelens/main/install.ps1 | iexor with Go:
go install github.com/bhagesh-h/sourcelens/cmd/sourcelens@latestPython 3.10 or newer. The macOS file runs on Apple silicon and Intel.
The binaries are not signed: if macOS blocks one downloaded in a browser, run
xattr -d com.apple.quarantine sourcelens.
Use
# once: the literature services ask for a contact address
sourcelens config set contact_email you@example.org
# start a catalogue; the same command later adds what is new
sourcelens "CRISPR base editing"
# the last month, or references for Zotero and LaTeX
sourcelens query --topic "CRISPR base editing" --range 1m
sourcelens export --topic "CRISPR base editing" --format BIB --out crispr.bibLook first, then download only what you pick:
sourcelens "CRISPR base editing" --dry-run
sourcelens query --topic "CRISPR base editing" --in reports/dryrun_<stamp>.csv --summary "off-target" --out picked.csv
sourcelens download --topic "CRISPR base editing" exports/picked.csv
sourcelens files --topic "CRISPR base editing" --ext xlsx,csv --copy-to ~/tablesCommas and OR separate alternatives, every word of an alternative
is required, and quotes keep a phrase: sourcelens '"base editing", "prime editing"'.
- --range 1m, --from 2024
- how far back to search (a new topic starts 12 months back)
- --types papers
- metadata only, no downloads
- --sources pubmed,arxiv
- only these sources
- --ext xlsx,pptx
- attachment file types to download
- --dry-run
- metadata and a table of what could be downloaded, no downloads
Each topic gets a folder under ~/sourcelens with
progress.csv (one row per paper, preprint, repository or website),
the full texts and attachments, and after every run a report: one page with
the numbers and a searchable table of the catalogue.