Managing dynamic data in knowledge bases, i.e. statements that are only valid for a certain period of time, is a very well-known problem for knowledge acquisition and representation, because data need to be constantly re-evaluated to allow reasoning. Let us imagine a very basic example, such as the knowledge base representing the Knowledge Media Institute working environment. While information about locations is static (e.g. the coordinates of a room), temperature, humidity, wifi signal or number of people in a room change often and the statements about them in the knowledge base might not be valid anymore after some time.
Common solutions to this, e.g. providing time-stamped versions of the knowledge base or using sensors to constantly stream the information, might be suitable for a simplified scenario such as the KMi one, but are costly and less flexible in terms of data collection if applied at large-scale (e.g. in a smart city environment). Much of the information provided is likely not be required, and only queries at specific locations would be allowed.
In our work “Update of time-invalid information in Knowledge Bases through Mobile Agents”, to be presented at the MIRROR-16 workshop at the International Conference on Intelligent Robots and Systems (IROS 2016), we propose to use RDF and SPARQL as a framework for knowledge representation, combined with an autonomous mobile agent which updates the time-invalid information of the knowledge base on demand. We designed and implemented a process, called DKA-robo (Dynamic Knowledge Acquisition with a Robot), in which a user submits a query to a knowledge base and receives a set of results that are valid in time, provided that there exists a plan that enables the agent to collect the required information in the limited time before it becomes invalid.
The process briefly consists in:
1) the user expresses the query to the knowledge base. This consists in a set of RDF quadsq = (t, g), where t is the ⟨subject, predicate, object⟩triple and g is the named graph to which t belongs, representing the time at which t will expire. When the query is executed, the execution process is monitored to retrieve the graphs from which triples are obtained and identify those that have expired.
2) The planner receives the time-invalid quads and asks the mobile agent for its location. Based on this, it calculates the plan to send to the agent, i.e. the right sequence of actions to perform so that none of the statements in the answer set remains time-invalid. The plan is evaluated using a best-first strategy designed to minimise the time-to-invalidity of the considered quads.
3) When the robot receives the plan and performs it, each new piece of information collected is sent to the knowledge base, which is updated. The time-to-invalidity of the new information is evaluated using a set of time-validity rules expressed as a triple pattern p associ- ated to a duration d. The rule for which the triple matches the pattern p that has the shortest duration is selected, and a new quad q = (t,current time+d) is written in the knowledge base.
4) Once all the actions have been executed, the user is shown the answer to its query. If no answer is received, this means that there is no plan that can be executed so that all the statements in the answer are time-valid.
The feasibility of our approach was evaluated using a robot moving in the KMi department on demand, and updating the outdated information of the KMi knowledge base. We acquired a map of the north wing of KMi through SLAM, as provided in the gmapping package of the Robot Operating System (ROS). As platform, we used a iRobot Create 2 equipped with a Kinect to emulate the laser range finder.
We then built the KMi knowledge base by representing environments as URI resources (e.g. location:Podium) and coordinates, types of area and sensor information (temperature, humidity, wifi signal quality in dB and number of people), to define the set of static and dynamic RDF predicates. We defined the set of time-validity rules to be matched against a triple once a new information is sensed, in order to establish the triple expiry date. We then designed four scenarios (e.g. where is the best wi-fi signal, or which meeting room is free) and analysed the behaviour of the process.
The promising results, that can be seen online (videos 1, 2, 3 and 4), demonstrated that using autonomous mobile agents combined with Semantic Web technologies allow more flexibility and reusability, as well as avoiding the deployment and management of unnecessary data-flows.