You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the CWL schema definition files (like CommandLineTool.yml, Process.yml, etc.) multiple times fields are declared as having the predicate ID rdf:type like so:
fields:
- name: class
jsonldPredicate:
"_id": "@type"
"_type": "@vocab"
For CWL files, which are instances of the CWL schema, this works totally fine and leads to the desired instance-of relation in RDF, e.g. class: CommandLineTool in CWL YAML gets transformed to a cwl:CommandLineTool in RDF.
But if the CWL schema itself is transformed to RDF with SALAD and the metaschema.yml the ID of JsonldPredicate object of the field is tranformed to sld:_id <file:///LOCAL/PATH/TO/CWL-SCHEMA-DIRECTORY/@type>, which is clearly ill-formed and should instead also lead to rdf:type.
According to the SALAD schema definition the _id of JsonldPredicate is resolved according to vocabulary resolution, which starts with link resolution. And as the link resolution rules do not state any special cases for URIs starting with @ the interpretation as relative reference seems legit and leads to the ill-formed predicate IRI.
So in my eyes the CWL schema files must not use '@type' for _id of JsonldPredicates, but instead should use rdf:type (+ rdf namespace definition).
Is this analysis correct and its a bug or have I missed anything from the definitions?
The text was updated successfully, but these errors were encountered:
- name: JsonldPredicate
type: record
doc: |
Attached to a record field to define how the parent record field is handled for
URI resolution and JSON-LD context generation.
fields:
- name: _id
type: ["null", JsonldPredicateIdEnum, string]
jsonldPredicate:
_id: sld:_id
_type: "@id"
identity: true
doc: |
The predicate URI that this field corresponds to.
Corresponds to JSON-LD `@id` directive.
- name: _type
type: ["null", JsonldPredicateTypeEnum, string]
In the CWL schema definition files (like
CommandLineTool.yml
,Process.yml
, etc.) multiple times fields are declared as having the predicate IDrdf:type
like so:For CWL files, which are instances of the CWL schema, this works totally fine and leads to the desired instance-of relation in RDF, e.g.
class: CommandLineTool
in CWL YAML gets transformed toa cwl:CommandLineTool
in RDF.But if the CWL schema itself is transformed to RDF with SALAD and the
metaschema.yml
the ID ofJsonldPredicate
object of the field is tranformed tosld:_id <file:///LOCAL/PATH/TO/CWL-SCHEMA-DIRECTORY/@type>
, which is clearly ill-formed and should instead also lead tordf:type
.According to the SALAD schema definition the
_id
ofJsonldPredicate
is resolved according to vocabulary resolution, which starts with link resolution. And as the link resolution rules do not state any special cases for URIs starting with@
the interpretation as relative reference seems legit and leads to the ill-formed predicate IRI.So in my eyes the CWL schema files must not use
'@type'
for_id
ofJsonldPredicates
, but instead should userdf:type
(+ rdf namespace definition).Is this analysis correct and its a bug or have I missed anything from the definitions?
The text was updated successfully, but these errors were encountered: