Widoco

Metadata

There are two ways to make WIDOCO aware of the metadata of your ontology:

In this document we illustrate how Widoco uses metadata in the final documentation of your ontology, using both options specified above.

Namespaces used in this document

Namespace prefix URI
bibo http://purl.org/ontology/bibo/
cc http://creativecommons.org/ns#
dc http://purl.org/dc/elements/1.1/
dcterms http://purl.org/dc/terms/
doap http://usefulinc.com/ns/doap#
foaf http://xmlns.com/foaf/0.1/
mod https://w3id.org/mod#
obo http://purl.obolibrary.org/obo/
org http://www.w3.org/ns/org#
owl http://www.w3.org/2002/07/owl#
pav http://purl.org/pav/
prov http://www.w3.org/ns/prov#
rdfs http://www.w3.org/2000/01/rdf-schema#
schema https://schema.org/
sw http://www.w3.org/2003/06/sw-vocab-status/ns#
skos http://www.w3.org/2004/02/skos/core#
vaem http://www.linkedmodel.org/schema/vaem#
vann http://purl.org/vocab/vann/
vcard http://www.w3.org/2006/vcard/ns#
wdrs http://www.w3.org/2007/05/powder-s#
widoco https://w3id.org/widoco/vocab#

Metadata usage in WIDOCO

This section explains the metadata recognized by WIDOCO for both ontology annotations and term annotations.

Vocabulary annotations

The table below shows which ontology metadata annotations are recognized in WIDOCO in alphabetical order. The links in the second column redirect to the corresponding sections of the good practice document.

Obligation Metadata category Ontology annotation property* config.properties field(s)** Accepted property value Example
OPTIONAL Abstract dc:abstract, dcterms:abstract abstract Text ontology, config
OPTIONAL Backwards compatible with owl:backwardCompatibleWith backwardCompatibleWith URI ontology, config
OPTIONAL Bibliographic citation dcterms:bibliographicCitation, schema:citation citeAs Text ontology, config
OPTIONAL Code repository schema:codeRepository, doap:repository codeRepository URI ontology, config
RECOMMENDED Contributors dcterms:contributor, dc:contributor, schema:contributor, pav:contributedBy, doap:documenter, doap:maintainer, doap:helper, doap:translator contributors, contributorsURI, contributorsInstitution, contributorsInstitutionURI Text or Person or BNode ontology, config
OPTIONAL Creation date dcterms:created, schema:dateCreated, prov:generatedAtTime, pav:createdOn, doap:created dateCreated Text ontology, config
RECOMMENDED Creators dcterms:creator, dc:creator, schema:creator, pav:createdBy, pav:authoredBy, prov:wasAttributedTo, doap:developer, foaf:maker authors, authorsURI, authorsInstitution, authorsInstitutionURI Text or Person or BNode ontology, config
OPTIONAL Description dc:description, dcterms:description, schema:description, rdfs:comment, skos:note, doap:description, doap:shortdesc description Text ontology, config
OPTIONAL Diagram foaf:image, foaf:depiction, schema:image diagram Text ontology, config
OPTIONAL DOI bibo:doi DOI Text ontology, config
OPTIONAL Extended ontologies voaf:extends extendedOntologyNames, extendedOntologyURIs URI ontology, config
OPTIONAL Funders (org/person) foaf:fundedBy, schema:funder funders Text orURI ontology, config
OPTIONAL Funding grants schema:funding fundingGrant Text orURI ontology, config
OPTIONAL Incompatible with owl:incompatibleWith incompatibleWith URI ontology, config
RECOMMENDED (good practice in ontology engineering) Imported ontologies owl:imports importedOntologyNames, importedOntologyURIs URI ontology, config
OPTIONAL Publication date dcterms:issued, schema:dateIssued dateIssued Text ontology, config
OPTIONAL License dc:rights, dcterms:license, schema:license, cc:license, doap:license licenseName, licenseURI, licenseIconURL Text orURI ontology, config
OPTIONAL Logo foaf:logo, schema:logo logo URI ontology, config
RECOMMENDED Name rdfs:label, mod:acronym, schema:alternateName, skos:prefLabel ontologyName Text ontology, config
RECOMMENDED Namespace prefix vann:preferredNamespacePrefix ontologyPrefix Text ontology, config
RECOMMENDED Namespace URI vann:preferredNamespaceUri ontologyNamespaceURI URI ontology, config
OPTIONAL Modification date dcterms:modified, schema:dateModified dateModified Text ontology, config
RECOMMENDED Previous version dc:replaces, dcterms:replaces, prov:wasRevisionOf, pav:previousVersion, owl:priorVersion previousVersionURI URI ontology, config
OPTIONAL Publisher dcterms:publisher, dc:publisher, schema:publisher publisher, publisherURI, publisherInstitution, publisherInstitutionURI Text or Organization or BNode ontology, config
OPTIONAL Similar resources rdfs:seeAlso seeAlso Text ontology, config
OPTIONAL Status bibo:status, mod:status, schema:creativeWorkStatus status Text or Status ontology, config
OPTIONAL Source dc:source, dcterms:source, prov:hadPrimarySource, wdrs:describedBy source URI ontology, config
RECOMMENDED Title dc:title, dcterms:title, schema:name ontologyTitle Text ontology, config
RECOMMENDED Version IRI owl:versionIRI thisVersionURI URI ontology, config
RECOMMENDED Version number owl:versionInfo, schema:schemaVersion, pav:version, dcterms:hasVersion ontologyRevisionNumber Text ontology, config

* All listed properties are supported by WIDOCO.

** Configuration properties do not support URIs or blank nodes. Hence, additional properties are needed (like authorsURI, contributorsURI) to annotate URIs in case they are needed.

Custom annotations

We prioritize reusing metadata properties already defined elsewhere. However, a small subset of OPTIONAL annotation properties (i.e., introduction and the URL to the different serializations) have been introduced by WIDOCO to customize parts of the documentation from the ontology itself:

Obligation Metadata category Ontology annotation property* config.properties field(s)** Accepted property value Example
OPTIONAL Introduction widoco:introduction introduction Text ontology, config
OPTIONAL N-Triples serialization widoco:ntSerialization NTSerialization URI ontology, config
OPTIONAL JSON-LD serialization widoco:jsonldSerialization JSONLDSerialization URI ontology, config
OPTIONAL RDF-XML serialization widoco:rdfxmlSerialization RDFXMLSerialization URI ontology, config
OPTIONAL Turtle serialization widoco:turtleSerialization TurtleSerialization URI ontology, config

Term annotations (concerning classes, properties and data properties)

The table below summarizes all the metadata annotations recognized for ontology terms, in alphabetical order. Note that there are no config.properties annotations here, as these annotations are only read from the ontology file. The links in the second column redirect to the corresponding sections of the good practice document.

Obligation Metadata category Ontology annotation property Accepted property value Example
RECOMMENDED Definition rdfs:comment, skos:definition Text ontology
OPTIONAL Deprecation status owl:deprecated Boolean ontology
OPTIONAL Editorial note skos:editorialNote Text ontology
OPTIONAL Example vann:example, skos:example Text ontology
RECOMMENDED Label rdfs:label, skos:prefLabel, obo:IAO_0000118 Text ontology
OPTIONAL Original source rdfs:isDefinedBy, dc:source URI ontology
OPTIONAL Rationale vaem:rationale Text ontology
OPTIONAL Scope note skos:scopeNote Text ontology
OPTIONAL Status sw:term_status, obo:IAO_0000114 Text ontology

Example: Using ontology annotations

The following Turtle code block shows sample annotations for each of the metadata categories on an ontology with namespace URI https://w3id.org/example:

@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix xml: <http://www.w3.org/XML/1998/namespace> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix dcterms: <http://purl.org/dc/terms/> .
@prefix dc: <http://purl.org/dc/elements/1.1/> .
@prefix schema: <https://schema.org/> .
@prefix voaf: <http://purl.org/vocommons/voaf#> .
@prefix vann: <http://purl.org/vocab/vann/> .
@prefix widoco: <https://w3id.org/widoco/vocab#> .
@prefix bibo: <http://purl.org/ontology/bibo/> .

<https://w3id.org/example> rdf:type owl:Ontology ;
    owl:versionIRI <https://w3id.org/example/1.0.1> ;
    dcterms:abstract "An example vocabulary designed to illustrate how to publish vocabularies on the Web following the FAIR principles"@en ;
    dc:description "This is an example ontology to illustrate some of the annotations that should be included"@en ;
    dc:title "The example ontology"@en ;
    dcterms:created "February 5th, 2020"@en ;
    dcterms:creator "Daniel Garijo"@en ,"Maria Poveda-Villalon"@en ;
    dcterms:license <http://creativecommons.org/licenses/by/2.0/> ;
    vann:preferredNamespacePrefix "exo"@en ;
    vann:preferredNamespaceUri "https://w3id.org/example" ;
    schema:citation "Cite this vocabulary as: Garijo, D. and Poveda-Villalón, M. The example ontology 1.0.1."@en ;
    rdfs:comment "An example vocabulary designed to illustrate how to publish vocabularies on the Web following the FAIR principles. This vocabulary describes three simple classes with 3 properties and a data property."@en ;
    rdfs:label "Example" ;
    owl:backwardCompatibleWith <https://w3id.org/example/1.0.0> ;
    owl:priorVersion <https://w3id.org/example/1.0.0> ;
    voaf:extends <https://w3id.org/otherOntology> ;
    owl:imports <http://www.w3.org/2000/01/rdf-schema> ;
    bibo:status <http://purl.org/ontology/bibo/status/draft> ;
    foaf:fundedBy <https://example.org/fundingOrganization> ;
    schema:funding <https://example.org/fundingGrant> ;
    schema:codeRepository "https://github.com/dgarijo/example"^^xsd:anyURI;
    widoco:introduction "A paragraph with the introduction section of the documentation about your resource"@en ;
    widoco:rdfxmlSerialization "https://example.org/serialization/ontology.xml"^^xsd:anyURI ; 
    owl:versionInfo "1.0.1" .
    #If content negotiation is enabled, the widoco:rdfxmlSerialization annotation may not be needed.

(Back to table)

Annotating the ontology using entities:

Certain categories like Authors, Contributors and Publisher can be annotated as RDF entities. If a URI or a blank node are used in these categories, Widoco will look for the the resource within the ontology itself (resolving external URIs is not currently supported). An example using a URI and a blank node can be seen below:

If URIs are used to define the creators of an ontology, the result would be similar to the snippet below:

@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix schema: <https://schema.org/> .

<https://w3id.org/example> rdf:type owl:Ontology ;
    schema:creator <https://w3id.org/example/ind/dgarijo> ,<https://w3id.org/example/ind/mpoveda> .

If blank nodes are used, then the the result should look similar to the following snippet:

@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix schema: <https://schema.org/> .

<https://w3id.org/example> rdf:type owl:Ontology ;
    schema:creator [
        a schema:Person;
        schema:name "Daniel Garijo"
    ] ,[
        a schema:Person;
        schema:name "María Poveda"
    ] .

Widoco will recognize the following properties when describing agents (persons or organizations):

Metadata category Ontology annotation property Accepted property value
Affiliation schema:affiliation, org:memberOf Text or Organization or BNode
Family Name schema:familyName, vcard:family-name, foaf:family_name Text
Full name rdfs:label, schema:name, vcard:fn, foaf:name Text
Given name schema:givenName, vcard:given-name, foaf:givenname Text
E-mail schema:email, vcard:hasEmail, foaf:mbox Text
URL schema:url, vcard:hasURL, foaf:homepage URI

Annotating ontology terms:

For status, the known values are: unstable, testing, stable and archaic

@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix vann: <http://purl.org/vocab/vann/> .
@prefix skos: <http://www.w3.org/2004/02/skos/core#> .
@prefix sw: <http://www.w3.org/2003/06/sw-vocab-status/ns#> .
@prefix : <https://w3id.org/example#> .

:Researcher rdf:type owl:Class ;
            vann:example "Daniel Garijo."@en ;
            vaem:rationale "The concept Researcher was added to the ontology to represent those authors of scientific publications that belong to a public institution."@en ;
            rdfs:comment "A researcher is a person who publishes scientific papers, writes research proposals and mentors students"@en ;
            sw:status "unstable";
            rdfs:isDefinedBy <https://w3id.org/example#> ;
            skos:editorialNote "Some editorial note by the creator of the term" ;
            skos:scopeNote "A note that helps to clarify the meaning and/or the use of a concept" ;
            rdfs:label "Researcher"@en .

Example: Using a configuration file

Create a config.properties file and use the -confFile option to invoke Widoco. The metadata is declared with a key=value pair as shown below:

abstract=An example ontology
authors=First Author;Second Author
authorsURI=http://example.org/author1;http://example.org/author2
authorsInstitution=First author institution;Second author institution
authorsInstitutionURI=https://www.isi.edu/;https://www.isi.edu/
backwardCompatibleWith=https://w3id.org/example/1.0.0
citeAs="add some citattion text here."
codeRepository=https://github.com/dgarijo/example
contributors=First contributor;Second contributor
contributorsURI=http://example.org/contributor1;http://example.org/contributor2
contributorsInstitution=First contributor institution;Second contributor institution
contributorsInstitutionURI=https://isi.edu/;https://isi.edu/
dateCreated="13 Nov, 2022"
dateIssued="14 Nov, 2022"
dateModified="15 April, 2023"
description=A description of what the ontology does goes here
extendedOntologyNames=test1; test2
extendedOntologyURIs=http://example.org/test1; http://example.org/test2
DOI=https://dx.doi.org/SOME/DOI
funder=https://example.org/institution
funding=https://example.org/fundingGrant
incompatibleWith=https://w3id.org/example/0.0.1
images=image1.png;image2.png
importedOntologyNames=Imported Ontology 1; Imported Ontology 2
importedOntologyURIs=http://example.org/test11; http://example.org/test22
introduction=A brief text for the introduction section may be written here.
licenseURI=http://creativecommons.org/licenses/by/2.0/
licenseName=CC-BY
licenseIconURL=https://i.creativecommons.org/l/by/2.0/88x31.png
logo="https://example.org/logo.svg"
ontologyName=The Cohort Ontology
ontologyNamespaceURI=https://w3id.org/example
ontologyTitle=The Example Ontology
ontologyPrefix=exo
ontologyRevisionNumber=1.0.0
pathToAbstract=abstract.html (superseedes abstract)
pathToDescription=description.html (superseedes description)
pathToIntro=intro.html (supersedes introduction)
pathToOverview=overview.html
pathToReferences=references.html
previousVersionURI=https://w3id.org/example/1.0.0
publisher=Ontology Engineering Group
publisherURI=https://oeg-upm.es
publisherInstitution=UPM
publisherInstitutionURI=https://www.upm.es
thisVersionURI=https://w3id.org/example/1.0.1
source=http://source1;http://source2
seeAlso=http://firstResource
status=Ontology Specification Draft
JSONLDSerialization=ontology.nt
NTSerialization=ontology.nt
RDFXMLSerialization=ontology.xml
TurtleSerialization=ontology.ttl

(Back to table)

Glossary

Text: A literal written in a textual manner.

URI: A URL that describes the target resource.

Boolean: True or False.

Status: Status of a term, or the ontology document. For terms, known statuses are: unstable, testing, stable and archaic (see the W3C sw-vocab for reference).

Person: Entity used to refer to people in general.

Organization: Entity used to represent an insitution or company. Typically used as the range of the publisher metadata property.

BNode: Blank node, used to refer to an entity without assigning an URI to that entity.

(Back to table)