18 Knowledge Representation Methods for Smart Devices in Intelligent Buildings Giuseppe Loseto Supervisor: Michele Ruta DEE, Politecnico di Bari via Re David 200 – I-70125 Bari, Italy loseto@deemail.poliba.it Abstract. Home and building automation aims at improving features and capabilities of household systems and appliances. Nevertheless, cur- rent solutions poorly support dynamic scenarios and context-awareness. The integration of knowledge representation features and reasoning tech- niques (originally devised for the Semantic Web) into standard home automation protocols can offer high-level services to users. A semantic- based approach is proposed, able to interface users and devices (whose characteristics are expressed by means of annotated profiles) within a service-oriented home infrastructure. 1 Introduction Home and Building Automation (HBA) –also known as domotics– is a growing research and industrial field, aimed at coordinating subsystems and appliances in a building to provide increased levels of user comfort and manageability, reduce energy consumption and minimize environmental impact. In latest years, the design of smart HBA environments is attracting efforts from several disciplines, including mobile and pervasive computing, wireless sensor networks, artificial intelligence and agent-based software, coalescing into a research area known as Ambient Intelligence (AmI) [12]. A crucial issue for feasible and effective AmI solutions lies in efficient resource/service discovery. Current HBA systems and standard technologies are still based on explicit user commands over static sets of operational scenarios, established during system design and installation. Conse- quently, they allow a low degree of autonomicity and flexibility. These restrictions can be by-passed through the adaptation and integration of Knowledge Repre- sentation (KR) formalisms and techniques originally conceived for the Semantic Web. Ontology languages, based on Description Logics (DLs), can be used to describe the application domain and relationships among resources in a way that can support inference procedures and matchmaking processes, in order to satisfy users’ needs and preferences to the best possible extent. 2 State of the Art Currently, most widespread technological standards for HBA –including KNX (www.knx.org), ZigBee (www.zigbee.org) and LonWorks (developed by Echelon 19 Corporation, www.echelon.com) – only offer static automation capabilities, con- sisting of pre-designed application scenarios. They do not allow autonomicity in environmental adaptation given a user profile and dynamic context-awareness. An early approach towards AmI was proposed in [10]. Intelligent agents were used to automate a service composition task, providing transparency from the user’s standpoint. Nevertheless, such an approach was based on service discov- ery protocols such as UPnP and Bluetooth SDP, presenting a too elementary discovery and supporting only exact match of code-based service attributes. Due to the growing interest in reducing energy consumption, several studies on AmI and multi-agent systems have been proposed for energy management and com- fort enhancement [3]. Unfortunately, these solutions either require direct user intervention or only support basic interaction between devices, lacking advanced resource discovery and composition capabilities. The use of knowledge represen- tation can allow to overcome such limitations. Knowledge Bases (KBs) will be exploited to enable a user-device interaction and to interconnect household appli- ances, using different protocols, in order to share services and data, e.g., related to device energy consumption [4]. In [1] an ontology-based domotic framework with a rule-based reasoning module was introduced to manage and coordinate heterogeneous devices endowed with semantic descriptions. The main weakness of the above works is in the presence of static rule sets and centralized KBs. A really pervasive environment requires a different approach, able to deal with the intrinsically dynamic, decentralized and unpredictable nature of AmI. 3 Proposed approach Framework. A general-purpose framework for HBA has been proposed, sup- porting semantic-enhanced characterization of both user requirements and ser- vices/resources provided by devices. Following pervasive computing spirit, during ordinary activities the user should be able to simultaneously exploit information and functionalities provided by multiple objects deployed in her surroundings. Each device should autonomously expose its services and should also be able to discover functionalities and request services from other devices. Technologies and ideas are borrowed from the Semantic Web initiative and adapted to HBA scenarios. Semantic Web languages, such as OWL1 , provide the basic terminological infrastructure for domotic ubiquitous KBs (u-KBs) which enable the needed information interchange. The fully exploitation of semantics in user and device description has several benefits which include: (i) machine- understandable annotated descriptions to improve interoperability; (ii) reason- ing on descriptions to characterize environmental conditions (context) and to support advanced services through semantic-based matchmaking. The reference framework architecture, shown in Figure 1, integrates both semantic-enabled and legacy home devices in a domotic network with an IP backbone. Coordination among user agents and domotic agents (representing 1 OWL Web Ontology Language, version 2, W3C Recommendation 27 October 2009, http://www.w3.org/TR/owl2-overview/ 20 (a) Testbed (b) Device Panel Fig. 1. Framework Architecture Fig. 2. Developed Testbed !"#$%&'()& *+("(,-+& '+)%($$.&/01+"& *2%& 3+$(4& 5+162#7& Play DVD Lighting Relax Play Classic Music Decrease Temp. High Safety Level Uncovered Medium Security Fig. 3. Concept Covering Result devices, rooms and areas) is facilitated by a home unit. Communication be- tween client agents and the home system may occur through either IEEE 802.11 or Bluetooth wireless standards. The discovery framework is based on a dis- tributed application-layer protocol. Optimized inference services [2] feature a Decision Support System (DSS) hosted by the coordination unit. Service dis- covery is not limited to identity matches (infrequent in real situations) but it supports a logic-based ranking of approximated matches allowing to choose re- sources/services best satisfying a request, also taking user preferences and con- text into account. Such an approach allows then user to require addressed ser- vices instead of simplistic device features. For example, the system could be able to reply to articulated requests as the one reported in what follows: I am tired and I have a splitting headache. For these reasons, I am very nervous and I wish a relaxing home environment. It is a warm evening and I feel hot. By sending a request to the home, an accurate home service selection can be performed, as shown in Figure 3. The selected service set includes suggestions for DVD play- back and music, following stored user preferences. A lower room temperature and soft lighting settings are selected to improve user comfort. Finally, system sets appropriate home safety and security settings inferred by the mobile match- maker exploiting the axioms in the ontology. An uncovered part of the request is also present, because there are no specific services able to match nervous user state. Methodology. In order to grant feasibility, the proposed framework was based on a fully backward-compatible extension of current domotic technologies. Con- sequently, besides review of the state of the art, the first research phase included a careful study of the most widespread HBA standards, in order to verify the possibility of a semantic enhancement and to select a reference protocol for sub- 21 sequent work. The second step involved the design of protocol enhancements to support the representation and exchange of semantic information, followed by an extensive evaluation through simulation campaigns. Then the framework has been defined in detail, including: (a) specification of an ontology for the HBA application domain able to support the functional and non–functional re- quirements of the project; (b) development and optimization of an embedded matchmaking engine, providing standard and non-standard inference services described in [2, 5]. Based on the theoretical framework, a testbed has been de- veloped to evaluate the effectiveness of the approach and to experiment about performance –considering several case studies, with user and device semantic descriptions varying in number and complexity. 4 Results KNX was selected as reference HBA standard due to its support for multiple communication media, availability of development tools and wide industry ac- ceptance. At protocol level, main contribution includes the definition of new data structures and application-layer services [6] conforming KNX 2.0 specifica- tion to store and exchange semantic metadata. Due to the reduced availability of both device storage and protocol bandwidth in current domotic infrastructures, the proposed enhancements envisage the use of a compression algorithm specifi- cally targeted to document in XML-based ontological languages [11]. The mobile semantic matchmaker in [7] has been extended with the Concept Covering infer- ence service [5] –in addition to Concept Abduction and Concept Contraction [2]– to support covering of a complex request through the conjunction of elementary service units. A prototypical testbed, shown in Figure 2, was developed. It repre- sents a small set of home environments equipped with different KNX-compliant off-the-shelf devices. Integration of the semantic-enhanced protocol features in an agent framework is a further step in the research. In [8], main characteristics of the framework are highlighted and early performance evaluation is presented. A subsequent step, under current investigation, involves the exploitation of a semantic-based negotiation protocol seeking to maximize energy efficiency. The agents are able to: (i) negotiate on available home and energy resources through a user-transparent and device-driven interaction; (ii) reveal conflicting infor- mation on energy constraints; (iii) support non-expert users in selecting home configurations. The first results are presented in [9]. 5 Conclusion and Future Work A semantic-based pervasive computing approach has been investigated to over- come existing limitations in HBA solutions. The integration of KR and reasoning techniques with current standards and technologies is fundamental to improve user comfort and building efficiency. Enhancements aim at building a distributed knowledge-based framework. 22 Beyond completing the outlined research tasks, future extensions will include a user agent running on a mobile client, enabling rich and autonomous interactions in a collaborative smart space. References 1. Bonino, D., Castellina, E., Corno, F.: The DOG gateway: enabling ontology-based intelligent domotic environments. IEEE Transactions on Consumer Electronics 54(4), 1656 –1664 (november 2008) 2. Colucci, S., Di Noia, T., Pinto, A., Ragone, A., Ruta, M., Tinelli, E.: A non- monotonic approach to semantic matchmaking and request refinement in e- marketplaces. International Journal of Electronic Commerce 12(2), 127–154 (2007) 3. Klein, L., young Kwak, J., Kavulya, G., Jazizadeh, F., Becerik-Gerber, B., Varakantham, P., Tambe, M.: Coordinating occupant behavior for building energy and comfort management using multi-agent systems. Automation in Construction 22(0), 525 – 536 (2012) 4. Kofler, M.J., Reinisch, C., Kastner, W.: A semantic representation of energy- related information in future smart homes. Energy and Buildings 47(0), 169 – 179 (2012) 5. Ragone, A., Di Noia, T., Di Sciascio, E., Donini, F.M., Colucci, S., Colasuonno, F.: Fully automated web services discovery and composition through concept covering and concept abduction. International Journal of Web Services Research (JWSR) 4(3), 85–112 (2007) 6. Ruta, M., Scioscia, F., Di Sciascio, E., Loseto, G.: A semantic-based evolution of EIB Konnex protocol standard. In: IEEE International Conference on Mechatron- ics (ICM 2011). pp. 773 –778 (April 2011) 7. Ruta, M., Scioscia, F., Di Sciascio, E.: Mobile semantic-based matchmaking: a fuzzy dl approach. In: The Semantic Web: Research and Applications. Proceed- ings of 7th Extended Semantic Web Conference (ESWC 2010). Lecture Notes in Computer Science, vol. 6088, pp. 16–30. Springer (2010) 8. Ruta, M., Scioscia, F., Di Sciascio, E., Loseto, G.: Semantic-based Enhancement of ISO/IEC 14543-3 EIB/KNX Standard for Building Automation. IEEE Trans- actions on Industrial Informatics 7(4), 731–739 (2011) 9. Ruta, M., Scioscia, F., Loseto, G., Di Sciascio, E.: An Agent Framework for Knowledge-based Homes. In: 3rd International Workshop on Agent Technologies for Energy Systems (ATES 2012) (2012, to appear) 10. Santofimia, M., Moya, F., Villanueva, F., Villa, D., Lopez, J.: Intelligent Agents for Automatic Service Composition in Ambient Intelligence. In: Usmani, Z. (ed.) Web Intelligence and Intelligent Agents, pp. 411–428. InTech (2010) 11. Scioscia, F., Ruta, M.: Building a Semantic Web of Things: issues and perspec- tives in information compression. In: Semantic Web Information Management (SWIM’09). In Proceedings of the 3rd IEEE International Conference on Semantic Computing (ICSC 2009). pp. 589–594. IEEE Computer Society (2009) 12. Shadbolt, N.: Ambient intelligence. Intelligent Systems, IEEE 18, 2–3 (July 2003)