Skip to content

Display of Data Patterns

Not all information related to a reference entity is expressed as simple key-value triples. To display more complicated and nested data patterns in a user-friendly way, corresponding display patterns can be configured.

A display pattern contains two components:

  • A condition that specifies to which resources the rule should be applied:

    • Resources of a certain type or
    • Resources that are referred to with certain predicates.
  • A list of expressions, concatenated together to form the final value:

    • Plain Text,
    • Newlines or
    • References to other properties

Example: Resources of type qudt:QuantityValue contain both numeric values (e.g. 50.3) and a unit (e.g. kg). A display pattern rule could define that the whole resource is presented to the user as 50.3 kg.


Display patterns can be administrated in the "admin" view, "configuration" tab, in the section "Display Patterns".

New patterns can be added with the "plus" symbol in the upper right corner, existing patterns can be edited or deleted.

Configuration of display patterns

The pattern's configuration consists of the following parts:

  • Name: The name should briefly describe what the pattern is used for and allows administrators to recognize the pattern easily. It does not affect the application of the pattern itself.
  • Entity Types: A value must have one of the given entity types for the display pattern to be applied. Each type is a valid URI. If no entity type is given, the type is not checked. If several types are given, it is sufficient if the entity has one of the types.
  • Properties: The value to display must be referred to by one of the given properties. If no property is given, all properties are accepted. If several properties are given, the entity to display must be referred by one of them.

    There must be at least one entity type or property specified. If both entity types and properties are specified, the rule matches when the value is linked to the entity by one of the properties and the value is of one of the properties. * Concatenated Values: When an entity is matched according to the entity types and properties described above, a list of expressions are evaluated and concatenated to calculate the result. Each expression can of one of the following types:

    • Text: The given text is appended to the result.
    • Newline: A new line is started. The shown value can be spread over several lines with options.
    • Path: Starting from the value, the given SPARQL path is evaluated and the found solution is shown. This option is used to extract certain values from the data. Only sequences of URIs are supported, each URI is put in angle brackets (like <>). A sequence is a list of such URIs, separated by slashes (/).


The following Turtle file shows an example of a unit definition (Kilogram) and an entity that has a "QuantityValue" and an address. In reality, the definition of a unit and the value often reside in separate datasets.

We show two examples of how to configure Accurids to present these values concisely.

@prefix test: <>
@prefix qudt: <> .
@prefix unit: <> .
@prefix rdfs: <> .
@prefix skos: <>

unit:KiloGM a qudt:Unit ;
      qudt:hasDimensionVector <> ;
      qudt:hasQuantityKind <> ;
      qudt:symbol "kg" ;
      rdfs:label "Kilogram"@en.

      a test:Example ;
      rdfs:label "Example with Address" ;

      test:hasAddress [
        test:street "Eisenbahnweg 7-9" ;
        test:city "52078 Aachen"
      ] ;

      test:hasWeight [
        a qudt:QuantityValue ;
        qudt:numericValue 60.0 ;
        qudt:unit unit:KiloGM
      ] .

When the two example display patterns below are configured, the example's entity should be presented as shown here:

Configuration of display patterns

Example: QUDT Quantity Value

The first pattern will match on QUDT quantity values and shows the value and the unit together as a short string. For the example above as 60.0 kg.

  • Name: Quantity Value (can be chosen arbitrarily)
  • Entity types: Value (The pattern should be applied to entities of this type)
  • Properties: None, the pattern is applied to values of all properties.
  • Concatenated Values:
  • Path: <> is the property that should be printed first.
  • Text: A single space should separate value and unit.
  • Path: <>/<> is a SPARQL path consisting of two steps. First, we navigate from the displayed entity via the unit property to the unit entity, then we look for the unit's symbol property which is kg in the example.

Configuration of display patterns

Example: Simple Address

This pattern shows how the properties are used to specify to which values the display pattern should be applied.

  • Name: Address (can be chosen arbitrarily)
  • Entity types: None, the pattern is applied to all kinds of entities.
  • Properties: specifies that this rule should only be applied to values that are referenced with this predicate.
  • Concatenated Values:
  • Path: <> The first line contains the street.
  • Newline: Between street and city should be shown a line break.
  • Path: <> The second line contains the city.

Screenshot of the address example configuration