From 83072bdfcc9be57f161c5e43f969388be79ca7ed Mon Sep 17 00:00:00 2001 From: Andrew Davison Date: Mon, 18 Mar 2019 14:03:05 +0100 Subject: [PATCH 1/6] Added ModelProject shape --- .../simulation/modelproject/v0.1.0.json | 130 ++++++++++++++++++ 1 file changed, 130 insertions(+) create mode 100644 modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json diff --git a/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json b/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json new file mode 100644 index 00000000..7f12547b --- /dev/null +++ b/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json @@ -0,0 +1,130 @@ +{ + "@context": [ + { + "imports": { + "@id": "owl:imports", + "@type": "@id", + "@container": "@set" + }, + "owl": "http://www.w3.org/2002/07/owl#" + }, + "https://nexus-int.humanbrainproject.org/v0/contexts/nexus/core/resource/v0.3.0", + "https://nexus-int.humanbrainproject.org/v0/contexts/neurosciencegraph/core/schema/v0.1.0", + { + "this": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/simulation/modelproject/v0.1.0/shapes/" + } + ], + "@type": "nxv:Schema", + "imports": [ + "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/entity/v0.1.0", + "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2" + ], + "shapes": [{ + "@id": "this:ModelProjectShape", + "@type": "sh:NodeShape", + "label": "This shape represents a modelling project, and is a way to link related ModelInstances", + "nodekind": "sh:BlankNodeOrIRI", + "targetClass": "nsg:ModelProject", + "and": [{ + "node": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/entity/v0.1.0/shapes/EntityShape" + }, + { + "property": [{ + "path": "nsg:modelOf", + "name": "Model of", + "description": "Models of many things such as cells, ion channels, circuits, whole brains,...", + "editorialNote": "The value of this property should be constrained by a sh:class corresponding to what is being modeled." + }, + { + "path": "schema:name", + "name": "Name", + "description": "the name of the model project", + "datatype": "xsd:string", + "mincount": "1", + "maxcount": "1" + }, + { + "path": "nsg:alias", + "name": "Alias", + "description": "the alias of the model project.", + "editorialNote": "used as an identifier, should be unique.", + "datatype": "xsd:string", + "maxcount": "1" + }, + { + "path": "nsg:brainRegion", + "name": "Brain region", + "description": "Brain region", + "node": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2/shapes/BrainRegionOntologyTermShape" + }, + { + "path": "nsg:species", + "name": "Species", + "description": "Species", + "node": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2/shapes/SpeciesOntologyTermShape" + }, + { + "path": "nsg:celltype", + "name": "Cell type", + "description": "Cell type", + "node": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2/shapes/CellTypeOntologyTermShape" + }, + { + "path": "nsg:organization", + "name": "Organization", + "description": "Organization", + "node": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/organization/v0.1.0/shapes/OrganizationShape" + }, + { + "path": "nsg:abstractionLevel", + "name": "Abstraction Level", + "description": "Abstraction level of the model", + "node": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2/shapes/AbstractionLevelOntologyTermShape" + }, + { + "path": "nsg:private", + "name": "Private", + "description": "a boolean flag indicating whether access to the model should be restricted", + "datatype": "xsd:boolean" + }, + { + "path": "schema:author", + "name": "Author", + "description": "Author of the model Project", + "node": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/person/v0.1.0/shapes/PersonShape", + "mincount": "1" + }, + { + "path": "nsg:owner", + "name": "Owner", + "description": "Owner of the model Project", + "node": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/person/v0.1.0/shapes/PersonShape", + "maxcount": "1", + "mincount": "1" + }, + { + "path": "schema:description", + "name": "Description", + "description": "model project description", + "datatype": "xsd:string", + "mincount": "1", + "maxcount": "1" + }, + { + "path": "nsg:collabID", + "name": "collab id", + "description": "collab id of the model project", + "datatype": "xsd:int" + }, + { + "path": "nsg:PLAComponents", + "name": "PLA components", + "description": "PLA components", + "datatype": "xsd:string" + } + + ] + } + ] + }] +} \ No newline at end of file From ca6740dd4aef2460d2a7d86522ad6a3c834727d7 Mon Sep 17 00:00:00 2001 From: Andrew Davison Date: Mon, 18 Mar 2019 14:21:09 +0100 Subject: [PATCH 2/6] Remove/rename some HBP-specific properties. --- .../simulation/modelproject/v0.1.0.json | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json b/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json index 7f12547b..929a31d4 100644 --- a/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json +++ b/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json @@ -113,16 +113,22 @@ { "path": "nsg:collabID", "name": "collab id", - "description": "collab id of the model project", + "description": "collab id of the model project.", + "editorialNote": "Note that this is not generic, and should be removed in a future schema version, but is retained here for short-term convenience.", "datatype": "xsd:int" }, { - "path": "nsg:PLAComponents", - "name": "PLA components", - "description": "PLA components", + "path": "schema:funder", + "name": "Funding", + "description": "Information about the funding for this project", + "datatype": "xsd:string" + }, + { + "path": "nsg:providerId", + "name": "Provider ID", + "description": "An existing, alternative id of the model project", "datatype": "xsd:string" } - ] } ] From c0bcc64d955201ed60a6415867d649b9d1e02ef4 Mon Sep 17 00:00:00 2001 From: Andrew Davison Date: Mon, 25 Mar 2019 16:01:58 +0100 Subject: [PATCH 3/6] fix typos --- .../simulation/modelproject/v0.1.0.json | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json b/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json index 929a31d4..92088680 100644 --- a/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json +++ b/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json @@ -29,7 +29,8 @@ "node": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/entity/v0.1.0/shapes/EntityShape" }, { - "property": [{ + "property": [ + { "path": "nsg:modelOf", "name": "Model of", "description": "Models of many things such as cells, ion channels, circuits, whole brains,...", @@ -40,8 +41,8 @@ "name": "Name", "description": "the name of the model project", "datatype": "xsd:string", - "mincount": "1", - "maxcount": "1" + "minCount": "1", + "maxCount": "1" }, { "path": "nsg:alias", @@ -49,7 +50,7 @@ "description": "the alias of the model project.", "editorialNote": "used as an identifier, should be unique.", "datatype": "xsd:string", - "maxcount": "1" + "maxCount": "1" }, { "path": "nsg:brainRegion", @@ -92,23 +93,23 @@ "name": "Author", "description": "Author of the model Project", "node": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/person/v0.1.0/shapes/PersonShape", - "mincount": "1" + "minCount": "1" }, { "path": "nsg:owner", "name": "Owner", "description": "Owner of the model Project", "node": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/person/v0.1.0/shapes/PersonShape", - "maxcount": "1", - "mincount": "1" + "maxCount": "1", + "minCount": "1" }, { "path": "schema:description", "name": "Description", "description": "model project description", "datatype": "xsd:string", - "mincount": "1", - "maxcount": "1" + "minCount": "1", + "maxCount": "1" }, { "path": "nsg:collabID", From 2f4e780ffee3b82f8a5b6cad1842f56f97075a46 Mon Sep 17 00:00:00 2001 From: Andrew Davison Date: Mon, 25 Mar 2019 16:04:54 +0100 Subject: [PATCH 4/6] Put in `{{base}}` placeholder --- .../simulation/modelproject/v0.1.0.json | 26 +++++++++---------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json b/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json index 92088680..ca8bbadd 100644 --- a/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json +++ b/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json @@ -8,16 +8,16 @@ }, "owl": "http://www.w3.org/2002/07/owl#" }, - "https://nexus-int.humanbrainproject.org/v0/contexts/nexus/core/resource/v0.3.0", - "https://nexus-int.humanbrainproject.org/v0/contexts/neurosciencegraph/core/schema/v0.1.0", + "{{base}}/contexts/nexus/core/resource/v0.3.0", + "{{base}}/contexts/neurosciencegraph/core/schema/v0.1.0", { - "this": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/simulation/modelproject/v0.1.0/shapes/" + "this": "{{base}}/schemas/neuralactivity/simulation/modelproject/v0.1.0/shapes/" } ], "@type": "nxv:Schema", "imports": [ - "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/entity/v0.1.0", - "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2" + "{{base}}/schemas/neuralactivity/commons/entity/v0.1.0", + "{{base}}/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2" ], "shapes": [{ "@id": "this:ModelProjectShape", @@ -26,7 +26,7 @@ "nodekind": "sh:BlankNodeOrIRI", "targetClass": "nsg:ModelProject", "and": [{ - "node": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/entity/v0.1.0/shapes/EntityShape" + "node": "{{base}}/schemas/neuralactivity/commons/entity/v0.1.0/shapes/EntityShape" }, { "property": [ @@ -56,31 +56,31 @@ "path": "nsg:brainRegion", "name": "Brain region", "description": "Brain region", - "node": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2/shapes/BrainRegionOntologyTermShape" + "node": "{{base}}/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2/shapes/BrainRegionOntologyTermShape" }, { "path": "nsg:species", "name": "Species", "description": "Species", - "node": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2/shapes/SpeciesOntologyTermShape" + "node": "{{base}}/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2/shapes/SpeciesOntologyTermShape" }, { "path": "nsg:celltype", "name": "Cell type", "description": "Cell type", - "node": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2/shapes/CellTypeOntologyTermShape" + "node": "{{base}}/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2/shapes/CellTypeOntologyTermShape" }, { "path": "nsg:organization", "name": "Organization", "description": "Organization", - "node": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/organization/v0.1.0/shapes/OrganizationShape" + "node": "{{base}}/schemas/neuralactivity/commons/organization/v0.1.0/shapes/OrganizationShape" }, { "path": "nsg:abstractionLevel", "name": "Abstraction Level", "description": "Abstraction level of the model", - "node": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2/shapes/AbstractionLevelOntologyTermShape" + "node": "{{base}}/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2/shapes/AbstractionLevelOntologyTermShape" }, { "path": "nsg:private", @@ -92,14 +92,14 @@ "path": "schema:author", "name": "Author", "description": "Author of the model Project", - "node": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/person/v0.1.0/shapes/PersonShape", + "node": "{{base}}/schemas/neuralactivity/commons/person/v0.1.0/shapes/PersonShape", "minCount": "1" }, { "path": "nsg:owner", "name": "Owner", "description": "Owner of the model Project", - "node": "https://nexus-int.humanbrainproject.org/v0/schemas/neuralactivity/commons/person/v0.1.0/shapes/PersonShape", + "node": "{{base}}/schemas/neuralactivity/commons/person/v0.1.0/shapes/PersonShape", "maxCount": "1", "minCount": "1" }, From f2704f41f719254bf6806d462d03a8bccd8b68c0 Mon Sep 17 00:00:00 2001 From: Andrew Davison Date: Fri, 10 May 2019 16:34:46 +0200 Subject: [PATCH 5/6] Change URIs to use parent namespace --- .../simulation/modelproject/v0.1.0.json | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json b/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json index ca8bbadd..1a9bc522 100644 --- a/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json +++ b/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json @@ -16,8 +16,8 @@ ], "@type": "nxv:Schema", "imports": [ - "{{base}}/schemas/neuralactivity/commons/entity/v0.1.0", - "{{base}}/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2" + "{{base}}/schemas/neurosciencegraph/commons/entity/v0.1.0", + "{{base}}/schemas/neurosciencegraph/commons/typedlabeledontologyterm/v0.1.2" ], "shapes": [{ "@id": "this:ModelProjectShape", @@ -26,7 +26,7 @@ "nodekind": "sh:BlankNodeOrIRI", "targetClass": "nsg:ModelProject", "and": [{ - "node": "{{base}}/schemas/neuralactivity/commons/entity/v0.1.0/shapes/EntityShape" + "node": "{{base}}/schemas/neurosciencegraph/commons/entity/v0.1.0/shapes/EntityShape" }, { "property": [ @@ -56,31 +56,31 @@ "path": "nsg:brainRegion", "name": "Brain region", "description": "Brain region", - "node": "{{base}}/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2/shapes/BrainRegionOntologyTermShape" + "node": "{{base}}/schemas/neurosciencegraph/commons/typedlabeledontologyterm/v0.1.2/shapes/BrainRegionOntologyTermShape" }, { "path": "nsg:species", "name": "Species", "description": "Species", - "node": "{{base}}/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2/shapes/SpeciesOntologyTermShape" + "node": "{{base}}/schemas/neurosciencegraph/commons/typedlabeledontologyterm/v0.1.2/shapes/SpeciesOntologyTermShape" }, { "path": "nsg:celltype", "name": "Cell type", "description": "Cell type", - "node": "{{base}}/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2/shapes/CellTypeOntologyTermShape" + "node": "{{base}}/schemas/neurosciencegraph/commons/typedlabeledontologyterm/v0.1.2/shapes/CellTypeOntologyTermShape" }, { "path": "nsg:organization", "name": "Organization", "description": "Organization", - "node": "{{base}}/schemas/neuralactivity/commons/organization/v0.1.0/shapes/OrganizationShape" + "node": "{{base}}/schemas/neurosciencegraph/commons/organization/v0.1.0/shapes/OrganizationShape" }, { "path": "nsg:abstractionLevel", "name": "Abstraction Level", "description": "Abstraction level of the model", - "node": "{{base}}/schemas/neuralactivity/commons/typedlabeledontologyterm/v0.1.2/shapes/AbstractionLevelOntologyTermShape" + "node": "{{base}}/schemas/neurosciencegraph/commons/typedlabeledontologyterm/v0.1.2/shapes/AbstractionLevelOntologyTermShape" }, { "path": "nsg:private", From f3a5c5fe35ab8d656f0af4f3024fa466632e2db8 Mon Sep 17 00:00:00 2001 From: Andrew Davison Date: Tue, 21 May 2019 15:46:26 +0200 Subject: [PATCH 6/6] allow ModelProjects to have parents/children of the same type; add ModelCollection shape --- .../simulation/modelcollection/v0.1.0.json | 44 +++++++++++++++++++ .../simulation/modelproject/v0.1.0.json | 21 +++++---- 2 files changed, 57 insertions(+), 8 deletions(-) create mode 100644 modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelcollection/v0.1.0.json diff --git a/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelcollection/v0.1.0.json b/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelcollection/v0.1.0.json new file mode 100644 index 00000000..ca76a161 --- /dev/null +++ b/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelcollection/v0.1.0.json @@ -0,0 +1,44 @@ +{ + "@context": [ + "{{base}}/contexts/neurosciencegraph/core/schema/v0.1.0", + { + "this": "{{base}}/schemas/neurosciencegraph/simulation/modelcollection/v0.1.0/shapes/" + } + ], + "@type": "nxv:Schema", + "imports": [ + "{{base}}/schemas/neurosciencegraph/commons/collection/v0.1.0", + "{{base}}/schemas/neurosciencegraph/commons/typedlabeledontologyterm/v0.1.1" + ], + "shapes": [ + { + "@id": "this:ModelCollectionShape", + "@type": "sh:NodeShape", + "label": "Collection of model instances (including ME-models)", + "and": [ + { + "node": "{{base}}/schemas/neurosciencegraph/commons/collection/v0.2.0/shapes/CollectionShape" + }, + { + "property": [ + { + "path": "prov:hadMember", + "name": "Member", + "description": "The model instance(s) that are members of the collection.", + "or": [ + { + "class": "nsg:ModelInstance" + }, + { + "class": "nsg:MEModel" + } + ], + "seeAlso": ["{{base}}/schemas/neurosciencegraph/simulation/modelinstance/v0.1.2/shapes/ModelInstanceShape", + "{{base}}/schemas/neurosciencegraph/simulation/memodel/v0.1.4/shapes/MEModelShape"] + } + ] + } + ] + } + ] + } diff --git a/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json b/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json index 1a9bc522..14350ec5 100644 --- a/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json +++ b/modules/simulation/src/main/resources/schemas/neurosciencegraph/simulation/modelproject/v0.1.0.json @@ -41,8 +41,8 @@ "name": "Name", "description": "the name of the model project", "datatype": "xsd:string", - "minCount": "1", - "maxCount": "1" + "minCount": 1, + "maxCount": 1 }, { "path": "nsg:alias", @@ -50,7 +50,7 @@ "description": "the alias of the model project.", "editorialNote": "used as an identifier, should be unique.", "datatype": "xsd:string", - "maxCount": "1" + "maxCount": 1 }, { "path": "nsg:brainRegion", @@ -93,23 +93,23 @@ "name": "Author", "description": "Author of the model Project", "node": "{{base}}/schemas/neuralactivity/commons/person/v0.1.0/shapes/PersonShape", - "minCount": "1" + "minCount": 1 }, { "path": "nsg:owner", "name": "Owner", "description": "Owner of the model Project", "node": "{{base}}/schemas/neuralactivity/commons/person/v0.1.0/shapes/PersonShape", - "maxCount": "1", - "minCount": "1" + "maxCount": 1, + "minCount": 1 }, { "path": "schema:description", "name": "Description", "description": "model project description", "datatype": "xsd:string", - "minCount": "1", - "maxCount": "1" + "minCount": 1, + "maxCount": 1 }, { "path": "nsg:collabID", @@ -129,6 +129,11 @@ "name": "Provider ID", "description": "An existing, alternative id of the model project", "datatype": "xsd:string" + }, + { + "path": "nsg:partOf", + "name": "Parent model project(s)", + "node": "{{base}}/schemas/neuralactivity/simulation/modelproject/v0.1.0/shapes/ModelProject" } ] }