Configuring Shortcut Properties
(Please note: This feature is available since Accurids 1.6.0)
Shortcut properties allow to make information more visible which is located somewhere in the nested data structures.
Warning
This feature allows to automatically generate a large amount of data and put additional load to a system when a shortcut is added. Please consider this before using it on a production system.
In particular, take caution when defining rules to infer "transitive" relationships (e.g. if a class "A" is subclass of class "B", and "B" of "C", then "A" is also a subclass of "C"). If you use such a relation to visualize a hierarchy in the tree view, this results in every element in the hierachy being directly under the root element, rendering the feature practically unusable.
The two main components of a shortcut is a "path" which defines where to look for certain information and a "property" that is created to link directly to that information.
Let's take this small example, where we have a medicinal product (defined using the IDMP ontology) with a marketing authorization which is applicable in a certain country.
@prefix ex: <https://accurids.com/example/> .
@prefix prod: <https://spec.pistoiaalliance.org/idmp/ontology/ISO/ISO11615-MedicinalProducts/> .
@prefix cd: <https://www.omg.org/spec/Commons/ContextualDesignators/> .
@prefix country: <https://www.omg.org/spec/LCC/Countries/ISO3166-1-CountryCodes/> .
ex:MagicPowder a prod:MedicinalProduct;
rdfs:label "Magic Powder (tm)";
prod:hasAuthorization [
a prod:MarketingAuthorization;
rdfs:label "Magic Powder, tablet, 15mg (Auth. for Germany)";
cd:isApplicableIn country:Germany;
].
To see in which countries a product has authorizations, the user has to open the authorization to access the information.
We want to introduce a new property for the product which directly refers to the country
(or countries) of the authorization.
To do that, We now define a new shortcut property ex:authorizedInCountry
where we first follow
the property prod:hasAuthorization
, then the property cd:isApplicableIn
.
For the configuration, we need the full URIs without prefixes: The property is https://accurids.com/example/authorizedInCountry
, the
The property path in SparQL syntax is <https://spec.pistoiaalliance.org/idmp/ontology/ISO/ISO11615-MedicinalProducts/hasAuthorization>/<https://www.omg.org/spec/Commons/ContextualDesignators/isApplicableIn>
.
The shortcut can be defined in the "Shortcut" section on the configuration page. Each shortcut has three fields:
- Description: A text field that allows us to organize the configured shortcuts and explain what the shortcut does. It is only used for the configuration page.
- Shortcut Property: The URI of the property that should be generated.
- Path: A path in
SparQL property path format.
Currently supported are the sequence (
/
) and inverse (^
) operators. Prefixes are not supported, URIs need to be written in full in angle brackets (<...>
).
After defining the shortcut, the new properties will be computed in the background. Depending on the size of the data that needs to be analyzed it can take several minutes until the result will be available to the user.
The computed property is then contained in the database like any other data, and can also
be used for searches. The generated data is located in the dataset with tag shortcuts
.
When we have now a look again at our product, we see that the new property refers to the country: