Appendix C: Extended Examples

Example is the school of mankind, and they will learn at no other.

Edmund Burke, "Letters on a Regicide Peace"

This appendix is from the book Knowledge Representation: Logical, Philosophical, and Computational Foundations, by John F. Sowa, Brooks/Cole Publishing Co., Pacific Grove, CA, 2000.

C.1 Hotel Reservation System

The following example, which describes a prototype reservation system for the National Park Service, is taken from a sample specification developed in the NCITS T2 Committee on Information Interchange and Interpretation. It illustrates the kind of informal specifications that a systems analyst or knowledge engineer must translate to a computable form.

The proposed system is being designed for the Old Faithful Inn Hotel in the Yellowstone National Park, the El Tovar Hotel in the Grand Canyon National Park, and the Ahwahnee Hotel in Yosemite National Park. The hotels can be uniquely identified by their names. The hotels have a normal address (line 1, line 2, city, state, zip code) and each one has a telephone number and a fax number. Each hotel has a rating from Mobil Travel Service of a certain number of diamonds (from one to five). Hotels may be open for only a certain period of a year. They may also have seasonal rates that reflect the change in demand for their rooms. Room rates are constant for different types of rooms during a season. Reservations are accepted up to thirteen months in advance (e.g., in January 1999 reservations can be made through January 2001). Reservations cannot be made in a hotel before it is open for business or after it is scheduled for permanent closure.

Rooms are of different types and are designated either smoking or nonsmoking. When making a reservation, the individual will select a room type and a smoking category. If a room is changed to a different type or smoking category, the change is effective on a certain date.

Reservations can be made by an individual or a travel agent. Reservations are confirmed for a specific time period, room type(s), smoking category(ies), and rate(s). An individual will give his or her name, address (see example above), phone, and possibly a fax number. A travel agent also gives this information, plus the agent's name and the travel agency identification number. This number will identify the specific travel agency making the reservation, its address, its telephone, and its fax number. Each reservation is made by a reservation clerk and is identified by a sequential number. When a reservation is complete, a timestamp is made for audit purposes.

If a reservation cannot be confirmed, the reservation clerk will ask if the guest would like to be waitlisted. The waitlist is for either a specific hotel or a category of hotels (number of diamonds) at a national park. The waitlist is for a certain period of days from the reservation date. If a room(s) matching the request on the reservation becomes available within the waitlist time period, a confirmation is automatically sent. On the day before the waitlist is to expire, the guest is contacted and asked if his or her place on the waitlist should be extended or if the room type(s) and smoking category(ies) could be changed to allow a reservation to be confirmed.

When a reservation is made, it must be either for a 16.00 hour arrival or guaranteed. A 16.00 hour arrival time allows a reservation to be made and at 16.00 hours on the date of arrival the reservation is automatically canceled without a penalty being assessed to the guest. To hold a reservation after 16.00 hours, the guest must guarantee the room. The guarantee is implemented through a credit card. A guest tells which type of credit card is to be used to guarantee the room and he or she must provide the credit card number and an expiration date.

If a guest with a guaranteed reservation does not show up and does not notify the hotel that he or she will not arrive, then the first night's rent for each reserved room will be charged against the credit card. Guests are encouraged to cancel their reservations if their travel plans change so that others on the waitlist can be accommodated. Guaranteed rooms can be canceled until 16.00 hours on the date of arrival and individuals then receive a cancellation number that insures that they will not be charged for the room. If a guaranteed reservation is canceled after 16.00 hours on the date of arrival then the hotel attempts to rent the room(s). If the room(s) are rented (this is decided based on the time of the cancellation and does not take into account the type or smoking category of the room), then a message is sent to the guest stating that he or she has not been charged for the room. If the room(s) are not rented, then the hotel management decides whether the guest will be charged and will be sent a notice that he or she has been charged or not charged.

A confirmation is sent to the guest when the reservation is confirmed. Each confirmation is time stamped for audit purposes. The confirmation includes all information pertinent to the reservation.

The cancellation notice is sent to the guest if a cancellation number is issued. The notice identifies the reservation and the clerk who canceled the reservation. A time stamp validates that the reservation was canceled in time to avoid a penalty.

Check-in occurs upon the arrival of the guest at the hotel. The time of check-in is noted and the departure date is confirmed. Room number(s) are assigned and keys are given to the guests. If a credit card is to be used for payment, then the information previously noted is collected. A guest may use a different credit card for the stay than the one used to guarantee the reservation. The Park Service also has a policy that hotel bills above a certain limit must be cleared before the guest is allowed to remain in the hotel. The check-in process notifies the guest of the limit he or she must abide by. Because of the flexible reservation policy, walk-in guests without reservations are encouraged — especially right after 16.00 hours.

At the time of check-in a guest may designate one room as the primary room and specify the other room(s) that will have their charges appear directly on the primary room's invoice. This allows a family to have only one bill even though it is occupying several rooms. Invoices show which room made each charge so that guests can better audit their own bills. Guests who have regularly paid their bills when they reach their account balance limits normally check out on their departure date. All guests in rooms that charge a primary room must check out when the guests in the primary room check out. Check-out is required to occur by 12.00 hours, but can be extended to 14.00 hours on request. Guests will be charged for the room if they are not checked out by the cited check-out time. The actual check-out time is used to prevent any further charges from being invoiced to a room. At check-out, each guest is given a copy of the invoice showing all charges and how the balance was cleared. If a guest does not make a payment when his or her account balance reaches the predetermined limit, the guest is automatically checked out. Extensions to stays are routinely made if rooms are available.