From ae0dd16d1daceb15061d8a3d5d8bd975a2f6d4e0 Mon Sep 17 00:00:00 2001 From: Sierra Taylor Moxon Date: Fri, 8 Mar 2024 11:24:19 -0800 Subject: [PATCH] fixing up check-infores script --- Makefile | 2 +- ...formation_resource_registry.context.jsonld | 2 +- .../information_resource_registry.jsonld | 2 +- project/owl/information_resource.owl.ttl | 56 +++++++++---------- .../information_resource_registry.shacl.ttl | 40 ++++++------- .../information_resource_registry.py | 2 +- .../scripts/extract_unhelpful_urls.py | 0 .../scripts/verify_infores.py | 0 8 files changed, 52 insertions(+), 52 deletions(-) rename src/{ => information_resource_registry}/scripts/extract_unhelpful_urls.py (100%) rename src/{ => information_resource_registry}/scripts/verify_infores.py (100%) diff --git a/Makefile b/Makefile index 6eeb7e4..3c634d0 100644 --- a/Makefile +++ b/Makefile @@ -131,7 +131,7 @@ tests: $(RUN) yamllint -c .yamllint-config infores_catalog.yaml $(RUN) python scripts/verify_infores.py -test: test-schema test-python test-examples lint spell +test: test-schema test-python test-examples lint spell tests validate_infores test-schema: gen-project diff --git a/project/jsonld/information_resource_registry.context.jsonld b/project/jsonld/information_resource_registry.context.jsonld index 086aff0..b11f07a 100644 --- a/project/jsonld/information_resource_registry.context.jsonld +++ b/project/jsonld/information_resource_registry.context.jsonld @@ -1,7 +1,7 @@ { "comments": { "description": "Auto generated by LinkML jsonld context generator", - "generation_date": "2024-03-08T11:03:16", + "generation_date": "2024-03-08T11:19:57", "source": "information_resource_registry.yaml" }, "@context": { diff --git a/project/jsonld/information_resource_registry.jsonld b/project/jsonld/information_resource_registry.jsonld index a753bc9..771d53e 100644 --- a/project/jsonld/information_resource_registry.jsonld +++ b/project/jsonld/information_resource_registry.jsonld @@ -614,7 +614,7 @@ "source_file": "information_resource_registry.yaml", "source_file_date": "2024-03-08T10:47:50", "source_file_size": 7890, - "generation_date": "2024-03-08T11:03:16", + "generation_date": "2024-03-08T11:19:57", "@type": "SchemaDefinition", "@context": [ "project/jsonld/information_resource_registry.context.jsonld", diff --git a/project/owl/information_resource.owl.ttl b/project/owl/information_resource.owl.ttl index 1f9f796..cd5685a 100644 --- a/project/owl/information_resource.owl.ttl +++ b/project/owl/information_resource.owl.ttl @@ -40,70 +40,70 @@ infores:InformationResource a owl:Class ; rdfs:label "InformationResource" ; rdfs:subClassOf [ a owl:Restriction ; owl:maxCardinality 1 ; - owl:onProperty infores:id ], + owl:onProperty infores:description ], [ a owl:Restriction ; owl:maxCardinality 1 ; - owl:onProperty infores:status ], + owl:onProperty infores:knowledge_level ], [ a owl:Restriction ; owl:minCardinality 0 ; - owl:onProperty infores:description ], - [ a owl:Restriction ; - owl:maxCardinality 1 ; - owl:onProperty infores:agent_type ], + owl:onProperty infores:status ], [ a owl:Restriction ; owl:maxCardinality 1 ; - owl:onProperty infores:knowledge_level ], + owl:onProperty infores:status ], [ a owl:Restriction ; owl:allValuesFrom xsd:string ; - owl:onProperty infores:id ], + owl:onProperty infores:name ], [ a owl:Restriction ; owl:allValuesFrom xsd:string ; owl:onProperty infores:xref ], [ a owl:Restriction ; - owl:allValuesFrom xsd:string ; + owl:minCardinality 0 ; + owl:onProperty infores:name ], + [ a owl:Restriction ; + owl:minCardinality 0 ; owl:onProperty infores:description ], + [ a owl:Restriction ; + owl:maxCardinality 1 ; + owl:onProperty infores:agent_type ], [ a owl:Restriction ; owl:allValuesFrom infores:InformationResourceStatusEnum ; owl:onProperty infores:status ], [ a owl:Restriction ; owl:minCardinality 0 ; - owl:onProperty infores:xref ], + owl:onProperty infores:agent_type ], [ a owl:Restriction ; - owl:allValuesFrom infores:KnowledgeLevelEnum ; - owl:onProperty infores:knowledge_level ], + owl:maxCardinality 1 ; + owl:onProperty infores:name ], [ a owl:Restriction ; owl:minCardinality 0 ; + owl:onProperty infores:synonym ], + [ a owl:Restriction ; + owl:allValuesFrom infores:AgentTypeEnum ; owl:onProperty infores:agent_type ], [ a owl:Restriction ; owl:minCardinality 0 ; - owl:onProperty infores:synonym ], + owl:onProperty infores:xref ], [ a owl:Restriction ; owl:allValuesFrom xsd:string ; owl:onProperty infores:synonym ], - [ a owl:Restriction ; - owl:minCardinality 0 ; - owl:onProperty infores:status ], - [ a owl:Restriction ; - owl:minCardinality 0 ; - owl:onProperty infores:knowledge_level ], - [ a owl:Restriction ; - owl:allValuesFrom infores:AgentTypeEnum ; - owl:onProperty infores:agent_type ], [ a owl:Restriction ; owl:maxCardinality 1 ; - owl:onProperty infores:name ], + owl:onProperty infores:id ], [ a owl:Restriction ; owl:minCardinality 1 ; owl:onProperty infores:id ], [ a owl:Restriction ; - owl:maxCardinality 1 ; + owl:allValuesFrom xsd:string ; owl:onProperty infores:description ], - [ a owl:Restriction ; - owl:minCardinality 0 ; - owl:onProperty infores:name ], [ a owl:Restriction ; owl:allValuesFrom xsd:string ; - owl:onProperty infores:name ], + owl:onProperty infores:id ], + [ a owl:Restriction ; + owl:allValuesFrom infores:KnowledgeLevelEnum ; + owl:onProperty infores:knowledge_level ], + [ a owl:Restriction ; + owl:minCardinality 0 ; + owl:onProperty infores:knowledge_level ], linkml:ClassDefinition ; skos:altLabel "knowledgebase" ; skos:definition "A database or knowledgebase and its supporting ecosystem of interfaces and services that deliver content to consumers (e.g. web portals, APIs, query endpoints, streaming services, data downloads, etc.). A single Information Resource by this definition may span many different datasets or databases, and include many access endpoints and user interfaces. Information Resources include project-specific resources such as a Translator Knowledge Provider, and community knowledgebases like ChemBL, OMIM, or DGIdb." ; diff --git a/project/shacl/information_resource_registry.shacl.ttl b/project/shacl/information_resource_registry.shacl.ttl index a8cc13e..4119f05 100644 --- a/project/shacl/information_resource_registry.shacl.ttl +++ b/project/shacl/information_resource_registry.shacl.ttl @@ -19,44 +19,44 @@ infores:InformationResource a sh:NodeShape ; sh:closed true ; sh:description "A database or knowledgebase and its supporting ecosystem of interfaces and services that deliver content to consumers (e.g. web portals, APIs, query endpoints, streaming services, data downloads, etc.). A single Information Resource by this definition may span many different datasets or databases, and include many access endpoints and user interfaces. Information Resources include project-specific resources such as a Translator Knowledge Provider, and community knowledgebases like ChemBL, OMIM, or DGIdb." ; sh:ignoredProperties ( rdf:type ) ; - sh:property [ sh:description "the status of the infores identifier, the default is \"released\"" ; + sh:property [ sh:description "The type of agent that supports an edge or node. This is a general categorization of the type of agent that supports a statement, and is not intended to be a comprehensive description of the agent. For example, a statement may be supported by a single publication, but that publication may contain multiple types of evidence, such as a computational prediction and a manual curation. In this case, the agent type would be \"publication\", and the evidence would be described in more detail in the evidence graph." ; + sh:in ( "not_provided" "computational_model" ) ; + sh:maxCount 1 ; + sh:order 7 ; + sh:path infores:agent_type ], + [ sh:datatype xsd:string ; + sh:description "A free-text description of an entity or attribute." ; + sh:maxCount 1 ; + sh:order 5 ; + sh:path rdfs:comment ], + [ sh:description "the status of the infores identifier, the default is \"released\"" ; sh:in ( "released" "deprecated" "draft" "modified" ) ; sh:maxCount 1 ; sh:order 0 ; sh:path infores:status ], - [ sh:datatype xsd:string ; - sh:description "A database cross reference or alternative identifier for a NamedThing or edge between two NamedThings. This property should point to a database record or webpage that supports the existence of the edge, or gives more detail about the edge. This property can be used on a node or edge to provide multiple URIs or CURIE cross references." ; - sh:order 3 ; - sh:path infores:xref ], [ sh:datatype xsd:string ; sh:description "Alternate human-readable names for a thing" ; sh:order 4 ; sh:path infores:synonym ], [ sh:datatype xsd:string ; - sh:description "A free-text description of an entity or attribute." ; + sh:description "A database cross reference or alternative identifier for a NamedThing or edge between two NamedThings. This property should point to a database record or webpage that supports the existence of the edge, or gives more detail about the edge. This property can be used on a node or edge to provide multiple URIs or CURIE cross references." ; + sh:order 3 ; + sh:path infores:xref ], + [ sh:datatype xsd:string ; + sh:description "A unique identifier for an entity. Must be either a CURIE shorthand for a URI or a complete URI" ; sh:maxCount 1 ; - sh:order 5 ; - sh:path rdfs:comment ], + sh:minCount 1 ; + sh:order 2 ; + sh:path infores:id ], [ sh:datatype xsd:string ; sh:description "A human-readable name for an attribute or entity." ; sh:maxCount 1 ; sh:order 1 ; sh:path rdfs:label ], - [ sh:description "The type of agent that supports an edge or node. This is a general categorization of the type of agent that supports a statement, and is not intended to be a comprehensive description of the agent. For example, a statement may be supported by a single publication, but that publication may contain multiple types of evidence, such as a computational prediction and a manual curation. In this case, the agent type would be \"publication\", and the evidence would be described in more detail in the evidence graph." ; - sh:in ( "not_provided" "computational_model" ) ; - sh:maxCount 1 ; - sh:order 7 ; - sh:path infores:agent_type ], [ sh:description "The level of knowledge that supports an edge or node. This is a general categorization of the type of evidence that supports a statement, and is not intended to be a comprehensive description of the evidence. For example, a statement may be supported by a single publication, but that publication may contain multiple types of evidence, such as a computational prediction and a manual curation. In this case, the knowledge level would be \"curated\", and the evidence would be described in more detail in the evidence graph." ; sh:in ( "curated" "predicted" "text_mined" "correlation" "observed" "other" "mixed" ) ; sh:maxCount 1 ; sh:order 6 ; - sh:path infores:knowledge_level ], - [ sh:datatype xsd:string ; - sh:description "A unique identifier for an entity. Must be either a CURIE shorthand for a URI or a complete URI" ; - sh:maxCount 1 ; - sh:minCount 1 ; - sh:order 2 ; - sh:path infores:id ] ; + sh:path infores:knowledge_level ] ; sh:targetClass infores:InformationResource . diff --git a/src/information_resource_registry/datamodel/information_resource_registry.py b/src/information_resource_registry/datamodel/information_resource_registry.py index 31b7259..cc00448 100644 --- a/src/information_resource_registry/datamodel/information_resource_registry.py +++ b/src/information_resource_registry/datamodel/information_resource_registry.py @@ -1,5 +1,5 @@ # Auto generated from information_resource_registry.yaml by pythongen.py version: 0.0.1 -# Generation date: 2024-03-08T11:03:28 +# Generation date: 2024-03-08T11:20:09 # Schema: Information-Resource-Registry-Schema # # id: https://w3id.org/biolink/information_resource_registry.yaml diff --git a/src/scripts/extract_unhelpful_urls.py b/src/information_resource_registry/scripts/extract_unhelpful_urls.py similarity index 100% rename from src/scripts/extract_unhelpful_urls.py rename to src/information_resource_registry/scripts/extract_unhelpful_urls.py diff --git a/src/scripts/verify_infores.py b/src/information_resource_registry/scripts/verify_infores.py similarity index 100% rename from src/scripts/verify_infores.py rename to src/information_resource_registry/scripts/verify_infores.py