Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
Already on GitHub? Sign in to your account
Implement ID/CURIE<->URI expansion and contraction #14
Comments
|
@cmungall anything missing from the interface specified here? One thing I see is maybe passing a collection of identifiers to expand all at once, getting back a Map with the results. Any thoughts on the type vs. value nuances for expansion? (e.g. monarch-initiative/owlsim-v3#24 (comment)) Enforcing that distinction is where my code deviates somewhat from ROBOT. I think it would be easy to add a function for creating a JSON-LD context from a simple YAML prefix map. |
|
For the general purpose module @jguyenx is writing we'd want to avoid all the JSON-LD edge cases and have a straightforward transform that is independent of where we are in the document. I think your code is a good starting point, we may be able to reuse it directly |
jnguyenx
commented
Dec 6, 2016
|
Here's my first draft: Let me know what you think. |
jnguyenx
commented
Dec 10, 2016
jnguyenx
commented
Dec 14, 2016
|
Pushed to Maven Central: |
cmungall commentedNov 22, 2016
We want to be able to expand and contract URIs using either a simple yaml curie map or a JSON-LD file. The latter provides certain advantages such as being a standard, and also allow recursive application of rules.
Doing this using a yaml map should be very easy. However, we end up implementing this code multiple times, it might be worth abstracting this into a separate java library. This could live in the org.prefixcommons space. Having a common library might be useful in other ways - e.g. centralization of validation etc.
These are some places where this is already implemented: