The default bibtex exports from Semantic Scholar(S2) libraries do not include DOIs, which is problematic for some. This simple CLI app scratches that itch for you. It creates a new bibtex file with the missing DOIs. You may find it useful to ask Zotero SciHub plugin to fetch PDFs or find citation counts (with other plugins).
![image](https://private-user-images.githubusercontent.com/1910117/294233616-35a100ad-5307-4142-a6fb-e96cb2bd8049.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTkwNTY5MDgsIm5iZiI6MTcxOTA1NjYwOCwicGF0aCI6Ii8xOTEwMTE3LzI5NDIzMzYxNi0zNWExMDBhZC01MzA3LTQxNDItYTZmYi1lOTZjYjJiZDgwNDkucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI0MDYyMiUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNDA2MjJUMTE0MzI4WiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9NDcyZTYwZTM0ODViNGE3YmVmMjIyYzk1MmZkZDMzOTc5NjkyYzdjZjIxMzVjYzdjMDM0MGJiNWFiNGZlZDIxZSZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QmYWN0b3JfaWQ9MCZrZXlfaWQ9MCZyZXBvX2lkPTAifQ.N9wYvExQ0ejGnOgqc1MDVADQ6nAscEwGppI60ydUxa0)
- Install the deps
pip install -r requirements.txt
- Run in CLI
python doi_lookup.py my_semantic_scholar_exported.bib
- Check the results.
We basically use the official S2 API to fetch full information with the S2-assigned CorpusId
number. The basic lookup quota is pretty generous and should suffice most library sizes.