Dynamic Adaptation in Ubiquitous Services

0 downloads 0 Views 1MB Size Report
Marshall Cline, 1996; South, Lenaghan, & Malyan,. 2000 ..... 30. R2. Limited. 70 … … … Rk. Available. 50. Table 1. Data structure within a sensor agent ..... (PhD Thesis). University of Maryland, College. Park, MD. Chen, H., Finin, T., & Joshi, ...
160

Chapter 7

Dynamic Adaptation in Ubiquitous Services: A Conceptual Architecture Moeiz Miraoui University of Gafsa, Tunisia

ABSTRACT Ubiquitous (or Pervasive) Computing is a new domain in Computer Science resulting from the emergence and evolution of both distributed systems and mobile computing. Technology is moving beyond the personal computer towards a growing trend of embedded microprocessors in everyday objects and is demanding an unobtrusive connectivity between them in order to serve users at anytime and anywhere. The main objective of a ubiquitous computing system is to provide adaptive services proactively, without explicit user intervention and according to the user’s current context. Despite interesting previous research works, there is still a lack of software tools and related research in terms of comprehensive context modeling, architecture of context-aware ubiquitous systems, and dynamic adaptation approaches in ubiquitous service computing environments. This chapter proposes a conceptual architecture to provide dynamic adaptability in ubiquitous services based on context-awareness and user preferences. As part of this proposal, the authors detail an ontology-based context modeling approach, a multi-agent architecture to support the development of ubiquitous computing applications, and a case-based reasoning method for service adaptation.

DOI: 10.4018/978-1-4666-6178-3.ch007

Copyright © 2014, IGI Global. Copying or distributing in print or electronic forms without written permission of IGI Global is prohibited.

 Dynamic Adaptation in Ubiquitous Services

INTRODUCTION The concept of Ubiquitous (or Pervasive) Computing was presented in a conference article by Mark Weiser (1991), where he described a twenty-year horizon for the future of computing. Ubiquitous computing is the result of computer technology advancement, particularly in distributed and mobile computing. Technology is moving beyond the personal computer to everyday devices with embedded intelligence. The goal of these systems is to assist the user implicitly and discreetly in tasks that are performed daily. The current technological developments contribute to the realization of the vision of Mark Weiser. Today, the user is surrounded by many smart devices, such as laptops, smart phones, smart tablet computers, GPS, etc. as objects of everyday life. The task of using and managing these devices can become complex and time consuming without these devices being context-aware and proactive, by providing services conforming to the user’s current context without the explicit intervention of the user. Consequently, Context-awareness is the principal characteristic of ubiquitous computing applications. One of the primary tasks of designing ubiquitous computing applications consists of understanding context and establishing its components. Context modeling is an important step in the development of ubiquitous computing applications. Many methods have been proposed for context modeling related to different techniques, and some of the most interesting ones are based on ontology. But they still suffer from the problem of being specific to certain situations which limits their use to particular applications. Ubiquitous computing is a new computer science paradigm that requires new tools and methodologies to satisfy ubiquitous computing requirements. Researchers have proposed archi-

tectures, middlewares, and frameworks to support the development of ubiquitous computing and context-aware applications. Most of these architectures use either a layered approach based on the context sensing processes, or provide modular building blocks. Each approach promotes a set of software qualities. However, only a small number of the existing architectures satisfy the requirements of ubiquitous and context-aware systems to a significant extent. After all, the aim of a ubiquitous service computing system is to provide adapted services based on the user’s current context, without manual intervention of the user. This adaptation should take into account not only current context but also user preferences and limited resources of devices which are generally hand held in the ubiquitous environment. This chapter discusses the challenges and promising solution approaches associated with developing ubiquitous service computing applications. The remainder of the chapter is organized as follows: the background section presents the related works on context modeling, architectural aspects of ubiquitous computing systems, and ubiquitous service adaptation. The following sections describe an ontology-based context modeling approach, introduce a multi-agent architecture for building ubiquitous service computing systems, and present a case-based reasoning approach for dynamic context-aware service adaptation in a ubiquitous computing environment. The final section summarizes key points and lessons learned.

BACKGROUND This section presents an overview of research works on context definition and modeling, software architecture of context-aware systems, and dynamic service adaptation.

161

 Dynamic Adaptation in Ubiquitous Services

Context Definition and Modeling Many researchers have proposed definitions of context. Some definitions were based on enumerating contextual information (localization, nearby people, time, date, etc…) like those proposed by (Schilit & Theimer, 1994; Brown, Bovey, & Chen, 1997; Ryan, Pascoe, & Morse, 1997). Others were based on providing more formal definitions in order to abstract the term like the one proposed by (Dey, 2001). Most of these definitions were specific to a particular domain such as humancomputer interaction and localization systems. A survey conducted by (Brézillon et al., 2004) concluded that most of the proposed definitions are responses to the following questions: Why? What? Where? When? and How? This will generate an enormous quantity of information – both useful and useless. In our previous work (Miraoui & Tadj, 2007), we proposed a service oriented definition of context for a ubiquitous computing system as follows: Any information that triggers a service or changes the quality of a service if its value changes. As per this definition, service adaptation in a ubiquitous computing application can be done in one of two ways: by automatic the triggering of a service according to the current context, or by changing the quality (form) of a provided service according to the current context. Let {xi} and {yj} be two sets of contextual information. Assume that the change in value of {xi} triggers a specific service. The change in value of {yj} changes the form of the service (i.e., the service is provided in another form). The union of the two sets ({xi} U {yj}) constitutes the service contextual information set. Figure 1 shows the components of a ubiquitous computing environment and the information (which is part of a global context) that causes the adaptation to occur. The above definition of the

162

contextual information set is abstract enough and helps to limit the set of contextual information, and will be used in this chapter. The aim of context modeling is to provide an abstraction of context information to permit easy context management and more flexible sharing among devices. Several approaches were proposed for the representation of context. A survey made by (Strang & Linnhoff-popien, 2004) contains an interesting comparative study of different modeling methods. They concluded that ontology provided the best description of context compared to the surveyed methods because it enables easy sharing of information with common semantics. A detailed discussion of these methods is out of the scope of this chapter, but it is important to mention that the authors distinguished the following models for context representation: Key-value model, Mark-up scheme model, Graphical model, Object oriented model, Logic based model, and, Ontology based model. The use of ontology to model contextual information has many advantages compared to other methods. It is considered as a promising tool for the future of context-aware systems in particular and ubiquitous computing systems in general, as indicated on the survey made by (Bettini et al., 2009). A further benefit of ontologies, with respect to simpler representation formalisms, consists in the support of reasoning tasks. Indeed, on the basis of the asserted knowledge, it is possible to: (i) automatically derive new knowledge about the current context, and (ii) detect possible inconsistencies in the context information. We believe that the most significant works on ontology-based context modeling are: 1. SOUPA (Standard Ontology for Ubiquitous and Pervasive Applications) (Chen et al., 2004). SOUPA is composed of two sets of ontologies: SOUPA core ontologies and

 Dynamic Adaptation in Ubiquitous Services

Figure 1. Context information in a ubiquitous computing system

SOUPA extension ontologies. Core ontologies try to define a generic vocabulary which is universal for different ubiquitous computing applications. Extension ontologies (extended from SOUPA core ontologies) define additional ontologies to support specific kinds of applications and provide examples for extending future ontologies. 2. CONON (Wang et al., 2004) is a Context Ontology coded in OWL for modeling context in ubiquitous environments and support context reasoning. CONON provides an upper context ontology that senses general concepts of basic context and provides the extension of added ontologies specific to a particular domain in a hierarchical manner. The authors have judged that the localization, user, user activity, and computer entities (devices) are the basic context elements.

3. COBRA-ONT of the CoBrA (Context Broker Agent) (Chen, Fenin, & Joshi, 2003) is an architecture to support the development of context-aware systems in an intelligent space. COBRA-ONT is expressed with OWL, which defines typical concepts associated with places, agents, and events. The ontology is categorized in four classes: a) physical place ontology, b) agent (human or software) ontology, c) agent localization agent ontology, and d) agent activity context ontology. 4. CoOL (context ontology language) (Preuveneers et al., 2004) is a context modeling approach which uses ontology as formal foundation and the ASC (AspectScale-Context) context model. CoOL context model permits context-awareness and context interoperability during service discov-

163

 Dynamic Adaptation in Ubiquitous Services

ery in a distributed architecture. In CoOL, contextual information that characterizes the content of other contextual information is called meta-information, which expresses the quality of low level contextual information. 5. SOCAM (Service-Oriented Context-aware Middleware) (Gu et al., 2004b) is an architecture for the building and rapid prototyping of context-aware services in intelligent environments. The context ontologies are divided into upper ontology which captures general context knowledge about the physical world and is composed of: computational entity, location, user, and activity. The domain-specific ontologies are a collection of low level ontologies that define the details of general concepts and their properties in each sub-domain. Most of the newly proposed ontology-based modeling methods are derived forms from previous methods. (Najar et al., 2009) proposed a framework that analyzes and compares different context models. The proposed framework contains a set of evaluation criteria used to analyze context models such as: information, structure, capture, maintenance, reasoning, and action. They noticed that the notion of context that is usually adopted is user-centric and it is limited to some physical aspects. They proposed an ontology-based context model, particularly designed for the Business Process modeling community. The majority of the proposed ontologies does not offer a complete description of contextual information and does not cover all aspects of context in ubiquitous computing environments. Each of the ontologies is based on a different definition of context, which limits its usage. (Miraoui, Tadj, & Ben Amar, 2008a) proposed a service based ontology for context modeling, but like other works this ontology does not cover some important aspects of a ubiquitous computing environment, such as device resources and user preferences.

164

Context-Aware System Architectures The software architecture of a program or computing system is the structure of the system which comprises software components, the externally visible properties of those components, and the relationships among them (Bass, Clements, & Kazmen, 2003). Several interesting architectures and middleware systems for context-awareness have been developed in the last decade. A survey on different architectures was performed by (Baldauf, Dustdar, & Rosenberg, 2004). It showed that most of them are layered architectures (Korpipää et al., 2003; Fahy & Clarke, 2004; Biegel & Cahill, 2004; Román et al., 2002) composed of the following layers: sensing, interpretation, reasoning, management, and adaptation. (Chaari & Laforest, 2006) proposed the SECAS project with aim to provide a generic platform to design and deploy context-aware applications. They defined five basic facets of context, but more can be added in specific application domains: network profile, user description/preferences, terminal characteristics, location and environment. They used an XML representation for context presentation. The global architecture of SECAS is based on four subsystems: the application core, the adaptation layer, the context management system, and the client-side system. Context adaptation is done at three levels: service adaptation, content adaptation, and UI adaptation. The adapters hold a database of adaptation rules defining the adaptation operations that the adapter has to compute on the service it adapts, and the context parameters related to it. However, they provided only a static aspect of the adaptation module and did not present a context definition and modeling approach. (Suraci, 2007) proposed a context-aware semantic service discovery architecture designed to perform distributed service discovery in heterogeneous networks. The architecture has the ability to make use of context information to discover the most relevant services for the user.

 Dynamic Adaptation in Ubiquitous Services

Proposed architecture uses an innovative context aware filtering process which extends the OWL-S capabilities in order to cooperate with a semantic knowledge base expressed in OWL, shared among all the components of the architecture. The reference context architecture composed of four main components: user, service, environment, and context manager. However, they do not take into account the limited resources of the devices or the user’s profile. Another survey done by (Miraoui, Tadj, & Ben Amar, 2008b) concluded that the proposed architectures (Fahy & Clarke, 2004; Biegel & Cahill, 2004; Hofer et al., 2002; Gu et al., 2004a; Chen, 2004) were mostly specific to an application domain (localization systems, human-computer interaction, etc.) and require additional effort for their adaptation to other domains, in particular, context-aware and ubiquitous systems. In their recent work, Saeed & Waheed (2012) concluded in their survey on context-aware middleware architectures that some architectures adopt layered approaches where different services are localized in layers with dependency among the layers. Such architectures support extensibility and flexibility to some extent. Other architectures are those in which modules or components represent the major building blocks. This kind of middleware is more flexible as compared to layered architecture, as in layered approach dependency exists between layers, whereas modules or components can be independent. Also modular architecture supports reusability. (Wagner et al., 2011) presented a middlewarebased solution providing comprehensive context management support according to the SOA principles. The general objective of their work was to provide a comprehensive approach for exchanging and selecting heterogeneously represented context information in a ubiquitous computing environment. Their solution specifically addresses the

characteristics of open, dynamic, heterogeneous, and ubiquitous computing environments. Proposed middleware supports the dynamic selection of context providers based on QoC (Quality of Context) and CoC (Cost of Context) criteria. However, they did not provide a context definition or a context modeling approach.

Context-Aware Service Adaptation A ubiquitous computing environment is highly dynamic, changing due to the mobility of both users and devices, which justifies service adaptation in such environments. The need for service adaptation has been long recognized (Aksit & Choukair, 2003; Keeney & Cahill, 2003; Segara & Andrea, 2000; Narayanan, Flinn, & Satyanarayanan, 2000; Efstratiou et al., 2001; Fayad & Marshall Cline, 1996; South, Lenaghan, & Malyan, 2000; Yarvis, Reiher, & Popek, 1999), and both manual and automatic approaches to service adaptation have been proposed. The most traditional method is rule-based adaptation, which consists of specifying for each service a set of rules for the possible contextual configurations and associating each rule to a service. The developer has to predict before the operation of the system, the set of rules relative to each service and associate it to each context configuration. The problem of this method is how to determine and limit the set of possible context configurations (Cremene, Riveill, & Martel, 2006). Adaptation through machine learning is based on experience. (Bridiczka, Crowley, Reignier, 2007) adopted the supervised learning method in their work and (Miraoui, Tadj, & Ben Amar, 2008a) used both neural network and Bayes network for dynamic services in their approach. The conditions model is learned and classified by the expert system and the user provides feedback indicating the corresponding service in each situation.

165

 Dynamic Adaptation in Ubiquitous Services

(Zaidenberg, 2009) used a reinforcement learning algorithm to develop a system that determines the adaptation model from the interaction of the system with the user and observing user reactions to system responses. This mechanism remains limited since it does not ensure the continuity of services (if the learning model confronts a new situation where it has not been trained). The training time and the training set size remain central challenges for these systems. (Preuveneers & Berbers, 2010) proposed an approach to improve the availability and accessibility of services in a highly dynamic ad hoc network where intermittent network connectivity can disrupt an application, when multiple services on mobile and stationary devices are temporarily coupled to behave as one single application. They illustrated the applicability of smart service diffusion in a distributed setting on top of the OSGi framework. Their aim was to replicate a service at runtime on one or more hosts to increase accessibility and expedite human interaction with the service. They did not deal with context modeling and architectural aspects. (Khan, 2010) proposed providing support of the unanticipated adaptation (which has not been foreseen at design time) to mobile applications by the use of components from independent developers in configuring the application at runtime. The proposal provided mechanisms to dynamically match application components and their metainformation, and adapt the application quickly using a new adaptation reasoning approach. Their adaptation was based on some assumptions with respect to context-awareness, context definition, and modeling. (Carillo-Ramos et al., 2007) presented a personalization of an information access process that aims at adapting and delivering user’s information taking into account their profile, more precisely, the preferences included in their profile. They ad-

166

dressed the personalization (based on user preferences) of Web information system accessed using mobile devices. They adopted the representation of three types of user preferences: activity, result, and display preferences; and a Contextual Matching Algorithm which examines a user profile and analyzes each user preference to evaluate if this preference can be satisfied according to the context of use. There was no context definition and modeling, in addition, their approach did not take into account limited resources of a mobile device. In order to handle uncertain and incomplete context information, Vanrompay & Berbers (2009) proposed a mechanism inspired by graphcomparison for matching contextual service descriptions using similarity measures that allow inexact matching. The service selection approach proposed here complements the service selection mechanism used by the MUSIC (Vanrompay & Berbers, 2009) middleware for selecting the most suitable service among discovered and compatible services. Such service selection should take into account the fact that context information is naturally uncertain and incomplete. The goal of the matching algorithm is to rank the available services based on their contextual non-functional properties. It compares the context description related to available services with the current execution context. Comparison based adaptation consists of providing the adequate service according to the most similar situation encountered previously. For a particular unknown context or situation, the adaptation application seeks the nearest previously encountered context or situation using appropriate similarity measures. Once the closest context is determined, the device behaves in the same way (i.e., triggers the same services). (Dietze et al., 2009) used similarity measures to develop a system based on a mapping of service descriptions with user needs to provide the nec-

 Dynamic Adaptation in Ubiquitous Services

essary adaptation algorithm. A similar approach proposed by (Preuveneers et al., 2009) is based on an adaptation by comparing the profiles defined in the application with the user profile. Once the profile is selected, the adaptation rules already defined in the profile are executed. (Miraoui, Tadj, & Belgacem, 2013) used a set of distance measures (Euclidian, Hamming, Manhattan, Cosine, and Jaccard) to seek the most similar context and adapt mobile phone incoming call indication. They concluded that the hamming distance gave the best results. A previous work done by (Miraoui et al., 2011) proposed a context-aware dynamic service adaptation which takes into account limited resources of devices, but it did not consider user’s preferences. Most of the previous works require enhancements in terms of context-awareness, and need to take into account both the limited resources of devices in ubiquitous computing environments and the user’s preferences. The works cited above represent a small but significant sample of related research.

MODELING AND ARCHITECTURE OF ADAPTIVE UBIQUITOUS SERVICES In the following sections, we will discuss the proposed ontology based modeling that is used to model both the ubiquitous computing environment and the contextual information. Then, we will present the proposed multi-agent architecture to handle context-awareness and satisfy the requirements of the ubiquitous environment. Finally, we will propose a case-based reasoning approach for context-aware service adaptation which takes into account the limited resources of devices and user’s preferences.

Ontology-Based Context Modeling The first task in designing a ubiquitous computing application consists of understanding context, establishing its components, and modeling it in a precise and concise manner. This will enable better usability, more flexible sharing among devices and ease the adaptation task. A clear description of a ubiquitous computing environment will help significantly in the modeling task. A ubiquitous computing environment is populated with several computing devices with different characteristics. Each device possesses a set of resources needed for running services. Some of these resources are limited and should be employed carefully because their availability decreases rapidly (e.g., battery charge level of a hand-held device). Each device also has several embedded sensors in order to perceive some context information surrounding both user and the device itself. These sensors can be either physical (e.g., light sensor) or logical (e.g., weather Web site). The perceived contextual information can cause services to trigger or change form as discussed earlier. The device user may have a list of preferences for each service provided (e.g., kind of ring tone used for incoming call indication of a cellular phone). The device provides a set of services to the user and each service can be provided over several forms (e.g., the service of incoming call indication of a cellular phone can be provided over the following forms: ringtone, vibrator, silent; or the service of Internet connection can be provided over the following forms: wired, wireless, mobile data). In order to satisfy the requirements of a ubiquitous computing system, each service should be provided according to the current context, by taking into account the user’s preferences and using device resources in an optimal manner.

167

 Dynamic Adaptation in Ubiquitous Services

As mentioned earlier, the recommended modeling approach is ontology-based. Ontology is a set of structured concepts that are organized in a graph where relations can be either semantic relations or composition and heritage relations. The main objective of ontology is to model the set of knowledge of a given domain. This means to choose a manner for describing domain information in a form comprehensible by computers. It provides a representative vocabulary for a given domain and permits a consistent interpretation of data. Ontology is a powerful tool for knowledge sharing. It permits the structuring of concepts and properties in the same way as classes and attributes in the object oriented model. The most significant concepts that can be extracted from the previous description of a ubiquitous computing environment are: • •

Device, Resource with its two sub-classes (limited and available),

Figure 2. Context ontology

168

• • • • • •

Sensor with its two sub-classes (physical and logical), Context with its two sub-classes (triggering information and form changing information), Service, Preferences, Form, User.

The service entity is a central concept which is in semantic relationship with most of the other concepts. The graphical presentation of the proposed ontology with semantic relations, composition, and heritage relations among concepts is shown in Figure 2. The proposed ontology covers the most important aspects of a ubiquitous computing system, in particular, context-awareness, user’s preferences, and limited resources of hand-held devices. There is no need to create a domain specific ontology

 Dynamic Adaptation in Ubiquitous Services

like in some of the previous works; just add new attributes or create subclasses from existing concepts. This is more general and extensible. The most significant advantage of using ontology-based context modeling resides in the possibility of carrying out logical reasoning. It permits deducing relevant new contextual information that cannot be explicitly provided by sensors of the ubiquitous computing system. Ontology reasoning enables to: • • •

Check context inconsistency and conflicts caused by imperfect sensing of contextual information. Check whether concepts are non contradictory. Find subsumption relationships between classes and instances (for instance, if a user is located in the classroom means the user is located at university too, because classroom is a part of the university).

There are many automated tools for ontology reasoning. In our work we have used the Pellet (Parsia & Sirin, 2004) ontology reasoner which is an OWL 2 reasoner. Pellet provides standard and cutting-edge reasoning services for OWL ontologies to check the consistency of the ontology and infer new implicit context information.

Multi-Agent Architecture for Ubiquitous Services Ubiquitous services should be designed with consideration for context-awareness. In this section, we will present the proposed multi-agent architecture to handle context-awareness and satisfy the requirements of the ubiquitous environment. The architecture is composed of three multiagent systems: sensor or context multi-agent system, resource multi-agent system, and service

multi-agent system. Additionally, there is an independent agent for user preferences. The agents feed their context perceptions into the central adaptation module to carry out the adaptation tasks. The overall architecture is shown in Figure 3. A modern device is equipped with several sensors to perceive contextual information. The proposed architecture assigns an agent to be responsible for each sensor. This agent will save the value of the contextual information perceived by the sensor. A sensor control agent will gather all contextual information perceived by the device’s sensors and send it to the adaptation module to perform context-aware service adaptation. Most devices in a ubiquitous computing system are hand-held and mobile (e.g., a cellular phone, a laptop computer, etc.). We can classify the resources of such devices into two categories: available and limited. We define the available resources as a category which is less likely to have an availability problem once used (e.g., the hard disk in a laptop). By contrast, limited resources can be defined as those that should be employed carefully because their availability can decrease rapidly (e.g., battery charge level of a cellular phone, the bandwidth of an Internet connection, etc.). In the proposed architecture, an agent will be responsible for each resource in the device and record its use rate. A resource control agent will gather the use rates of all resources and send it to the adaptation module in order to ensure an optimized use of resources (in particular, limited resources) during service adaptation. The architecture involves an independent agent to provide user preferences to the adaptation module to take into account when providing a new service. A device provides several services to the user, and each service can be provided in different forms (e.g., a network connection can be wired or wireless). An agent is made responsible for each service, to record the state of the service

169

 Dynamic Adaptation in Ubiquitous Services

Figure 3. The proposed multi-agent architecture for context-aware adaptation

(active of inactive), the form of the service, and the resources used by the service. A service control agent maintains the current state of services and can change the state or the form of a service according to the instructions from the adaptation module. The service control agent also maintains a database (called case base) containing relevant contexts and the context-aware actions such as what services should be triggered and in which form. This case base will be used by the adaptation module in the adaptation task. We will now discuss each component of the architecture in detail.

Sensor Multi-Agent System The Sensor Multi-agent System (MAS) is built on a client-server architecture where the clients are agents for each sensor and the server is the sensor

170

control agent. Each sensor agent maintains a data structure, as indicated in Table 1, that captures the name of the sensor, the perceived context, the current value, and the weight of the context element which depends on its possible values (e.g., if the context element time has four values: morning, afternoon, evening and night, then its weight will be four). The sensor control agent also maintains a data structure that stores a list of context information, and values and weights of the respective context elements, as shown in Table 2. When a change in the value of context information is detected, the concerned sensor agent sends a message to the sensor control agent containing the perceived context and the current value (recently detected). The sensor control agent sends to the adaptation module a context vector with current values and the weight of each context element.

 Dynamic Adaptation in Ubiquitous Services

Table 1. Data structure within a sensor agent Sensor Name GPS

Perceived Context

Current Value

Localization

Weight

Home

N

Table 2. Data structure within a sensor control agent Context Information

Current Value

Weight

Localization

Home

N1

Time

Evening

N2

Light

Bright

N3







Resource Multi-Agent System

Service Multi-Agent System

Similar to the Sensor MAS, the Resource Multiagent System is a thin client-server multi-agent system that is composed of a set of resource agents as clients, and each one is associated with a resource of a device. The resource agent maintains a data structure with three fields: resource name, type (available or limited), the current use rate (in percentage). The resource control agent (server) collects the information about all device resources in a structure as indicated in Table 3. This data will be communicated to the adaptation module each time there is a need for a new adaptation task or on demand from the adaptation module.

The service multi-agent system also has a clientserver architecture with a set of service agents as clients, and each service agent maintains a data structure containing the service name, possible forms, state, and required resources, as shown in Table 4. The service control agent (server) collects the list of currently running services and their current form from service agents. This list will be sent to the adaptation module each time there is a need for a new adaptation task. The service control agent in turn will receive a vector of service configurations from the adaptation module when an adaptation

Table 3. Resource description within resource control agent Resource Name

Type

Percentage of Use (%)

R1

Available

30

R2

Limited

70







Rk

Available

50

171

 Dynamic Adaptation in Ubiquitous Services

Table 4. Service description within service control agent Service S

Forms

State

Form 1

Inactive

R1

Form 2

Active

R2 & R3



Inactive

Rk

operation occurs. It commands each service agent to trigger a service in a particular form according to the service configuration request.

User Preferences Agent The user preferences agent is the last component of this multi-agent architecture (adaptation module will be discussed in the next section). It is a simple agent containing a list of user preferences which should be taken into account in the adaptation task. An example of this list consists of the incoming call indication service of a cellular phone for providing a particular ring tone set by the user. The proposed architecture presented several beneficial characteristics: •





172

Required Resources

There is minimum coupling between modules composing the architecture which decreases the information stream between them. Data communication happens between the adaptation module and the other components only via the control agents (interface). There is no communication between the multi-agent systems, thereby decoupling them. The data encapsulation ensures that data can be accessed only by the central agents and any external entity cannot accidentally or intentionally manipulate the data, making the data more secure.



It is an extensible architecture where new sensors (context element), services, resources, or user preferences can be easily added without major changes in the architecture. The sensor or context multi-agent system can be easily integrated in a ubiquitous computing system composed of several devices in order to share and communicate contextual information.

Case Based Reasoning for Service Adaptation This section presents a case-based reasoning approach for context-aware service adaptation which takes into account the limited resources of the devices and user’s preferences. Basically, the adaptation task consists of mapping context element values to service configurations (set of triggered services in appropriate forms). This mapping should then take into account the limited resources of the devices and user’s preferences. The user’s feed back of the provided services is a determining factor of the adaptation wellness. Case-based reasoning (CBR) (Aamodt & Plaza, 1994) is a machine learning method that consists of arriving at the solution of a new problem on the basis of the solutions of previously-solved similar problems. Unlike rule based systems, which are useful only where one or a few solutions to a problem are possible. On the other hand,

 Dynamic Adaptation in Ubiquitous Services

case based systems are useful in solving complex problems with many alternative solutions. Casebased reasoning can be seen as a cycle of the following four tasks:

ServiceConfiguration = (S1Fi, …, SpFj, …, SqFk)



SpFj: denotes Service P over Form J.

• • •

Retrieve (given a new case, retrieve similar cases from the case base). Reuse (adapt the retrieved cases to fit to the new case). Revise (evaluate the solution and revise it based on how well it works). Retain (decide whether to retain this new case in the case base).

The sensor control agent provides to the adaptation module a context vector each time one of the sensor agents perceives a new value of a context element. It will be considered as a new case for the CBR system. Each case can be described as a specific set of experiential knowledge that contains a vector of context values. The context vector can be defined as follows: ContextVector = (X1, X2, …, Xi, …, Xn) where Xi є ContextValuei = (V1,V2, …, Vm) The CBR case base contains a list of contextservice vectors where each one is composed of two sub-vectors: the first one is a list of context vectors and the second one is a list of configuration of provided services with their appropriate form as follows: ContextService = (ContextVector, ServiceConfiguration) where ContextVector is as described above and ServiceConfiguration is described as follows:

where S1, …, Sp, …, Sq: is the set of provided services

Figure 4 illustrates the overall operation of the Adaptation Module. The CBR case base will be initially populated with the most obvious ContextService vectors where each ContextVector is associated to a ServiceConfiguration vector containing a list of triggered services in appropriate forms as described earlier. The computation of similarity is an important issue for the case retrieving process in CBR. Upon receipt of a new case (new ContextVector) from the sensor control agent, the adaptation module will search for the Kth nearest neighbor ContextService from the case base. The number K will be fixed according to the application type and computation requirements. Kth-Nearest Neighbor (K-NN), also known as closest point search, is an optimization problem for finding the closest points in metric spaces. For each new case x, compute its Kth nearest neighbors in a set of already classified cases, and assign x to the class which is the most represented in the set of nearest neighbors. The similarity is determined using a distance measure. In our previous work (Miraoui, Tadj, & Belgacem, 2013) we have used a set of distance measures such as Euclidian, Hamming, Manhattan, Cosine, and Jaccard to seek the most similar context and adapt mobile phone incoming call indication. We concluded that the Hamming distance gave the best results. The Hamming Distance is a number used to denote the difference between two binary strings. It consists of comparing the first two bits in each string. If they are the same, assign a “0” for that

173

 Dynamic Adaptation in Ubiquitous Services

Figure 4. Overall operation of the Adaptation Module

bit. If they are different, assign a “1” for that bit. The Hamming distance is therefore obtained by making a weighted (each context element has a weight as discussed in the previous section) addition of all the ones and zeros previously obtained. This assumes that the operation of converting context values to binary strings was performed earlier. The smaller the number, the more similar are the strings. The Kth nearest neighbor ContextService obtained from previous step will then be used to adapt the new case. For each nearest neighbor ContextService, retrieve the ServiceConfiguration subvector, and check whether it is possible and optimal to run such service configuration without causing the expiration of the limited resources of the device. This task is done by using the current

174

resources of the device provided by the resource control agent and the service description data structure provided by the service control agent that contains the list of required resources for each service and each one of its forms. The adaptation module will then check if the selected service configurations satisfy user’s preferences using the table of user’s preferences provided by the user preferences agent. In case of conflict between optimal use of resources and user’s preferences, the former (resource optimality) takes precedence. The next step consists of selecting one ContextService among the elected ones (if there are many) and adding to the new ContextVector in order to form a new ContextService vector. The adaptation module will send the new ContextService to the service control agent

 Dynamic Adaptation in Ubiquitous Services

which in turn checks if the new ContextService differs from the previous one. If it is the case, it will command each of its service agents to provide services according to the ServiceConfiguration subvector received. Upon the execution of the new service configuration by the device, the adaptation module will wait for a limited time interval (fixed according to the device and application) for the user’s feedback. If the user is satisfied with the new running services, it will not perform any manipulation, the time interval will be elapsed and the adaptation module will save the new ContextService in the case base. Otherwise (not satisfied) it will perform some manipulations within the time interval in order to change the running service configuration. In this case, the adaptation module will take into consideration the user’s change and save the final ContextService vector in the case base. Through this process, knowledge can be updated and repeatedly used. The overall operation of the adaptation module is summarized in six steps as shown in Figure 4. One performance enhancement of the adaptation task involves adding a control bit in the ContextService vector to indicate the frequency of use of such vector and select the N most frequently used ContextVector from the case base, in order to reduce the complexity of the search algorithm and decrease the processing load.

CONCLUSION Despite several interesting and significant research works that have been performed in the realm of ubiquitous computing, there is still a lack of

software tools and related research in terms of comprehensive context modeling, architecture, and adaptation approaches. In a ubiquitous computing system, devices should be aware of the current context in order to provide adapted services proactively, without the explicit intervention of the user. In such systems, context should be well understood and modeled in an appropriate form to enhance its sharing among devices and provide a higher level of abstraction. Effective service adaptation in ubiquitous computing systems requires the incorporation of context-awareness and user’s preferences and handling the limited resources of devices (which are generally hand held and have limitations). In this chapter, we presented an overview of state-of-the-art research works in the ubiquitous computing realm and proposed a conceptual architecture to provide service adaptability based on context-awareness, user preferences, and resource limitations of devices. We also detailed an ontology for context modeling in ubiquitous computing environments. Further, we described a multi-agent architecture that facilitates extensible system architecture to support the development of ubiquitous services. Finally, we explained a context-aware service adaptation approach using case based reasoning method which takes into account the requirements of context-awareness, limited resources of devices in a ubiquitous computing system, and user’s preferences to perform the adaptation. The future work plan consists of applying the ontology-based modeling method on a real ubiquitous computing case scenario, implementing a prototype of the multi-agent architecture, and evaluating the adaptation approach.

175

 Dynamic Adaptation in Ubiquitous Services

REFERENCES Aamodt, A., & Plaza, E. (1994). Case-based reasoning: Foundational issues, methodological variations, and system approaches. Artificial Intelligence Communications, 7, 39–59. Aksit, M., & Choukair, Z. (2003). Dynamic, adaptive and reconfigurable systems overview and prospective vision. In Proceedings of the ICDCSW. Providence, RI: ICDCSW. doi:10.1109/ ICDCSW.2003.1203537 Baldauf, M., Dustdar, S., & Rosenberg, F. (2004). A survey on context-aware systems. International Journal of Ad Hoc and Ubiquitous Computing. Bass, L., Clements, P., & Kazman, R. (2003). Software architecture in practice (2nd ed.). Reading, MA: Addison-Wesley. Bettini, C., Brdiczka, O., Henricksen, K., Indulska, J., Nicklas, D., Ranganathan, A., & Riboni, D. (2010). A survey of context modeling and reasoning techniques. Ubiquitous and Mobile Computing, 6(2), 161–180. Biegel, G., & Cahill, V. (2004). A Framework for Developing Mobile, Context-aware Applications. In Proceedings of 2nd IEEE conference on Ubiquitous computing and Communications. IEEE. doi:10.1109/PERCOM.2004.1276875 Brézillon, P., Borges, M. R., Pino, J. A., & Pomerol, J. C. (2004). Context-Awareness in Group Work: Three Case Studies. In Proceedings of IFIP International Conference on Decision Support Systems. Prato, Italy: IFIP. Bridiczka, O., Crowley, J. L., & Reignier, P. (2007). Learning situation models for providing context-aware services. In Proceedings of the 4th International Conference on Universal Access in Human-Computer Interaction. Academic Press. doi:10.1007/978-3-540-73281-5_3

176

Brown, P. J., Bovey, J. D., & Chen, X. (1997). Context-aware Applications: From the laboratory to the Marketplace. IEEE Personal Communications, 4(5), 58–64. doi:10.1109/98.626984 Carrillo-Ramos, A., Villanova-Oliver, M., Gensel, J., & Martin, H. (2007). Contextual User Profile for Adapting Information in Nomadic Environments. In Proceedings of WISE, (pp. 337-349). WISE. doi:10.1007/978-3-540-77010-7_32 Chaari, T., Laforest, F., & Celentano, A. (2007). Adaptation in context-aware ubiquitous information systems: The SECAS project. Journal of Ubiquitous Computing and Communications, 3(4), 400–425. Chen, H. (2004). An Intelligent Broker Architecture for Ubiquitous Context-Aware systems. (PhD Thesis). University of Maryland, College Park, MD. Chen, H., Finin, T., & Joshi, A. (2003). An Ontology for Context-aware Ubiquitous Computing Environments. The Knowledge Engineering Review, 18(3), 197–207. doi:10.1017/ S0269888904000025 Chen, H., Perich, F., Finin, T. W., & Joshi, A. (2004). Soupa: Standard Ontology for Ubiquitous and Ubiquitous Applications. In Proceedings of MobiQuitous, (pp. 258-267). IEEE Computer Society. Cremene, M., Riveill, M., & Martel, C. (2006). Towards unanticipated dynamic service adaptation. In Proceedings of the Third International Workshop on Coordination and Adaptation Techniques for Software Entities. Nantes, France: Academic Press. Dey, A. K. (2001). Understanding and Using Context. Journal of Personal and Ubiquitous Computing, 5(1), 4–7. doi:10.1007/s007790170019

 Dynamic Adaptation in Ubiquitous Services

Dietze, S., Gugliotta, A., & Domingue, J. (2009). Bridging the gap between mobile application contexts and semantic web resources. In D. Stojanovic (Ed.), Context-Aware Mobile and Ubiquitous Computing for Enhanced Usability: Adaptive Technologies and Applications (pp. 217–234). Hershey, PA: IGI Global. doi:10.4018/978-160566-290-9.ch009 Efstratiou, C., Cheverst, K., Davies, N., & Friday, A. (2001). An Architecture for the Effective Support of Adaptive Context-Aware Applications. In Proceedings of the 2nd International Conference in Mobile Data Management. Hong Kong: Academic Press. doi:10.1007/3-540-44498-X_2 Fahy, P., & Clarke, S. (2004). CASS: Middleware for Mobile Context-Aware Applications. In Proceedings of ACM MobiSys Workshop on Context Awareness. Boston, MA: ACM. Fayad, M., & Cline, P. M. (1996). Aspects of software adaptability. Communications of the ACM, 39(10), 58–59. doi:10.1145/236156.236170 Gu, T., Wang, X. H., Pung, H. K., & Zhang, D. Q. (2004a). An Ontology-based Context Model in Intelligent Environments. In Proceedings of Communication Networks and Distributed Systems Modeling and Simulation Conference. San Diego, CA: Academic Press. Gu, T., Wang, X. H., Pung, H. K., & Zhang, D. Q. (2004b). A Middleware for Context-Aware Mobile Service. In Proceedings of IEEE Vehicular Technology Conference. Milan, Italy: IEEE.

Hofer, T., Schwinger, W., Pichler, M., Leonhartsberger, G., & Altmann, J. (2002). Contextawareness on mobile devices – The hydrogen approach. In Proceedings of the 36th Annual Hawaii International Conference on System Sciences, (pp. 292–302). IEEE. Keeney, J., & Cahill, V. (2003). Chisel: A PolicyDriven, Context-Aware, Dynamic Adaptation Framework. In Proceedings of the IEEE 4th International Workshop on Policies for Distributed Systems and Networks. Lake Como, Italy: IEEE. doi:10.1109/POLICY.2003.1206953 Khan, M. U. (2010). Unanticipated Dynamic Adaptation of Mobile Applications. University of Kassel Press. Korpipää, P., Mäntyjärvi, J., Kela, J., Keränen, H., & Malm, E. (2003). Managing Context Information in Mobile Devices. IEEE Ubiquitous Computing. Miraoui, M., & Tadj, C. (2007). Service Oriented Definition of Context for Ubiquitous Computing. In Proceedings of the 16th International Conference on Computing. Mexico City, Mexico: Academic Press. Miraoui, M., Tadj, C., & Belgacem, H. (2013). Dynamic context-aware adaptation of mobile phone incoming call indication using context similarity. In Proceedings of the World Congress on Computer and Information Technologies. Sousse, Tunisia: Academic Press. doi:10.1109/ WCCIT.2013.6618686

177

 Dynamic Adaptation in Ubiquitous Services

Miraoui, M., Tadj, C., & Ben Amar, C. (2008a). Context modeling and context aware service adaptation for ubiquitous computing systems. International Journal of Computer and Information Science and Engineering, 2(3), 148–157.

Preuveneers, D., van den Bergh, J., Wagelaar, D., Georges, A., Rigole, P., & Clerckx, T. … De Bosschere, K. (2004). Towards an Extensible Context Ontology for ambient intelligence. Lecture Notes in Computer Science, 3295, 148-159.

Miraoui, M., Tadj, C., & Ben Amar, C. (2008b). Architectural Survey of Context-aware Systems in Ubiquitous Computing Environment. Ubiquitous Computing and Communications Journal, 3(3).

Preuveneers, D., Victor, K., Vanrompay, Y., Rigole, P., Kirsch, M., & Berbers, Y. (2009). Context-aware adaptation in an ecology of applications. In D. Stojanovic (Ed.), Context-Aware Mobile and Ubiquitous Computing for Enhanced Usability: Adaptive Technologies and Applications (pp. 217–234). IGI Global. doi:10.4018/9781-60566-290-9.ch001

Miraoui, M., Tadj, C., Fattahi, J., & Ben Amar, C. (2011). Dynamic Context-aware and Limited Resources aware Service Adaptation for Ubiquitous Computing. Advances in Software Engineering Journal. Najar, S., Saidani, O., Kirsch-Pinheiro, M., Souveyet, C., Nurcan, S., & Gomez-Perez, J. M. Warren, P. (2009). Semantic representation of context models: a framework for analyzing and understanding In Proceedings of the 1st Workshop on Context, Information and Ontologies, European Semantic Web Conference, (pp. 1-10). ACM. Narayanan, D., Flinn, J., & Satyanarayanan, M. (2000). Using history to improve mobile application adaptation. In Proceedings of the 3rd IEEE Workshop on Mobile Computing Systems and Applications. Monterey, CA: IEEE. doi:10.1109/ MCSA.2000.895379 Parsia, B., & Sirin, E. (2004). Pellet: An OWL DL Reasoner. In Proceedings of the Third International Semantic Web Conference. Hiroshima, Japan: Academic Press. Preuveneers, D., & Berbers, Y. (2010). Contextdriven migration and diffusion of ubiquitous services on the OSGi framework. International Journal of Autonomous and Adaptive Communications Systems, 3(1), 3–22. doi:10.1504/ IJAACS.2010.030309

178

Román, M., Hess, C., Cerqueira, R., Ranganat, A., Campbell, R. H., & Nahrstedt, K. (2002). Gaia: A Middleware Infrastructure to Enable Active Spaces. IEEE Pervasive Computing / IEEE Computer Society [and] IEEE Communications Society, 1(4), 74–83. doi:10.1109/MPRV.2002.1158281 Ryan, N., Pascoe, J., & Morse, D. (1997). Enhanced Reality Fieldwork: the Context-Aware Archeological Assistant. Computer Applications in Archeology. Saeed, A., & Waheed, T. (2012). An Extensive Survey of Context-aware Middleware Architectures. American Journal of Computer Architecture, 1(3), 51–56. Schilit, S., & Theimer, M. (1994). Disseminating Active Map Information to Mobile Hosts. IEEE Network, 8(5), 22–32. doi:10.1109/65.313011 Segara, M. T., & Andrea, F. (2000). A Framework for Dynamic Adaptation in Wireless Environments, IRISA Research Institute. In Proceedings of the Technology of Object Oriented Languages and Systems Conference. St. Malo, France: Academic Press.

 Dynamic Adaptation in Ubiquitous Services

South, G., Lenaghan, A. P., & Malyan, R. R. (2000). Using reflection for service adaptation in mobile clients (t4) (Technical report). Kingston University. Strang, T., & Linnhoff-Popien, C. (2004). A Context Modeling survey. In Proceedings of the First International Workshop on Advanced Context Modeling, Reasoning, and Management. Academic Press.

Wang, X. H., Zhang, D. Q., Gu, T., & Pung, H. K. (2004). Ontology Based Context Modeling and Reasoning Using owl. In Proceedings of the Second IEEE Annual Conference on Ubiquitous Computing and Communications Workshops. Washington, DC: IEEE Computer Society. Weiser, M. (1991). The Computer for the 21st Century. Scientific American, 265(9), 66–74. PMID:1754874

Suraci, V., Mignanti, S., & Aiuto, A. (2007). Context-aware Semantic Service Discovery. In Proceedings of the 16th International Mobile and Wireless Communications Summit, (pp. 1-5). Academic Press.

Yarvis, M., Reiher, P., & Popek, G. J. (1999). Conductor: A framework for distributed adaptation. In Proceedings of the Workshop on Hot Topics in Operating Systems, (pp. 44–49). Academic Press. doi:10.1109/HOTOS.1999.798376

Vanrompay, Y., & Berbers, Y. (2009). Context grouping and distribution in the MUSIC middleware. In Proceedings of the International Conference ICT that Makes the Difference (vol. 1, pp. 143-146). Brussels, Belgium: Academic Press.

Zaidenberg, S. (2009). Apprentissage par renforcement de modèles de contexte pour l’informatique ambiante. (PhD thesis). Grenoble INP, France.

Vanrompay, Y., Kirsch-Pinheiro, M., & Berbers, Y. (2011). Service Selection with Uncertain Context Information. In S. Reiff-Marganiec, & M. Tilly (Eds.), Handbook of Research on Service-Oriented Systems and Non-Functional Properties: Future Directions (pp. 192–215). IGI Global. doi:10.4018/978-1-61350-432-1.ch009

ADDITIONAL READING

Wagner, M., Reichle, R., & Geihs, K. (2011). Context as a service Requirements, design and middleware support. In Proceedings of the IEEE International Conference on Ubiquitous Computing and Communications Workshops, (pp. 220-225). IEEE. doi:10.1109/PERCOMW.2011.5766873

Dey, A., Abowd, G. D., & Salber, D. (2001). A conceptual framework and a toolkit for supporting the rapid prototyping of context-aware applications. Human-Computer Interaction, 16(2), 97–166. doi:10.1207/S15327051HCI16234_02

KEY TERMS AND DEFINITIONS Case-Based Reasoning: A machine learning method consisting of solving a new problem according to previously solved similar problems.

179

 Dynamic Adaptation in Ubiquitous Services

Context-Aware System: A system reacting according to the current context of users and devices. Multi-Agent System: A set of communicating and collaborating agents where each agent senses its environment changes and reacts accordingly. Ontology: A description of a concept with a common understanding in a particular domain. Resource: A logical or physical entity required for the running of a service.

180

Service Adaptation: A behavioral change of a service in order to become better suited to the user. Ubiquitous Computing: A new domain of computing where the user is surrounded by several networked devices that provide services continuously.

Suggest Documents