Skip to content
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

JSON-LD archive contents should contain @context specification #13

Closed
bkuczenski opened this issue Feb 24, 2022 · 8 comments
Closed

JSON-LD archive contents should contain @context specification #13

bkuczenski opened this issue Feb 24, 2022 · 8 comments
Assignees

Comments

@bkuczenski
Copy link

JSON-LD spec requires objects to include @context with something resembling the following contents:
"@context":"http://greendelta.github.io/olca-schema/context.jsonld"

https://json-ld.org/
https://github.com/GreenDelta/olca-schema/blob/1ab2f1a52b8a85ab2c81e9fcaaebcbb4db38df20/examples/unit.json

@bl-young
Copy link
Collaborator

have you seen documentation anywhere for what that field is for?

@WesIngwersen
Copy link
Collaborator

They are intended to include a URL or multiple URLs where the terms in the spec are defined. The link used for the olca-schema isn't working. I will post an issue in olca-schema for it.

@bkuczenski
Copy link
Author

It specifies how the entries in the JSON file are to be interpreted, i.e. what the dictionary entries "mean". Essentially, provides a semantic namespace for the keys. Without it, it's just JSON (i.e. not JSON-LD). With it, a reader will know how to interpret the fields. Since the OLCA schema does provide a context, schema-compliant files should use it

@WesIngwersen
Copy link
Collaborator

posted an issue here
GreenDelta/olca-schema#6

@WesIngwersen
Copy link
Collaborator

@bkuczenski I agree that is should be a part of any JSON-LD file but just noting that what the olca schema has created to be that context information is broken on multiple levels.

@WesIngwersen
Copy link
Collaborator

I think what would work for now would just be to use

"@context":"http://greendelta.github.io/olca-schema/"

@bl-young
Copy link
Collaborator

I can plan to add that field to all objects

@bl-young bl-young self-assigned this Feb 24, 2022
@msrocka
Copy link

msrocka commented Feb 24, 2022

fyi: @context is not a required field and openLCA 2 will not write it anymore. It is only required when you want to fully expand the linked data graph with URIs etc. (e.g. define that enumeration values are not just strings but belong to the vocabulary) but then there are other ways to link the context for that.

bl-young added a commit that referenced this issue Mar 25, 2022
- update model name and version
- add source for primary publication `Ingwersen et al. 2022, USEEIO 2.0`
- move source IDs and name to `useeio_sources.yml`
- add context #13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants