diff options
author | Bryan Newbold <bnewbold@archive.org> | 2021-11-10 16:47:03 -0800 |
---|---|---|
committer | Bryan Newbold <bnewbold@archive.org> | 2021-11-10 16:47:03 -0800 |
commit | c164970449a392b5165d903d213c2bb51f2a187f (patch) | |
tree | 917de69bef051e211c38018e8d91950d7cae2f71 /fatcat_scholar | |
parent | 36ddc22358614be5c38f230594f6f83e19f4ad96 (diff) | |
download | fatcat-scholar-c164970449a392b5165d903d213c2bb51f2a187f.tar.gz fatcat-scholar-c164970449a392b5165d903d213c2bb51f2a187f.zip |
pull GROBID refs along with crossref records into bundles
Diffstat (limited to 'fatcat_scholar')
-rw-r--r-- | fatcat_scholar/sandcrawler.py | 4 | ||||
-rw-r--r-- | fatcat_scholar/work_pipeline.py | 1 |
2 files changed, 4 insertions, 1 deletions
diff --git a/fatcat_scholar/sandcrawler.py b/fatcat_scholar/sandcrawler.py index 087cdc6..9b016f5 100644 --- a/fatcat_scholar/sandcrawler.py +++ b/fatcat_scholar/sandcrawler.py @@ -40,7 +40,9 @@ class SandcrawlerPostgrestClient: return None def get_crossref(self, doi: str) -> Optional[Dict[str, Any]]: - resp = requests.get(self.api_url + "/crossref", params=dict(doi="eq." + doi)) + resp = requests.get( + self.api_url + "/crossref_with_refs", params=dict(doi="eq." + doi) + ) resp.raise_for_status() resp_json = resp.json() if resp_json: diff --git a/fatcat_scholar/work_pipeline.py b/fatcat_scholar/work_pipeline.py index 5c32767..ea4b0a4 100644 --- a/fatcat_scholar/work_pipeline.py +++ b/fatcat_scholar/work_pipeline.py @@ -252,6 +252,7 @@ class WorkPipeline: release_ident=re.ident, doi=doi, record=crossref_meta["record"], + grobid_refs=crossref_meta["refs_json"], ) def lookup_sim(self, release: ReleaseEntity) -> Optional[SimIssueRow]: |