Closed gtsueng closed 3 years ago
I suggest not validating @ JSON-LD properties, that is a JSON-LD thing that we cannot change. Will dct:conformsTo also be a problem?
dct:conformsTo
should be expanded to http://purl.org/dc/terms/conformsTo
; if dct:conformsTo
is used then it must have been declared in the context file of the markup.
While you won't be able to add dct:conformsTo
via the DDE UI, you can edit the json schema as seen here, and it will render fine in the DDE schema viewer.
We can work around the issue involving dct:conformsTo
by including it in the bioschemas json specification merging script, and it will be viewable within the DDE viewer.
With regards to the @ JSON-LD properties, @id
, @type
, etc--Even without including them in the validation, treating them as properties will render a schema unviewable by the DDE since the DDE conforms to schema.org naming requirements for properties. @newgene @marcodarko What do you think would be the best way of dealing with this?
Based on discussions with the DDE team, @id
, @type
, and @context
will not be allowable as explicit properties via the DDE since these are jsonld requirements and not schema requirements. Instead, it should be made clear to schema adopters that they need to include these 3 properties if they are using jsonld. The dct:conformsTo
is the adoption/reuse of a non-schema.org property which will not be generated within the DDE; rather, it will be generated for profiles via script, and will be viewable via the DDE.
dct:conformsTo addressed in https://github.com/BioSchemas/bioschemas-dde/commit/0ac06df5ee3c5a3de0d8c95532041a1242d6f4e8
Per discussion with DDE team, @type
, @id
, and @context
are requirements of jsonld not schema.org and will not be addressed by the DDE UI.
Note, this is NOT an issue just yet, but may become one in the near future. Bioschemas intends to automatically add
@type
,@id
,@context
, anddct:conformsTo
as required properties to all of its profiles as discussed here and here.While I can create these properties for a class within the schema editor:
and I can even edit the validation for said property:
Once I save the newly-created schema to Github, it cannot be loaded into the schema viewer due to the property having an unconventional name:
Suggestions on the best way to handle this issue? We can continue as is and create the schema profiles without these properties, but this would mean that the profiles displayed in the DDE might not match those displayed in Bioschemas resulting in two sets of profiles that would need to be maintained by Bioschemas, when they are looking at DDE as being a potential solution for profile creation and maintenance.