@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix sh: <http://www.w3.org/ns/shacl#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .

<https://www.cdisc.org/cosmos/biomedical_concept_v1.0/BiomedicalConcept> a sh:NodeShape ;
    sh:closed true ;
    sh:ignoredProperties ( rdf:type ) ;
    sh:property [ sh:class <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/DataElementConcept> ;
            sh:description "Data Element Concept" ;
            sh:nodeKind sh:IRI ;
            sh:order 12 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/dataElementConcepts> ],
        [ sh:description "Scale of measurement for the Biomedical Concept result" ;
            sh:in ( "Ordinal" "Narrative" "Nominal" "Quantitative" "Temporal" ) ;
            sh:order 9 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/resultScales> ],
        [ sh:description "URI link to NCIt for the Biomedical Concept; blank if  concept is not available in NCIt" ;
            sh:maxCount 1 ;
            sh:nodeKind sh:IRI ;
            sh:order 4 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/href> ],
        [ sh:description "Package type (bc for Biomedical Concepts)" ;
            sh:in ( "bc" ) ;
            sh:maxCount 1 ;
            sh:minCount 1 ;
            sh:order 1 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/packageType> ],
        [ sh:datatype xsd:string ;
            sh:description "NCIt definition for the Biomedical Concept; provisional defintion if concept is not available in NCIt" ;
            sh:maxCount 1 ;
            sh:minCount 1 ;
            sh:nodeKind sh:Literal ;
            sh:order 10 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/definition> ],
        [ sh:class <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/Coding> ;
            sh:description "Coding for the Biomedical Concept" ;
            sh:nodeKind sh:BlankNodeOrIRI ;
            sh:order 11 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/coding> ],
        [ sh:datatype xsd:string ;
            sh:description "Biomedical Concept synonym equivalent to BC short name for the facilitation of API search and extraction" ;
            sh:nodeKind sh:Literal ;
            sh:order 8 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/synonyms> ],
        [ sh:datatype xsd:string ;
            sh:description "A unique identifier for a Biomedical Concept which will be assigned as the NCIt code if it exists or a placeholder identifier if the concept is not yet available in NCIt" ;
            sh:maxCount 1 ;
            sh:nodeKind sh:Literal ;
            sh:order 2 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/conceptId> ;
            sh:pattern "^(C[0-9]+|NEW_[A-Z_]*[0-9]*)$" ],
        [ sh:datatype xsd:string ;
            sh:description "C-code for the parent concept in the NCIt hiearchy; blank if concept is not available in NCIt" ;
            sh:maxCount 1 ;
            sh:nodeKind sh:Literal ;
            sh:order 5 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/parentConceptId> ],
        [ sh:datatype xsd:date ;
            sh:description "Biomedical Concept package release date indicating when the BC package was published to production" ;
            sh:maxCount 1 ;
            sh:minCount 1 ;
            sh:nodeKind sh:Literal ;
            sh:order 0 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/packageDate> ],
        [ sh:datatype xsd:string ;
            sh:description "Biomedical Concept category for the faciliation of API search and extract" ;
            sh:minCount 1 ;
            sh:nodeKind sh:Literal ;
            sh:order 6 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/categories> ],
        [ sh:datatype xsd:string ;
            sh:description "NCI Preferred Name for the concept; provisional name will be used if concept is not available in NCIt" ;
            sh:maxCount 1 ;
            sh:minCount 1 ;
            sh:nodeKind sh:Literal ;
            sh:order 7 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/shortName> ],
        [ sh:datatype xsd:string ;
            sh:description "NCIt C-code for the Biomedical Concept" ;
            sh:maxCount 1 ;
            sh:nodeKind sh:Literal ;
            sh:order 3 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/ncitCode> ;
            sh:pattern "^(C[0-9]+)$" ] ;
    sh:targetClass <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/BiomedicalConcept> .

<https://www.cdisc.org/cosmos/biomedical_concept_v1.0/Coding> a sh:NodeShape ;
    sh:closed true ;
    sh:ignoredProperties ( rdf:type ) ;
    sh:property [ sh:datatype xsd:string ;
            sh:description "Human-readable name for the code system" ;
            sh:maxCount 1 ;
            sh:nodeKind sh:Literal ;
            sh:order 2 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/systemName> ],
        [ sh:datatype xsd:string ;
            sh:description "Synonym concept for the Biomedical Concept as defined in a code system" ;
            sh:maxCount 1 ;
            sh:minCount 1 ;
            sh:nodeKind sh:Literal ;
            sh:order 0 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/code> ],
        [ sh:datatype xsd:string ;
            sh:description "Identifies the code system for the synonym concept. The URL of the code system should be used if it exists" ;
            sh:maxCount 1 ;
            sh:minCount 1 ;
            sh:nodeKind sh:Literal ;
            sh:order 1 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/system> ] ;
    sh:targetClass <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/Coding> .

<https://www.cdisc.org/cosmos/biomedical_concept_v1.0/DataElementConcept> a sh:NodeShape ;
    sh:closed true ;
    sh:ignoredProperties ( rdf:type ) ;
    sh:property [ sh:description "Data Type for the Data Element Concept" ;
            sh:in ( "boolean" "date" "datetime" "decimal" "duration" "float" "integer" "string" "uri" ) ;
            sh:maxCount 1 ;
            sh:minCount 1 ;
            sh:order 4 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/dataType> ],
        [ sh:description "Link to NCIt for the Data Element Concept" ;
            sh:maxCount 1 ;
            sh:nodeKind sh:IRI ;
            sh:order 2 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/href> ],
        [ sh:datatype xsd:string ;
            sh:description "Example values for the Data Element Concept" ;
            sh:nodeKind sh:Literal ;
            sh:order 5 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/exampleSet> ],
        [ sh:datatype xsd:string ;
            sh:description "NCI C-code for the BC Data Element Concept" ;
            sh:maxCount 1 ;
            sh:nodeKind sh:Literal ;
            sh:order 1 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/ncitCode> ;
            sh:pattern "^(C[0-9]+)$" ],
        [ sh:datatype xsd:string ;
            sh:description "An identifier for a Data Element Concept (DEC) which will be assigned as the NCIt code if it exists or a placeholder identifier if the concept is not yet available in NCIt" ;
            sh:maxCount 1 ;
            sh:nodeKind sh:Literal ;
            sh:order 0 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/conceptId> ;
            sh:pattern "^(C[0-9]+|NEW_[A-Z_]*[0-9]*)$" ],
        [ sh:datatype xsd:string ;
            sh:description "NCI Preferred Name for the concept; provisional name will be used if concept is not available in NCIt" ;
            sh:maxCount 1 ;
            sh:minCount 1 ;
            sh:nodeKind sh:Literal ;
            sh:order 3 ;
            sh:path <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/shortName> ] ;
    sh:targetClass <https://www.cdisc.org/cosmos/biomedical_concept_v1.0/DataElementConcept> .

