HOME

TheInfoList



OR:

The Rule Interchange Format (RIF) is a
W3C Recommendation The World Wide Web Consortium (W3C) is the main international standards organization for the World Wide Web. Founded in 1994 by Tim Berners-Lee, the consortium is made up of member organizations that maintain full-time staff working together in ...
. RIF is part of the infrastructure for the
semantic web The Semantic Web, sometimes known as Web 3.0, is an extension of the World Wide Web through standards set by the World Wide Web Consortium (W3C). The goal of the Semantic Web is to make Internet data machine-readable. To enable the encoding o ...
, along with (principally)
SPARQL SPARQL (pronounced ":wikt:sparkle, sparkle", a recursive acronym for SPARQL Protocol and RDF Query Language) is an RDF query language—that is, a Semantic Query, semantic query language for databases—able to retrieve and manipulate data sto ...
, RDF and
OWL Owls are birds from the order Strigiformes (), which includes over 200 species of mostly solitary and nocturnal birds of prey typified by an upright stance, a large, broad head, binocular vision, binaural hearing, sharp talons, and feathers a ...
. Although originally envisioned by many as a "rules layer" for the semantic web, in reality the design of RIF is based on the observation that there are many "rules languages" in existence, and what is needed is to exchange rules between them. RIF includes three dialects, a Core dialect which is extended into a Basic Logic Dialect (BLD) and Production Rule Dialect (PRD).


History

The RIF working group was chartered in late 2005. Among its goals was drawing in members of the commercial rules marketplace. The working group started with more than 50 members and two chairs drawn from industry, Christian de Sainte Marie of
ILOG ILOG S.A. was an international software company purchased and incorporated into IBM announced in January, 2009. It created enterprise software products for supply chain, business rule management, visualization and optimization. The main product ...
, and Chris Welty of
IBM International Business Machines Corporation (using the trademark IBM), nicknamed Big Blue, is an American Multinational corporation, multinational technology company headquartered in Armonk, New York, and present in over 175 countries. It is ...
. The charter, to develop an interchange format between existing rule systems was influenced by a workshop in the spring of 2005 in which it was clear that one rule language would not serve the needs of all interested parties (Dr. Welty described the outcome of the workshop as
Nash Equilibrium In game theory, the Nash equilibrium is the most commonly used solution concept for non-cooperative games. A Nash equilibrium is a situation where no player could gain by changing their own strategy (holding all other players' strategies fixed) ...
). RIF became a
W3C Recommendation The World Wide Web Consortium (W3C) is the main international standards organization for the World Wide Web. Founded in 1994 by Tim Berners-Lee, the consortium is made up of member organizations that maintain full-time staff working together in ...
on June 22, 2010.


Rules and rule systems

A ''rule'' is perhaps one of the simplest notions in computer science: it is an IF - THEN construct. If some condition (the IF part) that is checkable in some dataset holds, then the conclusion (the THEN part) is processed. Deriving somewhat from its roots in
logic Logic is the study of correct reasoning. It includes both formal and informal logic. Formal logic is the study of deductively valid inferences or logical truths. It examines how conclusions follow from premises based on the structure o ...
, rule systems use a notion of predicates that hold or not of some data object or objects. For example, the fact that two people are married might be represented with predicates as: ''MARRIED(LISA,JOHN)'' ''MARRIED'' is a predicate that can be said to ''hold'' between ''LISA'' and ''JOHN''. Adding the notion of variables, a rule could be something like: IF ''MARRIED(?x, ?y)'' THEN ''LOVES(?x, ?y)'' We would expect that for every pair of ?x and ?y (e.g. ''LISA'' and ''JOHN'') for which the ''MARRIED'' predicate holds, some computer system that could understand this rule would conclude that the ''LOVES'' predicate holds for that pair as well. Rules are a simple way of encoding knowledge, and are a drastic simplification of
first order logic First-order logic, also called predicate logic, predicate calculus, or quantificational logic, is a collection of formal systems used in mathematics, philosophy, linguistics, and computer science. First-order logic uses quantified variables over ...
, for which it is relatively easy to implement inference engines that can process the conditions and draw the right conclusions. A ''rule system'' is an implementation of a particular
syntax In linguistics, syntax ( ) is the study of how words and morphemes combine to form larger units such as phrases and sentences. Central concerns of syntax include word order, grammatical relations, hierarchical sentence structure (constituenc ...
and
semantics Semantics is the study of linguistic Meaning (philosophy), meaning. It examines what meaning is, how words get their meaning, and how the meaning of a complex expression depends on its parts. Part of this process involves the distinction betwee ...
of rules, which may extend the simple notion described above to include
existential quantification Existentialism is a family of philosophy, philosophical views and inquiry that explore the human individual's struggle to lead an Authenticity (philosophy), authentic life despite the apparent Absurdity#The Absurd, absurdity or incomprehensibili ...
,
disjunction In logic, disjunction (also known as logical disjunction, logical or, logical addition, or inclusive disjunction) is a logical connective typically notated as \lor and read aloud as "or". For instance, the English language sentence "it is ...
,
logical conjunction In logic, mathematics and linguistics, ''and'' (\wedge) is the Truth function, truth-functional operator of conjunction or logical conjunction. The logical connective of this operator is typically represented as \wedge or \& or K (prefix) or ...
,
negation In logic, negation, also called the logical not or logical complement, is an operation (mathematics), operation that takes a Proposition (mathematics), proposition P to another proposition "not P", written \neg P, \mathord P, P^\prime or \over ...
, functions, non monotonicity, and many other features. Rule systems have been implemented and studied since the mid-1970s and saw significant uptake in the 1980s during the height of so-called
Expert Systems In artificial intelligence (AI), an expert system is a computer system emulating the decision-making ability of a human expert. Expert systems are designed to solve complex problems by Automated reasoning system, reasoning through bodies of knowl ...
.


Standard RIF dialects

The standard RIF dialects are Core, BLD and PRD. These dialects depend on an extensive list of datatypes with builtin functions and predicates on those datatypes. Relations of various RIF dialects are shown in the following Venn diagram.


DTB

Datatypes and Built-Ins (DTB) specifies a list of datatypes, built-in functions and built-in predicates expected to be supported by RIF dialects. Some of the datatypes are adapted from
XML Schema An XML schema is a description of a type of XML document, typically expressed in terms of constraints on the structure and content of documents of that type, above and beyond the basic syntactical constraints imposed by XML itself. These constrai ...
Datatypes,
XPath XPath (XML Path Language) is an expression language designed to support the query or transformation of XML documents. It was defined by the World Wide Web Consortium (W3C) in 1999, and can be used to compute values (e.g., strings, numbers, or ...
functions and rdf:PlainLiteral functions.


Core

The Core dialect comprises a common subset of most rule dialect. RIF-Core is a subset of both RIF-BLD and RIF-PRD.


FLD

Framework for Logic Dialects (FLD) describes mechanisms for specifying the syntax and semantics of logic RIF dialects, including the RIF-BLD and RIF-Core, but not RIF-PRD which is not a logic-based RIF dialect.


BLD

The Basic Logic Dialect (BLD) adds features to the Core dialect that are not directly available such as: logic functions, equality in the then-part and named arguments. RIF BLD corresponds to positive datalogs, that is, logic programs without functions or negations. RIF-BLD has a model-theoretic semantics. The
frame A frame is often a structural system that supports other components of a physical construction and/or steel frame that limits the construction's extent. Frame and FRAME may also refer to: Physical objects In building construction *Framing (con ...
syntax of RIF BLD is based on
F-logic F-logic (Frame logic) is a knowledge representation and ontology language. It combines the advantages of conceptual modeling with Object-oriented programming, object-oriented, Frame (artificial intelligence), frame-based languages, and offers a Decl ...
, but RIF BLD doesn't have the non-monotonic reasoning features of F-logic.


PRD

The Production Rules Dialect (PRD) can be used to model production rules. Features that are notably in PRD but not BLD include negation and retraction of facts (thus, PRD is not monotonic). PRD rules are order dependent, hence conflict resolution strategies are needed when multiple rules can be fired. The PRD specification defines one such resolution strategy based on
forward chaining Forward chaining (or forward reasoning) is one of the two main methods of reasoning when using an inference engine and can be described logically as repeated application of ''modus ponens''. Forward chaining is a popular implementation strategy f ...
reasoning. RIF-PRD has an
operational semantics Operational semantics is a category of formal programming language semantics in which certain desired properties of a program, such as correctness, safety or security, are verified by constructing proofs from logical statements about its exec ...
, whereas the condition formulas also have a model-theoretic semantics. Example (Example 1.2 in ) Prefix(ex ) (* ex:rule_1 *) Forall ?customer ?purchasesYTD ( If And( ?customer#ex:Customer ?customer x:purchasesYTD->?purchasesYTD External(pred:numeric-greater-than(?purchasesYTD 5000)) ) Then Do( Modify(?customer x:status->"Gold" ) )


Non-standard RIF dialects

Several other RIF dialects exist. None of them are officially endorsed by W3C and they are not part of the RIF specification.


CASPD

The Core Answer Set Programming Dialect (CASPD) is based on answer set programming, that is, declarative logic programming based on the answer set semantics ( stable model semantics). Example:
Document(
      Prefix(ex )

      Group (
          Forall ?S (
              ex:afraid(?S ex:Math) :- And ( ?S#ex:Student (Naf Neg ex:afraid(?S ex:Math)) )
	  )
      
	  Forall ?S (
	      Neg ex:afraid(?S ex:Math) :- And ( ?S#ex:Student ?S x:majors -> ex:Math)
	  )
      )


URD

The Uncertainty Rule Dialect (URD) supports a direct representation of uncertain knowledge. Example:
Document( 
  Import () 
  Group 
  ( 
    Forall ?x ?y( 
        cheapFlight(?x ?y) :- affordableFlight(?x ?y) 
    )  / 0.4 
    Forall ?x ?y(affordableFlight(?x ?y))  / left_shoulder0k4k1k3k(?y) 
  )    ) 


SILK

RIF-SILK can be used to model default logic. It is based on declarative logic programming with the
well-founded semantics In computer science, the well-founded semantics is a three-valued semantics for logic programming, which gives a precise meaning to general logic programs. History The well-founded semantics was defined by Van Gelder, et al. in 1988. The Prolog ...
. RIF-SILK also includes a number of other features present in more sophisticated declarative logic programming languages such as SILK.The SILK Language, Benjamin Grosof, Michael Kifer, Mike Dean. Vulcan Inc., 2009.
/ref> Example
Document 
}


See also

*
Ontology alignment Ontology alignment, or ontology matching, is the process of determining correspondences between concepts in ontologies. A set of correspondences is also called an alignment. The phrase takes on a slightly different meaning, in computer science, c ...
* R2ML * Production Rule Representation - comparable to the dialect of RIF called Production Rule Dialect, although targeting modeling not run-time interchange.


References


External links


RIF Working Group

RIF FAQ
{{Semantic Web Semantic Web Knowledge representation languages