-
Notifications
You must be signed in to change notification settings - Fork 8
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
Generic LDNodes and RO-Crate parsing rework #496
base: main
Are you sure you want to change the base?
Conversation
- Json: parse `@type`/`additionalType` from either string (-> singleton) or array field, always write array - add tests
@floWetzels could you also take a look onto whether #326 is actually fixed or not (e.g. by inspecting a written RO-Crate metadata json) |
I tested the metadata json file generated for the ArcPrototype with the rocrate-validator. I found the following errors that need to be fixed:
Furthermore, I noticed the following when parsing the file manually:
|
Looks a lot better now! The validator accepts the RO-Crate. When looking through the file, I noticed a few more things:
|
I incorporated your suggested fixes and included the test file in d3d786e |
Reworked Generic JSON-LD Objects
This is a generic JSON-LD implementation that represents those aspects of the JSON-LD specification which are relevant for handling ARC-RO-Crate:
LDContext
(Contains mappings from compacted terms to extended IRIs)LDNode
(Our basic objects with@id
, types and fields)LDGraph
(Basically a collection of nodes; Top-level object in the RO-Crate)LDRef
(Object containing only@id
, meant for linking)LDValue
Expanded, self-contextualizing valuesAdded ARC-RO-Crate profile layer
This layer acts like a ARC-RO-Crate view on the generic JSON-LD model. All actual handled objects are either FSharp primitive types or generic JSON-LD objects. Through making use of static methods which in turn use static IRIs, a loose typing is emulated. These static IRI mostly consist of types and properties from schema.org and bioschemas.org.
Added a set of static classes, containing functions for
@id
sFor the following types/profiles:
Added contexts of RO-Crate specification 1.1 and 1.2DRAFT
Added context for all other fields exclusive to the ARC-RO-Crate profile
ARC Scaffold <-> ARC-RO-Crate conversion layer
Added functions for Conversion between Scaffold and RO-Crate representation types.
E.g.
Added top-level members to ARC Scaffold object to parse to and from an RO-Crate JSON-LD metadata string.
To-do:
@id
are empty (LabProtocol)To-do after this PR is merged:
@list
for ordered process inputs and outputscloses #326
closes #400
closes #429
closes #465
closes #494
closes #495