Semantic information

The semantic information is the part of the entry where we will define the different attributes for an entry. This are the fields available to do so:

Semantic information fields

The first two fields that you can see are the entry type and the ontology type, which edit two of the features defined in the semantic information most commonly used. Both have been mentioned in the import process.

  • Entry type defines if the entry is considered an entity or a concept.
  • Ontology type defines if the value within the ontology associated to the entry. The menu has available a number of values from our ontology (the most common ones), but you can also write whichever value you want by selecting Write your own value.
    Additional info set in the import process

    In this case all the entities imported would be of the type Characters, a node that does not exist in our ontology, in the node Person, which is part of our basic ontology.

Did you notice...?

That when you select different elements in the entry type and ontology type fields, the part affected by this modification changes automatically in the Semantic information tab.

The third field in this section is composed by two tabs: semantic information and raw view. These two tabs show the complete semantic information associated to the entry. The first one, semantic information, shows a user-frienly version of the information while raw view shows this same information but in the format they are saved in the dictionary and interpreted by the different APIs.

The tab semantic information cannot be modified. The only way changes will appear in it is through the manipulation of the entry type and the ontology type fields.

On the other hand, the data contained in raw view will be completely editable:

Raw semantic information

In this field and through a specific syntax, you can define any kind of attribute and associate it to your entry. The fields entry type and ontology type modify two of these attributes:

  • entry type modifies the attribute class inside the complex attribute sementity.
  • ontology type modifies the attribute type, also inside the complex attribute sementity.

Important

Any changes in any of the fields related to the semantic information will not be definitive until they are saved.

Semantic information syntax

There are two possible attributes: simple and complex.

  • Simple attributes are defined separating with = the name from the value/s, and using | to separate the different values:
    ATTRIBUTE=VALUE_1[|VALUE_N]*
    • number_of_players=25
    • uniform_color_list=blue|red|yellow

    This is how these examples will look in the semantic information tab:

    Semantic information with simple attributes
  • Complex attributes are defined separating with / the name from the sub-attributes, and using @ to separate the sub-attributes from each other:
    COMPLEX_ATTRIBUTE/ATTRIBUTE_1=VALUE_11[|VALUE_1N]*[@ATTRIBUTE_N=VALUE_N1[|VALUE_NN]*]*
    • sementity/class=instance@type=Top>Organization>SportsOrganization>SportsTeam
    • sports_team/number_of_players=25@uniform_color_list=blue|red|yellow

    This is how these examples will look in the semantic information tab:

    Semantic information with complex attributes

Each attribute will be included in a new line and if they include _list in their name, they will be considered arrays at the output of the APIs that show semantic information.

There are a number of checks that will be carried out over the information included in Raw view. This means that when the entry is saved, there are a number of errors that may appear:

  • Format errors, which appear when one of the attributes does not have the correct format.
    Wrong format error
    Wrong value for class attribute
  • Forbidden name errors, when you try to create an attribute with one of the forbidden values.
    Forbidden attribute name error

    The forbidden attribute names are the following: form, id, dictionary, type and relevance.