-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add etl cli #42
Merged
Merged
Add etl cli #42
Conversation
This file contains 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
ships
force-pushed
the
ships/add-etl-cli
branch
2 times, most recently
from
May 3, 2023 23:56
2164cae
to
9a83b47
Compare
3mcd
reviewed
May 4, 2023
3mcd
approved these changes
May 16, 2023
Looks great to me! Tests look comprehensive enough and I feel I have a good grasp for how it works after your walkthrough. And thank you for adding those comments! |
in prep for merge
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.
Description
This PR adds a CLI tool in typescript that enables creation of docmaps based on an external source of similar data. In this MVP, it will infer docmapsy information from the Crossref API and make several assumptions. The goal will be to extract the upstream adapter as a pluggable component so this CLI becomes generic.
The basic usage can be discovered with
pnpm start help
. It is something like this:Recall that a Docmap's core datapoints are a collection interconnected
steps
. Additional metadata is also included. However the docmap does not explicitly have a "subject" that is a DOI -- this can sometimes be inferred from its ID or its steps.The CLI follows a basic recursive routine: it creates a Step for the identified DOI, and if it has any review articles referring to it, an additional step is included after the main step. Further, if there is a Preprint for the identified DOI, it will recursively invoke this routine and prepend the result to the step list. Once all the Steps are identified they are wired together using
next-step
andprevious-step
in a slightly hacky way to be fed into a Docmap.Related Issues
#37 - Crossref-to-Docmaps
#24 - Example using fp-ts to parse
Checklist
Additional Information
Provide any additional information that might be helpful in understanding this pull request, such as screenshots, links to relevant research, or other context.