Semantic Adapter

The semantic adapter allows to translate data coming from heterogeneous sources into homogeneous data expressed in RDF following the AURORAL ontology by using mappings, allowing semantic interoperability, allowing interoperability. This tutorial explains how to install and manage the Semantic Adapter.

The Semantic Adapter counts with a Playground portal to test the mappings and also learn how to develop them:

https://helio-playground.linkeddata.es/home

Installation

To install the Semantic Adapter, the prerequisite is to install Docker. Once installed, create a new file called docker-compose.yml with the following code:

version: '3'
services:
  helio-rest:
    container_name: helio
    image: acimmino/helio-rest:latest
    volumes:
      - ./helio-db:/helio/app
    ports:
      - "4567:4567"
  playground:
    container_name: playground
    image: emiliocrespoperan/helio-frontend:latest
    depends_on:
      - helio-rest
    ports:
      - "4201:80"
    environment:
      - HELIO_REST_HOST=http://localhost:4567
      - HELIO_MODE=APP

It should be noted that the semantic adapter has two modes:

Once created, open the terminal, go to the file location directory and run:

docker compose up

Docker will do all the installation process for you.

Semantic Adapter playground

The semantic adapter playground provides an interface to learn how to write the mappings and another interface to test the mappings.

In the first interface, the playground, the user can select the builder and try the mapping.

Playground

In the second interface, the tour, a list of tutorials can be followed to learn how to develop mappings. This list will be expanded over time. The tour will be updated automatically once new tours are added; there is no need to install the docker recipe again.

Playground_tour

Semantic Adapter app

The semantic adapter app provides an interface to add additional components (for example, those developed by other users) and an interface to create new/modify/delete mappings and the information about them.

On the one hand, the Semantic Adapter have a marketplace, where the user can find all the components that are being used by the Semantic Adapter. This list can be extended by adding new components. In order to do this, the user can add new components with the button “new component”.

SA_App_Marketplace

To add a new component, the Semantic Adapter needs the URL of the “.jar” file, the class (the package and the java class, for example, “helio.providers.MqttProvider”, where “helio.providers” is the package and “MqttProvider” the java class), and the type of the component (provider, action, etc).

SA_App_AddComp

Once created, if there are no errors, it will appear with the rest of the components.

SA_App_CompAdded

On the other hand, the Semantic Adapter provides a list of the mappings added to use. New mappings can be added with the button “New mapping”.

SA_App_AddMapping

To add a new mapping, the Semantic Adapter needs a name for the component, the builder (normally SIoTRxBuilder) and a mapping template to test the mapping.

SA_App_Marketplace

In the next step, the mapping provided will be tested.

SA_App_MappingTest

If the test is correct, the mapping is completed and will be added to the list.

App_Mapping_done

In the list, the user can modify a mapping, can delete a mapping, and can get the data, through a URL endpoint.

App_with_mapping

This URL endpoint can be use by other programs to get the data, for example, Postman.

App_testing_endpoint


Brought to you by the AURORAL community, keep posted! 💪