The Logic Of Semantic Annotations

Annotations
The below HTML fragment intends to markup the name and the address of a person. However as this markup is suitable for humans using a web browser (anyone understands that this is the name of a person and hers address) it is not at all useful for a computer application tying to understand the name and the address of a person. One solution is to annotate the above markup such that a computer application can understand the name and the address of a person. The annotation properties must come from a vocabulary that can be understood by the application, therefore the markup MUST declare the vocabulary it uses. The RDFa mechanism uses three attributes to encode this information:
 * - an attribute to express the particular annotation vocabulary to be used.
 * - an attribute to express the particular object (type) to be described by the markup
 * - an attribute to encode a specific property of the object type described by the markup.

One can use them as below:

As expressed by the annotation definition the annotation object must conform with the ontological definition of the property.

But what is "ontological definition"?

Types, subtypes
Schema.org vocabulary defines various types such as Person, CreativeWork, Restaurant and so on. The type Thing is the supertype of all schema types, therefore its properties can be used by all sub types.

For example, the property image is defined by Thing therefore it can be used by all sub types e.g., by Person or by Book or Place, Review and so on.

Person is identified by the URI  http://schema.org/Person  as Book is identified by  http://schema.org/Book . When one wants to annotate using a type it MUST use its Web identifier ( URI).

Properties
Basically each concept and property of a vocabulary is formally described. Each property has a domain (the objects than can use the property) and a range (the structure of the value of the property). Properties are inherited from the supertypes.

For example, Schema.org vocabulary defines the property name with the domain Thing and the range Text. Therefore name can be used by all object types that are subclasses of Thing particularly in our example, by the class Person. The value of name must be an instance of Text (as Text is the range of property name). By consequence, the way we encoded Jane Doe as a name conforms with the property definition.

However the way of encoding the Jane Doe address does not conform with the definition of property address.