W3C


RIF Use Cases and Requirements

W3C Editor's Draft 1823 May 2008

This version:
http://www.w3.org/2005/rules/wg/draft/ED-rif-ucr-20080518/http://www.w3.org/2005/rules/wg/draft/ED-rif-ucr-20080523/
Latest editor's draft:
http://www.w3.org/2005/rules/wg/draft/rif-ucr/
Previous version:
http://www.w3.org/2005/rules/wg/draft/ED-rif-ucr-20080318/http://www.w3.org/2005/rules/wg/draft/ED-rif-ucr-20080518/ (color-coded diff)
Editors:
Allen Ginsberg, Mitre David Hirtle, National Research Council CanadaAdrian Paschke, Technical University Dresden, Germany
David Hirtle, National Research Council Canada
Allen Ginsberg, Mitre
Paula-Lavinia Patranjan, REWERSE
Frank McCabe, Fujitsu


Abstract

This document, developed by the Rule Interchange Format (RIF) Working Group, specifies use cases and requirements for the W3C Rule Interchange Format, a formatfamiliy of rule interchange dialects that allows rules to be translated between rule languages and thus transferred between rule systems. The Phase 1 versionpurpose of thisthe RIF Use Cases and Requirements (RIF-UCR) document presentsis two-fold. On the one hand it should document goals, use cases and requirements as reference to what shaped the design of the general Framework for Logic-based RIF in general, butDialects (RIF-FLD) and its first two RIF dialects, namely the RIF Basic Logic Dialect (RIF-BLD) and the RIF Production Rules Dialect (RIF-PRD). On the other hand, the general requirements primarily for Phase 1.and the Phase 1 deliverables will provide an extensible baserepresentative usage scenarios with whichexamples should guide users and implementers to RIF by illustrating the use cases can be addressed, but it will not be until Phase 2 that mostimplemented syntax and semantics of these use cases are directly addressed bythe Working Group.currently released RIF dialects, and by supporting engineers of future dialects and tools in their design choices.

Status of this Document

May Be Superseded

This section describes the status of this document at the time of its publication. Other documents may supersede this document. A list of current W3C publications and the latest revision of this technical report can be found in the W3C technical reports index at http://www.w3.org/TR/.

Set of Documents This document is being published as one of a set of 5 documents: RIF Basic Logic Dialect RIF Framework for Logic Dialects RIF RDF and OWL Compatibility RIF Data Types and Built-Ins RIF Use Cases and Requirements (this document)Please Comment By 2008-05-25

The Rule Interchange Format (RIF) Working Group seeks public feedback on these Working Drafts. Please send your comments to public-rif-comments@w3.org (public archive). If possible, please offer specific changes to the text that would address your concern. You may also wish to check the Wiki Version of this document for internal-review comments and changes being drafted which may address your concerns.

No Endorsement

Publication as a Working Draft does not imply endorsement by the W3C Membership. This is a draft document and may be updated, replaced or obsoleted by other documents at any time. It is inappropriate to cite this document as other than work in progress.

Patents

This document was produced by a group operating under the 5 February 2004 W3C Patent Policy. W3C maintains a public list of any patent disclosures made in connection with the deliverables of the group; that page also includes instructions for disclosing a patent. An individual who has actual knowledge of a patent which the individual believes contains Essential Claim(s) must disclose the information in accordance with section 6 of the W3C Patent Policy.


Contents

1 Introduction

Rule-languages and rule-based systems have played seminal roles in the history of computer science and the evolution of information technology. From expert systems to deductive databases, the theory and practice of automating inference based on symbolic representations has had a rich history and continues to be a key technology driver.

Due to the innovations made possible by the Internet, the World Wide Web, and, most recently, the Semantic Web, there is now even greater opportunity for growth in this sector. While some of these opportunities may require advances in research, others can be addressed by enabling exisiting rule-based technologies to interoperate according to standards-based methodologies and processes. The basic goal of the Rule Interchange Format (RIF) Working Group is to devise such standards and make sure that they are not only useful in the current environment, but are easily extensible in order to deal with the evolution of rule technology and other enabling technologies.

The purpose of this RIF-UCR document is to provide a structured contextreference to the design of RIF and a guide for formulating futureusers and implementers to the current technical specifications for RIF. Section 2 presents a set of use cases that are representativeof the types of application scenarios thatRIF is intended to support. Besides providing concrete examples for analysis, these use cases also representdialects. Beside that, it delivers a kindstructured context for formulating future technical specifications of committment, since it is expected that the relevant functionality specified in the use cases will ultimately be enabled by applications or systems that incorporatefurther RIF technical specifications. Additionally,dialects. The presented use cases illustrate some of the principal ways in which RIF can provide benefits. RIF can promote innovation and development by fostering collaborative work and providing new opportunities for third-party services. RIF can promote e-commerce by providing interoperability across vendor platforms. RIF can promote efficient process management through reuse, sharing, and the ability to provide unified views across disparate platforms. Last, but not least, RIF can promote the growth of knowledge by enabling reasoning with merged sets of rules originating from disparate knowledge sources.

Section 4 of thisThe RIF-UCR document begins with a brief explanationis structured as follows: Section 2 formulates the overall goals of RIF and several accordant critical success factors Analysis , which is a methodology, orthogonal to use-case analysis, that can be used using to drivefor RIF. Section 3 summarized the process of capturingreleased RIF dialects and organizing requirements. This form of analysis proceeds by first enumeratingthe main goalscurrent structure of an activity, or project, in this case the goalsRIF. Section 4 presents a set of RIF working group activity, and relates those goals to what are determined to be key factorsuse cases that are critical to their attainment. Requirements, in turn, are measurable properties that directly support one or morerepresentative of these critical success factors.the section includes diagramstypes of application scenarios that show the relationships among the goals, critical success factors, and requirements. Critical factor analysisRIF is especially helpful inintended to support. Besides illustrating the generationutilization of "non-functional requirements" and constraints, sincethe latter do not arise fromcurrent RIF dialects, the needfunctionality specified in the use cases, together with the inferred requirements, acts as input for a particular typethe technical specification of function or specific behavior,future RIF dialects and for the implementation of various variants of this scenarios by applications or systems that incorporate the existing or newly developed RIF technical specifications. In section 5 several important requirements for RIF are therefore difficult to inferinferred from individualthe goals and the use cases. For example "implementability," is a general requirement on RIF as a whole - one that is presupposed byIn the main all requirements should have a use cases. The actual statementcase or derivation of requirements is given in Section 5. In addition to being generated bya use cases analysis and critical factor analysis, somecase from which they are derived. In exceptional circumstances requirements may not be derived from a use case, e.g. when they are additionaly directly stated in, or implied by,already defined as constraints in the working group charter. For example the "XML syntax" requirementTheir fulfillment is explicit in the charter.discussed with respect to the "RDF Data" requirement, generated by use case analysis, is also interpreted as being implied byexisting RIF dialects.


2 Goals

The charter's call for RDF compatibility. Oneprimary goal of the critical factors for a successfulRIF is that itto be useful for interchangean effective means of exchanging rules amongthat has the set of rule languages itpotential to be widely adopted in industry and that is consistent with existing W3C technologies and specifications.

2.1 Consistency with W3C specifications

RIF is intended to cover.be a W3C specification that builds on and develops the existing range of specifications that have been developed by the W3C. This leads toimplies that existing W3C technologies should fit well with the requirement "Rule Language Coverage" which is currently somethingRIF.

2.2 Exchange of a promissory note concerningRules

The languages RIF will cover. As discussed in section 6, Coverage ,primary goal of the ideaRIF is to characterizefacilitate the spaceexchange of rule languages in such a way that clear and principled decisions as to what the RIF will (and will not) cover can be made. We note that inrules. This document we deliberately refrain from definingmission is part of W3C's larger goal of enabling the notionsharing of "coverage"information in forms suited to machine processing:

    1. Rules themselves represent a rigorous manner, since precisely what it meansvaluable form of information for diverse rule languages to be "covered" by RIF may vary from case to case. Intuitively, when we say that "RIF covers rule language L" we mean thatwhich there is at least onenot yet a standard dialect of RIF into which rules written in L can be translated and vice versa. 2 Use Cases Nearly fifty use cases documentinginterchange format, although significant progress has been made within the need for a RIF were originally submitted. These were grouped into eight general categoriesRuleML Initiative and then synthesized as muchelsewhere.
    2. Rules provide a powerful business logic representation, as possible.business rules, in many modern information systems.
    3. Rules are often the second round, two new use cases were added. The following use case descriptions, guided by this synthesis, provide scenarios that motivate the need and explain the benefitstechnology of a RIF. They are also intended to provide an ongoing reference pointchoice for the working group in its goalcreating maintainable adapters between information systems.
    4. As part of providingthe Semantic Web architecture, rules can extend or complement the OWL Web Ontology Language to more thoroughly cover a precisebroader set of requirements for a RIF.applications, with knowledge being encoded in order to enhance readability and avoid the appearanceOWL or rules or both.

2.3 Widescale Adoption

It is an explicit goal of syntactic prejudice, we have deliberately avoidedthe use of formal notation in representingW3C that the Rules in these use cases except where doing so might introduce ambiguity. However, this informality may lead readers toInterchange Format will have the conclusion thatmaximum potential for widescale adoption. Rules can perform arbitrary actions ininterchange becomes more effective the real world. Thiswider adoption there is notof the case;specification -- the RIF WG has not yet decided onso-called "network effect".

2.4 Critical Succes Factors

Given the ultimate power that rules will have. 2.1 Negotiating eBusiness Contracts Acrossgreat diversity of existing rule Platforms This use case illustrates a fundamental uselanguages and rule concepts, the design of a general Rule Interchange Format, which has the RIF:potential to supplyachive the above three primary goals, is a vendor-neutral representation of rules, so that rule-system developers and stakeholders can do their work and make product investments without concern about vendor lock-in,difficult integration and in particular without concern that a business partner does notconceptualization problem. Factors which have been identified by the same vendor technology. It also illustratesWorking Group as critical for the fact thatsuccess of the RIF can be used to foster collaborative work. Each developer and stakeholder can make a contribution toare:

    1. Alignment with Key W3C Specifications: The joint effort without being forced to adoptRIF should fit well with key existing W3C specifications such as XML and should align well with the tools or platforms ofSemantic Web standards such as resource descriptions (RDF) and ontologies (OWL).
    2. Coverage: The other contributors. John is negotiating an electronic business contract regardingRIF should cover the supply of various typesmajor classes of itemsrule formalisms that Jane's company is manufacturing. Jane and John interchange the contract-related data and rules involved in the negotiationare in electronic form so that they can run simulations. Both agree on a standard Business Object Model / data model (i.e., vocabulary / ontology) for the goodswidespread use and services involved - in this case an XML schemashould provide adequate expressiveness to represent them.
    3. Encouragement of Interoperability: RIF will encourage interoperability, e.g., overlap between dialects and appropriate test XML documents are interchangeddistinguished dialects with their rules. Since John and Jane run applications based on different vendors' rule engines and rule languages, they interchangemaximum overlap.
    4. PredictabilityThe rules usingRIF must be a sound basis for exchanging rules, i.e., it must be predictable what is exchanged when a ruleset is exchanged between partners and/or tools.
    5. Extensibility: Given that rule languages are expected to continue to evolve, it is important that the RIF; both vendors used can interpretRIF is able to incorporate rule languages not currently envisaged.
    6. Ease of use: The XML schema and data,RIF should provide a low learning barrier and producehave a minimal set of concepts with a clear meaning
    7. Low Cost of Implementation: The results as an amended XML document. John's company defines its purchase orders in termscost of an XML descriptionsupporting the RIF will have a direct impact on the extent of goods, packaging, delivery locationits deployability and datehence indirectly on it adoption.

Along with deliverythe use cases in the next section, these goals and payment rules. A rule proposed by John might becritical success factors motivate the following: If an item is perishablerequirements and itobjectives in Sections 5.

3 Structure of RIF

RIF is delivereddescribed by a set of documents, each fulfilling a different purpose, and catering to John more than 10 days after the scheduled delivery date thena different audience. Currently the item will be rejected by him. Representation in RIF BLD Presentation Syntax: Herefollowing set of documents has been released:

  • The prefix ppl is an abbreviationRIF-FLD (Framework of Logic Dialects) document describes a framework of mechanisms for http://example.com/people#,specifying the prefix cpt for http://example.com/concepts#,syntax and op stands for a yet-to-be-determined IRI forsemantics of logic-based RIF builtin predicates. Forall ?item ?deliverydate ?scheduledate ?diffduration ?diffdays ( "cpt:reject"^^rif:iri("ppl:John"^^rif:iri ?item) :- And("cpt:perishable"^^rif:iri(?item) "cpt:delivered"^^rif:iri(?item ?deliverydate "ppl:John"^^rif:iri) "cpt:scheduled"^^rif:iri(?item ?scheduledate) External("fn:subtract-dateTimes-yielding-dayTimeDuration"^^rif:iri(?deliverydate ?scheduledate ?diffduration)) External("fn:get-days-from-dayTimeDuration"^^rif:iri(?diffduration ?diffdays)) External("op:numeric-greater-than"^^rif:iri(?diffdays "10"^^xsd:integer))) ) Abridged syntax: Forall ?item ?deliverydate ?scheduledate ?diffduration ?diffdays ( <cpt:reject>(<ppl:John> ?item) :- And(<cpt:perishable>(?item) <cpt:delivered>(?item ?deliverydate <ppl:John>) <cpt:scheduled>(?item ?scheduledate) External(<fn:subtract-dateTimes-yielding-dayTimeDuration>(?deliverydate ?scheduledate ?diffduration)) External(<fn:get-days-from-dayTimeDuration>(?diffduration ?diffdays)) External(<op:numeric-greater-than>(?diffdays 10))) ) Jane replies with some suggested rule changes: If an item is perishable and it is delivered to John more than 7 days after the scheduled delivery date but less than 14 days after the scheduled delivery date thendialects through a discountnumber of 18.7% will be applied togeneric concepts.
  • The delivered item. Representation inRIF-SWC (Semantic Web Compatibility)document specifies the interoperation between RIF BLD (Abridged) Presentation Syntax: Forall ?item ?deliverydate ?scheduledate ?diffduration ?diffdays ( <cpt:discount>(?item 18.7) :- And(<cpt:perishable>(?item) <cpt:delivered>(?item ?deliverydate <ppl:John>) <cpt:scheduled>(?item ?scheduledate) External(<fn:subtract-dateTimes-yielding-dayTimeDuration>(?deliverydate ?scheduledate ?diffduration)) External(<fn:get-days-from-dayTimeDuration>(?diffduration ?diffdays)) External(<op:numeric-greater-than>(?diffdays 7)) External(<op:numeric-less-than>(?diffdays 14))) ) John considers this and agrees with Jane. Both organizations utilize these rules in their operational systems using disparate rule representations internally to compute prices for this orderand determine contract compliance. Future requests forthe supply of items by John's company are defined on their purchasing web site, asdata and ontology languages RDF, RDFS, and OWL.
  • The appropriate XML schemaRIF-DTB (Data Types and aBuiltins) document describes RIF ruleset (or rulesets). This allows Jane's companydata types and its competitors to respond electronically with XML cost sheets. Suppliers respond with multiple cost sheets with different variations onbuilt-in functions and predicates
  • The RIFRIF-Core document ...
  • The RIF-BLD (Basic Logic Dialect) document specifies a basic interchange format that allows logic rules proposed by John's company, allowing John's company(definite Horn rules with equality) to reviewbe exchanged
  • The alternativeRIF-PRD (Production Rules with their associated costsDialect) document specifies the RIF production rules dialect to determine whether they, as a business, would benefit by relaxing or adding newenable the interchange of production rules
  • as proposed by suppliers. Motivates: Compliance model -- An obvious constraint onThe rule languages used in John'sRIF-UCR (Use Cases and Jane's applicationsRequirements) document describes use cases and requirements for RIF

RIF is that they must supportdesigned as a familiy of RIF classdialects. Each dialect is a collection of expressivenesscomponents that is sufficient to expressworks together, forming an interlingua. New dialects are needed when no existing dialect provides the rules they need torequired rule-language features for interchange.

Although this is obviously true whether they useThe RIF Framework for Logic-based Dialects (RIF-FLD) describes mechanisms for specifying the interchange or not, in thesyntax and semantics of logic-based RIF case, the applications may need to be awaredialects through a number of thegeneric concepts. Every logic-based RIF expressiveness classdialect is required to specialize these general mechanisms, which may include leaving out some elements of the other part. In that sense, it motivates the "compliance model" requirement. XMLRIF-FLD, to produce its concrete syntax --and model-theoretic semantics. Currently, the use case explicitely states that rulesfirst two existinting RIF dialects are interchanged as an XML document. XML types -- the use case motivates the "XML types" requirement, sincethe agreed exchange data model in terms of whichRIF Basic Logic Dialect (RIF-BLD) and the RIF Production Rules are specifiedDialect (RIF-PRD).

RIF-BLD is an XML schema: for example if thea specialization of RIF-FLD capable of representing definite Horn rules are goingwith equality enhanced with a number of syntactic extensions to do testssupport expressive features such as objects and frames, internationalized resource identifiers (IRIs) as identifiers for concepts, and arithmetic on values transmitted over thatXML then the semantics of those tests oughtSchema data types.

RIF-PRD specifies a production rules dialect to be compatible with the corresponding XML datatypes - including allenable the annoying corner cases of NaNs , treatmentinterchange of equality in floats/doubles, type promotion etc. If either end use different representations for the concrete types internally thenproduction rules.

The normative syntax for RIF "translators" are going to have to compensate. Coverage -- suppose that Jane's company usesdialects is a Prolog-like rule language, and John's company usesconcrete XML syntax. A production rule language. To exchange rules, it must be possible to translate between rule language dialects .non-normative presentation syntax is additionally specified for example, prolog rule bodies map to production rule conditions and prolog rule heads mapeach dialect, to production rule actions, all the while preserving the intended meaning. 2.2 Negotiating eCommerce Transactions Through Disclosure of Buyer and Seller Policiesallow a more easily readable and Preferences Thiscompact presetation language fragments (such as examples etc).

4 Use Cases

A use case concerns the ability of parties involved in formal transactions or procedures, e.g., credit card authorization ofmay be considered to be a purchase, accessdescription of private medical records, etc., to expressa problem and protect their interests withina policy-governed framework. The goal is to formally encodesolution that utilized an existing RIF dialect or requires the preferences, priorities, responses, etc.,specification of the parties in sucha waynew one. It is intended that the overall policy can work as intended while providing opportunity for automatic negotiationuse cases presented here include the widest possible number of terms when allowed byrequirements using as few use cases as possible. The policy. Utilizationincluded usage scenarios are meant to be representative, meaning that the general concepts are common to many possible use cases across a broad array of rule-based application domains and industrial sectors.

Nearly fifty use cases documenting the need for a RIF in thiswere originally submitted by the working group members. These were grouped into general categories and then synthesized as much as possible. The following use case would extenddescriptions, guided by this synthesis, provide scenarios that motivate the scopecurrent design of this technology, affording a higher degreeRIF, explain the benefits of interoperability, as well as enabling re-usea RIF, and sharing of preferences, etc., through interchange.guide users its currently specified dialects. The detailed scenario below shows how this would work. Alice wantsuse cases are also intended to buy a device atprovide an online site called "eShop." Alice employs software called "Emptor" that functions as automated negotiating agentongoing reference point for buyers. eShop employs software called "Venditor" as automated negotiating agentthe working group in its goal of providing a precise set of requirements for sellers. Alice's and eShop's policies describe who they trusta RIF and for what purposes. The negotiation is based onin developing new RIF dialects.

Whenever possible, we will give concrete illustrations how the policies, which are specified as rules, and credentials Emptor and Venditor have. These policiesexisting RIF dialects (BLD and credentials are disclosed (interchanged) so asPRD) address various aspects of the use cases. In order to automatically establish trust withenhance readability and avoid the goalappearance of successfully completingsyntactic prejudice, we have deliberately avoided the transaction. Policies are themselves subjectuse of formal notation in representing rules in these use cases. Instead, we will use a highly compact abridged presentation syntax which maps to access control. Thus, rule interchange is necessarily done during negotiation and (in general) depends onthe current level of trust thatdialect's presentation syntax as follows:


Editor's Note: We need to discuss the systems have on each other. Since Emptor and Venditor might use different rule languages and/or engines for evaluating (ownabridged presentation syntax and imported) rules, a (standard) rule interchange format (RIF) needsits mapping to be employed for enablingthe rule interchange betweenfull presentation syntax

*** Abridged Presentation Syntax ***


Editor's Note: The two systems. When Alice clicks on a "buy it" button atexamples in the eShop's Web site, Emptor takes over and sends a requestuse cases will be updated according to eShop's site. Venditor receivesthe requestlatest BLD and sends parts of its policy (i.e.PRD syntax. More examples illustrating e.g. frames and other features will be added

4.1 Negotiating eBusiness Contracts Across Rule Platforms

This use case illustrates a setfundamental use of rules) back to Emptor. Among other things,the policy states that:RIF: to supply a buyer must provide credit card information together with delivery information (address, postal code, city, and country).vendor-neutral representation in RIF BLD (Abridged) Presentation Syntax: allow(access(?Resource)) :- valid_payment_method(?C), valid_delivery_address(?D). valid_payment_method(?C) :- credential(payment_card, ?C#<ex:CreditCard>). valid_delivery_address(?D) :- declaration(delivery_address,?D[address->?A, postal_code->?P, city->?CI, country->?CO]). Rules express compactly possible ways in which a resourceof rules, so that rule-system developers and stakeholders can be accessed; by exchanging them negotiations are shorterdo their work and make product investments without concern about vendor lock-in, and privacy protection is improved.in our example, Venditor reveals part of its policy in form of rules to enable Emptor to choose how to answer, i.e. to decide which credentials to disclose. Note, however,particular without concern that this isa deliberately simplified example in which credentials' requests can be handled more directly. For determining whether Venditor's request for information is consistent with Alice's policy, Emptor takes its rules into account, which state for example: Disclose Alice's credit card information only to online shops belonging to the Better Business Bureau. Representation in RIF BLD (Abridged) Presentation Syntax: allow(release(credential(?C#<ex:CreditCard>))) :- credential(bbb, ?Cred[issuer->"Betterbusiness Bureau"]). By disclosing (interchanging)partner does not have the above given rule, Emptor asks Venditor to provide credentials saying thatsame vendor technology. It belongs toalso illustrates the Better Business Bureau, Alice's most trusted source of information on online shops. eShop has such a credentialfact that the RIF can be used to foster collaborative work. Each developer and its policy containsstakeholder can make a rule stating to release itcontribution to any potential purchaser. Hence, Venditor passesthe credentialjoint effort without being forced to Emptor. Emptoradopt the tools or platforms of the other contributors.

John is now ready to disclose Alice's credit card information to Venditor but it still must check whether disclosing allnegotiating an electronic business contract regarding the information does not break Alice's denial constraints. Alice has stated two constraints stating: Never disclose two different credit cards tosupply of various types of items that Jane's company is manufacturing. Jane and John interchange the same online shop. For anonymity reasons, never provide both her birth datecontract-related data and postal code. Representationrules involved in RIF BLD (Abridged) Presentation Syntax: :- allow(release(credential(?C1#<ex:CreditCard>))), allow(release(credential(C2#<ex:CreditCard>))), ?C1 != ?C2. Different choices exist for implementing the above constraints as rules; choosingthe type of rules for implementing policies depends alsonegotiation in electronic form so that they can run simulations. Both agree on the capabilities of the Emptor system.a standard Business Object Model / data model (i.e., vocabulary / ontology) for the goods and services involved - in this purchase, anonymity is no issuecase an XML schema and only information on one credit card is requested. Thus, Alice's constraintsappropriate test XML documents are respected. Emptor therefore provides Alice's credit card information to Venditor. Venditor checks that Alice is not on eShop's blacklist, then confirms the purchase transaction. Companies that provide software such as Venditorinterchanged with their rules. Since John and Emptor would make use of the RIF in a number of ways. The rules expressing Alice's and/or eShop's policies could be expressed inJane run applications based on different vendors' rule languages but still work with the software, using RIF-based interchanges. Secondly, assuming Venditorengines and Emptor are products of different companies using different internalrule languages, it would still be possible for them to work together in real-time. When these two systems need to exchange policy or preference information of their respective clientsthey would useinterchange the RIF to enablerules using the interchange in real-time. When Venditor sends its initial policy information to Emptor it usesRIF; both vendors used can interpret the RIF. Emptor takes that policyXML schema and translates it fromdata, and produce the RIF to its internal representationresults as an amended XML document. John's company defines its purchase orders in order to determine what it needs to do. Motivates: Default behavior Theterms of an XML description of goods, packaging, delivery location and date with delivery and payment rules. A rule systems employedproposed by the agents involved in a negotiation, Emptor and Venditor here,John might have different capabilities. Thus, situations may occur where an agent does not understand (part of) the rules received from the other agent, even though they were interchanged through RIF. In such cases, a way to specify the default behavior would at least ease the understanding of the reasons whybe the negotiation failed or entailed just partial results, such as accessfollowing:

If an item is perishable and it is delivered to  part ofJohn more than 10 days after the  data or services. Limited number of dialects Because ofscheduled delivery date
then the  rich diversity of agentsitem will be rejected by him.

Representation in the setting of automatically establishing trust through negotiations, a limited number ofRIF dialects would decreaseBLD Presentation Syntax:

Here the  number of negotiations that failed because of incompatible dialects. Rule language coverage Intuitively, itprefix ppl is  clear that RIF should cover features found in most of the existing policy languages. A more detailed discussion onan abbreviation for http://example.com/people#,
the  rule language coverage follows. Syn 1.7 Means to access data in Web formats Policies frequently contain simple ontologies; means to accessprefix cpt for http://example.com/concepts#,
and  reason with OWL data is neededop stands for  applications involving such policies. SeS 2.9 Prioritya  conflict resolution mechanism is needed e.g. in situations where different policies may apply; prioritizing policies would be useful in such cases. ECA 5.1 General Policies may need support for event detection, event communication, and execution of actions; thus, supportyet-to-be-determined IRI for  reactive behaviourRIF builtin predicates.
Forall ?item ?deliverydate ?scheduledate ?diffduration ?diffdays (
    "cpt:reject"^^rif:iri("ppl:John"^^rif:iri ?item) :-
        And("cpt:perishable"^^rif:iri(?item)
            "cpt:delivered"^^rif:iri(?item ?deliverydate "ppl:John"^^rif:iri)
            "cpt:scheduled"^^rif:iri(?item ?scheduledate)
            External("fn:subtract-dateTimes-yielding-dayTimeDuration"^^rif:iri(?deliverydate ?scheduledate ?diffduration))
            External("fn:get-days-from-dayTimeDuration"^^rif:iri(?diffduration ?diffdays))
            External("op:numeric-greater-than"^^rif:iri(?diffdays "10"^^xsd:integer)))
)

Abridged syntax:

Forall ?item ?deliverydate ?scheduledate ?diffduration ?diffdays (
    <cpt:reject>(<ppl:John> ?item) :-
        And(<cpt:perishable>(?item)
            <cpt:delivered>(?item ?deliverydate <ppl:John>)
            <cpt:scheduled>(?item ?scheduledate)
            External(<fn:subtract-dateTimes-yielding-dayTimeDuration>(?deliverydate ?scheduledate ?diffduration))
            External(<fn:get-days-from-dayTimeDuration>(?diffduration ?diffdays))
            External(<op:numeric-greater-than>(?diffdays 10)))
)


Jane replies with some suggested rule changes:

If an item is  needed. ECA 5.4 Actions Different kinds of actions are needed, such as updates to data, sending events, procedural attachments, etc. Types 6 Support for datatypesperishable and it is  needed; the kinds of datatypes depend ondelivered to John more than 7 days after the  considered application. Dialect Identificationscheduled delivery date
but less than 14 days after the  dialect specificationscheduled delivery date
then a discount of  the interchanged rules together with information on the compatibility between the (standard) RIF dialects used by the parties, which need to establish trust by interchanging rules, can18.7% will be  used in this setting for decidingapplied to  continuethe  negotiation or not. Incompatible (standard)delivered item.

Representation in RIF dialects do not support the negotiation of the parties involved. Merge Rule Sets Often, agent softwares need to adopt existing policies, such asBLD (Abridged) Presentation Syntax:

Forall ?item ?deliverydate ?scheduledate ?diffduration ?diffdays (
    <cpt:discount>(?item 18.7) :-
        And(<cpt:perishable>(?item)
            <cpt:delivered>(?item ?deliverydate <ppl:John>)
            <cpt:scheduled>(?item ?scheduledate)
            External(<fn:subtract-dateTimes-yielding-dayTimeDuration>(?deliverydate ?scheduledate ?diffduration))
            External(<fn:get-days-from-dayTimeDuration>(?diffduration ?diffdays))
            External(<op:numeric-greater-than>(?diffdays 7))
            External(<op:numeric-less-than>(?diffdays 14)))
)

John considers this and agrees with Jane. Both organizations utilize these rules regulating some application domain, which might be writtenin othertheir operational systems using disparate rule languages thanrepresentations internally to compute prices for this order and determine contract compliance.

Future requests for the one usedsupply of items by John's company are defined on their purchasing web site, as the agent. In such cases, these existing policies need to be merged with agent's own policies, i.e. there is a need for merging rule sets. Concrete examples given in Protune 2.3 Collaborative Policy Development for Dynamic Spectrum Access This use case demonstrates how theappropriate XML schema and a RIF leadsruleset (or rulesets). This allows Jane's company and its competitors to increased flexibility in matching the goals of end-users of a service/device,respond electronically with the goals of providers and regulators of such services/devices.XML cost sheets. Suppliers respond with multiple cost sheets with different variations on the RIF can do that because it enables deployment of third party systems that can generate various suitable interpretations and/or translations ofrules proposed by John's company, allowing John's company to review the sanctionedalternative rules governingwith their associated costs to determine whether they, as a service/device.business, would benefit by relaxing or adding new rules as proposed by suppliers.


4.2 Negotiating eCommerce Transactions Through Disclosure of Buyer and Seller Policies and Preferences

This use case concerns Dynamic Spectrum Access for wireless communication devices . Recent technological and regulatory trends are converging toward a more flexible architecture in which reconfigurable devices may operate legally in various regulatory and service environments.the ability of parties involved in formal transactions or procedures, e.g., credit card authorization of a devicepurchase, access of private medical records, etc., to absorbexpress and protect their interests within a policy-governed framework. The rules defininggoal is to formally encode the policiespreferences, priorities, responses, etc., of the parties in such a region, orway that the operational protocols required to dynamically access available spectrum, is contingent upon those rules being in a form that the deviceoverall policy can use, as well as their being tailored towork with devices inas intended while providing opportunity for automatic negotiation of terms when allowed by the same class having different capabilities.policy. Utilization of the RIF in this use-case we suppose a region adopts a policy that allows certain wireless devices to opportunisticallyuse frequency bands that are normally reserved for certain high-priority users. (The decision bycase would extend the European Union to allow "Dynamic Frequency Selection" (DFS) usescope of the 5 GHz frequency band by wireless systems,this technology, affording a band intermittently used by militaryhigher degree of interoperability, as well as enabling re-use and weather radar, is a recent example - See http://europa.eu.int/eur-lex/lex/LexUriServ/site/en/oj/2005/l_187/l_18720050719en00220024.pdf.) Supposesharing of preferences, etc., through interchange. The policy states: A wireless device can transmit on a 5 GHz band if no priority user is currently using that band. Representation in RIF BLD (Abridged) Presentation Syntax:detailed scenario below shows how does a device know that no priority user is currently using a band itthis would work.

Alice wants to use? The answer will depend on the specific capabilities of the device. One type ofbuy a device may answer this question by sensingat an online site called "eShop." Alice employs software called "Emptor" that functions as automated negotiating agent for buyers. eShop employs software called "Venditor" as automated negotiating agent for sellers.

Alice's and eShop's policies describe who they trust and for what purposes. The amount of energy itnegotiation is receivingbased on that band. That is, it might employthe rule: If no energypolicies, which are specified as rules, and credentials Emptor and Venditor have. These policies and credentials are disclosed (interchanged) so as to automatically establish trust with the goal of successfully completing the transaction.

Policies are themselves subject to access control. Thus, rule interchange is detectednecessarily done during negotiation and (in general) depends on a desired band then assume no other device is usingthe band. Representation in RIF BLD (Abridged) Presentation Syntax: Forall A second typecurrent level of device, may get information from a control channeltrust that lets it know whetherthe desired band is being used by a priority user. That is, itsystems have on each other. Since Emptor and Venditor might employ the rule: If no control signal indicatinguse ofdifferent rule languages and/or engines for evaluating (own and imported) rules, a desired band by(standard) rule interchange format (RIF) needs to be employed for enabling the rule interchange between the two systems.

When Alice clicks on a priority user is detected then assume"buy it" button at the band is available.eShop's Web site, Emptor takes over and sends a request to eShop's site. Venditor receives the request and sends parts of its policy (i.e. a set of rules) back to Emptor. Among other things, the policy states that:

A buyer must provide credit card information together with delivery information (address, postal code, city, and country).

Representation in RIF BLD (Abridged) Presentation Syntax:

 Forall So each type of device will need to employ different "interpretations" or "operational definitions" of the policy in question. Now assume that there are 10 manufacturers of these 2 different types of wireless devices. Suppose that each of these manufacturers usesallow(access(?Resource)) :-
   valid_payment_method(?C),
   valid_delivery_address(?D).

valid_payment_method(?C) :-
   credential(payment_card, ?C#<ex:CreditCard>).

valid_delivery_address(?D) :-
   declaration(delivery_address,?D[address->?A, postal_code->?P, city->?CI, country->?CO]).

Rules express compactly possible ways in which a distinct rule-based platformresource can be accessed; by exchanging them negotiations are shorter and privacy protection is improved. In designing its devices. Each manufacturer needs to write 2 interpretationsour example, Venditor reveals part of theits policy (for each of the two typesin form of device). That meansrules to enable Emptor to choose how to answer, i.e. to decide which credentials to disclose. Note, however, that 20 different versions of the policy must be written, tested and maintained. Enter the RIF. The 10 manufacturers form a consortium.this is a third-party group that is responsibledeliberately simplified example in which credentials' requests can be handled more directly.

For translating regional policiesdetermining whether Venditor's request for information is consistent with Alice's policy, Emptor takes its rules into the RIF. When it does so, however, it provides different versions correspondingaccount, which state for example:

Disclose Alice's credit card information only to online shops belonging to the  possible interpretations (operational definitions) of the policy. SoBetter Business Bureau.

Representation in this case, 2RIF versions ofBLD (Abridged) Presentation Syntax:

allow(release(credential(?C#<ex:CreditCard>))) :-
    credential(bbb, ?Cred[issuer->"Better Business Bureau"]).

By disclosing (interchanging) the DFS policy are provided forabove given rule, Emptor asks Venditor to provide credentials saying that it belongs to the 2 types of device mentioned above. EachBetter Business Bureau, Alice's most trusted source of these RIF specifications can be automatically translated into the appropriate rule-platform providedinformation on online shops. eShop has such a RIF-Compiler for the target device architecture exists. Clearlycredential and its policy contains a rule stating to release it will be into any potential purchaser. Hence, Venditor passes the interest of each device manufacturercredential to develop such compilers. ThatEmptor. Emptor is because the manufacturer only needsnow ready to develop such a compiler once for every architecturedisclose Alice's credit card information to Venditor but it owns. Contrast that investment with havingstill must check whether disclosing all the information does not break Alice's denial constraints. Alice has stated two constraints stating:

Never disclose two different credit cards to  produce, test,the same online shop.

For anonymity reasons, never provide both her birth date and  maintainpostal code.

Representation in RIF BLD (Abridged) Presentation Syntax:

:- allow(release(credential(?C1#<ex:CreditCard>))), 
allow(release(credential(C2#<ex:CreditCard>))), 
?C1 != ?C2.

Different versionschoices exist for implementing the above constraints as rules; choosing the type of variousrules for implementing policies overdepends also on the lifetimecapabilities of a product. This arrangement also allowsthe overall processEmptor system.

For this purchase, anonymity is no issue and only information on one credit card is requested. Thus, Alice's constraints are respected. Emptor therefore provides Alice's credit card information to be organized in a fashionVenditor. Venditor checks that maintainsAlice is not on eShop's blacklist, then confirms the natural divisionpurchase transaction.

Companies that provide software such as Venditor and Emptor would make use of labor inthe corresponding divisionRIF in a number of artifacts produced by that labor:ways. The policy and its various interpretations are written and maintained in platform-independent artifacts (the RIF); knowledge about howrules expressing Alice's and/or eShop's policies could be expressed in different rule languages but still work with the software, using RIF-based interchanges. Secondly, assuming Venditor and Emptor are products of different companies using different internal rule languages, it would still be possible for them to translate fromwork together in real-time. When these two systems need to exchange policy or preference information of their respective clients they would use the RIF to a particular device architecture is maintainedenable the interchange in real-time. When Venditor sends its initial policy information to Emptor it uses the compilers. A changeRIF. Emptor takes that policy and translates it from the RIF to its internal representation in order to determine what it needs to do.


4.3 Collaborative Policy is inserted atDevelopment for Dynamic Spectrum Access

This use case demonstrates how the top levelRIF leads to increased flexibility in matching the policy artifact hierarchy wheregoals of end-users of a service/device, with the goals of providers and regulators of such services/devices. The RIF can do that because it should be; possible operational interpretationsenables deployment of third party systems that change are inserted at the next level down;can generate various suitable interpretations and/or translations of the implementation implicationssanctioned rules governing a service/device.

This use case concerns Dynamic Spectrum Access for thewireless communication devices. Recent technological and regulatory trends are converging toward a more flexible architecture in which reconfigurable devices may operate legally in various regulatory and service environments. The ability of a device architectures is generated automatically atto absorb the lowest level. Motivates: Default Behaviorrules defining the regulatorypolicies specify certain constraints, e.g., "if radar is sensed onof a channelregion, or the operational protocols required to dynamically access available spectrum, is contingent upon those rules being in use,a form that the channel must be evacuated within 10 seconds," whichdevice can be vieweduse, as a default for a devicewell as their being tailored to bework with devices in compliance. However, the RIF-based specifications promulgated by the consortium will not simply statethe constraint, but rather containsame class having different capabilities.

In this use-case we suppose a set of implementable rules that make it possible forregion adopts a suitably configured devicepolicy that allows certain wireless devices to meet this constraint.opportunistically use frequency bands that are normally reserved for some configurations and device types these rules may go beyond simply ceasing transmission oncertain high-priority users. (The decision by the channel, e.g.,European Union to allow "Dynamic Frequency Selection" (DFS) use of the device might send5 GHz frequency band by wireless systems, a control message toband intermittently used by military and weather radar, is a recent example - See http://europa.eu.int/eur-lex/lex/LexUriServ/site/en/oj/2005/l_187/l_18720050719en00220024.pdf.)

Suppose the policy states:

A  masterwireless device  (an access point) askingcan transmit on a 5 GHz band if  an alternate channelno priority user is  available, etc. As long as these additional steps do not prevent devices from vacating the channel within 10 seconds (and do not violate any other constraints) they are allowed. So,currently using that band.

Representation in RIF BLD (Abridged) Presentation Syntax:


How does a device know that no priority user is currently using a band it would be worthwhilewants to allowuse? The RIF-based specifications to "point" to a RIF-based versionanswer will depend on the specific capabilities of the general 10-second constraint as a default behavior ifdevice. One type of device may answer this question by sensing the more detailed rules cannot be applied. Different semantics Depending upon the needs of an application, there are a numberamount of waysenergy it is receiving on that band. That is, it might employ the rule:

If no energy is detected on a  formaldesired band then assume no other device is using the band.

Representation of a policy can be achieved.in RIF BLD (Abridged) Presentation Syntax:

Forall 

A devicesecond type of device, may need to reason about whatget information from a policy requires andcontrol channel that lets it may also need to allow its behavior to be guided by the policy. Inknow whether the former case, deductive logic can bedesired band is being used to formulate statements and draw valid inferences as to what the policy entails. For example, relative to the 10 second channel evacuation requirement mentioned above, it turns out that ifby a device (or its associated master) checks for radar every 9 seconds then there will be enough time to evacuatepriority user. That is, it might employ the channelrule:

If  needed. So a RIF-based specification might containno control signal indicating use of a  declarative rule that states "ifdesired band by a  channelpriority user is  in use, and it's last radar check was 9 seconds ago,detected then  a radar check on that channel is due." The important thing to note here is thatassume the  ruleband is  a statement (capableavailable.

Representation in RIF BLD (Abridged) Presentation Syntax:

Forall 

So each type of being truedevice will need to employ different "interpretations" or false)"operational definitions" of whatthe implementation requires.policy in order to utilize such statements to guide the behaviorquestion.

Now assume that there are 10 manufacturers of these 2 different types of wireless devices. Suppose that each of these manufacturers uses a device, connections must be forged between conclusions reached and actions to be taken. Production rules, specifically, ECA rules can be useddistinct rule-based platform in designing its devices. Each manufacturer needs to establish those connections. For example, "if it has been concludedwrite 2 interpretations of the policy (for each of the two types of device). That a radar check for a channel is due, then do <action>!" Since this use case envisions devicesmeans that are both capable20 different versions of reasoning aboutthe policy requirements and being guided by them, we expect that these RIF-based specifications will require rules having both declarativemust be written, tested and imperative semantics. Limited Number of Dialects Asmaintained.

Enter the use case states, RIF-based specifications are beneficial because they allowRIF. The 10 manufacturers form a consortium. This is a third-party group of interested parties (the consortium) to write machine-usable specificationsthat can be deployedis responsible for translating regional policies into the RIF. When it does so, however, it provides different versions corresponding to a wide varietythe possible interpretations (operational definitions) of devicesthe policy. So in this case, 2 RIF versions of the DFS policy are provided for the 2 types of device manufacturer, or other party, writesmentioned above. Each of these RIF specifications can be automatically translated into the appropriate rule-platform provided a "RIF-compiler," i.e., translator,RIF-Compiler for the giventarget device platform. If RIF-based specifications were themselves allowed to take on many different forms in a non-cohesive fashion, and specifications using them were generated,architecture exists. Clearly it is possible that this benefit wouldwill be compromised.in other words, athe interest of each device manufacturer or third party might find it necessaryto invest too much time in maintaining translators to make use of the RIF worthwhile. OWL data The rules in these applications will utilize conceptsdevelop such compilers. That are defined in accordance withis because the definitions devised by standard organizations. The use of OWL ontologies is likelymanufacturer only needs to develop such a compiler once for that task. Moreoverevery architecture it is possibleowns. Contrast that future protocol message payloads might contain OWL data. Coverageinvestment with having to produce, test, and maintain different versions of various policies over the rules require support for negation.lifetime of a product.

This arrangement also allows the rules reactoverall process to changesbe organized in a fashion that maintains the environment. Features from production rulesnatural division of labor in the corresponding division of artifacts produced by that labor: the policy and ECA rules such as forward chaining, events,its various interpretations are written and actions will be useful. 2.4maintained in platform-independent artifacts (the RIF); knowledge about how to translate from the RIF to a particular device architecture is maintained in the compilers. A change in policy is inserted at the top level in the policy artifact hierarchy where it should be; possible operational interpretations of that change are inserted at the next level down; the implementation implications for the various device architectures is generated automatically at the lowest level.

4.4 Access to Business Rules of Supply Chain Partners

A business process (BP) designer designs processes that can span multiple departments in the same business as well as other business partners. A classic example of this is the integration of supply chain business processes which typically involve multiple partners. Supply chain integration involves exposing a certain amount of business logic between partners as well as integrating processes across partners. In such activities it is therefore often necessary to access or invoke rules that originate in other ownership domains.

A key part of a business process is the logic used to make decisions within the process. Such logic is often coded in rules because rule languages are easier for BP designers to understand and manipulate than procedural code (as in Java) -- although both forms of business logic are prevalent. Where business logic is represented in different rule languages this presents a significant burden to the BP designer in designing an integrated process.

Two primary integration modalities are possible: importing the different rulesets into a single engine and processing them in a uniform manner, or accessing the rulesets by querying remote engines and processing the results. Each modality has its uses and contra-indications. Where there are strong ownership boundaries involved it may not be permitted to merge rule sets of partners.

For example, in an insurance adjustment process, the inspection of a damaged vehicle is often performed by independent inspectors. The critical decision in how an insurance claim will proceed is whether the damage results in a total loss or whether a repair is feasible:

If inspector believes vehicle is repairable then process as repair otherwise process as total loss.

Representation in RIF BLD (Abridged) Presentation Syntax:

repair(?Vehicle) :-
   believes("inspector",?Vehicle, "repairable").
loss(?Vehicle):-
   believes("inspector",?Vehicle, "notRepairable").

The question of whether a vehicle is repairable is one that is dependent on the processes executed by the inspector and cannot be directly integrated into the insurance companies own adjustment process. The insurance company effectively queries the inspector's logic. Within the adjustment process, the overall flow will be quite different for repairable claims and total loss claims.

Even in the case of a single company, which is nominally under a common ownership domain, information and business logic is often controlled by multiple stakeholders. For example, a large company will often be organized into semi-independent profit centers (business units). Each unit will be motivated differently, will have different ontologies and business logic and may use different rule languages to represent their logic (this is particularly the case where one company acquires another company).

The RIF should be used to permit the BP designer a unified view of the different partners' business rules in designing the process, while at the same time permitting the partners to continue to leverage their own business rules without changing their own technologies.

How such a unifed view of the business rules can be realized in a deployed BP will depend on both technical and non-technical factors. Even where all the parties are required to use a common rule language, there may be compelling ownership issues that mitigate against a simple merge of the rule sets. In the situation where merging of rulesets is not possible, then a query-style access to partners' business rules may be used. In this way, the RIF permits a unified dynamic view of the business rule logic no matter what the original form of the rules.

For this to be viable from a business perspective it is critical that the semantics of the rules and query exchange be completely predictable and preferably loss-less.

Motivates Default behavior The4.5 Managing Inter-Organizational Business Policies and Practices

This use case concerns organizations that acquire rule systems employed by the supply chain partners mightsets from external sources and that have different capabilities. Thus, situationsto integrate these new rule sets into their existing rule bases. Such rule sets may occur where interchanged process rules cannotbe (safely) executed.acquired in such cases, a default to revert to manual processing, or rejection ofthe process definition,following ways:

  • An organization may be required. Different semantics Business logic implemented in Business Processes (eg in BPM environments)buy rule sets from expert sources
  • An organization may be expected to be used in different semantic environments. An exampleuse rule sets from shared interest groups such as trade associations
  • A component of this would be simple interchangeable business logic thata distributed organization may acaquire rules when a rule set is executeddistributed across a distributed organization. In BPM environment #1 using an inference rule engine,such case, there may be different localization requirements in different regions and passed tolocations, entailing a BPM environment #2 using an "script" (rule) engine (without inferencing). In this case if inferencing rules are detectedvariety of integration challenges in the supply chain process being interchanged,these various locations and component organizations.

The receiver only has scripted engine support, thenfollowing scenario examines these different methods of acquisition and the default behavior may be invoked. Embedded Comments Additional informationvarious types of integration and management issues that may be required by supply chain partners if their default behavior is to NOT automate the rule execution, whereasarise.

This scenario uses the originator's rules were automated. Embedded Metadata Metadata that is appropriate to(fictitious) car rental company, EU-Rent, used as the supply chain interchange of rules may include applicability ofcase study in the ruleset(s) (aka preconditions), compliance regulations affected, cost per use, etc. ImplementationSemantics of supply chain policiesBusiness Vocabulary and practices asBusiness Rules Specification. The EU legislation discussed is considered "well established". Implementability of supply chain partner rulesalso fictitious, as (for example) production rules will support this motivation. Limited Number of Dialects Minimizing the number of RIF dialects (aka rule semantics supported) will maximizeare the applicabilityconsulting companies CarWise and usability of rulesAutoLaw.

EU-Rent's corporate HQ deals with CarWise, a consulting company with expertise in supply chain scenarios. OWL Data For those industries that utilize OWL (eg pharma, healthcare, academia), the representation of supply chain data in OWL and their subsequent references in supply chain intra-business rulesets will be required. RDF Data For those industries that utilize RDF (eg content management, academia), the representation of supply chain data in RDF and their subsequent references in supply chain intra-business rulesets will be required. XML Types , XML Syntax Much supply chain information (data) is transported as XML, which is replacing EDI. Therefore support for XML is critical for the supply chain use case. 2.5 Managing Inter-Organizational Business Policies and Practices This use case concerns organizations that acquire rule sets from external sources and that have to integrate these new rule sets into their existing rule bases. Such rule sets may be acquired in the following ways: An organization may buy rule sets from expert sources An organization may use rule sets from shared interest groups such as trade associations A component of a distributed organization may acaquire rules when a rule set is distributed across a distributed organization. In such case, there may be different localization requirements in different regions and locations, entailing a variety of integration challenges in these various locations and component organizations. The following scenario examines these different methods of acquisition and the various types of integration and management issues that may arise. This scenario uses the (fictitious) car rental company, EU-Rent, used as the case study in the Semantics of Business Vocabulary and Business Rules Specification . The EU legislation discussed is also fictitious, as are the consulting companies CarWise and AutoLaw . EU-Rent's corporate HQ deals with CarWise , a consulting company with expertise in managing fleetsmanaging fleets of vehicles. One service CarWise offers to its clients is negotiating with EU regulators to clarify regulations.

An EU regulator issues a directive dealing with insurance for vehicles owned by corporations. CarWise agrees with the regulator on an acceptable interpretation, and provides EU-Rent (and its other car rental clients) with two sets of rules:

A business policy, stating that every car rental must be insured for damages to third parties.
A supporting rule set, addressing levels of required coverage, tax calculation in different EU countries, liabilities in rentals 
that span multiple countries, and reporting of compliance with this business policy.

Representation in RIF BLD (Abridged) Presentation Syntax:

Forall 

EU-Rent decides that it will maintain its compliance documentation electronically. CarWise then provides EU-Rent with an additional rule set for electronic compliance documentation, including such rules as:

Each tax schedule must have electronic signatures from two EU-Rent employees who are at least at the level of manager.

Representation in RIF BLD (Abridged) Presentation Syntax:

Forall 

Before it can use the two general rule sets, EU-Rent needs to connect them to the relevant data sets in its IT systems, e.g. relate the EU country-specific taxation rules to the relevant record types in its databases.

EU-Rent corporate HQ subsequently decides that the cost of third-party insurance will be built into the basic cost of each rental, and not shown as a separate item on the rental contract, to ensure that it can never be omitted from rentals or disputed by renters. It then sends three rule sets to its operating companies in the EU:

The rule set for car rental insurance (from CarWise), including the basic policy and the supporting rule set
The rule set for electronic compliance documentation (also from CarWise)
Its own rule set for building insurance into the basic rental cost.

Representation in RIF BLD (Abridged) Presentation Syntax:

Forall 

The operating companies then have to localize the rule sets for their countries of operation. For example, in the UK, another consulting company, AutoLaw, advises EU-Rent of rules for placing aggregate insurance for large fleets with more than one insurer in order to spread the risk, for example:

For fleets of more than 200 vehicles, fleet insurance policies must be placed with at least 3 insurers, each of whom covers at 
least 25% of the risk.

Representation in RIF BLD (Abridged) Presentation Syntax:

Forall 

A timing issue makes it difficult for EU-Rent UK to strictly comply with this directive. EU-Rent UK has some existing insurance policies in place, which provide third-party insurance as an explicit item, and it cannot get refunds on early termination. It therefore asks corporate HQ for a temporary dispensation: that it can continue its existing insurance until it expires, and then switch to the new rules.

EU-Rent HQ permits this, not just for the UK, but for any of its operating companies that have similar insurance arrangements. To ensure that this dispensation is temporary, it adds a new rule:

Insurance policies that provide separate third-party coverage must not be renewed.

Representation in RIF BLD (Abridged) Presentation Syntax:

Forall 

EU-Rent HQ is also concerned about meeting deadlines for electronic filing. It introduces a new rule that it distributes to operating companies:

Each electronic compliance document must have its required electronic signatures 48 hours before its filing deadline.

Representation in RIF BLD (Abridged) Presentation Syntax:

Forall 

This rule is meant to be implemented as follows: If '48 hours before filing deadline' passes, and the electronic signatures are not present, then the operating company's rules system must report the out-of-compliance situation, and subsequently wait for the responsible managers to provide the signatures.

Implication for Requirements

Many of the rules and rule sets interchanged via the RIF will be directly executable. Some will need human intervention, which is likely to be of two kinds. First, rule sets (especially general rule sets from external sources) may need to be localized before being used or further distributed within an organization, e.g.

  • Connected to relevant data sets
  • Irrelevant rules excluded
  • Local rules added

Second, during execution, some rules may need an input from a person, such as a decision or some data.

Motivates: Embedded metadata Metadata, applicable to both rules and rule sets, will be needed for: "€œnot immediately processable" indicators "from" and "to" effective dates Embedded comments Comments will be needed for guidance on what intervention is needed before rules can be executed automatically (or should this be considered as metadata?). Different semantics Rule sets acquired from third parties may be presented in rule languages with different semantics. OWL data Part of user intervention may be to indicate which knowledge base(s) need to be referenced for localization of reusable rule sets. Default behavior Requires default behavior: not to try to execute marked rules or rule sets; to inform RIF Client owner that marked rules and rule sets cannot be automatically processed without some intervention beforehand. Merge rule sets This is a central requirement of this use case (although it's possible it could be done in tools outside the RIF). Identification of rule sets This is important for replacement of acquired rulesets with updated versions or alternative rulesets. XML syntax Required for compatibility with developments taking place in parallel with RIF (e.g. in OMG, OASIS, XBRL). 2.64.6 Ruleset Integration for Medical Decision Support

Decision support systems aid in the process of human decision making, especially decision making that relies on expertise. Reasoning with rules is an important part of this expert decision making. For complex decision support systems, it is expected that rules will be furnished by a variety of different sources, including ontologies, knowledge bases, and other expert systems. This use case illustrates how the RIF makes it possible to merge rulesets from diverse sources in diverse formats into one rule-based system, thereby enabling inferences that might otherwise have remained implicit.

Medical decision support systems, such as the ones discussed below, might use rules from pharmaceutical knowledge bases, laboratory knowledge bases, patient databases, and medical ontologies. For example, a large amount of information on therapeutic medications (drug taxonomies, indications, contraindications, and clearance times) and diseases (disease taxonomies, etiologies, and symptoms) is contained in existing ontologies such as SNOMED Clinical Terms®. Rules can be used to express therapeutic recommendations, to formulate queries about relevant prescriptions for a patient, and to assess the effectiveness of a treatment.

The following scenario illustrates how rule-interchange would be used in various medical decision support systems to support the following functionalities:

  • Improving situation assessment, e.g., determining when a patient needs to be put on medication, or have his medication switched.
  • Prescribing a course of action, e.g., determining which drug is best for a patient in a particular circumstance.
  • Improving event planning, e.g., determining whether a patient can be scheduled for a procedure given the medication that he is currently taking.

Bob, 62 years old and reasonably healthy, has been going to his internist, Dr. Rosen, for several years for control of his Type II diabetes. Dr. Rosen has been using the AutoDoc system to help him decide when to switch to medications and which drugs to prescribe. The AutoDoc system uses two sources when making its recommendations: a laboratory knowledge base giving particular results for patients and specifying when these results are out of normal range, and a pharmaceutical knowledge base giving guidelines for the use of medications. Automated reasoning with rules from these combined sources is possible if the rules are first mapped to the RIF. Here are two specific examples of such synergistic effects.

This scenario discusses the fictitious expert systems AutoDoc and MEDIC. In the interest of readability and brevity, the information and rules presented in the following scenario may not precisely capture the current state of medical knowledge and best practices in this field, but may be somewhat simplified.

Originally Bob's diabetes was controlled through diet and moderate exercise. In time, however, Bob's blood glucose level began to rise, even under this regimen. Due to Bob's elevated HbA1c level (which indicates one's average blood sugar level over the last several months), Dr. Rosen prescribed oral medication for Bob. He was forced to change Bob's medication a number of times over the course of a year. He first prescribed Precose, an oral alpha-glucosidase inhibitor, but had to discontinue this medication due to undesired side effects. He then prescribed several sulfonylurea drugs, Micronase and Glucotrol, to no avail. Bob's lab results still indicated an elevated HbA1c level. The following rule from the laboratory knowledge base suggests that Bob's treatment at that time was not effective:

If a Type II diabetes patient's current level of HbA1c is high, then the patient's current treatment
is considered to be ineffective.

Representation in RIF BLD (Abridged) Presentation Syntax:

holds(ineffective(?P,?X, "diabetesTypeII"),?T) :- 
  holds(hasDisease(?X, diabetesTypeII),?T),
  holds(elevated(levelOf("hbA1c",?X)), ?T),
  holds(treatmentPlan(?X, ?P), ?T).
holds(elevated(levelOf(?L,?X)),?T) :- 
  normalRange(?L,?J,?K),
  holds(?T, levelOf(?L,?X) = ?Z),
  ?Z > ?K.

To deal with this problem, Dr. Rosen was about to prescribe Glucophage (metformin, one of the biguanides) 850 mg, 3 times a day, when as usual, he double checked his prescription with the AutoDoc system. The system, based on the following guidelines from the pharmaceutical knowledge base, informed Dr. Rosen that he should have prescribed an oral bitherapy (two medications, each of which controls blood sugar levels) instead of a monotherapy.

If an oral monotherapy at recommended doses of a sulfonylurea or biguanide, combined with lifestyle changes,
is ineffective, then the monotherapy should be replaced by an oral bitherapy.

Representation in RIF BLD (Abridged) Presentation Syntax:

Forall 

Based on the recommendation from AutoDoc, Dr. Rosen switched Bob's prescription to Glucophage and Avandia (rosiglitazone, one of the thiazolidinediones).

Bob recently suffered a concussion and has become increasingly forgetful. He went to see a neurologist, Dr. Cervello, who prescribed a contrast MRI (Magnetic Resonance Imaging). When asked about current medication, Bob told Dr. Cervello that he was taking Glucotrol to control his diabetes, forgetting that he had been switched to Glucophage. This was potentially problematic, since Glucophage should not be taken close to the administration of a contrast injection.

Fortunately, when Bob went to the lab to schedule his MRI, the medical receptionist pulled up MEDIC (Medical Event and Drug Interaction Consultant), the hospital's new automated system, which checks for incompatible medical events and/or drugs (e.g., liposuction scheduled during pregnancy, blood thinners prescribed before surgery, etc.).

MEDIC uses a variety of sources in its reasoning, including:

  • the pharmaceutical knowledge base, described above
  • the patient databases, which gives the patient record, including the medications a patient is currently taking
  • the hospital medical event protocol knowledge base, which details the protocol used for different medical procedures

In this case, MEDIC uses all three sources, and pulls up the following information:

  • Metformin is contraindicated with contrast dye.
  • Metformin is the generic form of Glucophage.
  • Bob is taking Glucophage.
  • The contrast MRI requires as one of its steps injecting the patient with contrast dye.

MEDIC therefore determines that Bob should not be taking the contrast MRI at this time.

For MEDIC to work, the rules from these different sources must be mapped to a unified interchange format.

Motivates: Embedded comments Note that this requirement isn't entirely clear. The requirement reads "RIF must be able to pass comments." Are these comments about the rules themselves, or explanations for the rules (which might be used, say, by a human user to explain policy to a consumer), or advice about how4.7 Interchanging Rule Extensions to handleOWL

Rules which conflict? Suppose it is the second. Let us assume also that thereare comments/explanations for the rules from the pharmaceutical knowledge basedoften used by MEDIC. Then therein conjunction with other declarative knowledge representation formalisms, such as ontology languages (e.g. RDF and OWL), in order to provide greater expressive power than is provided by either formalism alone. Ontology languages, for example, typically provide a link between this requirement and UCR Case 6. One would want the comments from the pharmaceutical KB passedricher language for describing classes (unary predicates). Rules, on to MEDIC. Embedded metadata Suppose MEDIC hasthe following method for dealing with contradictions: If a rule set is inconsistent, it attempts to find a maximally consistent subset (MCS) of the rule set. Since there will always be muliple MCS. it needs to find a way, based on some preference criteria, to calculate a preferred MCS, or to choose among multiple MCS's. One preference criterion could be assigning a low priority to rules from the medical event data base, which could lead to the event being rescheduled. Another preference criterion could assign a low priority to the rules from the patient data base, which might lead to a patient's medications being temporarily changed. In order to implement this preference criterion, MEDIC needs to know the source/author of each rule. OWL data Suppose at least one of the knowledge bases or data bases above is written in OWL. A likely candidate would be the pharmaceutical knowledge base, due to the highly taxonomic structure of such knowledge bases. Then clearly the RIF will need to be able to cover OWL knowledge bases. RDF data Again, assume one of the data bases above contains RDF data. Then clearly, the RIF will need to be able to cover RDF data. Coverage This needs more analysis and more detailed specification of the types of rules that will be used. 2.7 Interchanging Rule Extensions to OWL Rules are often used in conjunction with other declarative knowledge representation formalisms, such as ontology languages (e.g. RDF and OWL), in order to provide greater expressive power than is provided by either formalism alone. Ontology languages, for example, typically provide a richer language for describing classes (unary predicates). Rules, on the other hand, typically provideother hand, typically provide a richer language for describing dependencies between properties (binary predicates), and may also support higher-arity predicates.

Rich domain models combining both rules and ontologies are often needed in domains such as medicine, biology, e-Science and Web services. In such domains, several actors and/or agents are involved that have to interchange the data, ontologies, and rules that they work with. An example is the use of such a domain model in an application that aims at assisting the labelling of brain cortex structures in MRI images. In this case, an OWL ontology is used to capture knowledge about the most important brain cortex anatomical structures, and a rule base is used to capture knowledge about mereological and spatial dependencies between properties.

For example, a rule is used to express the dependency between the ontology properties isMAEConnectedTo and isMAEBoundedBy, in particular (a simplified form of) the knowledge that two Material Anatomical Entities having a shared boundary are connected:

If MAE X is bounded by Z and MAE Y is also bounded by Z then X is connected to Y.

Representation in RIF BLD (Abridged) Presentation Syntax:

?X#<ex:MAE> [ <ex:isConnectedTo> -> ?Y#<ex:MAE>] :-
   ?X#<ex:MAE> [ <ex:isMAEBoundedBy> -> ?Z#<ex:MAE>], 
   ?Y#<ex:MAE> [ <ex:isMAEBoundedBy> -> ?Z#<ex:MAE>].

Benefits of interchange via RIF include the ability to collaboratively develop and share valuable knowledge, the ability to integrate anatomical images, possibly from distributed image sources, and the ability to use large-scale federated systems for statistical analysis of brain images of major brain pathologies.

Motivates: Coverage , especially Syn5: slotted arguments are a good fit for RDF/OWL properties Syn6: webized names Ses1: hybrid rules so OWL predicates can be used in rules Limited number of dialects because OWL has a limited number of dialects OWL data because this extends OWL RDF data because this extends OWL and OWL supports RDF data XML syntax because this extends OWL and OWL has an XML syntax XML types because this extends OWL and OWL supports XML types 2.8 Vocabulary Mapping4.8 Vocabulary Mapping for Data Integration

This use case concerns the integration of information from multiple data sources. The Semantic Web provides a common data representation and query language, which greatly simplifies access to diverse sources but does not directly address the problem that independent data sources may have rather divergent information models.

Rules are an effective way to express mappings between such information models. However, rules locked within local proprietary systems cannot be reused. With a common rule representation, such mappings can be published across the Semantic Web, enabling an enterprise or community to progressively build up a rich network of mappings unifying the information models.

Information mapping and integration problems like this arise in many diverse domains including health care, travel planning, IT management and customer information management. The following scenario comes from the world of IT systems management.

Vlad has been given the job of analyzing how exposed his division's business processes are to changes in their IT maintenance contracts. He has three sources of information to combine:

  • a report on application services and associated servers, databases and networks (from the IT department)
  • a maintenance contracts database (from the finance department)
  • a registry indicating which business processes use which IT services (from the business planning group)

Each of these sources is in a different form but can be mapped into RDF to simplify access. However, they all have different information models. The IT report is too fine-grained: it talks about routers and interface cards whereas Vlad only needs to identify servers and pick out some generic dependency relations. On the other hand, the finance database models the world in terms of physical assets such as racks, which is too coarse-grained.

First, Vlad creates simple mapping rules to create a uniform, simplified view of the data in terms of a small number of concepts -- Server, BusinessProcess and Dependency. This involves rules such as:

If x is a ComputeNode in Rack r
   and Rack r is in Cage c
   and mc is a MaintenanceContract for Cage c
      then x is a Server with MaintenanceContract mc

If x is a ComputeNode with a NetworkInterface with Port p
   and app is an Application running on Port p
      then x is a Server that hosts app

If bp is a BusinessProcess that uses Application app
      then bp has a Dependency on app

Representation in RIF BLD (Abridged) Presentation Syntax:

contract(?X#<ex:Server>,?MC#<ex:MaintenanceContract>):-
   in(?X#<ex:ComputeNode>,?R#<ex:Rack>),
   in(?R#<ex:Rack>,?c#<ex:Cage>),
   contract(?C#<ex:Cage>, ?MC#<ex:MaintenanceContract>).

hosts(?X#<ex:Server>,?App#<ex:Application>) :-
    has(?X#<ex:ComputeNode>, ?NI#<ex:NetworkInterface>),
    has(?NI#<ex:NetworkInterface>, ?P#<ex:Port>),
    running(?App#<ex:Application>,?P#<ex:Port>).

dependency(?BP#<ex:BusinessProcess>, ?App#<ex:Application>) :-
    uses(?BP#<ex:BusinessProcess>, ?App#<ex:Application>).

He then creates rules that combine the data across his now simplified data sources, e.g.

If bp is a BusinessProcess that has a Dependency on Application app
   and x is a Server with MaintenanceContract mc that hosts Application app
      then bp has a Dependency on mc

Representation in RIF BLD (Abridged) Presentation Syntax:

dependency(?BP#<ex:BusinessProcess>,?MC#<ex:MaintenanceContract>) :-
    dependency(?BP#<ex:BusinessProcess>,?App#<ex:Application>),
    contract(X#<ex:Server>, ?MC#<ex:MaintenanceContract>),
    hosts(?X#<ex:Server>, ?App#<ex:Application>).

This gives him a uniform view that links from business processes through to the IT and finance data. Vlad publishes these rules so that other people across the company can reuse them to construct similar views.


Motivates: Embedded comments , Comments might be helpful when integrating diverse sources Coverage Syn5: slotted arguments are a good fit for RDF/OWL properties Limited number of dialects the value of RIF in this use case (reusability of the rules across the enterprise) is only realised if there is a good chance that the dialect Vlad uses is supported widely by the tools other users might have access to RDF data , Sources can be mapped into RDF 2.94.9 BPEL Orchestration of Rule-Based Web Services

Rule-based Web services depend on the use of XML data for their request and response format. The involved rules must be able to access and compare XML data in their conditions and modify and generate XML data in their actions.

An existing commercial credit approval service deployed as a Web service takes an applicant credit request document as input and returns an approval or denial (with reason). It is implemented as a BPEL orchestration of two Web services -- a credit history providing service and a decision service containing a rules engine. BPEL first passes the credit request document to the decision service to determine, using rules, whether enough information (SSN, mother's maiden name, etc.) is available to request a credit history. If so, BPEL then requests a credit history from the history providing service and passes the credit history document to the decision service to be evaluated. Based on the evaluation, credit is approved or denied.

Because the rule engine is part of a Web service, existing BPEL diagramming and execution facilities can be used to integrate rules into this credit approval service. The credit evaluation model can be changed easily using GUI tools to customize rules. Use of RIF would improve the situation further. First, the credit history vendor could supply a default set of rules for evaluating its histories. Second, there would be several rule editing and customization tools from different RIF compatible vendors to tailor the rules to meet specific business objectives.

The credit evaluation rules are themselves grouped into three rulesets that are executed sequentially. Rules in the first ruleset apply thresholds to several "red flag" quantities in the credit report, such as:

  • number of times a payment was 60 days late
  • debt-to-income ratio
  • number of foreclosures or repossessions
  • number of garnishments
  • number of liens
  • bankruptcy

A red flag above the threshold results in denial of credit.

Rules in the second ruleset increment a credit score variable. For example:

If applicant owns residence then add 40.

If applicant rents then add 30.

If applicant has lived at current address 2 to 4 years then add 20.

If applicant's income is under 20000 then add 10.

If applicant's income is between 40000 and 50000 then add 40.

Representation in RIF BLD (Abridged) Presentation Syntax:

% A goal-driven solution with makes use of assert and retract to
% update a global score value, which is stored in a fact.

score(0).

score(?Applicant, ?Score):-
 increment(?Applicant)
 score(?Score),
 % now reset score to null
 retract(score(?Score)), 
 assert(score(0)).   

increment(?Applicant):-   
  owns(?Applicant),
  score(?Score),
  retract(score(?Score)),
  ?NewScore = External(op:numeric-add(?Score,40)),
  assert(score(?NewScore)).

increment(?Applicant):-   
  rents(?Applicant),
  score(?Score),
  retract(score(?Score)),
  ?NewScore = External(op:numeric-add(?Score,30)),
  assert(score(?NewScore)).

increment(?Applicant):-   
  lives(?Applicant, ?Date),
  sysTime(?CurrentDateTime),
  ?CurrentYear = External(fn:year-from-dateTime(?CurrentDateTime)),
  ?Year = External(fn:year-from-dateTime(?Date)),
  ?Diff = External(op:numeric-subtract(?CurrentYear,?Year)),
  External(op:numeric-more-than(?Diff,1)),
  External(op:numeric-less-than(?Diff,5)),
  score(?Score),
  retract(score(?Score)),
  ?NewScore = External(op:numeric-add(?Score,20)),
  assert(score(?NewScore)).

increment(?Applicant):-   
  income(?Applicant,?Income),
  External(op:numeric-less-than(?Income,20000)),
  score(?Score),
  retract(score(?Score)),
  ?NewScore = External(op:numeric-add(?Score,10)),
  assert(score(?NewScore)).

increment(?Applicant):-   
  income(?Applicant,?Income),
  External(op:numeric-less-than(?Income,50000)),
  External(op:numeric-more-than(?Income,50000)),
  score(?Score),
  retract(score(?Score)),
  ?NewScore = External(op:numeric-add(?Score,40)),
  assert(score(?NewScore)).


The third and final ruleset compares the applicant's credit score and income to threshold values, and makes the final decision to approve or deny credit to the applicant.

The decision and supporting rationale is returned from the decision service as an XML document. This decision document is then used to construct the reply to the original credit approval request.

Motivates: Coverage The scoring rules express actions and not logical conclusions. Therefore production rules are required. These additional RAF discriminants are also relevent: Syn 5: Slotted (Keyed, Role-Named) Arguments, since they directly correspond to attributes in Web service descriptions Syn 6: Webized Names, since URIs are fundamental to Web service descriptions SeS 9: Priority, since conflicts between credit evaluation rules can often be solved based on relative rule importance Sem 2: Decidable, since there must be a definitive answer for every credit request Sem 3: Finite-Model Rulebases, because of the reason given for Sem 2 Prag 2: Computational complexity should be tractable, since response time should be acceptable Prag 3: Interoperability Annotations should use Controlled English, since justifications/explanations of decisions should be understandable without formal training XML data Web services depend on XML request and response formats. XML types Rule variables must be bound to fields from the XML request and response formats. UC9 Worked Example 2.104.10 Publishing Rules for Interlinked Metadata

The Semantic Web includes technologies (e.g., RDF) that allow metadata to be published in machine-readable form. Currently, this information is mostly enumerated as a set of facts. It is often desirable, however, to supplement such facts with rules that capture implicit knowledge. To maximize the usefulness of such published rules, a standard rule format such as RIF is necessary.

One case involves extending current standards for metadata publication with rules in order to express implicit knowledge. Suppose that the International Movie Database (IMD) publishes its metadata and rules in a machine readable format at http://imd.example.org. Besides the ground facts, which can be expressed in RDF, the metadata might also have general rules like the following:

Every science fiction movie is a movie.

Every movie produced before 1930 is black and white.

Representation in RIF BLD (Abridged) Presentation Syntax:

?Movie # <ex:Movie> :-
   ?Movie # <ex:ScienceFictionMovie>.

?Movie # <ex:BlackWhiteMovie> :-
   ?Movie # <ex:Movie>[<ex:date> -> ?Date],
   External(op:dateTime-less-than(?Date,"1930"^^xsd:dateTime).

Such rules allow data to be published more concisely by expressing knowledge that, without these rules, is implicit. This can greatly simplify the maintenance of data, guard against inadvertently introduced inconsistencies, and reduce storage requirements.

Published rules also allow combining data from different sources to exploit this knowledge. Consider an alternative database of movies published at http://altmd.example.org. In addition to metadata, it again publishes its own rules:

All movies listed at http://altmd.example.org but not listed at http://imd.example.org are independent movies.

All movies with budgets below 5 million USD are low-budget movies.

Representation in RIF BLD (Abridged) Presentation Syntax:

?Movie # <ex:IndependentMovie> :-
   listed(?Movie # <ex:Movie>,<http://altmd.example.org>),
   not(listed(?Movie # <ex:Movie>,<http://imd.example.org>)).     

?Movie # <ex:LowBudgetMovie> :-
   ?Movie # <ex:Movie> [date -> ?Date, budget -> ?Budget],
   External(op:numeric-less-than(?Budget,5000000^^xsd:long).


Publication of rules with explicit references to other rulesets allows the definition of knowledge dependent on explicitly specified remote sources. Such explicitly specified scope is important in the Web environment, since it can reduce the danger of unintended interference from rules published at other remote sources, which may be exporting their own predicates.

Another example of such explicit referencing, which also illustrates implicit person-centric metadata, involves published rules being used to specify how to use other metadata, e.g. in the form of a widespread vocabulary such as FOAF or a standard exchange format like iCalendar. For example, FOAF user Charlie might choose to complement his normal FOAF profile with his preferences about which of his phone numbers should be used depending on his iCalendar schedule:

If Charlie is currently attending a public talk according to http://charlie.example.org/calender.ical
    then leave him a voicemail message

If Charlie is currently in a meeting according to http://charlie.example.org/calender.ical
  and the importance is high
    then call his cell number

If Charlie currently has no appointments according to http://charlie.example.org/calender.ical
    then call his office number

Representation in RIF BLD (Abridged) Presentation Syntax:

contactInfo("Charlie", ?ContactInfo) :- 
   sysTime(?Time),
   attending("Charlie","talk", ?Time),
   contact("Charlie", "voicemail", ?ContactInfo).

contactInfo("Charlie", ?ContactInfo) :- 
   sysTime(?Time),
   attending("Charlie","meeting", ?Time),
   contact("Charlie", "cell number", ?ContactInfo).

contactInfo("Charlie", ?ContactInfo) :- 
   sysTime(?Time),
   not(attending("Charlie",?Event, ?Time)),
   contact("Charlie", "office number", ?ContactInfo).


sysTime(?Time):-
   % get the actual system time e.g. via a built-in
   % or procedural attachment call to Java or C++.
   ?Time = External(call(java.util.Calendar().getInstance())).

    
attending("Charlie","talk", ?CurrentTime) :-
   % getEventData would implement the functionality to dynamically access and query
   % http://charlie.example.org/calender.ical
   getEventData(<http://charlie.example.org/calender.ical>,?EventTitle,?Type,?StartDate,?EndDate),
   ?Type = "talk",
   External(op:dateTime-less-than(?CurrentTime,?EndDate),
   External(op:dateTime-greater-than(?CurrentTime,?StartDate).
       

attending("Charlie","meeting", ?CurrentTime) :-
   getEventData(<http://charlie.example.org/calender.ical>,?EventTitle,?Type,?StartDate,?EndDate),
   ?Type = "meeting",
   External(op:dateTime-less-than(?CurrentTime,?EndDate),
   External(op:dateTime-greater-than(?CurrentTime,?StartDate).
      


contact("Charlie", "voicemail", ?ContactInfo):-
   % retrieve the Voice mail number, e.g. from
   % Charlie's vCard, 
   % e.g. xmlns:vCard = "http://www.w3.org/2001/vcard-rdf/3.0#
   <http://charlie.example.org/vCard>[<vCard:FN> -> "Charlie"],
   <http://charlie.example.org/vCard>[<vCard_TEL> -> ?Telephone],
   ?Telephone[<rdf:type> -> <http://www.w3.org/2001/vcard-rdf/3.0#voice>],
   ?Telephone[<rdf_value> -> ?ContactInfo].

contact("Charlie", "cell number", ?ContactInfo):-
   <http://charlie.example.org/vCard>[<vCard:FN> -> "Charlie"],
   <http://charlie.example.org/vCard>[<vCard_TEL> -> ?Telephone],
   ?Telephone[<rdf:type> -> <http://www.w3.org/2001/vcard-rdf/3.0#cell>],
   ?Telephone[<rdf_value> -> ?ContactInfo].

contact("Charlie", "office number", ?ContactInfo):-
   <http://charlie.example.org/vCard>[<vCard:FN> -> "Charlie"],
   <http://charlie.example.org/vCard>[<vCard_TEL> -> ?Telephone],
   ?Telephone[<rdf:type> -> <http://www.w3.org/2001/vcard-rdf/3.0#work>],
   ?Telephone[<rdf_value> -> ?ContactInfo]. 

RIF should allow extending current standards for metadata publication by enabling such implicit knowledge to be captured via rules and allowing metadata and rules distributed over different sources to be interlinked. In a manner similar to how HTML links human-readable Web pages, RIF should permit linking metadata on the Web to support new kinds of "intelligent" crawling and search. Motivates: Coverage The following discriminators in the Rule Arrangement Framework are particularly relevant for this use case: Syn 1.4 Explicit vs. Implicit Rule Scope Scoped inference and Scoped NAF are needed to model the rules in this use case Syn1.6 Webized Names: HTML and RDF use IRIs to link data and metadata on the web, and so rules which define implicit interlinked metadata. Syn1.7 Means to access data in Web formats: access of data in RDF, and other XML based data, respecting ontologies in OWL are essential for this use case. SeS2 .2 Fact-and-Rule Bases: This use case needs mixed fact and rule bases. SeS2 .8 Certain vs. Uncertain Clauses and Atoms: Default rules to specify default, implicitly defined metadata which may be overridden by more specific facts are an issue in this use case. Sem3.2 Finite-Model vs. Infinite-Model Rulebases: The models of RDF alone are infinite already by the infinite number of axiomatic triples. On the contrary finite models are desirable for the evaluation of the consequences of rule sets. RDF data ( OWL data ) The described rules shall take metadata in the form of RDF facts as a basis. As a possible extension additional inferences over OWL ontologies shall be taken into account, see also Semantic tagging below. Semantic tagging A layered approach such as taken in SPARQL (or allowing SPARQL queries in rule bodies) which decouples the adopted entailment regime (simple, RDF(S), OWL, etc. entaiment) from the semantics of such rules is possible, which requires semantic tagging of rulesets. 3 Goals A critical factors analysis (CFA) is an analysis of the key properties of a project (in this case the RIF). A CFA is analyzed in terms of the goals of the project, the critical factors that will lead to its success and the measurable requirements of the project implementation that support the goals of the project. Goals A goal is an overall target that you are trying to reach with the project. Typically, goals are hard to measure by themselves. Goals are often directed at the potential consumer of the product rather than the technology developer. Critical Success Factors A critical success factor (CSF) is a property, sub-goal that directly supports a goal and there is strong belief that without it the goal is unattainable. CSFs themselves are not necessarily measurable in themselves. Requirements A requirement is a specific measurable property that directly supports a CSF. The key here is measurability: it should be possible to unambiguously determine if a requirement has been met. While goals are typically directed at consumers of the specification, requirements are focused on technical aspects of the specification. CFA Diagram It can often be helpful to illustrate graphically the key concepts and relationships between them. Such diagrams can act as effective indices into the written descriptions of goals etc., but is not intended to replace the text. The legend: illustrates the key elements of the graphical notation. Goals are written in round ovals, critical success factors are written in round-ended rectangles and requirements are written using open-ended rectangles. The arrows show whether a CSF/goal/requirement is supported by another element or opposed by it. This highlights the potential for conflict in requirements. 3.1 Description of Goals The primary goal of the RIF is to be an effective means of exchanging rules that has the potential to be widely adopted in industry and that is consistent with existing W3C technologies and specifications. 3.1.1 Consistency with W3C specifications This is intended to be a W3C specification that builds on and develops the existing range of specifications that have been developed by the W3C. This implies that existing W3C technologies should fit well with the RIF. CSFs directly supporting this goal: Alignment with Key W3C Specifications 3.1.2 Exchange of Rules The primary goal of the RIF is to facilitate the exchange of rules. This mission is part of W3C's larger goal of enabling the sharing of information in forms suited to machine processing: Rules themselves represent a valuable form of information for which there is not yet a standard interchange format, although significant progress has been made within the RuleML Initiative and elsewhere. Rules provide a powerful business logic representation, as business rules, in many modern information systems. Rules are often the technology of choice for creating maintainable adapters between information systems. As part of the Semantic Web architecture, rules can extend or complement the OWL Web Ontology Language to more thoroughly cover a broader set of applications, with knowledge being encoded in OWL or rules or both. CSFs directly supporting this goal: Coverage , Extensibility , Predictability 3.1.3 Widescale Adoption It is an explicit goal of the W3C that the Rules Interchange Format will have the maximum potential for widescale adoption. Rules interchange becomes more effective the wider adoption there is of the specification -- the so-called "network effect". CSFs directly supporting this goal: Alignment with Key W3C Specifications , Coverage , Encouragement of Interoperability , Low Cost of Implementation , Predictability 3.2 Critical Success Factors 3.2.1 Alignment with Key W3C Specifications RIF should fit well with key existing W3C specifications such as XML. In particular, it should align well with the Semantic Web standards such as resource descriptions (RDF) and ontologies (OWL). Goals that are supported by this CSF: Consistency with W3C specifications , Widescale Adoption Requirements supporting this CSF: OWL data , RDF data , XML data , XML syntax , XML types 3.2.2 Coverage The RIF should cover the major classes of rule formalisms that are in widespread use. Goals that are supported by this CSF: Exchange of Rules , Widescale Adoption CSFs opposing this CSF: Low cost of implementation Requirements supporting this CSF: Embedded comments , Embedded metadata , OWL data , RDF data , Rule language coverage 3.2.3 Encouragement of Interoperability RIF will encourage interoperability, e.g., overlap between dialects and distinguished dialects with maximum overlap. Goals that are supported by this CSF: Widescale Adoption A compliance model supports interoperability in that a formal understanding of what it means to comply to the RIF is essential to the succesful use of RIF, and hence to interoperability. The alternative to a formal compliance model is an informal one: i.e., that defined by what popular tools support. Requirements supporting this CSF: Limited number of dialects , Compliance model 3.2.4 Extensibility Given that rule languages are expected to continue to evolve, it is important that the RIF is able to incorporate rule languages not currently envisaged. Goals that are supported by this CSF: Exchange of Rules CSFs opposing this CSF: Low cost of implementation Requirements supporting this CSF: Default behavior 3.2.5 Low Cost of Implementation The cost of supporting the RIF will have a direct impact on the extent of its deployability. This applies not only to any execution costs of employing the RIF but also to the design-time costs associated with it. For example, a RIF that requires expensive theorem provers to process the interchange or requires highly complex implementation techniques will be less likely to be deployed than one that is less demanding of technology and people. Goals that are supported by this CSF: Widescale Adoption CSFs opposing this CSF: Coverage , Extensibility Requirements supporting this CSF: Compliance model , Implementability , Standard components , Translators 3.2.6 Predictability The RIF must be a sound basis for exchanging rules, i.e., it must be predictable what is exchanged when a ruleset is exchanged between partners and/or tools. Goals that are supported by this CSF: Exchange of Rules , Widescale Adoption Requirements supporting this CSF: Default behavior , Different semantics , Semantic precision , Semantic tagging 4 Requirements The Working Group has currently approved the following requirements. This list is a work in progress and may change in future drafts, especially for Phase 2. Requirements listed as "General" are deemed to be fundamental properties which are presupposed by all use cases involving RIF. Whenever possible, Phase 1 and Phase 2 are listed along with links back to the specific use cases in section 3 that are deemed to motivate them. Note that certain requirements, including some of those specified in the charter (e.g. named arguments and Horn Logic as a semantics) are not explicitly mentioned in the list below. It is intended that these requirements will be incorporated via the Rulesystem Arrangement Framework (RIFRAF). The umbrella requirement, Rule language coverage , will thus entail the entire set of requirements implicit in the RIFRAF. Note also that a language is said to be 'covered' by RIF if RIF can be used to interchange rulesets written in that language. The Working Group expects to provide a precise framework for talking about coverage and interoperability in a later draft. 4.1 General 4.1.1 Implementability RIF must be implementable using well understood techniques, and should not require new research in e.g. algorithms or semantics in order to implement translators. 4.1.2 Semantic precision RIF core must have a clear and precise syntax and semantics. Each standard RIF dialect must have a clear and precise syntax and semantics that extends RIF core. 4.1.3 Extensible Format It must be possible to create new dialects of RIF and extend existing ones upwardly compatible. 4.1.4 Translators For every standard RIF dialect it must be possible to implement translators between rule languages covered by that dialect and RIF without changing the rule language. 4.1.5 Standard components RIF implementations must be able to use standard support technologies such as XML parsers and other parser generators, and should not require special purpose implementations when reuse is possible. 4.1.6 Rule language coverage RIF must cover the set of languages identified in the Rulesystem Arrangement Framework . See the Coverage section. 4.2 Phase 1 4.2.1 Compliance model RIF must define a compliance model that will identify required/optional features. Motivated by Negotiating eBusiness Contracts Across Rule Platforms 4.2.2 Default behavior RIF must specify at the appropriate level of detail the default behavior that is expected from a RIF compliant application that does not have the capability to process all or part of the rules described in a RIF document, or it must provide a way to specify such default behavior. Motivated by Negotiating eCommerce Transactions Through Disclosure of Buyer and Seller Policies and Preferences Collaborative Policy Development for Dynamic Spectrum Access Access to Business Rules of Supply Chain Partners Managing Inter-Organizational Business Policies and Practices 4.2.3 Different semantics RIF must cover rule languages having different semantics. Motivated by Collaborative Policy Development for Dynamic Spectrum Access Access to Business Rules of Supply Chain Partners Managing Inter-Organizational Business Policies and Practices 4.2.4 Embedded comments RIF must be able to pass comments. Motivated by Access to Business Rules of Supply Chain Partners Managing Inter-Organizational Business Policies and Practices Ruleset Integration for Medical Decision Support 4.2.5 Embedded metadata RIF must support metadata such as author and rule name. Motivated by Access to Business Rules of Supply Chain Partners Managing Inter-Organizational Business Policies and Practices Ruleset Integration for Medical Decision Support 4.2.6 Limited number of dialects RIF must have a standard core and a limited number of standard dialects based upon that core. Motivated by Negotiating eCommerce Transactions Through Disclosure of Buyer and Seller Policies and Preferences Collaborative Policy Development for Dynamic Spectrum Access Access to Business Rules of Supply Chain Partners Interchanging Rule Extensions to OWL Vocabulary Mapping for Data Integration 4.2.7 OWL data RIF must cover OWL knowledge bases as data where compatible with Phase 1 semantics. Motivated by Collaborative Policy Development for Dynamic Spectrum Access Access to Business Rules of Supply Chain Partners Managing Inter-Organizational Business Policies and Practices Ruleset Integration for Medical Decision Support Interchanging Rule Extensions to OWL Publishing Rules for Interlinked Metadata 4.2.8 RDF data RIF must cover RDF triples as data where compatible with Phase 1 semantics. Motivated by Access to Business Rules of Supply Chain Partners Ruleset Integration for Medical Decision Support Interchanging Rule Extensions to OWL Vocabulary Mapping for Data Integration Publishing Rules for Interlinked Metadata 4.2.9 Dialect Identification RIF must have a standard way to specify the dialect of the interchanged rule set in a RIF document. Motivated by Negotiating eCommerce Transactions Through Disclosure of Buyer and Seller Policies and Preferences 4.2.10 XML syntax RIF must have an XML syntax as its primary normative syntax. Motivated by Negotiating eCommerce Transactions Through Disclosure of Buyer and Seller Policies and Preferences Access to Business Rules of Supply Chain Partners Managing Inter-Organizational Business Policies and Practices Interchanging Rule Extensions to OWL 4.2.11 XML types RIF must support an appropriate set of scalar datatypes and associated operations as defined in XML Schema part 2 and associated specifications. See the charter on Datatype support . Motivated by Negotiating eBusiness Contracts Across Rule Platforms Access to Business Rules of Supply Chain Partners Interchanging Rule Extensions to OWL BPEL Orchestration of Rule-Based Web Services 4.2.12 Merge Rule Sets RIF should support the ability to merge rule sets. Motivated by Negotiating eCommerce Transactions Through Disclosure of Buyer and Seller Policies and Preferences Access to Business Rules of Supply Chain Partners Managing Inter-Organizational Business Policies and Practices 4.2.13 Identify Rule Sets RIF will support the identification of rule sets. (implicit in previous requirement) 4.3 Phase 2 4.3.1 XML data RIF must be able to accept XML elements as data. Motivated by Negotiating eBusiness Contracts Across Rule Platforms BPEL Orchestration of Rule-Based Web Services 5 Coverage The RIF Rulesystems Arrangement Framework (RIFRAF) is meant to define a description space for existing (or potential) rule languages (rule systems). Each criterion defines an axis with two or more values that can be usedover different sources to discriminate between, or at least characterize, rule languages. The idea is not that every criterion used in the RIFRAF shouldbe reflectedinterlinked. In a coverage requirement:manner similar to how HTML links human-readable Web pages, RIF should permit linking metadata on the contrary, the RIFRAF will be usedWeb to identifysupport new kinds of "intelligent" crawling and to prioritize featuressearch.



5 Requirements

The goals and to abstract classesbase use cases motivate a number of requirements and objectives for a Rule languages/systems thatInterchage Format. The Working Group has currently approved the following requirements.

Requirements listed as "General" are deemed to be fundamental properties which are presupposed by all use cases involving RIF and which need to be fully covered by RIF.the Working Group iscurrently working to populate the RIFRAF description spacespecified RIF dialects. Other requirements are listed along with links back to the specific rule languages/systemsuse cases that need be coveredare deemed to motivate them. Their coverage, i.e. the level of fulfilment, by RIF.the starting point forexisting RIF dialects is discussed. In addition to the RIFRAF was aset of criteria deemed especially relevantfeatures that should be in the existing languages, as defined by these requirements, there are further features that would be useful for Phase 1 of RIF. It has andmany use cases or are definitely needed in one or more use cases. These objectives will continue to evolve as it is populated:be addressed in future RIF dialects which will be specified by the description of additional rule languages/systems may requireworking group if possible, but the additiongroup may decide to leave them to be implemented outside of this working group. Some of these objectives are not fully defined, and as such need further clarification if they are to be addressed by a RIF dialect.

Note that certain requirements, including some of new criteria (descriptors/discriminators). Phasing is not a limitation, sincethose specified in the anaysis ofcharter are not explicitly mentioned in the populated RIFRAF willlist below. Note also that a language is said to be 'covered' by a RIF dialect if RIF can be used to prioritize requirements with respect to phases. The setinterchange rulesets written in that dialect language.

Editor's Note: A discussion of criteria described below isthe current statecoverage of the RIFRAF. It is included to provide the reader with a snapshot ofrequirements by the workcurrent dialects (BLD and PRDF) will be added

5.1 General

5.1.1 Implementability

RIF must be implementable using well understood techniques, and should not require new research in progress at the time this working draft is releasede.g. algorithms or semantics in order to implement translators.

5.1.2 Semantic precision

RIF core must have a clear and withprecise syntax and semantics. Each standard RIF dialect must have a concrete idea of the meaning of the coverage requirement.clear and precise syntax and semantics that extends RIF core.

5.1.3 Extensible Format

It should notmust be construed as a listpossible to create new dialects of requirementsRIF and extend existing ones upwardly compatible.

5.1.4 Translators

For every standard RIF coverage, nor as a representation of how the Working Group views the space ofdialect it must be possible to implement translators between rule languages and systems at this time. 5.1 RIFRAF Expressive Discriminators (or Dimensions) are collected here into four groups: Purely-Syntactic Syntactic-entailing-Semantic Semantic Pragmatic Values of Semantic and Pragmatic Discriminators, stated by Rulebase authors or foundcovered by Static Analysis, can of course stillthat dialect and RIF without changing the rule language.

5.1.5 Standard components

RIF implementations must be marked up syntactically, e.g. via Semantic/Pragmatic (XML) Attributes on Rulebases, Rules, ..., via (RDF) metadata annotations, etc. In each group, Discriminators,able to use standard support technologies such as XML parsers and possibly subgroups of Discriminators, are listed (cf. rdf:subPropertyOf).other parser generators, and should not require special purpose implementations when reuse is possible.

5.1.6 Rule language coverage

RIF must cover the numberingsset of languages identified in the Discriminators do not reflect priority orderings but are there for ease of reference such as "Syn 1.2" forRulesystem Arrangement Framework. See the Range-restrictedness Discriminator (however, new subgroups may emerge from subsequences of neighboring Discriminators). For most Discriminators there existsCoverage section.

5.2 Basic Requirements

5.2.1 Compliance model

RIF must define a lotcompliance model that will identify required/optional features.

5.2.2 Default behavior

RIF must specify at the appropriate level of literature, under various names. For example, Discriminator SeS 1 on "Homogeneous vs. Hybrid Rules"detail the default behavior that is discussed, under this name, in Combining Rules and Ontologies.expected from a survey.RIF compliant application that paper provides various Subdiscriminators useful for OWL Compatibility .does not have the Hybrid approach is furthercapability to process all or part of the rules described in a Realistic Architecture for the Semantic Web . The RIF-crucial Interoperability Discriminators are regarded here as Pragmatic Discriminators, and grouped under Prag 3. 5.1.1 Syn: Syntactic Discriminators Restricted vs. Unrestricted UseRIF document, or it must provide a way to specify such default behavior.

5.2.3 Different semantics

RIF must cover rule bodieslanguages having different semantics.

5.2.4 Embedded comments

RIF must be able to pass comments.

5.2.5 Embedded metadata

RIF must support metadata such as conjunctionauthor and classical implication in rule heads http://www.w3.org/Submission/SWSF-SWSL/#swsl-rules-mon-lt Explicit vs. Implicitrule Scope Allowing formulas and/or names denoting what has been called Modules, Contexts, Rulesets, or Models http://www.isi.edu/~argos/matthew/triple_by_example.html Slotted (Keyed, Role-Named) vs. Positional Arguments Allowing n-ary atoms with a setname.

5.2.6 Limited number of Premises in Rules Labeled (Anchored, OIDed) vs. Unlabeled Clauses Labels Allowed vs. not Allowed as Arguments of User Predicates and/or System Predicates (such as in SCLP's priority-giving 'overrides' predicate, cf. SeS 9) Certain vs. Uncertain Clauses and Atoms Priority Static vs. Dynamic: Static priority does not change. It could be specified usingdialects

RIF must have a numeric constant,standard core and a listlimited number of rule (labels) with lesser (or greater) priority, or the positionstandard dialects based upon that core.

5.2.7 OWL data

RIF must cover OWL knowledge bases as data where compatible with Phase 1 semantics.

5.2.8 RDF data

RIF must cover RDF triples as data drawn from diverse sources,where the original Web mainly concentrated on the interchangecompatible with Phase 1 semantics.

5.2.9 Dialect Identification

RIF must have a machine,standard way to start off in one database, and then move through an unending set of databases which are connected not by wires but by being aboutspecify the same thing."(From http://www.w3.org/2001/sw/, italics added)dialect of the paragraph above characterizesinterchanged rule set in a very high-level fashion how Semantic Web technologies are supposedRIF document.

5.2.10 XML syntax

RIF must have an XML syntax as its primary normative syntax.

5.2.11 XML types

RIF must support an appropriate set of scalar datatypes and associated operations as defined in standard formatsXML Schema part 2 and allowing the relationship of data toassociated specifications. See the "œreal world"€ to be represented in a precise fashion are necessary conditions for turning "data"€ into machine-processable information having an invariant meaningcharter on Datatype support.

5.2.12 Merge Rule Sets

RIF should support the information they encounter in some way. Thus, another aspectability to merge rule sets.

5.2.13 Identify Rule Sets

RIF will support the processing that machines performidentification of rule sets. (implicit in a way that is invariantprevious requirement)

5.3 Objectives

5.3.1 XML data

RIF must be able to accept XML elements as data.


6 Conclusion

The goal of thisthe RIF working group is to provide suchrepresentational interchange formats for processes based on the use of rules and rule-based systems. These formats act as "interlingua" to interchange rules and integrate with other languages, in particular (Semantic) Web mark-up languages.

As can be seen by studying the use-cases presented in this document, rules are used to perform a wide variety of tasks, and, therefore, rule-based systems are not monolithic. Rules have been used to perform or validate inference, perform calculations, direct the flow of information, enforce integrity constraints on databases, represent and enforce policies, control devices and processes in real-time, determine the need for human intervention, and so on.

In light of this diversity the working group expects that RIF, rather than being a single all-encompassing format, will consist of several dialects, each dialect serving a particular set of related rule languages. The key idea is to attain the goal of interoperability (via interchange of RIF rules) within each dialect. This should allow the main benefits of RIF to be realized. For example, the invariant meaning of a set of integrity-constraint-enforcing rules would be represented within the appropriate RIF dialect and could then be translated into the native format of any of the formalisms capable of representing such rules.

Each RIF dialect will be built upon the general framework for logic-based RIF dialects (RIF-FLD).RIF must be designed in such a way that it is possible to create new dialects based upon(extensibility) according to the framework,overal goals and the general requirements of RIF, as well as to update existing dialects (upwardly compatible). This is in keeping with the working group charter'€™s call for an extensible format.€ Other requirements on the framework, and RIF as a whole, are included in this document in the section Requirements . Work on the technical specification of RIF FLD is presented in the document RIF-FLD .document.

Achieving inter-dialect interoperability is, by its very nature, an ill-constrained problem since, by definition, 100% meaning-preserving translations between dialects with different semantics are not likely to exist in most cases. That is not to say that useful inter-dialect "€œtranslation"€ is impossible, only that additional criteria are required in order to formulate precise notions of what satisfactory translation (via interchange of RIF rules) amounts to in such cases. Developing criteria for understanding and managing RIF inter-dialect translations is not within the current phase of RIF working group activity.