@prefix rb:    <https://w3id.org/riverbench/schema/metadata#> .
@prefix dct:   <http://purl.org/dc/terms/> .
@prefix rdf:   <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix owl:   <http://www.w3.org/2002/07/owl#> .
@prefix xsd:   <http://www.w3.org/2001/XMLSchema#> .
@prefix rdfs:  <http://www.w3.org/2000/01/rdf-schema#> .
@prefix dcat:  <http://www.w3.org/ns/dcat#> .
@prefix vann:  <http://purl.org/vocab/vann/> .
@prefix j.0:   <http://schema.org/> .
@prefix foaf:  <http://xmlns.com/foaf/0.1/> .
@prefix dc:    <http://purl.org/dc/elements/1.1/> .

rb:usesGeneralizedTriples
        a                   owl:DatatypeProperty ;
        rdfs:comment        "Whether the dataset uses the non-standard generalized triples feature"@en ;
        rdfs:label          "Uses generalized triples"@en ;
        rdfs:range          xsd:boolean ;
        rdfs:seeAlso        "https://www.w3.org/TR/rdf11-concepts/#section-generalized-rdf"@en ;
        rdfs:subPropertyOf  rb:conformanceProperty .

rb:Distribution  a       owl:Class ;
        rdfs:comment     "A distribution of a dataset in the RiverBench benchmark suite."@en ;
        rdfs:label       "RiverBench dataset distribution"@en ;
        rdfs:subClassOf  dcat:Distribution .

rb:hasStreamElementSplit
        a                   owl:ObjectProperty ;
        rdfs:comment        "Indicates how the stream was split into elements."@en ;
        rdfs:domain         rb:Dataset ;
        rdfs:label          "Has stream element split"@en ;
        rdfs:range          rb:StreamElementSplit ;
        rdfs:subPropertyOf  owl:topObjectProperty .

rb:maximum  a               owl:DatatypeProperty ;
        rdfs:comment        "Maximum value of a distribution"@en ;
        rdfs:label          "Maximum"@en ;
        rdfs:range          xsd:decimal ;
        rdfs:subPropertyOf  rb:statisticalProperty .

rb:ObjectCountStatistics
        a                owl:Class ;
        rdfs:comment     "Statistics about the number of objects in the dataset."@en ;
        rdfs:label       "Object count statistics"@en ;
        rdfs:subClassOf  rb:Statistics .

rb:graphs  a          owl:NamedIndividual , rb:StreamElementType ;
        rdfs:comment  "Graph streams are a special case of quad streams, where each element contains exactly one named RDF graph."@en ;
        rdfs:label    "Graphs"@en .

rb:StatementCountStreamElementSplit
        a                owl:Class ;
        rdfs:comment     "The number of statements in an element was the criterion for splitting the stream elements."@en ;
        rdfs:label       "Stream elements split by statement count"@en ;
        rdfs:subClassOf  rb:StreamElementSplit .

rb:SubjectCountStatistics
        a                owl:Class ;
        rdfs:comment     "Statistics about the number of subjects in the dataset."@en ;
        rdfs:label       "Subject count statistics"@en ;
        rdfs:subClassOf  rb:Statistics .

rb:SimpleLiteralCountStatistics
        a                owl:Class ;
        rdfs:comment     "Statistics about the number of simple literals (of type xsd:string) in the dataset."@en ;
        rdfs:label       "Simple literal count statistics"@en ;
        rdfs:subClassOf  rb:Statistics .

rb:quads  a           owl:NamedIndividual , rb:StreamElementType ;
        rdfs:comment  "Quad streams consist of elements, where each element is an RDF dataset."@en ;
        rdfs:label    "Quads"@en .

rb:TopicStreamElementSplit
        a                owl:Class ;
        rdfs:comment     "The elements correspond to different topics/subjects in the dataset."@en ;
        rdfs:label       "Stream elements split by topic"@en ;
        rdfs:subClassOf  rb:StreamElementSplit .

dcat:seriesMember  a  owl:ObjectProperty ;
        rdfs:comment  "Indicates which datasets are included in the profile"@en ;
        rdfs:label    "Includes dataset"@en .

rb:uniqueCount  a           owl:DatatypeProperty ;
        rdfs:comment        "Only used for count statistics. Indicates how many unique elements are in the entire dataset. The value is estimated with a Bloom filter and is accurate to ~1%."@en ;
        rdfs:label          "Unique count (estimated)"@en ;
        rdfs:range          xsd:integer ;
        rdfs:subPropertyOf  rb:statisticalProperty .

rb:StatementCountStatistics
        a                owl:Class ;
        rdfs:comment     "Statistics about the number of RDF statements in the dataset."@en ;
        rdfs:label       "Statement count statistics"@en ;
        rdfs:subClassOf  rb:Statistics .

rb:tripleStreamDistribution
        a             owl:NamedIndividual , rb:DistributionType ;
        rdfs:comment  "The dataset is distributed as a stream of RDF triples."@en ;
        rdfs:label    "Triple stream distribution"@en .

rb:graphStreamDistribution
        a             owl:NamedIndividual , rb:DistributionType ;
        rdfs:comment  "The dataset is distributed as a stream of named RDF graphs."@en ;
        rdfs:label    "Graph stream distribution"@en .

rb:usesGeneralizedRdfDatasets
        a                   owl:DatatypeProperty ;
        rdfs:comment        "Whether the dataset uses the non-standard generalized datasets feature. A \"dataset\" here is used in the same meaning as in the RDF 1.1 specification."@en ;
        rdfs:label          "Uses generalized RDF datasets"@en ;
        rdfs:range          xsd:boolean ;
        rdfs:seeAlso        <https://www.w3.org/TR/rdf11-concepts/#section-generalized-rdf> ;
        rdfs:subPropertyOf  rb:conformanceProperty .

rb:conformsToRdf11  a       owl:DatatypeProperty ;
        rdfs:comment        "Whether the dataset is RDF 1.1-compliant, i.e., does not use any non-standard features, like generalized triples."@en ;
        rdfs:label          "Conforms to W3C RDF 1.1 specification"@en ;
        rdfs:range          xsd:boolean ;
        rdfs:seeAlso        <https://www.w3.org/TR/rdf11-concepts/> ;
        rdfs:subPropertyOf  rb:conformanceProperty .

rb:QuotedTripleCountStatistics
        a                owl:Class ;
        rdfs:comment     "Statistics about the number of quoted triples in the dataset."@en ;
        rdfs:label       "Quoted triple count statistics"@en ;
        rdfs:subClassOf  rb:Statistics .

rb:RiverBench  a         owl:Class ;
        rdfs:comment     "RiverBench – RDF streaming benchmark suite"@en ;
        rdfs:label       "RiverBench suite"@en ;
        rdfs:subClassOf  dcat:Catalog .

<https://w3id.org/riverbench/schema/metadata>
        a                              owl:Ontology ;
        dc:description                 "Ontology for describing datasets and profiles in the RiverBench benchmark suite."@en ;
        dc:title                       "RiverBench metadata ontology"@en ;
        dct:created                    "2023-04-30T00:00:00"^^xsd:dateTime ;
        dct:creator                    "Piotr Sowiński"@en ;
        dct:creator                    [ foaf:homepage  <https://github.com/Ostrzyciel> , <https://orcid.org/0000-0002-2543-9461> ;
                                         foaf:name      "Piotr Sowiński" ;
                                         foaf:nick      "Ostrzyciel"
                                       ] ;
        dct:issued                     "2023-05-05T00:00:00"^^xsd:dateTime ;
        dct:license                    <https://spdx.org/licenses/CC-BY-4.0> ;
        vann:preferredNamespacePrefix  "rb" ;
        vann:preferredNamespaceUri     "https://w3id.org/riverbench/schema/metadata#" ;
        j.0:citation                   "Please cite this work according to the instructions here: https://w3id.org/riverbench/documentation/licensing/"@en ;
        owl:imports                    <http://www.w3.org/ns/dcat> ;
        owl:versionIRI                 <https://w3id.org/riverbench/schema/metadata/dev> .

rb:TimeStreamElementSplit
        a                owl:Class ;
        rdfs:comment     "The elements correspond to different instants or intervals of time."@en ;
        rdfs:label       "Stream elements split by time"@en ;
        rdfs:subClassOf  rb:StreamElementSplit .

rb:conformsToRdfStarDraft_20211217
        a                   owl:DatatypeProperty ;
        rdfs:comment        "Whether the dataset is RDF-star compliant, i.e., does not use any non-standard features. Note that all standard RDF 1.1 datasets also qualify, as RDF-star is a superset of RDF 1.1."@en ;
        rdfs:label          "Conforms to W3C RDF-star draft specification as of December 17, 2021"@en ;
        rdfs:range          xsd:boolean ;
        rdfs:seeAlso        <https://www.w3.org/2021/12/rdf-star.html> ;
        rdfs:subPropertyOf  rb:conformanceProperty .

rb:hasStreamElementType
        a             owl:ObjectProperty ;
        rdfs:comment  "Indicates the type of contents of each stream element"@en ;
        rdfs:label    "Has stream element type"@en ;
        rdfs:range    rb:StreamElementType .

rb:IriCountStatistics
        a                owl:Class ;
        rdfs:comment     "Statistics about the number of IRIs in the dataset."@en ;
        rdfs:label       "IRI count statistics"@en ;
        rdfs:subClassOf  rb:Statistics .

rb:isSupersetOfProfile
        a             owl:ObjectProperty , owl:TransitiveProperty ;
        rdfs:comment  "Indicates that this profile contains all datasets of the other profile"@en ;
        rdfs:domain   rb:Profile ;
        rdfs:label    "Is superset of profile"@en ;
        rdfs:range    rb:Profile .

rb:Statistics  a      owl:Class ;
        rdfs:comment  "Class for statistics objects about distributions"@en ;
        rdfs:label    "Statistics"@en .

rb:hasFileName  a     owl:DatatypeProperty ;
        rdfs:comment  "Canonical file name of this distribution"@en ;
        rdfs:domain   rb:Distribution ;
        rdfs:label    "Has file name"@en ;
        rdfs:range    xsd:string .

rb:hasRestriction  a  owl:ObjectProperty ;
        rdfs:comment  "Has profile restriction. The restrictions are joined with the AND operator."@en ;
        rdfs:domain   rb:Profile ;
        rdfs:label    "Has restriction"@en ;
        rdfs:range    rb:ProfileRestriction .

rb:triples  a         owl:NamedIndividual , rb:StreamElementType ;
        rdfs:comment  "Triple streams consist of elements, where each element is an RDF graph."@en ;
        rdfs:label    "Triples"@en .

rb:BlankNodeCountStatistics
        a                owl:Class ;
        rdfs:comment     "Statistics about the number of blank nodes in the dataset."@en ;
        rdfs:label       "Blank node count statistics"@en ;
        rdfs:subClassOf  rb:Statistics .

rb:DistributionType  a  owl:Class ;
        rdfs:comment  "Type of dataset distribution, indicating the corresponding streaming task formulation."@en ;
        rdfs:label    "RiverBench distribution type"@en .

rb:quadStreamDistribution
        a             owl:NamedIndividual , rb:DistributionType ;
        rdfs:comment  "The dataset is distributed as a stream of RDF quads."@en ;
        rdfs:label    "Quad stream distribution"@en .

rb:hasStreamElementCount
        a                   owl:DatatypeProperty ;
        rdfs:comment        "Number of elements in the stream"@en ;
        rdfs:label          "Has stream element count"@en ;
        rdfs:subPropertyOf  owl:topDataProperty .

rb:statisticalProperty
        a             owl:DatatypeProperty ;
        rdfs:comment  "The base statistical property." ;
        rdfs:domain   rb:Statistics ;
        rdfs:label    "Statistical property"@en .

rb:usesOntology  a    owl:ObjectProperty ;
        rdfs:comment  "Indicates that the dataset uses an ontology. The object must be a resource, but it doesn't neccesarily have to be an OWL ontology."@en ;
        rdfs:domain   rb:Dataset ;
        rdfs:label    "Uses ontology"@en .

rb:flatDistribution  a  owl:NamedIndividual , rb:DistributionType ;
        rdfs:comment  "The dataset is distributed as a single flat file."@en ;
        rdfs:label    "Flat distribution"@en .

rb:PredicateCountStatistics
        a                owl:Class ;
        rdfs:comment     "Statistics about the number of predicates in the dataset."@en ;
        rdfs:label       "Predicate count statistics"@en ;
        rdfs:subClassOf  rb:Statistics .

rb:hasProfile  a            owl:ObjectProperty ;
        rdfs:comment        "Indicates benchmark profiles that belong to this benchmark suite."@en ;
        rdfs:domain         rb:RiverBench ;
        rdfs:label          "Has benchmark profile"@en ;
        rdfs:range          rb:Profile ;
        rdfs:subPropertyOf  dcat:resource .

rb:hasVersion  a      owl:DatatypeProperty ;
        rdfs:comment  "Version tag of an artifact"@en ;
        rdfs:label    "Has version"@en ;
        rdfs:range    xsd:string .

rb:StreamElementType  a  owl:Class ;
        rdfs:comment  "Indicates the type of the contents of stream elements"@en ;
        rdfs:label    "Stream element type"@en .

rb:minimum  a               owl:DatatypeProperty ;
        rdfs:comment        "Minimum value of a distribution"@en ;
        rdfs:label          "Minimum"@en ;
        rdfs:range          xsd:decimal ;
        rdfs:subPropertyOf  rb:statisticalProperty .

rb:usesRdfStar  a           owl:DatatypeProperty ;
        rdfs:comment        "Whether the dataset uses RDF-star features."@en ;
        rdfs:label          "Uses RDF-star"@en ;
        rdfs:range          xsd:boolean ;
        rdfs:seeAlso        "https://www.w3.org/2021/12/rdf-star.html"@en ;
        rdfs:subPropertyOf  rb:conformanceProperty .

rb:hasStatistics  a   owl:ObjectProperty ;
        rdfs:comment  "Has a dataset statistics object"@en ;
        rdfs:domain   rb:Distribution ;
        rdfs:label    "Has statistics"@en ;
        rdfs:range    rb:Statistics .

rb:Dataset  a            owl:Class ;
        rdfs:comment     "A dataset in the RiverBench benchmark suite"@en ;
        rdfs:label       "RiverBench dataset"@en ;
        rdfs:subClassOf  dcat:Dataset .

rb:Profile  a            owl:Class ;
        rdfs:comment     "Benchmark profile grouping several datasets in RiverBench"@en ;
        rdfs:label       "Benchmark profile"@en ;
        rdfs:subClassOf  dcat:DatasetSeries .

rb:isSubsetOfProfile  a  owl:ObjectProperty , owl:TransitiveProperty ;
        rdfs:comment   "Indicates that this profile's datasets are all in the other profile"@en ;
        rdfs:domain    rb:Profile ;
        rdfs:label     "Is subset of profile"@en ;
        rdfs:range     rb:Profile ;
        owl:inverseOf  rb:isSupersetOfProfile .

rb:StreamElementSplit
        a             owl:Class ;
        rdfs:comment  "Describes how was the stream split into individual elements."@en ;
        rdfs:label    "Stream element split"@en .

rb:LiteralCountStatistics
        a                owl:Class ;
        rdfs:comment     "Statistics about the number of literals in the dataset."@en ;
        rdfs:label       "Literal count statistics"@en ;
        rdfs:subClassOf  rb:Statistics .

rb:conformanceProperty
        a                   owl:DatatypeProperty ;
        rdfs:comment        "Base property for all conformance data properties"@en ;
        rdfs:label          "Conformance property"@en ;
        rdfs:range          xsd:boolean ;
        rdfs:subPropertyOf  owl:topDataProperty .

dcat:DatasetSeries  a  owl:Class ;
        rdfs:label  "Dataset series"@en .

rb:LanguageLiteralCountStatistics
        a                owl:Class ;
        rdfs:comment     "Statistics about the number of language literals in the dataset."@en ;
        rdfs:label       "Language string count statistics"@en ;
        rdfs:subClassOf  rb:Statistics .

rb:hasDistributionType
        a             owl:ObjectProperty ;
        rdfs:comment  "Indicates the type of RiverBench dataset distribution"@en ;
        rdfs:label    "Has distribution type"@en ;
        rdfs:range    rb:DistributionType .

rb:ProfileRestriction
        a             owl:Class ;
        rdfs:comment  "Resource with properties that specify conditions for datasets to be included in the profile. The conditions are joined with the OR operator."@en ;
        rdfs:label    "Profile restriction"@en .

rb:mean  a                  owl:DatatypeProperty ;
        rdfs:comment        "Arithmetic mean of a distribution"@en ;
        rdfs:label          "Mean"@en ;
        rdfs:range          xsd:decimal ;
        rdfs:subPropertyOf  rb:statisticalProperty .

rb:GraphCountStatistics
        a                owl:Class ;
        rdfs:comment     "Statistics about the number of RDF graphs in the dataset, including the default graph."@en ;
        rdfs:label       "Graph count statistics"@en ;
        rdfs:subClassOf  rb:Statistics .

rb:fullDistribution  a  owl:NamedIndividual , rb:DistributionType ;
        rdfs:comment  "A full distribution, including all data in the dataset."@en ;
        rdfs:label    "Full distribution"@en .

rb:partialDistribution
        a             owl:NamedIndividual , rb:DistributionType ;
        rdfs:comment  "A partial distribution, including only a subset of the data in the dataset. The rb:hasStreamElementCount property indicates the length of this distribution."@en ;
        rdfs:label    "Partial distribution"@en .

rb:hasTemporalProperty
        a             owl:ObjectProperty ;
        rdfs:comment  "The IRI of the property that is used in the stream to denote time at which the event occured."@en ;
        rdfs:domain   rb:TimeStreamElementSplit ;
        rdfs:label    "Has temporal property"@en .

rb:sum  a                   owl:DatatypeProperty ;
        rdfs:comment        "Sum of all values in the distribution. In statistics about counts, this corresponds to the total number of given elements in the dataset."@en ;
        rdfs:label          "Sum"@en ;
        rdfs:range          xsd:decimal ;
        rdfs:subPropertyOf  rb:statisticalProperty .

rb:standardDeviation  a     owl:DatatypeProperty ;
        rdfs:comment        "Standard deviation of a distribution"@en ;
        rdfs:label          "Standard deviation"@en ;
        rdfs:range          xsd:decimal ;
        rdfs:subPropertyOf  rb:statisticalProperty .

rb:DatatypeLiteralCountStatistics
        a                owl:Class ;
        rdfs:comment     "Statistics about the number of datatype literals (NOT of type rdf:langString) in the dataset."@en ;
        rdfs:label       "Datatype literal count statistics"@en ;
        rdfs:subClassOf  rb:Statistics .
