Changes for page Application details
Last modified by lzehl on 2021/10/13 13:11
Summary
-
Page properties (1 modified, 0 added, 0 removed)
Details
- Page properties
-
- Content
-
... ... @@ -16,26 +16,19 @@ 16 16 As stated above, openMINDS supports JSON-LD as serialization format for the metadata representations (instances) of its schemas. In the following we will briefly explain the JSON-LD syntax necessary for writing a correct openMINDS instance. 17 17 18 18 (% style="text-align: justify;" %) 19 -Let us first start with the most simple example: the openMINDS core schema ContactInformation. According to its schema template (cf. [[ContactInformation HTML>>https://humanbrainproject.github.io/openMINDS/core/schemas/v3/actors/contactInformation.html||rel="noopener noreferrer" target="_blank"]]), the only required property for a contact information instance is **##"email"##**. However, every valid JSON-LD needs two more technical properties: **##"@type"##** and **##"@id"##**. Here, as example, a valid JSON-LD for a contact information instance:19 +Let us first start with the most simple example: the openMINDS core schema ContactInformation. According to its schema template (cf. [[ContactInformation HTML>>https://humanbrainproject.github.io/openMINDS/core/schemas/v3/actors/contactInformation.html||rel="noopener noreferrer" target="_blank"]]), the only required property for a contact information instance is **##"email"##**. However, every valid JSON-LD needs two more technical properties: **##"@type"##** and **##"@id"##**. 20 20 21 -{{code language="json"}} 22 -{ 23 - "@type": "https://openminds.ebrains.eu/core/ContactInformation", 24 - "@id": "http://localhost/contactInformation/email_openMINDS", 25 - "email": "openminds@ebrains.eu" 26 -} 27 -{{/code}} 28 - 29 29 (% style="text-align: justify;" %) 30 30 To simplify the human-readability for all openMINDS users, technical properties specifically required for the JSON-LD syntax are, on purpose, not defined in the openMINDS schema templates. Instead, these technical properties are first added to the required property list of all openMINDS schemas after their template is transformed into an established, full-blown metadata schema format, such as JSON-Schema (cf. [[Technical details>>Technical details]]). 31 31 32 32 (% style="text-align: justify;" %) 33 -The JSON-LD property **##"@type"##** expects an entry (value) of type string that defines which schema is used to validate the particular JSON-LD. Within openMINDS each schema can be identified through its namespace (type) with the following naming convention: 34 -##"@type": "https:~/~/openminds.ebrains.eu/XXX/YYY"##, where **##XXX##** and **##YYY##** should be replaced with the openMINDS sub-module (e.g., ##core##) and corresponding schema (e.g., ##ContactInformation##), respectively. 25 +The JSON-LD property **##"@type"##** expects an entry (value) of type string that defines which schema is used to validate the particular JSON-LD. Within openMINDS each schema can be identified through its namespace (type) with the following naming convention: 35 35 36 - TheJSON-LD property **##"@id"##** expectsan entry(value) oftypestring that provides a unique identifier for the created metadata instance. On yourlocal machine,youhould usethe following naming conventionforthis identifier:37 -##"@ id": "http:~/~/localhost/YYY/ZZZ"##, where **##YYY##** and **##ZZZ##** should be replaced with the openMINDS schema (e.g., ##ContactInformation##) andyour own collection-unique identifier, respectively.Within theEBRAINS Knowledge Graph (KG) this identifier hasto beauniversally unique identifier (UUID). Assuming you locally generated a openMINDSetadata collection, your user-defined**##"@id"##**will be automatically replaced with a UUIDin all your JSON-LDsif theyare uploaded to the KG..27 +(% style="text-align: justify;" %) 28 +(% class="small" %)##"**@type": "https:~/~/openminds.ebrains.eu/**<//openMINDS-submodule-label//>**/**<//openMINDS-schema-label//>"## 38 38 30 +The JSON-LD property **##"@id"##** expects an entry (value) of type string that provides a unique 31 + 39 39 === The openMINDS Python API === 40 40 41 41 (% style="text-align: justify;" %)