- From: Drew McDermott <drew.mcdermott@yale.edu>
- Date: Tue, 22 Nov 2005 19:23:48 -0500
- To: public-sws-ig@w3.org
> [Shi, Xuan]
> My suggestion is that service description can be separated from service
> development. Let's describe the service first. Supposed we have such a
> service description:
>
> <ServiceRequest>
> <Service Name="SearchHotelInformation">
> <Function Name="WebService.Hotel.SearchInformation">
> <InputVariables>
> <CheckInDate></CheckInDate>
> <CheckOutDate></CheckOutDate>
> <NumberOfCustomer></NumberOfCustomer>
> <RoomType></RoomType>
> </InputVariables>
> </Function>
> </Service>
> </ServiceRequest>
>
> it's then easy to develop such a Web service.
It is? Only if there's a Catalog of Hotel Industry Standard Web
Services somewhere that says "SearchInformation expects 4 inputs ...
and yields one output, a list of ..., which means ...."
Suppose we take standardization one step further, and create a
vocabulary for talking about the properties of hotels and ancillary
entities. Using this vocabulary, we could define a couple of message
patterns
(:functions
(search-hotel-information
&key check-in-date check-out-date - Date
number-of-cust - Integer
room-type - Room-type)
(available-rooms rl - (Lst Hotel-room))
- Message)
[Sorry to switch from XML to Lisp, but the verbosity of the former is
unendurable.]
Then we could give axioms such as this --
(forall (g h - Agent
d1 d2 - (Literal Date)
i - (Literal Integer)
rt - (Literal Room-type)
avail - (Lst Room-quote))
(if (implements h hotel-search-protocol)
(message-exchange
g h
(search-hotel-information
:check-in-date d1 :check-out-date d2
:number-of-cust i
:room-type rt)
(available-rooms avail)
(know-val-is
g
(set-of-all
(lambda (r)
(and (has-type r (lit-val rt))
(forall (d - Date)
(if (date-in-interval d (lit-val d1) (lit-val d2))
(room-available r d))))))
(list-elements avail)))))
which we can paraphrase thus: "If agent h implements the
hotel-search-protocol, then a message to it from agent g of the form
(search-hotel-information ...) will yield a reply consisting of a list
of Room-quotes. Once this reply is received, g will know that the
elements of that list are all the available rooms over the date
specified in its message."
[Obviously, there is a lot more that needs to be said, including how
abstract messages get embodied at more concrete levels.]
The idea is to agree on standard vocabulary items such as
'message-exchange' and 'know-val-is', which apply to every domain; and
on terms such as 'room-available' that apply to the hotel industry in
particular. It seems as if it wouldn't be any harder to agree on
'room-available' than on 'search-hotel-information', and you would
gain the ability to knit actions together in unforeseeable ways.
-- Drew
--
-- Drew McDermott
Yale University
Computer Science Department
Received on Wednesday, 23 November 2005 00:22:43 UTC