Capability Matchmaking of Semantic Web Services with Preconditions and Eﬀects∗ Hai Wang Institute of Computer System Structure and Networks School of Electronics & Information Engineering, Xi’an Jiaotong University, Xi’an Shaanxi 710049, PR China email@example.com ∗ This work is supported by National Natural Science Foundation (60673170) of Peoples Republic of China. The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li Abstract Capability matchmaking is one of the key issue in the ﬁeld of semantic web services research community because it is the basis of doing service discovery and composition. Generally, capability description of the service involves two aspects: the information transformation and the state change produced by execution of the service. The former is represented by inputs and outputs of the service while the latter is represented by preconditions and eﬀects. The matchmaking of inputs and outputs has got some good results but the preconditions and eﬀects is still lack of methods to tract. In this paper we propose using satisﬁability checking of Description Logic reasoner to do the matchmaking of preconditions and eﬀects. A formal analysis of the IOP E description with regarding to web services based on Description Logic has been given and also the corresponding matchmaking algorithm. We show that the algorithm proposed has an obvious promotion in the precision at diﬀerent recall levels.  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li Contents • Related Work • Formal Description of Services • Matchmaking of Services – Matchmaking of IO – Matchmaking of PE • Experiments and Evaluations • Conclusions  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li Related Work Matchmaking considers the relationship between two diﬀerent services. Its objective is to answer whether the advertised service could satisfy the request. The matchmaking of Web services is actually the matchmaking of the service description. The description of Web services includes both the syntactic and semantic information. The syntactic description denotes the signature of services while the semantic information describes the functional capabilities of the services. Generally, the description of web services involves the so called IOP E conditions. That means the inputs, outputs, preconditions and eﬀects of the service.  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li Related Work The inputs and outputs description reﬂects the signature of the services. Quite a number of work [4, 5] has been done to cope with the matchmaking of the IO description of the services. In , the author proposed a formalism to describe web services by their P E based on Description Logic . The formalism is ﬁrmly grounded on the research in the reasoning about action community. The formalism is designed to deal with the problem of service reasoning.  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li Related Work Service reasoning, matchmaking and discovery • Reasoning concerns how the world be changed by executing the service. in other words, what the reasoning research group cares about is how to use the P E to describe the worlds before and after executing the services. Its point is the relationship between the world and the service. • Matchmaking considers the relationship between two services. Its objective is to answer whether the advertised service could satisfy the request or if they are matched. • Discovery means to ﬁnd out all the services satisfying the request. Obviously, it needs the support of service matchmaking techniques.  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li Formal Description of Services Service Deﬁnition: Let T be an acyclic TBox. An atomic ground service S = (in, out, pre, ef f ect) for an acyclic TBox T consists of • a ﬁnite set in of SHOIN +(D) concepts, the inputs. • a ﬁnite set out of SHOIN +(D) concepts, the outputs. • a ﬁnite set pre of SHOIN +(D) axioms, the preconditions; • a ﬁnite set ef f ect of SHOIN +(D) axioms, the eﬀects.  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li Formal Description of Services Service Execution: Let T be an acyclic TBox, S = (in, out, pre, ef f ect) a service for T , and I, I models of T sharing the same domain and interpretation of all individual names. Then S may transform I to I iﬀ • I |= in, I |= out, • I |= pre, I |= ef f ect, • there does not exist a model J of T such that J |= out, J |= ef f ect, J = I and J I,S,T I .  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li Matchmaking of Services Given two services descriptions, there’s four kinds of relationships concerns with matchmaking: • Related means there’s some kind of connections explicite or implicite, positive or negative between the two descriptions. • Similar means these two descriptions positively alike to some degree at speciﬁc aspects but just alike. • Replaceable tells us the two descriptions in speciﬁc aspects appeared identical, and the services they represented could substitute each other in these aspects. • Equivalent the two descriptions represents the same or identical things.  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li Matchmaking of Services For the same acyclic TBox, given two services descriptions Sr = (inr , outr , prer , ef f ectr ) and Sa = (ina, outa, prea, ef f ecta), where the Sr represents the requested service and the Sa denotes the advertised usable service. There’s four principles must be keep in mind with regarding to the matchmaking: • Every input needed by Sa could be oﬀered by Sr to some degree; • Every output requested by Sr should be oﬀered by Sa to some degree; • The preconditions of the Sa must be easier to satisfy than the request. Or at least they are as easier to satisfy as each other. • The eﬀects claimed by the Sa must not less than the request. In other words, the eﬀects expected must be satisﬁed in the ﬁrst place.  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li Matchmaking of IO Two observations: • The ﬁrst is we notice that some inputs maybe repeatedly described. For example, some services need an password as an input and also need the user to conﬁrm that password, i.e. reinput that password. • The second situation is some inputs or outputs could be decomposed to two or more related inputs or outputs. For example, some services need a person’s name as a input, this can be one input with the full name or two inputs with the ﬁrst name and last name. So, in our algorithm we are not seeking for an one-to-one matching between the IO of the Sr and Sa. On the other hand, what we expected is how the Inputs needed by Sa might be oﬀered by Sr and how the Outputs required by Sr be supported by Sa.  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li Matchmaking of IO Their exist four degrees of matching for the output: • exact match: for all output oa ∈ outa, there exit an or ∈ outr , such that oa ≡ outr . • plug-in match: for all input oa ∈ outa, there exit an or ∈ outr , such that oa ⊇ or . • subsumes match: for all input oa ∈ outa, there exit an or ∈ outr , such that oa ⊆ or . • fail match: if no subsumption relation is found between outputs of the Sa and Sr . In case of the matching of inputs, roles of advertisement and request are reversed. Degrees of the described matching above are in decreasing order of precedence with exact match having the highest precedence.  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li Matchmaking of PE The pre and ef f ect as to the service description could be looked as two knowledge base Kpre and Kef f ect with respect to the corresponding same acyclic TBox. Accordingly, the matchmaking problem is transformed to the problem of determine the relationship between the two pair of knowledge base Kr−pre, Ka−pre and Kr−ef f ect, Ka−ef f ect. Given two knowledge base K1 and K1, there’s four kind of relationship between them: K1 |= K2, K2 |= K1, K1 ⇔ K2, and last situation means there’s no any deﬁnitely relationship between them.  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li Matchmaking of PE NO. 1 2 3 4 5 6 7 8 9 10 pre Kr−pre |= Ka−pre Kr−pre |= Ka−pre Kr−pre |= Ka−pre Ka−pre |= Kr−pre Ka−pre |= Kr−pre Ka−pre |= Kr−pre Kr−pre ⇔ Ka−pre Kr−pre ⇔ Ka−pre Kr−pre ⇔ Ka−pre no any deﬁnitely relation ef f ect Kr−ef f ect |= Ka−ef f ect Ka−ef f ect |= Kr−ef f ect Kr−ef f ect ⇔ Ka−ef f ect Kr−ef f ect |= Ka−ef f ect Ka−ef f ect |= Kr−ef f ect Kr−ef f ect ⇔ Ka−ef f ect Kr−ef f ect |= Ka−ef f ect Ka−ef f ect |= Kr−ef f ect Kr−ef f ect ⇔ Ka−ef f ect no any deﬁnitely relation Table 1: All possible relationship Between Request and Advertisement about PE  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li Matchmaking of PE • exact match: Obviously, the exact match is the number 9, the advertisement is exactly the request; • perfect match: The number 3 situation, eﬀects is matched perfectly and preconditions fulﬁls Kr−pre |= Ka−pre. The semantics of this situation is the goal advertised is exactly the requested, but the advertised preconditions is easier to satisfy. For example, maybe you searched for a 5$ service, but you got a 3$ one, cheaper than you expected. Certainly, it’s a better choice.  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li Matchmaking of PE • side-eﬀects match: Correspondingly, the number 8 situation means preconditions is matched perfectly and eﬀects holds Ka−ef f ect |= Kr−ef f ect. The semantics of this situation is if the advertised service is executable then the request service is executable, and vice visa. But by applying the advertised service, we will obtain some additional eﬀects than requested. The additional eﬀects oﬀered by the advertised service maybe good or maybe bad. Whatever, we call the excessive part of eﬀects as side-eﬀects. For example, the request is 5$ service to get a hamburger and the advertisement is a 5$ service but oﬀers a hamburger and also a cup of milk. The additional milk is the side-eﬀects and this kind of match is called side-eﬀects match. • common match: The last situation we considered is the number 2. At this situation, both preconditions and eﬀects are not matched perfectly. The advertised preconditions is easier to satisfy than requested and the advertised eﬀects is more than requested.  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li This means the advertised service could work well as needed, but the requirement of preconditions is too much more. Additionally, Applying the advertised service will bring side-eﬀects.  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li Experiments and Evaluations Because of in the speciﬁcation OWL-S, the preconditions and eﬀects are not described in formalism as we proposed. Directly using the OWL-S deﬁned services as input of the matchmaking algorithm won’t work. So we need prepare the service for experiment by ourself. We selected 100 service descriptions from OWLS-TC(service retrieval test collection from SemWebCentral) and translated the P E descriptions to our formalism. We run both IO and IOP E algorithms separately for 10 requests and retrieve the ranked result set for each. For evaluating the matching results, it is common to measure precision at diﬀerent recall levels. Figure 1 shows the average precision value at 5 recall levels. The precision of the IO algorithm is comparatively lower than the IOP E algorithm. The reason is not complex. Since without the P E, some IO acceptable results could be looked as match. The involvement of P E makes false positive of pure IO algorithm added.  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li Experiments and Evaluations  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li Conclusions In this paper, a formal analysis of web services based on Description Logic is given, including the formal deﬁnition of services and the corresponding semantics behind the deﬁnition. According to that deﬁnition, we analyzed the matchmaking of IO as well as P E. Through the analysis of semantics behind the circumstances, we obtain 4 kinds of match situation for IO as well as 4 kinds of match situation for P E. This solution has been examined by our analysis and experiment. We have showed the solution are suitable for the capability matchmaking about web services.  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li Thank you! Email: firstname.lastname@example.org  The 3rd Chinese Semantic Web Symposium Hai Wang, Lin Fan, Zengzhi Li References  F. Baader, D. Calvanese, D. McGuinness, D. Nardi, and P. Patel-Schneider. The Description Logic Handbook : Theory, Implementation and Applications. Cambridge University Press, 2003.  F. Baader, C. Lutz, M. Milicic, U. Sattler, and F. Wolter. A Description Logic Based Approach to Reasoning about Web Services. In Proceedings of the WWW 2005 Workshop on Web Service Semantics (WSS2005), Chiba City, Japan, 2005.  B. F. Mahboob Alam Khalid, Patrick Kapahnke. Owls-tc version 2.2 revision 2, March 2008. Available at http://www.semwebcentral.org/projects/owls-tc/.  T. R. P. Massimo Paolucci, Takahiro Kawamura and K. Sycara. Semantic matching of web services capabilities. In I. Horrocks and J. Hendler, editors, The Semantic Web – ISWC 2002. Proceedings of the First International Semantic Web Conference, volume 2348 of Lecture Notes in Computer Science, pages 333–347, 2002.  E. Sirin, J. Hendler, and B. Parsia. Semi-automatic composition of web services using semantic descriptions. In Web Services: Modeling, Architecture and Infrastructure workshop in ICEIS 2003, Angers, France, April 2003.