---
id: https://w3id.org/lmodel/void
name: void
title: Vocabulary of Interlinked Datasets (VoID)
description: >-
  A LinkML rendering of the Vocabulary of Interlinked Datasets (VoID), the RDF vocabulary for describing
  datasets of linked data and the links between them, as the W3C Interest Group Note of 3 March 2011
  explains it. Every VoID class and property keeps its VoID IRI, and the Dublin Core, FOAF and RDF Schema
  terms the Note uses in a description keep theirs.
version: "2011-03-03"
source: https://www.w3.org/TR/2011/NOTE-void-20110303/
license: Apache-2.0
see_also:
  - https://lmodel.github.io/void
  - https://www.w3.org/TR/void/
annotations:
  vocabulary_file: https://github.com/cygri/void/blob/5b2ca68b7897c2613d4269fd725f1812dce21267/rdfs/void.ttl
  vocabulary_modified: "2011-03-06"
  upstream_license: >-
    The Note is under the W3C Document License (https://www.w3.org/Consortium/Legal/copyright-documents);
    the vocabulary file states no licence.
comments:
  - >-
    The version is the date of the Note's edition, and the source its dated address. The schema renders
    every class and property that the vocabulary file declares, as its editors keep it at the commit the
    vocabulary_file annotation names; tests/upstream/void-terms.tsv lists them, and the tests hold this
    schema to that list.
  - >-
    Neither the Note nor the vocabulary file is copied: every description here is this project's own,
    and NOTICE says why.
  - >-
    A slot whose value names a resource by its IRI or a CURIE, such as id, class, subset or target, carries
    the pattern of a scheme or prefix, a colon and no space. LinkML 1.12.1 renders the uriorcurie type, and
    a reference to a class, as a JSON Schema string with no format, so without it the validator would pass
    any text there.
  - >-
    Each class and slot names, in its note_section annotation, the section of the Note that explains it.
    The class names are VoID's own, with no prefix of this schema's: no record carries a class name, and
    the adapt copy renames Dataset, which LOKF also defines, to VoidDataset.
  - >-
    Kept from the Note's account of a description: the Dublin Core terms of its sections 2.2, 2.4 and 2.5,
    FOAF's homepage and page (2.1) and topic and primaryTopic (6.2), and the RDF Schema label, comment and
    seeAlso of a technical feature (2.6). Left out: dcterms:date, since a slot named date takes the name
    of LinkML's date type, and the generated Pydantic model then checks none of the dates, while created,
    issued and modified carry the dates the Note names; the agents a description names, which FOAF
    describes; the Waiver vocabulary's norms and waiver (2.4); and the SPARQL Service Description terms
    (6.5), which describe a service rather than a dataset.

prefixes:
  void: http://rdfs.org/ns/void#
  void_linkml: https://w3id.org/lmodel/void/
  dcterms: http://purl.org/dc/terms/
  foaf: http://xmlns.com/foaf/0.1/
  rdf: http://www.w3.org/1999/02/22-rdf-syntax-ns#
  rdfs: http://www.w3.org/2000/01/rdf-schema#
  owl: http://www.w3.org/2002/07/owl#
  xsd: http://www.w3.org/2001/XMLSchema#
  dcat: http://www.w3.org/ns/dcat#
  sd: http://www.w3.org/ns/sparql-service-description#
  linkml: https://w3id.org/linkml/

default_prefix: void_linkml
default_range: string

imports:
  - linkml:types

classes:

  Dataset:
    class_uri: void:Dataset
    description: >-
      RDF triples from one provider, gathered under an IRI so that a description can speak of them as a
      whole.
    tree_root: true
    comments:
      - >-
        A dataset is named by an IRI, and the IRI of another dataset is how a subset, a linkset's target or
        a description refers to it.
    narrow_mappings:
      - sd:Dataset
      - sd:Graph
    broad_mappings:
      - dcat:Dataset
    notes:
      - >-
        The narrow mappings are the Note's own statement (section 6.5) that a SPARQL service description's
        datasets and graphs are VoID datasets. The broad mapping follows DCAT 3 (sections 1 and 6.2.1),
        which offers VoID's properties for the statistics of a DCAT dataset whose data is RDF: a DCAT
        dataset may hold data in any format, and a VoID dataset holds RDF alone.
    slots:
      - id
      - title
      - description
      - creator
      - contributor
      - publisher
      - source
      - created
      - issued
      - modified
      - license
      - subject
      - homepage
      - page
      - feature
      - sparqlEndpoint
      - dataDump
      - uriLookupEndpoint
      - openSearchDescription
      - rootResource
      - exampleResource
      - uriSpace
      - uriRegexPattern
      - vocabulary
      - subset
      - classPartition
      - propertyPartition
      - triples
      - entities
      - classes
      - properties
      - distinctSubjects
      - distinctObjects
      - documents
    annotations:
      note_section: "1.3"

  Linkset:
    is_a: Dataset
    class_uri: void:Linkset
    description: >-
      A dataset of triples that join two datasets: each triple's subject belongs to one of them and its
      object to the other.
    slots:
      - target
      - subjectsTarget
      - objectsTarget
      - linkPredicate
    slot_usage:
      target:
        multivalued: true
        minimum_cardinality: 2
        maximum_cardinality: 2
    any_of:
      - description: Two targets, named with target.
        slot_conditions:
          target:
            required: true
      - description: The subjects' target and the objects' target.
        slot_conditions:
          subjectsTarget:
            required: true
          objectsTarget:
            required: true
    comments:
      - >-
        A linkset links exactly two distinct datasets: the targets, the subjects' target and the objects'
        target together name two. The validator checks that two are named; tests/test_data.py checks that
        they differ.
      - >-
        VoID also accepts one target beside one directed target, which together name two datasets. This
        schema asks for both targets or both directed targets, so such a linkset names the missing one too.
    annotations:
      note_section: "1.4"

  DatasetDescription:
    class_uri: void:DatasetDescription
    description: >-
      A web document, such as a void.ttl file published beside a dataset, that describes one or more
      datasets.
    broad_mappings:
      - foaf:Document
    notes:
      - The broad mapping is the vocabulary file's own statement that a dataset description is a FOAF document.
    slots:
      - id
      - title
      - description
      - creator
      - created
      - modified
      - primaryTopic
      - topic
      - inDataset
    any_of:
      - description: The one dataset the description is about.
        slot_conditions:
          primaryTopic:
            required: true
      - description: The datasets the description is about.
        slot_conditions:
          topic:
            required: true
    annotations:
      note_section: "6.2"

  TechnicalFeature:
    class_uri: void:TechnicalFeature
    description: >-
      A technical property of how a dataset is served, such as an RDF syntax it can be read in or an HTTP
      feature its server supports.
    comments:
      - >-
        W3C names the RDF syntaxes under http://www.w3.org/ns/formats/, such as
        http://www.w3.org/ns/formats/Turtle; a feature of another kind takes an IRI of its publisher's own.
    slots:
      - id
      - label
      - comment
      - seeAlso
    annotations:
      note_section: "2.6"

  ClassBasedPartition:
    class_uri: void_linkml:ClassBasedPartition
    description: >-
      The slice of a dataset about the members of one class, written inside that dataset, most often to
      give counts for it.
    broad_mappings:
      - void:Dataset
    comments:
      - >-
        VoID gives a partition no class of its own: it is a dataset, usually a blank node. This schema
        writes it as a value inside its dataset, so it has no IRI, and its class lives in this schema's own
        namespace. The name follows VoID's phrase for it and differs from the classPartition slot's by
        more than case, so that their pages are two files on a filesystem that ignores case.
    slots:
      - class
      - triples
      - entities
      - classes
      - properties
      - distinctSubjects
      - distinctObjects
      - documents
      - propertyPartition
    slot_usage:
      class:
        required: true
    annotations:
      note_section: "4.5"

  PropertyBasedPartition:
    class_uri: void_linkml:PropertyBasedPartition
    description: >-
      The slice of a dataset made of the triples whose predicate is one property, written inside that
      dataset, most often to give counts for it.
    broad_mappings:
      - void:Dataset
    comments:
      - >-
        As for a class partition, VoID gives it no class of its own, and this schema writes it as a value
        inside its dataset.
    slots:
      - property
      - triples
      - entities
      - classes
      - properties
      - distinctSubjects
      - distinctObjects
      - documents
    slot_usage:
      property:
        required: true
    annotations:
      note_section: "4.5"

slots:

  id:
    identifier: true
    range: uriorcurie
    pattern: "^[A-Za-z_][A-Za-z0-9_.+-]*:[^\\s]+$"
    description: The IRI of the dataset, document or feature, written in full or as a CURIE.
    comments:
      - VoID has no property for the IRI, which RDF writes as the subject, so the key lives in this schema's own namespace.
    annotations:
      note_section: "6.1"

  # Dublin Core terms the Note uses for a dataset's general metadata.

  title:
    slot_uri: dcterms:title
    description: A human-readable name for the dataset or document.
    annotations:
      note_section: "2.2"

  description:
    slot_uri: dcterms:description
    description: A few sentences of prose saying what the dataset or document contains.
    annotations:
      note_section: "2.2"

  creator:
    slot_uri: dcterms:creator
    range: uri
    multivalued: true
    description: The IRI of the agent, human or not, that chiefly made the dataset or document.
    annotations:
      note_section: "2.2"

  contributor:
    slot_uri: dcterms:contributor
    range: uri
    multivalued: true
    description: The IRI of an agent that added to the dataset without being its main maker.
    annotations:
      note_section: "2.2"

  publisher:
    slot_uri: dcterms:publisher
    range: uri
    description: The IRI of the agent that releases the dataset for others to use.
    annotations:
      note_section: "2.2"

  source:
    slot_uri: dcterms:source
    range: uri
    multivalued: true
    description: The IRI of an earlier resource whose content the dataset draws on.
    annotations:
      note_section: "2.2"

  created:
    slot_uri: dcterms:created
    range: date
    description: The date the dataset or document was made.
    annotations:
      note_section: "2.2"

  issued:
    slot_uri: dcterms:issued
    range: date
    description: The date the dataset was first published.
    annotations:
      note_section: "2.2"

  modified:
    slot_uri: dcterms:modified
    range: date
    description: The date the dataset or document last changed.
    annotations:
      note_section: "2.2"

  license:
    slot_uri: dcterms:license
    range: uri
    description: The IRI of the licence that sets the terms for using the dataset.
    annotations:
      note_section: "2.4"

  subject:
    slot_uri: dcterms:subject
    range: uri
    multivalued: true
    description: The IRI of a topic the dataset covers, such as a DBpedia resource or a SKOS concept.
    annotations:
      note_section: "2.5"

  # FOAF terms the Note uses for web pages and for what a description is about.

  homepage:
    slot_uri: foaf:homepage
    range: uri
    description: The web page about the dataset itself.
    annotations:
      note_section: "2.1"

  page:
    slot_uri: foaf:page
    range: uri
    multivalued: true
    description: Any further web page with information on the dataset, for instance its download page or its catalogue entry.
    annotations:
      note_section: "2.1"

  primaryTopic:
    slot_uri: foaf:primaryTopic
    range: Dataset
    pattern: "^[A-Za-z_][A-Za-z0-9_.+-]*:[^\\s]+$"
    description: The dataset a description is about, when it describes one.
    annotations:
      note_section: "6.2"

  topic:
    slot_uri: foaf:topic
    range: Dataset
    multivalued: true
    pattern: "^[A-Za-z_][A-Za-z0-9_.+-]*:[^\\s]+$"
    description: A dataset a description is about, when it describes several of equal weight.
    annotations:
      note_section: "6.2"

  # RDF Schema terms the Note uses for a technical feature.

  label:
    slot_uri: rdfs:label
    description: A short name for the feature.
    annotations:
      note_section: "2.6"

  comment:
    slot_uri: rdfs:comment
    description: A sentence or two about the feature.
    annotations:
      note_section: "2.6"

  seeAlso:
    slot_uri: rdfs:seeAlso
    range: uri
    multivalued: true
    description: A web page that tells more about the feature.
    annotations:
      note_section: "2.6"

  # VoID's properties: access to a dataset.

  feature:
    slot_uri: void:feature
    range: TechnicalFeature
    multivalued: true
    pattern: "^[A-Za-z_][A-Za-z0-9_.+-]*:[^\\s]+$"
    description: Something the dataset's server or files support, for instance an RDF syntax, named by its IRI.
    annotations:
      note_section: "2.6"

  sparqlEndpoint:
    slot_uri: void:sparqlEndpoint
    range: uri
    multivalued: true
    description: A SPARQL service whose default graph holds the dataset, for running queries on it.
    annotations:
      note_section: "3.2"

  dataDump:
    slot_uri: void:dataDump
    range: uri
    multivalued: true
    description: A downloadable RDF file holding all of the dataset or a share of it.
    comments:
      - A page that links to downloads is not a dump; give it as a page instead.
    annotations:
      note_section: "3.3"

  uriLookupEndpoint:
    slot_uri: void:uriLookupEndpoint
    range: uri
    multivalued: true
    description: >-
      A web address that, with an entity's percent-encoded IRI added to its end, answers an HTTP GET with
      RDF about that entity.
    annotations:
      note_section: "3.5"

  openSearchDescription:
    slot_uri: void:openSearchDescription
    range: uri
    multivalued: true
    description: An OpenSearch file telling a client how to run keyword searches over the dataset.
    annotations:
      note_section: "3.6"

  rootResource:
    slot_uri: void:rootResource
    range: uri
    multivalued: true
    description: >-
      The IRI of a starting point for crawling the dataset: a resource from which links lead, within a
      few hops, to all the others.
    annotations:
      note_section: "3.4"

  exampleResource:
    slot_uri: void:exampleResource
    range: uri
    multivalued: true
    description: The IRI of an entity typical of the dataset, for a reader to look up.
    annotations:
      note_section: "4.1"

  # VoID's properties: the structure of a dataset.

  uriSpace:
    slot_uri: void:uriSpace
    description: The string every entity IRI in the dataset starts with, such as http://example.org/resource/.
    pattern: "^[A-Za-z][A-Za-z0-9+.-]*:[^\\s]*$"
    comments:
      - VoID writes it as a literal, not as an IRI, so the range is a string, held to the form of an IRI's start.
    annotations:
      note_section: "4.2"

  uriRegexPattern:
    slot_uri: void:uriRegexPattern
    description: A regular expression in SPARQL's syntax that each entity IRI of the dataset satisfies.
    comments:
      - The validator checks no regular expression's syntax; tests/test_data.py compiles each one in the examples.
    annotations:
      note_section: "4.2"

  vocabulary:
    slot_uri: void:vocabulary
    range: uri
    multivalued: true
    pattern: "[^#]$"
    description: >-
      The namespace IRI of a vocabulary the dataset uses, as a term's IRI reads without its local name and
      without a final hash, such as http://xmlns.com/foaf/0.1/.
    annotations:
      note_section: "4.3"

  subset:
    slot_uri: void:subset
    range: Dataset
    multivalued: true
    pattern: "^[A-Za-z_][A-Za-z0-9_.+-]*:[^\\s]+$"
    description: Another dataset contained in this one, named by its IRI.
    annotations:
      note_section: "4.4"

  classPartition:
    slot_uri: void:classPartition
    range: ClassBasedPartition
    multivalued: true
    inlined: true
    inlined_as_list: true
    description: The dataset's slice for one class, given inside it.
    comments:
      - VoID makes it a narrower subset; here it is a value, so it does not inherit subset's range.
    annotations:
      note_section: "4.5"

  propertyPartition:
    slot_uri: void:propertyPartition
    range: PropertyBasedPartition
    multivalued: true
    inlined: true
    inlined_as_list: true
    description: The dataset's slice for one property, given inside it.
    comments:
      - VoID makes it a narrower subset; here it is a value, so it does not inherit subset's range.
    annotations:
      note_section: "4.5"

  class:
    slot_uri: void:class
    range: uriorcurie
    pattern: "^[A-Za-z_][A-Za-z0-9_.+-]*:[^\\s]+$"
    description: The class whose instances a class partition describes, named by its IRI, such as foaf:Person.
    annotations:
      note_section: "4.5"

  property:
    slot_uri: void:property
    range: uriorcurie
    pattern: "^[A-Za-z_][A-Za-z0-9_.+-]*:[^\\s]+$"
    description: The property whose triples a property partition holds, named by its IRI, such as foaf:name.
    annotations:
      note_section: "4.5"

  # VoID's statistics: each a count of zero or more, which may be an estimate.

  triples:
    slot_uri: void:triples
    range: integer
    minimum_value: 0
    description: How many triples the dataset holds; for a linkset, how many links.
    annotations:
      note_section: "4.6"

  entities:
    slot_uri: void:entities
    range: integer
    minimum_value: 0
    description: How many entities, resources with an IRI, the dataset describes.
    annotations:
      note_section: "4.6"

  classes:
    slot_uri: void:classes
    range: integer
    minimum_value: 0
    description: How many distinct classes the dataset's rdf:type triples name.
    annotations:
      note_section: "4.6"

  properties:
    slot_uri: void:properties
    range: integer
    minimum_value: 0
    description: How many distinct properties the dataset's triples use as predicates.
    annotations:
      note_section: "4.6"

  distinctSubjects:
    slot_uri: void:distinctSubjects
    range: integer
    minimum_value: 0
    description: How many distinct IRIs and blank nodes the dataset's triples have as subjects.
    annotations:
      note_section: "4.6"

  distinctObjects:
    slot_uri: void:distinctObjects
    range: integer
    minimum_value: 0
    description: How many distinct IRIs, blank nodes and literals the dataset's triples have as objects.
    annotations:
      note_section: "4.6"

  documents:
    slot_uri: void:documents
    range: integer
    minimum_value: 0
    description: >-
      How many RDF documents together carry the dataset, for example RDFa web pages.
    comments:
      - Use it where the triples are hard to count; triples and entities say more where they can be given.
    annotations:
      note_section: "4.6"

  # VoID's properties: linksets and documents.

  target:
    slot_uri: void:target
    range: Dataset
    pattern: "^[A-Za-z_][A-Za-z0-9_.+-]*:[^\\s]+$"
    description: Either dataset a linkset joins, named by its IRI.
    comments:
      - >-
        Linkset makes it a list of two. The slot itself stays single-valued, so that subjectsTarget and
        objectsTarget, its narrower slots, inherit one value each.
    annotations:
      note_section: "5.1"

  subjectsTarget:
    slot_uri: void:subjectsTarget
    is_a: target
    range: Dataset
    description: The dataset at the subject end of every link in a linkset, named by its IRI.
    annotations:
      note_section: "5.1"

  objectsTarget:
    slot_uri: void:objectsTarget
    is_a: target
    range: Dataset
    description: The dataset at the object end of every link in a linkset, named by its IRI.
    annotations:
      note_section: "5.1"

  linkPredicate:
    slot_uri: void:linkPredicate
    range: uriorcurie
    pattern: "^[A-Za-z_][A-Za-z0-9_.+-]*:[^\\s]+$"
    description: The property every link of a linkset has as its predicate, such as owl:sameAs.
    comments:
      - A linkset has one; links with two predicates make two linksets.
    annotations:
      note_section: "5.3"

  inDataset:
    slot_uri: void:inDataset
    range: Dataset
    pattern: "^[A-Za-z_][A-Za-z0-9_.+-]*:[^\\s]+$"
    description: The dataset that this document's triples belong to, named by its IRI.
    comments:
      - A document names one; a document in two datasets points at a dataset that holds both as subsets.
    annotations:
      note_section: "6.3"
