;; ============================================================================ ;; REARDEN COMMERCE, INC. ;; Travel Policies Ontology ;; ============================================================================ ;; Created by: Valeria de Paiva (vdepaiva [at] reardencommerce [dot] com) ;; Created on: July 1, 2011 ;; ;; Description: This describes concepts related to Corporate Travel policies ;; Ontology dependencies for TravelPolicies.kif: ;; Mid-level-ontology.kif, ;; Hotel.kif, ;; FinancialOntology.kif ;; Transportation.kif ;; NAICS.kif ;; Media.kif ;; Dining.kif ;; Geography.kif ;; Contract.kif ;; Government.kif ;; Catalog.kif ;; Access to and use of these products is governed by the GNU General Public ;; License . ;; By using these products, you agree to be bound by the terms of the GPL. ;; We ask the people using or referencing this work to cite the primary paper: ;; Niles, I., and Pease, A. 2001. Towards a Standard Upper Ontology. In ;; Proceedings of the 2nd International Conference on Formal Ontology in ;; Information Systems (FOIS-2001), Chris Welty and Barry Smith, eds, ;; Ogunquit, Maine, October 17-19, 2001. See also http://www.ontologyportal.org ;;;---------------------------------------------------------------------------- ;;; 1. Corporate Travel Policies ;;;---------------------------------------------------------------------------- ;;; Most companies have corporate travel policies, that govern employees traveling procedures. ;;; Corporate travel policies usually have two parts: ;;; the norm (what the employee is allowed or not to do) ;;; and the algorithm (how he should go about asking for what he wants to do). ;;; Most corporate travel policies start with a Purpose: ;;; The policy's purpose is to ensure that employee travel is consistent with the ;;; business objectives of the company the employee works for. ;;; Employee travel should be via the lowest cost alternative, consistent with good business practices. ;;; Examples of Travel and Expense Policy models: ;;; www.westrav.com/corporate/TravelPolicy.html; ;;; wiki.mygazoo.com/display/fin/Policies+and+Procedures; ;;; wiki/display/eng/Policies+on+Hotel+Bookings+by+RC+Corporate+Clients+-+A+Preliminary+Report+from+A+Knowledge+Engineering+Approach ;;; www.ucop.edu/ucophome/policies/bfb/g28summary.pdf Policy and Regulations Governing Travel University of California ;;; --------------------------------------------------------------------------------- ;;; 2. Policy ;;; --------------------------------------------------------------------------------- ;; September 2, 2011: What is the ontological status of policies? ;; kn: In the wordnet mappings, Policy is subsumed by Plan, however looking at the definition ;; of Plan in SUMO, it is subclassed from Procedure, which is a "sequence-dependent ;; specification", which is not necessarily the case. As such, I will be subclassing policy from Proposition instead. ;; vcvp: I think this is too generic, subclassed from Agreement ;; ap: says Policies can be discussed, approved and implemented before there are any people ;; bound by them. Hence they are not Agreements. ;; vcvp: They are some kind of Declaring, by the Organization that implements the Policy, the policyOwner. ;; They could also be considered Orderings (as there are implicit sanctions if the policy clauses are not followed), ;; but if we follow the example of Law (documentation Law EnglishLanguage "attribute that applies to propositions that are required by a government ;; or a branch of the government and that are enforced with penalties for non-compliance. [..] in the case of government policy.") ;; then they're simply an attribute of propositions. ;; vcvp: I'm against subclassing policy from propositions, as *everything* that is slightly abstract is a proposition. ;; and things that are at the moment subclassed from proposition are messy. They are: ;;(subclass Agreement Proposition) ;;(subclass Argument Proposition) ;;(subclass BankStatement Proposition) ;;(subclass ClassificationScheme Proposition) ;;(subclass Constitution Proposition) ;;(subclass EconomicIndicator Proposition) ;;(subclass Equation Proposition) ;;(subclass FieldOfStudy Proposition) ;;(subclass Procedure Proposition) ;;(subclass RegionalLaw Proposition) ;;(subclass ScientificLaw Proposition) ;;(subclass SuffrageLaw Proposition) ;;(subclass TPFDD Proposition) ;; vcvp: a BankStatement is not a Proposition but a ContentBearingObject, in my opinion. ;; But every ContentBearingObject has a propositional content, which is kind of said in the following: ;(=> ; (and ; (instance ?PROP Proposition) ; (instance ?CBO ContentBearingObject) ; (containsInformation ?CBO ?PROP) ; (instance ?COMM Communication) ; (patient ?COMM ?CBO)) ; (represents ?COMM ?PROP)) ;; This is in Geography.kif 2820-2827, it most certainly shouldn't be there. ; This would be better (I believe) as: (=> (instance ?CBO ContentBearingObject) (exists (?PROP) (and (instance ?PROP Proposition) (containsInformation ?CBO ?PROP)))) ; Moreover all kinds of Communication have their own propositional content: (=> (instance ?C Communication) (exists (?PROP) (and (instance ?PROP Proposition) (containsInformation ?C ?PROP)))) ;; since Communication is partitioned into Stating, Supposing, Directing, Committing, Expressing and Declaring ;; (partition Communication Stating Supposing Directing Committing Expressing Declaring) ;; we need to know how to differentiate between these kinds of "speech acts/illocutionary acts" and their propositional contents. ;; Also every kind of ContentDevelopment have their own propositional content: (=> (instance ?CD ContentDevelopment) (exists (?PROP) (and (instance ?PROP Proposition) (containsInformation ?CD ?PROP)))) ;But this last rule might be redundant because we already have that every ContentDevelopment process results in the creation of a CBO ;(whether the propositional content of the CBO is the same as the propositional content of the ContentDevelopment process is another fine point of philosophy...) ;(=> ; (instance ?DEVELOP ContentDevelopment) ; (exists (?OBJ) ; (and ; (instance ?OBJ ContentBearingObject) ; (result ?DEVELOP ?OBJ)))) ; Anyway the ContentDevelopment processes are another messy bunch, left for another occasion. ;;--------------------------------------------------------------------------------------------------------------- (documentation Policy EnglishLanguage "&%Policy is (the contents of) a type of &%Declaring created and enforced by an &%Organization such as a government or a business, which contains guiding principles or a plan or course of action adopted by that organization.") (termFormat EnglishLanguage Policy "policy") (subclass Policy Proposition) ;(subclass Policy Declaring) ;(subclass Policy ContentBearingProcess) ;; Policies bind the organization (and some individuals) in some informal agreement (=> (instance ?POLICY Policy) (exists (?ORG) (policyOwner ?ORG ?POLICY))) (instance policyOwner BinaryPredicate) (documentation policyOwner EnglishLanguage "(&%policyOwner ?&%Organization ?&%Policy) describes how ?&%Policy is adopted and enforced by ?&%Organization") (termFormat EnglishLanguage policyOwner "policy owner") (domain policyOwner 1 Organization) (domain policyOwner 2 Policy) ;; The policy owner creates the Policy (=> (policyOwner ?AGENT ?POLICY) (exists (?CREATE) (and (instance ?CREATE Creation) (agent ?CREATE ?AGENT) (result ?CREATE ?POLICY)))) ;; if a Travel Policy was a kind of Agreement, ;; it would have the relation partyToAgreement (Geography.kif 2876-2877) ;; since it isn't we only have a policyOwner and no term for the people that are bound by the policy. ;; Need some other notions shared by agreements and contracts. ;; For example policies are `in force' for a duration (from Government.kif 779-790) (instance activePolicy BinaryPredicate) (instance activePolicy AsymmetricRelation) (domain activePolicy 1 Proposition) (domainSubclass activePolicy 2 TimePosition) (documentation activePolicy EnglishLanguage "(&%activePolicy ?POL ?DATE) means that the policy ?POL is effective during the time indicated by ?DATE. The policy may be effective for longer than ?DATE, but it is in effect at least throughout the time indicated by ?DATE.") (=> (and (activePolicy ?POL ?DATE) (instance ?TIME ?DATE) (instance ?FORMULA Formula) (containsInformation ?FORMULA ?POL)) (holdsDuring ?TIME ?FORMULA)) ;; Policies have a date when they become effective (from Government 722-731) (instance policyEffectiveDate BinaryPredicate) (instance policyEffectiveDate AsymmetricRelation) (domain policyEffectiveDate 1 Proposition) (domainSubclass policyEffectiveDate 2 TimePosition) (documentation policyEffectiveDate EnglishLanguage "(&%policyEffectiveDate ?POL ?TIME) means that the policy ?POL becomes effective on the date indicated by ?TIME.") (=> (and (policyEffectiveDate ?POL ?DATE) (confersObligation ?FORMULA ?POL ?AGENT) (instance ?TIME ?DATE)) (holdsDuring (ImmediateFutureFn ?TIME) (holdsObligation ?FORMULA ?AGENT))) (=> (and (policyEffectiveDate ?POL ?DATE) (confersRight ?FORMULA ?POL ?AGENT) (instance ?TIME ?DATE)) (holdsDuring (ImmediateFutureFn ?TIME) (holdsRight ?FORMULA ?AGENT))) ;; Policies have a time period when they are active (from Contract.kif 79-91): (instance policyPeriod BinaryPredicate) (domain policyPeriod 1 Policy) (domain policyPeriod 2 TimeInterval) (documentation policyPeriod EnglishLanguage "(&%policyPeriod ?POL ?DURATION) holds if ?DURATION specifies a &%TimeDuration, which is the length of time that the ?POL is an &%activePolicy.") (=> (and (policyPeriod ?POL ?DURATION) (policyEffectiveDate ?POL ?STARTDATE)) (holdsDuring (TimePeriodFn ?STARTDATE ?DURATION) (property ?POL activePolicy))) ;; Policies need to be agreed on by owners and people subject to them. ;; this might be necessary if there is a dispute. (from ReachingAgreement, Media.kif 122-157) (subclass AdoptingPolicy Stating) (documentation AdoptingPolicy EnglishLanguage "Instances of this &%Class are &%Statings in which two or more agents affirm the same thing (acknowledge the truth of the same &%Propositions).") (=> (instance ?AP AdoptingPolicy) (exists (?A1 ?A2) (and (agent ?AP ?A1) (agent ?AP ?A2) (not (equal ?A1 ?A2))))) (=> (instance ?AP AdoptingPolicy) (exists (?PROP) (and (instance ?PROP Policy) (result ?AP ?PROP)))) ;; PolicyClauses are the important concept for Travel Policies (from Contract.kif 129-150) (instance policyClause QuaternaryPredicate) (documentation policyClause EnglishLanguage "(&%policyClause ?CLAUSE ?ATTR ?POL ?AGENT) means that &%Formula ?CLAUSE, which has &%modalAttribute ?ATTR, is part of &%Policy ?POL and was issued by &%CognitiveAgent ?AGENT") (termFormat EnglishLanguage policyClause "policy clause") (domain policyClause 1 Formula) (domain policyClause 2 DeonticAttribute) (domain policyClause 3 Policy) (domain policyClause 4 CognitiveAgent) (=> (policyClause ?CLAUSE ?ATTR ?POL ?AGENT) (exists (?PROP ?PROC) (and (policyOwner ?AGENT ?POL) (instance ?PROC ContentDevelopment) (result ?PROC ?CLAUSE) (agent ?PROC ?AGENT) (containsInformation ?CLAUSE ?PROP) (subProposition ?PROP ?POL) (modalAttribute ?CLAUSE ?ATTR)))) ;;-------------------------------------------- ;; Ideally *all* policies of a Company would be described in documents. ;; A (e.g. travel) policy of a company is described in a PolicyDocument given to its employees. (documentation PolicyDocument EnglishLanguage "Instances of PolicyDocument are TextDocuments that describe the terms of a specific policy (e.g. Travel Policy) of a given company.") (termFormat EnglishLanguage PolicyDocument "policy document") (subclass PolicyDocument TextDocument) (=> (instance ?DOC PolicyDocument) (exists (?PROP) (and (containsInformation ?DOC ?PROP) (property ?PROP Policy)))) ;; Policies like Contracts must be legal ;; legal is defined in Mid-level-ontology.kif 8370-8377. (=> (and (instance ?DOC PolicyDocument) (containsInformation ?DOC ?PROP) (property ?PROP Policy)) (modalAttribute ?PROP Legal)) ;; Other kinds of Policy that we might want to do: Purchasing or Procurement Policy, ;; Investment Policy, Information Policy, Privacy Policy, ... ;;;------------------------------------------------------------------------ ;;; 3. Travel Policies ;;;------------------------------------------------------------------------- ;;; A TravelPolicy provides guidelines and establishes procedures for individuals ;;; incurring business travel expenses on the organization’s behalf. (subclass TravelPolicy Policy) (subclass TravelPolicyDocument PolicyDocument) (subrelation travelPolicyClause policyClause) (instance travelPolicyClause QuaternaryPredicate) ;;; clearly TravelPolicy is a subclass of Policy; ;;; TravelPolicyDocument a subclass of PolicyDocument and ;; travelPolicyClause a subrelation of policyClause. ;;; A TravelPolicy legislates over the *business trips* (or company travel) that individuals ;;; that represent the organization in a Transaction (mainly employees) are allowed/required to take. ;;; Business Trips ;;; To model business trips, first a SocialRole for an agent representing an Organization (in an Event) ;;; (SocialRole defined in Merge.kif 14122-14122) (instance organizationRepresentative BinaryPredicate) (documentation organizationRepresentative EnglishLanguage "(&%organizationRepresentative ?&%INDIVIDUAL ?ORG) means that the ?INDIVIDUAL is a official representative of ?ORG in some transaction)" ) (termFormat EnglishLanguage organizationRepresentative "an agent that is an organization representative (in some transaction)") (domain organizationRepresentative 1 Agent) (domain organizationRepresentative 2 Organization) (instance organizationRepresentative SocialRole) ;; if a person represents an organization there is a Transaction in which they do so. ;; Government.kif has representativeAgentToAgent 4380-4384 for DiplomaticAgent, but no notion of beneficiary. (=> (organizationRepresentative ?Person ?Org) (exists (?TRANSACTION) (and (instance ?TRANSACTION Transaction) (agent ?TRANSACTION ?Person)))) ;; need to say that the beneficiary of the ?TRANSACTION is Org? ;;;-------------------------------------------------------- ;;; A TravelPolicy legislates over the *business trips* that employees are allowed/required to take. ;;; Business trips (the subject of Travel Policies) are trips whose purpose is working of some sort, ;;; involving the individual representing their organization and the working happens during the trip. ;;; A working trip is a trip whose purpose is doing some work. (subclass WorkingTrip Trip) (=> (instance ?T WorkingTrip) (exists (?TRIP ?HUMAN) (and (instance ?TRIP Trip) (agent ?TRIP ?HUMAN) (hasPurpose ?TRIP (exists (?Work) (and (instance ?Work Working) (agent ?Work ?HUMAN) (holdsDuring ?Work ?TRIP))))))) ;;; since Working is always a FinancialTransaction in SUMO ;;; (subclass Working FinancialTransaction) in Mid-level-ontology.kif 13734-13734 ;;; there is a problem when a self-supporting person takes a business trip and ;;; there is no organization paying for the work involved. ;;; This definition of BusinessTrip subsumes a trip from home to work, which it should not. ;;; A business trip is a trip whose purpose is doing some work on behalf of the company. ;;; BUT this work is not in the employee's usual working place. ;;; A notion of "official working place for an employee" (documentation basedIn EnglishLanguage "(basedIn ?EMPLOYEE ?ORG ?AREA) means that the employee ?EMPLOYEE of the organization ?ORG is usually based or headquartered in ?AREA.") (domain basedIn 1 Human) (domain basedIn 2 Organization) (domain basedIn 3 GeopoliticalArea) (instance basedIn TernaryPredicate) (subrelation basedIn located) (=> (employs ?EMPLOYEE ?ORG) (exists (?AREA) (and (located ?ORG ?AREA) (basedIn ?EMPLOYEE ?ORG ?AREA)))) ;;; Thus (subclass BusinessTrip Trip) (=> (instance ?T BusinessTrip) (exists (?TRIP ?HUMAN ?ORG ?AREA) (and (instance ?TRIP Trip) (agent ?TRIP ?HUMAN) (organizationRepresentative ?HUMAN ?ORG) (hasPurpose ?TRIP (exists (?WORK) (and (instance ?WORK Working) (agent ?WORK ?HUMAN) (holdsDuring ?WORK ?TRIP)))) (not (and (basedIn ?HUMAN ?ORG ?AREA) (located ?WORK ?AREA)))))) ;;; A trip consists of a collection of translocations via some transportation devices, ;;; undertaken by an agent. At least one translocation and at least one agent. (=> (instance ?T Trip) (exists (?TRANSLOCATION ?HUMAN) (and (instance ?TRANSLOCATION Translocation) (instance ?HUMAN Human) (agent ?TRANSLOCATION ?HUMAN) (agent ?T ?HUMAN) (subProcess ?TRANSLOCATION ?T)))) ;;; A business trip has at least one CommercialService ;;; that the employee pays for (and expects reimbursement for). (=> (and (instance ?T BusinessTrip) (agent ?T ?EMPLOYEE)) (exists (?SERVICE ?PAYMENT) (and (instance ?SERVICE CommercialService) (instance ?PAYMENT Payment) (subProcess ?PAYMENT ?SERVICE) (agent ?PAYMENT ?EMPLOYEE)))) ;;; missing employee expects to be reimbursed for CommercialServices by the Org ;;; missing connection between the policyClauses and the TravelServices. ;;;----------------------------------------------------------------- ;;; A BusinessTrip has several Travel Services associated to it, ;;; transportations of different kinds (IntermodalTrip) and ;;; financial transactions corresponding to paying for all the services, like accommodation, food, etc ;;; A Travel Policy regulates which Travel Services can/should be acquired by ;;; the Company's representative when traveling on behalf of the company. ;;; --------------------------------------------------------------------------------- ;;; 4. TRAVEL POLICIES as NORMS ;;; --------------------------------------------------------------------------------- ;;; The propositional content of the Travel Policy (as an Statement of Intention) is a norm. ;;; It determines what employees are obliged to do, ;;; and what they're allowed to do, when traveling on behalf of the company. ;;; What they're allowed to do is to buy some Travel Services and not others. ;;; Say S is an individual TravelService (?to be defined in the Travel Services Ontology?), ;;; then a given TravelPolicy from a given Organization either allows a ;;; given employee to Purchase/acquire that Service or not. ;;; A TravelPolicy can be considered a list of the allowed/permitted TravelServices and a ;;; list of the forbidden ones, for each employee and for each organization. ;;; Each of the allowed (or not)travel services should be modeled by a clause of the TravelPolicy. ;;; The next two rules are sound, but don't help much. (=> (instance ?T TravelPolicy) (exists (?FORMULA1 ?PART1) (and (instance ?FORMULA1 Formula) (containsInformation ?FORMULA1 ?PART1) (instance ?PART1 Proposition) (subProposition ?PART1 ?T) (modalAttribute ?FORMULA1 Obligation)))) (=> (instance ?T TravelPolicy) (exists (?FORMULA2 ?PART2) (and (instance ?FORMULA2 Formula) (containsInformation ?FORMULA2 ?PART2) (instance ?PART2 Proposition) (subProposition ?PART2 ?T) (modalAttribute ?FORMULA2 Permission)))) ;;; ------------------------------------------------------------------------- ;;; 5.Procedures associated with a Travel Policy ;;;--------------------------------------------------------------------------- ;;; A business trip must be requested by the employee (Requesting Merge.kif 10545-10545) (documentation TravelRequest EnglishLanguage "A TravelRequest expresses a desire that some future BusinessTrip.") (termFormat EnglishLanguage TravelRequest "an employee must request permission to go in a BusinessTrip") (subclass TravelRequest Requesting) (=> (and (instance ?BT BusinessTrip) (agent ?BT ?EMPLOYEE)) (exists (?TRAVELREQUEST ?CORPORATION) (and (employs ?CORPORATION ?EMPLOYEE) (instance ?TRAVELREQUEST Requesting) (agent ?TRAVELREQUEST ?EMPLOYEE) (result ?TRAVELREQUEST ?BT)))) ;; a TravelRequest has a propositional content, the result of the request is desired (=> (and (instance ?TR TravelRequest) (agent ?TR ?EMPLOYEE) (patient ?TR ?FORMULA) (instance ?FORMULA Formula)) (desires ?EMPLOYEE ?FORMULA)) ;; the propositional content of the requested TravelRequest and the propositional content of the posted TravelPolicy *should* be consistent. ;; below we say they are consistent. (=> (and (instance ?TR TravelRequest) (instance ?TP TravelPolicy)) (exists (?FORMULA1 ?FORMULA2) (and (realization ?TR ?FORMULA1) (realization ?TP ?FORMULA2) (consistent ?FORMULA1 ?FORMULA2)))) ;;; A travel request is done via a TravelRequestForm ;;; A form is a printed document with spaces in which to write ;;; (subclass FormText Text) in Mid-level-ontology 8698 (subclass TravelRequestForm FormText) (=> (instance ?FORM TravelRequestForm) (exists (?PROP) (and (instance ?FORM TravelRequestForm) (containsInformation ?FORM ?PROP) (property ?PROP TravelRequest)))) ;;; the purpose of a TravelRequestForm is to request travel, the form is an instrument for requesting (=> (instance ?T TravelRequestForm) (hasPurpose ?T (exists (?R) (and (instance ?R TravelRequest) (instrument ?R ?T))))) ;;; A business trip should be approved by the Organization (=> (instance ?BT BusinessTrip) (exists (?TA) (and (instance ?TA TravelApproval) (agent ?TA ?ORG) (patient ?TA ?BT)))) ;;; TravelApproval is a ExpressingApproval by the Organization that refers to a BusinessTrip ;;; ExpressingApproval (Mid-level-ontology.kif 7820-7821) ;;; Missing that the content of the approval is that employee can go in the trip (subclass TravelApproval ExpressingApproval) (=> (instance ?TA TravelApproval) (exists (?PROP ?NORM ?ORG) (and (confersNorm ?TA ?PROP ?NORM) (agent ?TA ?ORG)))) ;;; If an employee has a TravelApproval approved, they are permitted to go on a business trip (=> (and (instance ?TA TravelApproval) (possesses ?EMPLOYEE ?TA)) (confersNorm ?TA (exists (?BT) (and (instance ?BT BusinessTrip) (patient ?TA ?BT) (agent ?BT ?EMPLOYEE))) Permission)) ;;; A business trip must be reported by the employee (=> (instance ?BT BusinessTrip) (exists (?ER ?EMPLOYEE) (and (instance ?ER ExpenseReport) (agent ?BT ?EMPLOYEE) (agent ?ER ?EMPLOYEE)))) ;;; an ExpenseReport is a Report. ;;; Reports are TextualDocuments and FactualText ;;; but it looks like there is no Reporting with agent and result=REPORT. ;;; need to say that an ExpenseReport is done by the employee and refers to the expenses incurred in a business trip. ;;; (Report in Mid-level-ontology.kif 8883-8883) (subclass ExpenseReport Report) (=> (instance ?ER ExpenseReport) (exists (?EMPLOYEE ?ORG) (and (instance ?ER Report) (agent ?ER ?EMPLOYEE) (patient ?ER ?ORG)))) ;; expense reports are communications between the organization and the employee (=> (instance ?ER ExpenseReport) (hasPurpose ?ER (exists (?COMM) (and (instance ?COMM Communication) (instrument ?COMM ?ER))))) ;; expense reports have a CBO(content bearing object) and a propositional content (=> (and (instance ?PROP Proposition) (instance ?CBO ContentBearingObject) (containsInformation ?CBO ?PROP) (instance ?ER ExpenseReport) (patient ?ER ?CBO)) (represents ?ER ?PROP)) ;;; must say that the information the ExpenseReport contains is about BusinessTrips ;;; Geography.kif 2820-2827 ;;; ExpenseReports relate an agent(the employee, the reporter) with the company that employs him (the destination of the report) (=> (instance ?ER ExpenseReport) (exists (?PHYS ?ENTITY ?AGENT1 ?AGENT2) (and (refers ?PHYS ?ENTITY) (patient ?ER ?PHYS) (instance ?AGENT1 CognitiveAgent) (agent ?ER ?AGENT1) (instance ?AGENT2 CognitiveAgent) (destination ?ER ?AGENT2) (employs ?AGENT2 ?AGENT1)))) ;;; A business trip must be reimbursed by the Organization, ;; so there is a reimbursement which is a payment from the company to the employee, because of the business trip taken. (=> (instance ?BT BusinessTrip) (exists (?R) (and (instance ?R Payment) (agent ?BT ?EMPLOYEE) (agent ?R ?ORG) (destination ?R ?EMPLOYEE)))) ;;; relating the Reimbursement to the ExpenseReport (subclass Reimbursement FinancialTransaction) (documentation Reimbursement EnglishLanguage "A &%FinancialTransaction where an &%employee of a company incurs a business expense using his or her own funds and is later paid for the purchases by the company.") (=> (and (instance ?BT BusinessTrip) (instance ?ER ExpenseReport)) (exists (?EMPLOYEE ?ORG) (and (instance ?R Reimbursement) (agent ?BT ?EMPLOYEE) (agent ?R ?ORG) (destination ?R ?EMPLOYEE)))) ;;; ------------------------------------------------------------------------------------ ;;; All official Company travel shall be *properly* authorized, reported, and reimbursed. ;;; ------------------------------------------------------------------------------------ (=> (and (instance ?BT BusinessTrip) (agent ?BT ?EMPLOYEE) (employs ?ORG ?EMPLOYEE)) (exists (?TA ?ER ?R) (and (instance ?TA TravelApproval) (instance ?ER ExpenseReport) (instance ?R Reimbursement) (agent ?TA ?ORG) (agent ?ER ?EMPLOYEE) (agent ?R ?ORG)))) ;;; must make sure that ?TA, ?ER and ?R refer to the BusinessTrip ;;; Connection between the policyClauses and the TravelServices when Travel Services? ;;; Other kinds of Policy that we might want to do: Purchasing or Procurement Policy, ;;; Investment Policy, Information Policy, Privacy Policy, ... ;;;------------------------------------------------------------------------ ;;; 6. More about BusinessTrips ;;;------------------------------------------------------------------------- ;;; BusinessTrips have a duration a number of nights away that the employee need accommodation for. ;;; e.g. if one takes the red eye flight or an overnight train, one does not need one night accommodation. ;;; BusinessTrips have a destination, where the employee is supposed to do work in behalf of the company. ;;; problem with a multi-city trip? (=> (instance ?T BusinessTrip) (exists (?Destination) (and (instance ?Destination City) (destination ?BT ?Destination)))) ;;;------------------------------------------------------------------------------------------------------- ;;; 7. Accommodation Service ;;;------------------------------------------------------------------------------------------------------- ;;; business trips usually have an accommodation service associated to them, provided by a Hotel-Organization ;;; an accommodation service is a CommercialService, which subclasses from ServiceProcess and from FinancialTransaction Merge 9047-MILO 11916 (documentation HotelOrganization EnglishLanguage "An organization that provides TravelerAccommodation, usually in a Hotel building and style.") (subclass AccommodationService CommercialService) (subclass HotelOrganization ServiceOrganization) (=> (and (instance ?BT BusinessTrip) (agent ?BT ?EMPLOYEE)) (exists (?AS ?H) (and (instance ?AS AccommodationService) (subProcess ?AS ?BT) (serviceRecipient ?AS ?EMPLOYEE) (serviceProvider ?AS ?H) (instance ?H HotelOrganization)))) ;;; A Hotel organization provides accommodation services, which are rooms for customers (=> (instance ?H HotelOrganization) (exists (?AS ?CUST ?ROOM) (and (instance ?AS AccommodationService) (attribute ?H TravelerAccommodation) (agent ?AS ?H) (destination ?AS ?CUST) (instrument ?AS ?ROOM) (instance ?ROOM HotelUnit)))) ;; since an AccommodationService is a ServiceProcess, it has a serviceProvider and a serviceRecipient MILO 16467-16477. (=> (instance ?AS AccommodationService) (and (serviceProvider ?AS HotelOrganization) (serviceRecipient ?AS Human))) ;; some services have an instrument through which the service is rendered, e.g. photocopying needs instrument Photocopier. ;; Accommodation services require an instrument Room, which is an instance of HotelUnit, but for which we need more details. ;; So rewriting above as: (=> (instance ?AS AccommodationService) (and (serviceProvider ?AS HotelOrganization) (serviceRecipient ?AS Human) (serviceInstrument ?AS HotelUnit))) (documentation serviceInstrument EnglishLanguage "(serviceInstrument ?EVENT ?OBJ) means that ?OBJect is the instrument of the service provided in ?EVENT.") (domain serviceInstrument 1 ServiceProcess) (domain serviceInstrument 2 Object) (instance serviceInstrument BinaryPredicate) (subrelation serviceInstrument instrument) ;; since an AccommodationService is a FinancialTransaction it has a transactionAmount, Merge 9036 ;; this transactionAmount should be the total paid by the employee to the hotel for which reimbursement is wanted ;; (there might be issues with asking for less reimbursement than the bill, develop this later...) (=> (instance ?AS AccommodationService) (exists (?AMOUNT) (transactionAmount ?AS ?AMOUNT))) ;; Need the propositional content of an accommodation service, something that might or not agree with an accommodationPreferred clause in a Travel Policy ;; also need to link with the rates, see below for max room rate allowed, restricted rates out of policy, private rate hotel ;;; ------------------------------------------------------------------------- ;;; Policy Clauses for Accommodation: Modeling the clauses in ;;; http://wiki/display/eng/Policies+on+Hotel+Bookings+by+RC+Corporate+Clients+-+A+Preliminary+Report+from+A+Knowledge+Engineering+Approach ;;;;------------------------------------------------------------------------- ;;; 1. Some corporations have Preferred Hotel Chains ; a chain in business: a number of similar establishments (stores or restaurants or banks or hotels or theaters) under one ownership.(from wordnet) ; a hotel chain is a collection of hotels-- with a single owner (subclass HotelChain Collection) (=> (instance ?HC HotelChain) (and (instance ?HC Collection) (member ?H ?HC) (attribute ?H TravelerAccommodation))) ;; all hotels in a hotel chain have the same owner (=> (and (instance ?HC HotelChain) (member ?H1 ?HC) (member ?H2 ?HC) (possesses ?H1 ?OWNER1) (possesses ?H2 ?OWNER2)) (equal ?OWNER1 ?OWNER2)) (documentation HotelChain EnglishLanguage "A collection of hotel establishments under one ownership.") ;;; a preferred Accommodation (prefAccomm) is a Policy Clause where the policyOwner (the ?ORG) who set up the TravelPolicy (?TP) ;;; 'orders' any accommodation service (?AS) to be from a specific Hotel-Organization ?H (whether it's a chain or not) ;(=> ; (and ; (instance ?ORG Organization) ; (instance ?TP TravelPolicy) ; (policyOwner ?ORG ?TP)) ; (exists (?CLAUSE) ; (policyClause ; (=> ; (instance ?AS AccommodationService) ; (exists (?ORD ?H) ; (and ; (instance ?ORD Ordering) ; (agent ?ORD ?ORG) ; (agent ?AS ?H) ; (attribute ?H TravelerAccommodation) ; (instance ?H HotelOrganization)))) Obligation ?TP ?ORG))) ;;; 'Preferred Hotel' is a Hotel organization that the company who set up the Travel Policy prefers and it is hence recommended/ordered to its employees. ;;; not all organizations have preferred accommodation rules, it's up to the company whether it prefers a certain hotel (preferred property) or not. (instance Preferred SubjectiveAssessmentAttribute) (instance non-Preferred SubjectiveAssessmentAttribute) (disjoint Preferred non-Preferred) ;(=> ; (and ; (attribute ?PH Preferred) ; (instance ?ORG Organization) ; (policyOwner ?ORG ?TP) ; (policyClause prefAccomm Obligation ?TP ?ORG)) ; (exists (?ORD) ; (and ; (instance ?ORD Ordering) ; (agent ?ORD ?ORG) ; (patient ?ORD ?FORM) ; (containsInformation ?ORD ?FORM) ; (subjectiveAttribute ?PH Favorite ?ORG)))) ;;; Companies might prefer certain properties (modeled above) or they might prefer a chain of Hotels. (subclass PreferredChain HotelChain) ;(=> ; (and ; (instance ?PC PreferredChain) ; (instance ?ORG Organization) ; (policyOwner ?ORG ?TP) ; (policyClause prefAccomm Obligation ?TP ?ORG)) ; (exists (?ORD) ; (and ; (instance ?ORD Ordering) ; (agent ?ORD ?ORG) ; (patient ?ORD ?FORM) ; (containsInformation ?ORD ?FORM) ; (subjectiveAttribute ?PC Favorite ?ORG)))) ;;; "Ordering" is stronger than preferring but has the implicit idea that not following the recommendation results in sanctions. ;;; (maybe TravelPolicies are collections of 'orderings' instead of a collection of 'declaring'?) ;;; given a specific BusinessTrip and an accommodation service, if the TravelPolicy has preferred accommodation ?H, ;;; then the preferred hotel/or preferred chain should be used. ; preferred accommodation might be a Hotel (=> (and (instance ?BT BusinessTrip) (instance ?AS AccommodationService) (subProcess ?AS ?BT) (instance ?TP TravelPolicy) (agent ?BT ?EMPLOYEE) (employs ?COMPANY ?EMPLOYEE) (policyOwner ?COMPANY ?TP) (policyClause ?PrefAccom Obligation ?TP ?COMPANY)) (exists (?H) (and (serviceRecipient ?AS ?EMPLOYEE) (serviceProvider ?AS ?H) (instance ?H HotelOrganization) (subjectiveAttribute ?H Favorite ?ORG)))) ; preferred accommodation might be a HotelChain (=> (and (instance ?BT BusinessTrip) (instance ?AS AccommodationService) (subProcess ?AS ?BT) (instance ?TP TravelPolicy) (agent ?BT ?EMPLOYEE) (employs ?COMPANY ?EMPLOYEE) (policyOwner ?COMPANY ?TP) (policyClause ?PrefAccom Obligation ?TP ?COMPANY)) (exists (?HC) (and (serviceRecipient ?AS ?EMPLOYEE) (serviceProvider ?AS ?HC) (instance ?HC HotelChain) (subjectiveAttribute ?H Favorite ?ORG)))) ; need to say that a RoomRate is out of policy ;; would like to say that what the policy says about accomm is consistent with the accomm service actually used, but ?AS is not a proposition ;(=> ; (and ; (instance ?BT BusinessTrip) ; (agent ?BT ?EMPLOYEE) ; (employs ?COMPANY ?EMPLOYEE) ; (policyOwner ?COMPANY ?TP) ; (policyClause ?PrefAccom Obligation ?TP ?COMPANY)) ; (modalAttribute ?FORM Obligation) ; (consistent ?PrefAccom ?AS)))) ;;;------------------------------------------------------------------------------------------------------ ;;; 2. Classes of Employees ;;; Corporations have classes of employees, as far as travel policies are concerned, VIP and non-VIP employees ;;; it's subjective for the company to decide who's VIP, who's not, but it's an objective norm... (instance VIP SubjectiveAssessmentAttribute) (instance NonVIP SubjectiveAssessmentAttribute) (disjoint VIP NonVIP) (=> (attribute ?P VIP) (exists (?ORG) (and (employs ?ORG ?P) (instance ?P Human) (attribute ?P VIP)))) ;;;------------------------------------------------------------------------------------------------------ ;;; 3. Classes of hotels ;; Sometimes companies have negotiated / special rates with hotels. These are called private rate hotels PRH. ;; in the wiki http://wiki/display/qa/Hotel+Private+Rates ;;; As far as RC is concerned there are Private Rate Hotels and non-Private Rate Hotels, for a given company ?ORG who owns the travel policy ?TP. ;;; While it is an objective norm if a hotel is considered Private Rate or not, only the company who owns the travel policy decides ;;; whether a given Hotel is a PrivateRate Hotel (or not), for them (instance PrivateRate SubjectiveAssessmentAttribute) (instance NonPrivateRate SubjectiveAssessmentAttribute) (disjoint PrivateRate NonPrivateRate) (=> (and (instance ?H HotelOrganization) (instance ?ORG Organization) (instance ?TP TravelPolicy) (policyOwner ?ORG ?TP)) (or (attribute ?H PrivateRate) (not (attribute ?H PrivateRate)))) ;; A private rate hotel might be required or not. If it's required there is a policy clause that `obliges' the accommodation service to have a private rate ;(=> ; (and ; (instance ?ORG Organization) ; (instance ?TP TravelPolicy) ; (policyOwner ?ORG ?TP)) ; (exists (?CLAUSE) ; (policyClause ; (=> ; (instance ?AS AccommodationService) ; (exists (?ORD ?H) ; (and ; (instance ?ORD Ordering) ; (agent ?ORD ?ORG) ; (agent ?AS ?H) ; (attribute ?H TravelerAccommodation) ; (instance ?H HotelOrganization) ; (attribute ?H PrivateRate)))) Obligation ?TP ?ORG))) ;;; given a specific BusinessTrip ?BT and an accommodation service ?AS, if the TravelPolicy has private rate hotel as required, ;;; then a hotel with private rate should be used. (=> (and (instance ?BT BusinessTrip) (instance ?AS AccommodationService) (subProcess ?AS ?BT) (instance ?TP TravelPolicy) (agent ?BT ?EMPLOYEE) (employs ?COMPANY ?EMPLOYEE) (policyOwner ?COMPANY ?TP) (policyClause ?PrivRate Obligation ?TP ?COMPANY)) (exists (?H) (and (serviceRecipient ?AS ?EMPLOYEE) (serviceProvider ?AS ?H) (attribute ?H PrivateRate) (instance ?H HotelOrganization)))) ;;; a private rate hotel (PRH) room rate might be required in the policy... ;; Even if a Private Rate Hotel is not required, and a private hotel rate is not required, the PrivateHotelRate can be used as a bound on the RoomRate allowed, instead of a given max rate allowed. ;;; Condition (8) in John's summary reads "Room rate limited to private rate", a little flowchart to explain how this relates to private rates. ;; given a hotel ?H room ?ROOM the there is a RoomRate which is the amount of rental that one pays for the room per night, usually. (subclass RoomRate FunctionQuantity) (=> (instance ?RR RoomRate) (exists (?H ?ROOM ?ORG ?PS) (and (instance ?H HotelOrganization) (instance ?ROOM HotelRoom) (located ?ROOM ?H) (rentalPrice ?ROOM ?RR ?ORG ?PS)))) ;;; If a given hotel is a PrivateRate hotel and ROOM is any room in it, then ROOM has a PrivateRate hotel rate (as well as a normal rate?). (=> (and (instance ?H HotelOrganization) (attribute ?H PrivateRate) (instance ?ROOM HotelRoom) (located ?ROOM ?H)) (exists (?RATE1 ?PS ?ORG) (and (instance ?PS PricingScheme) (rentalPrice ?ROOM ?RATE1 ?ORG ?PS)))) ;; The pricing scheme should give us a different room rate when the Hotel has a Private Rate. ;;;------------------------------------------------------------------------------------------------------- ;;; 4. Room types ;;; this is an ad hoc definition for RC travel policies. ;;; RC considers the following kinds of room: KingBedRoom, QueenBedRoom, DoubleRoom, SuiteRoom, SuperiorRoom (instance RC-roomType CodeMap) (=> (codeMapping RC-roomType ?String ?HotelRoom) (represents ?String ?HotelRoom)) (codeMapping RC-roomType "KI" KingBedRoom) (codeMapping RC-roomType "QU" QueenBedRoom) (codeMapping RC-roomType "SU" SuiteRoom) (codeMapping RC-roomType "DB" DoubleRoom) (codeMapping RC-roomType "SP" DeluxeRoom) ;; hotel.kif has both SuiteRoom and DeluxeRoom=called Superior in RC policy. Hotel-11.kif 881-886 defines SuiteRoom ;; A QueenBedBedRoom has a queen bed located in it, similar for a KingBedBedroom. ;; Hotel.kif 92-97 already has that a hotel room has a bed, so the following are just sub-cases for the travel app (subclass QueenBedRoom HotelRoom) (subclass KingBedRoom HotelRoom) (=> (instance ?QB QueenBedRoom) (exists (?B) (and (instance ?QB HotelRoom) (instance ?B QueenBed) (located ?B ?QB)))) (=> (instance ?KB KingBedRoom) (exists (?B) (and (instance ?KB HotelRoom) (instance ?B KingBed) (located ?B ?KB)))) (subclass DoubleRoom HotelRoom) ;; A double room has either a double bed or two single beds ;; actually most hotels I know in the US have two *full* beds. need to add this detail? (=> (instance ?DR DoubleRoom) (exists (?B ?B1 ?B2) (or (and (instance ?B DoubleBed) (instance ?DR HotelRoom) (located ?B ?DR)) (and (instance ?B1 SingleBed) (instance ?B2 SingleBed) (instance ?DR HotelRoom) (located ?B1 ?DR) (located ?B2 ?DR))))) ;;; The accommodation service has a serviceProvider, the hotel, a serviceRecipient, the customer and a serviceInstrument, the hotel room provided. ;;; The policy is to restrict the room type, that is, one policy clause is "Do not permit SuiteRoom", "Do not permit KingBedRoom", etc.. ;(=> ; (and ; (instance ?ORG Organization) ; (instance ?TP TravelPolicy) ; (policyOwner ?ORG ?TP)) ; (exists (?CLAUSE) ; (policyClause ; (=> ; (instance ?AS AccommodationService) ; (exists (?ORD ?H ?ROOM) ; (and ; (instance ?ORD Ordering) ; (agent ?ORD ?ORG) ; (serviceProvider ?AS ?H) ; (serviceInstrument ?AS ?ROOM) ; (attribute ?H TravelerAccommodation) ; (instance ?H HotelOrganization) ; (attribute ?ROOM SuiteRoom)))) Prohibition ?TP ?ORG))) ;;; given a specific BusinessTrip ?BT and an accommodation service ?AS, if the TravelPolicy has "Do not permit SuiteRoom", code:SU ;;; then a room which is not a suite should be used. (=> (and (instance ?BT BusinessTrip) (instance ?AS AccommodationService) (subProcess ?AS ?BT) (instance ?TP TravelPolicy) (agent ?BT ?EMPLOYEE) (employs ?COMPANY ?EMPLOYEE) (policyOwner ?COMPANY ?TP) (policyClause ?SuiteRoom Prohibition ?TP ?COMPANY)) (exists (?H ?ROOM) (and (serviceRecipient ?AS ?EMPLOYEE) (serviceProvider ?AS ?H) (serviceInstrument ?AS ?ROOM) (instance ?H HotelOrganization) (instance ?ROOM HotelRoom) (not (attribute ?ROOM SuiteRoom))))) ;; similar rules for KingBedRoom, QueenBedRoom, DeLuxeRoom, DoubleRoom. a way of doing it once only? ;;;------------------------------------------------------------------------------------------------------- ;;; an accommodation service (?AS) has a rate associated to it. ;;; Karen is dealing with rates in general ;;; 5. Maximum Room Rate Allowed: ;;; this is another ad hoc definition for RC travel policies. ;;; Consider the following kinds of maximum rate per room, where the numbers are amounts of dollars per night ;;; {0, .01, 1, 10, 100, 1000, 10000, 105, 110, 115, 119, 120,...,200} ;;; Karen has PricingScheme in Catalog.kif and rents and rentalPrice (=> (and (instance ?AS AccommodationService) (serviceRecipient ?AS ?CUST) (serviceProvider ?AS ?H) (serviceInstrument ?AS ?ROOM) (instance ?CUST Human) (instance ?ROOM HotelRoom) (instance ?H HotelOrganization)) (exists (?RATE ?PS) (and (instance ?PS PricingScheme) (rentalPrice ?ROOM ?RATE ?H ?PS) (rents ?CUST ?H ?ROOM (MeasureFn 1 DayDuration))))) ;; Rate is what the pricing scheme says you pay for a room per day (or night) ;; the policy clause is to say that the max rate allowed for a room is N, say 1000 dollars. ;; or that a rate that is greater than 1000 dollars is forbidden. ;(=> ; (and ; (instance ?ORG Organization) ; (instance ?TP TravelPolicy) ; (policyOwner ?ORG ?TP)) ; (exists (?CLAUSE) ; (policyClause ; (=> ; (instance ?AS AccommodationService) ; (exists (?ORD ?H ?RATE ?ROOM) ; (and ; (instance ?ORD Ordering) ; (agent ?ORD ?ORG) ; (agent ?AS ?H) ; (attribute ?H TravelerAccommodation) ; (instance ?H HotelOrganization) ; (instance ?ROOM HotelRoom) ; (rentalPrice ?ROOM ?RATE ?H ?PS) ; (greaterThan ?RATE (MeasureFn 1000 UnitedStatesDollar))))) Prohibition ?TP ?ORG))) ;;; given a specific BusinessTrip ?BT and an accommodation service ?AS, if the TravelPolicy has "Do not permit room rate above 1000 dollars", ;;; then a room which costs more than 1000 dollars should not be used. (=> (and (instance ?BT BusinessTrip) (instance ?AS AccommodationService) (subProcess ?AS ?BT) (instance ?TP TravelPolicy) (agent ?BT ?EMPLOYEE) (employs ?COMPANY ?EMPLOYEE) (policyOwner ?COMPANY ?TP) (serviceRecipient ?AS ?EMPLOYEE) (serviceProvider ?AS ?H) (serviceInstrument ?AS ?ROOM) (policyClause ?MaxRateK Prohibition ?TP ?COMPANY) (rentalPrice ?ROOM ?RATE ?H ?PS)) (not (greaterThan ?RATE (MeasureFn 1000 UnitedStatesDollar)))) ;;; the existence of a max rate clause does not mean that what it requires is true. ;;;------------------------------------------------------------------------------------------------------- ;;; 6. Per Diem Rates ;;; Per diem (Latin for "per day") refers to a specific amount of money that an organization allows an individual to spend per day, ;;; to cover living and traveling expenses in connection with work. ;;; For some companies 'per diem' does not include accommodation (it's only for meals and incidental expenses). ;;; But for others, as in condition(7) of accommodation rules, they can serve as a fixed bound ;;; "Room rate limited to per-diem" and "The per-diem rates (per company) are stored in another table for the check". ;;;the room rate of an accommodation service cannot be greater than the Per-diem rate, a constant for each ORG, stored in a table somewhere. (instance PerDiemFn UnaryFunction) (domain PerDiemFn 1 Organization) (range PerDiemFn ConstantQuantity) (=> (and (instance ?TP TravelPolicy) (policyOwner ?ORG ?TP) (policyClause ?PerDiemBound Obligation ?TP ?ORG)) (exists (?AS ?H ?RATE ?ROOM ?BOUND) (and (instance ?AS AccommodationService) (instance ?H HotelOrganization) (instance ?PS PricingScheme) (serviceProvider ?AS ?H) (serviceInstrument ?AS ?ROOM) (rentalPrice ?ROOM ?RATE ?H ?PS) (not (greaterThan ?RATE ?BOUND)) (equal ?BOUND (PerDiemFn ?ORG))))) ;;;--------------------------------------------------------------------------------------------------------- ;;; 7. Single leg transportation (flight or rail), no hotel ;;; the condition reads: "Check whether the flights or rails are ;;; round trips or have multiple legs with some hotel stay in between. ;;; A one-way, single leg trip will fail the check." (subclass SingleLegTransportation Transportation) (documentation SingleLegTransportation EnglishLanguage "A single leg transportation service has origin not the same as destination.") (termFormat EnglishLanguage SingleLegTransportation "single leg transportation") (termFormat EnglishLanguage SingleLegTransportation "one way transportation") (=> (instance ?SLT SingleLegTransportation) (exists (?CITY1 ?CITY2) (and (origin ?SLT ?CITY1) (destination ?SLT ?CITY2) (not (equal ?CITY1 ?CITY2))))) (subclass RoundTripTransportation Transportation) (documentation RoundTripTransportation EnglishLanguage "A single leg transportation service has an origin the same as its destination.") (termFormat EnglishLanguage RoundTripTransportation "round trip transportation") (termFormat EnglishLanguage RoundTripTransportation "return transportation") (=> (instance ?SLT SingleLegTransportation) (exists (?CITY1 ?CITY2) (and (origin ?SLT ?CITY1) (destination ?SLT ?CITY2) (equal ?CITY1 ?CITY2)))) ;; a single leg transportation service has origin not the same as destination ;(=> ; (and ; (instance ?ORG Organization) ; (instance ?TP TravelPolicy) ; (policyOwner ?ORG ?TP)) ; (exists (?CLAUSE) ; (policyClause ; (=> ; (instance ?TS SingleLegTransportation) ; (not ; (exists (?AS) ; (instance ?AS AccommodationService)))) ; Permission ?TP ?ORG))) ;; a travel policy clause forbids single leg transportation accommodation if ;; it says that for a single leg transportation, no accommodation service is permitted. ;;;--------------------------------------------------------------------------------------------------------- ;;;; 8. Out of Policy Some accommodation services are OOP (out-of-police) for a given ;; company policy and a given employee (subclass OutOfPolicyAccom AccommodationService) (=> (instance ?OOP OutOfPolicyAccom) (exists (?ORG ?POL ?PROP1 ?PROP2) (and (instance ?ORG Organization) (instance ?POL Policy) (policyOwner ?ORG ?POL) (containsInformation ?POL ?PROP1) (containsInformation ?OOP ?PROP2) (not (consistent ?PROP1 ?PROP2))))) ;;; Services do not have a propositional content... ;;;----------------------------------------------------------------------------------------------------- ;; 9. CostOfTrip is the sum of transportation services cost plus accommodation costs plus meals plus incidental costs ;;;----------------------------------------------------------------------------------------------------- ;; given a TravelPolicy, then there exists an organization, a person and a business trip such that the TravelPolicy is imposed by the organization, ;; the person represents the org in some event, the business trip is taken by the person--still need to say in behalf of the organization ;; and that the business trip conforms to the Travel Policy. (=> (instance ?T TravelPolicy) (exists (?ORG ?INDIVIDUAL ?BUSINESSTRIP) (and (policyOwner ?ORG ?T) (organizationRepresentative ?INDIVIDUAL ?ORG) (instance ?BUSINESSTRIP BusinessTrip) (agent ?BUSINESSTRIP ?INDIVIDUAL)))) ;;; Missing conditions: ;;; Should a mark be made when the hotel (not only the rate) is out of policy? (3) actually modeled hotel out of policy not rate... ;;; Employees have CorporateCreditCards whose purpose is to pay for BusinessTrips ;;; If a trip is less than 24 h duration hotel accommodation is not allowed. ;;; (A difficult clause) ;;; A traveler may use surface transportation for personal reasons even though air travel is the appropriate mode of transportation. ;;; The cost of meals and lodging, parking, mileage, tolls, taxis, and ferries incurred while in transit by surface transportation may be reimbursed. ;;; Such costs shall not exceed the cost of airfare, based on the lower of the regular coach fare available for the location of travel from a standard ;;; commercial air carrier or the preferred travel program fare, plus transportation costs to and from the terminals.