Getting Started

& how to use RealEstateCore

Making the Knowledge Graph of a building

In this section you will find examples of how to use the RealEstateCore ontology both as triplets (the foundation of semantic web technologies) and how we use it in a high capacity production environment with document oriented storage (using JSON or JSON-LD).

RealEstate, Building, and Location

The real estate’s name is “Great view estate”, it has been assigned an UUID (would look something like “8a9c11d9-60c8-4c37-bc47-b7b4f44e74d8”), let’s call it “EstateUUID”. The main building on the real estate is called “Main Building” and it has also been assigned an UUID, let’s call it “MainBuildingUUID”. The second building is called “Annex Building” -> “AnnexBuildingUUID” (same for the land, etc. -> “LandUUID”).

Using RealEstateCore we can express these statements in RDF triplets as follows:

EstateUUID isA RealEstate
EstateUUID hasPopularName “Great view estate”
LandUUID isA Land
LandUUID belongsTo EstateUUID

And defining that the “Main Building” and “Annex Building” are BuildingStructure:s and belongs to “Great view estate”:

MainBuildingUUID isA BuildingStructure
MainBuildingUUID belongsTo EstateUUID
MainBuildingUUID hasSourceDataPopularName “Main Building”
AnnexBuildingUUID isA BuildingStructure
AnnexBuildingUUID belongsTo EstateUUID
AnnexBuildingUUID hasSourceDataPopularName “Annex Building”

Device, Sensor, and Actuator

We define a Device as a thing made or adapted for a particular purpose, specifically a piece of electronic equipment.

  • A Sensor is a thing which detects or measures a physical property and records, indicates, or otherwise responds to it.

  • A Device has one or more Sensor(s) and/or Actuator(s).

  • An Actuator is a component that is responsible for moving and controlling a mechanism or system.


Let’s assume that we have 1 Sensor that measures temperature and that it is placed in a conference room called “Great Meeting” in the outlet air vent:

First, let’s define the conference room:

RoomUUID isA BuildingStructureComponent

MainBuildingUUID hasBuildingStructureComponent RoomUUID

RoomUUID hasPopularName “Great Meeting”

The definition of the Device and Sensor and that it is placed in RoomUUID:

DeviceUUID isA Device

SensorUUID isA Sensor

SensorUUID isPartOf DeviceUUID

SensorUUID isLocatedIn RoomUUID

Next we define that the Sensor records temperature and that it is placed in an outlet air vent:

SensorUUID hasQuantityKind Temperature

SensorUUID hasPlacementContext SupplyAir

  • QuantityKind describes the value observed by a Sensor or the value used by an Actuator.
  • PlacementContext describes in what context or media that the Sensor or Actuator is operating in. E.g in the SupplyAir or the ExhaustAir flow.

Crossing the chasm
Triplets-store to document-oriented-database

Applying RealEstateCore to our example

If we would apply RealEstateCore to our example “Great view estate” using a document-oriented database it would be represented as two collections, RealEstates and BuildingStructures with one and three documents respectively (in JSON).

As triplets:
EstateUUID isLocatedAt ”59.333239,18.061099,10”
EstateUUID hasPopularName “Great view estate”

As JSON:
{
”id”: ”EstateUUID”,
”isLocatedAt”: ”59.333239,18.061099,10”,
”hasPopularName”: ”Great view estate”
}

As JSON-LD:
{
”@context”: ”
http://w3id.org/rec/core/2.2/
”,
”@id”: ”http://mydatanamespace/EstateUUID”,
”isLocatedAt”: ”59.333239,18.061099,10”,
”hasPopularName”: ”Great View Estate”
}

More examples of how RealEstateCore can be implemented as JSON and JSON-LD will come.