<?xml version="1.0"?>
<?xml-stylesheet type="text/css" href="http://www.w3.org/2005/rules/wiki/skins/common/feed.css?207"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
	<channel>
		<title>RIF - User contributions [en]</title>
		<link>http://www.w3.org/2005/rules/wiki/Special:Contributions/Sandro</link>
		<description>From RIF</description>
		<language>en</language>
		<generator>MediaWiki 1.15.5</generator>
		<lastBuildDate>Wed, 19 Jun 2013 06:49:59 GMT</lastBuildDate>
		<item>
			<title>Errata</title>
			<link>http://www.w3.org/2005/rules/wiki/Errata</link>
			<description>&lt;p&gt;Sandro:&amp;#32;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;For errata reported through January 2013, see: [[Errata First Edition]].  These were all addressed in Second Edition.&lt;br /&gt;
&lt;br /&gt;
For errata on the Second Edition, see http://www.w3.org/2001/sw/wiki/RIF_Errata&lt;br /&gt;
&lt;br /&gt;
Please report any suspected errors to [mailto:public-rif-comments@w3.org public-rif-comments@w3.org] ([http://lists.w3.org/Archives/Public/public-rif-wg/ public archive]).&lt;/div&gt;</description>
			<pubDate>Wed, 08 May 2013 14:01:39 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Talk:Errata</comments>		</item>
		<item>
			<title>Errata</title>
			<link>http://www.w3.org/2005/rules/wiki/Errata</link>
			<description>&lt;p&gt;Sandro:&amp;#32;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;For errata reported through January 2013, see: [[Errata First Edition]].  These were all addressed in Second Edition.&lt;br /&gt;
&lt;br /&gt;
For errata on the Second Edition, see http://www.w3.org/2010/rif/errata&lt;br /&gt;
&lt;br /&gt;
Please report any suspected errors to [mailto:public-rif-comments@w3.org public-rif-comments@w3.org] ([http://lists.w3.org/Archives/Public/public-rif-wg/ public archive]).&lt;/div&gt;</description>
			<pubDate>Wed, 08 May 2013 13:54:27 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Talk:Errata</comments>		</item>
		<item>
			<title>Errata</title>
			<link>http://www.w3.org/2005/rules/wiki/Errata</link>
			<description>&lt;p&gt;Sandro:&amp;#32;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;For errata reported through January 2013, see: [[Errata First Edition]].  These were all addressed in Second Edition.&lt;br /&gt;
&lt;br /&gt;
Please report any suspected errors to [mailto:public-rif-comments@w3.org public-rif-comments@w3.org] ([http://lists.w3.org/Archives/Public/public-rif-wg/ public archive]).  Confirmed errors will be documented on this page.&lt;/div&gt;</description>
			<pubDate>Wed, 06 Feb 2013 17:54:45 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Talk:Errata</comments>		</item>
		<item>
			<title>Errata</title>
			<link>http://www.w3.org/2005/rules/wiki/Errata</link>
			<description>&lt;p&gt;Sandro:&amp;#32;moved Errata to Errata First Edition&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[Errata First Edition]]&lt;/div&gt;</description>
			<pubDate>Wed, 06 Feb 2013 17:53:35 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Talk:Errata</comments>		</item>
		<item>
			<title>Errata First Edition</title>
			<link>http://www.w3.org/2005/rules/wiki/Errata_First_Edition</link>
			<description>&lt;p&gt;Sandro:&amp;#32;moved Errata to Errata First Edition&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Please report any suspected errors to [mailto:public-rif-comments@w3.org public-rif-comments@w3.org] ([http://lists.w3.org/Archives/Public/public-rif-wg/ public archive]).  Confirmed errors will be documented on this page.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Proposed Erratum 1 == &lt;br /&gt;
&lt;br /&gt;
Typos in [[BLD#Semantic_Structures]] ([http://lists.w3.org/Archives/Public/public-rif-wg/2011Jan/0000.html reported here])&lt;br /&gt;
&lt;br /&gt;
* In item: &amp;lt;em&amp;gt;'''''I'''''(&amp;lt;tt&amp;gt;o[a&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... a&amp;lt;sub&amp;gt;k&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;k&amp;lt;/sub&amp;gt;]&amp;lt;/tt&amp;gt;) = '''''I'''''&amp;lt;sub&amp;gt;frame&amp;lt;/sub&amp;gt;('''''I'''''(&amp;lt;tt&amp;gt;o&amp;lt;/tt&amp;gt;))({&amp;amp;lt;'''''I'''''(&amp;lt;tt&amp;gt;a&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;),'''''I'''''(&amp;lt;tt&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;)&amp;gt;, ..., &amp;amp;lt;'''''I'''''(&amp;lt;tt&amp;gt;a&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;),'''''I'''''(&amp;lt;tt&amp;gt;v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;)&amp;gt;})&amp;lt;/em&amp;gt;&lt;br /&gt;
 Thus, for instance, &amp;lt;tt&amp;gt;[a-&amp;gt;b a-&amp;gt;b]&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;o[a-&amp;gt;b]&amp;lt;/tt&amp;gt; always have the same truth value.&lt;br /&gt;
should read&lt;br /&gt;
 Thus, for instance, &amp;lt;tt&amp;gt;o[a-&amp;gt;b a-&amp;gt;b]&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;o[a-&amp;gt;b]&amp;lt;/tt&amp;gt; always have the same truth value.&lt;br /&gt;
&lt;br /&gt;
* Last sentence before '''''The effect of datatypes'''''&lt;br /&gt;
 This implies that the equalities like t(a-&amp;gt;1 b-&amp;gt;2 c-&amp;gt;3) = t(c-&amp;gt;3 a-&amp;gt;2 b-&amp;gt;2) are tautologies in RIF-BLD.&lt;br /&gt;
should read&lt;br /&gt;
 This implies that the equalities like t(a-&amp;gt;1 b-&amp;gt;2 c-&amp;gt;3) = t(c-&amp;gt;3 a-&amp;gt;1 b-&amp;gt;2) are tautologies in RIF-BLD.&lt;br /&gt;
&lt;br /&gt;
'''Corrected'''&lt;br /&gt;
&lt;br /&gt;
== Proposed Erratum 2 ==&lt;br /&gt;
&lt;br /&gt;
XML serialization of &amp;lt;tt&amp;gt;rdf:PlainLitteral&amp;lt;/tt&amp;gt; ([http://lists.w3.org/Archives/Public/public-rif-dev/2010Nov/0000.html reported here] and [http://lists.w3.org/Archives/Public/public-rif-comments/2009Nov/0000.html here]). See WG reply ([http://lists.w3.org/Archives/Public/public-rif-comments/2010Mar/0004.html here])&lt;br /&gt;
&lt;br /&gt;
* PROPOSE to make it explicit (in DTB) that the &amp;lt;tt&amp;gt;xml:lang&amp;lt;/tt&amp;gt; attribute must be used with value equal ''langTag'' for &amp;lt;tt&amp;gt;rdf:PlainLitteral&amp;lt;/tt&amp;gt; constant where the ''langTag'' is not empty and that the content of a &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt; element with &amp;lt;tt&amp;gt;type=&amp;quot;&amp;amp;rdf;PlainLitteral&amp;quot;&amp;lt;/tt&amp;gt; is either the data value if the &amp;lt;tt&amp;gt;xml:lang&amp;lt;/tt&amp;gt; attribute is not present, or the first element in the data value pair if the &amp;lt;tt&amp;gt;xml:lang&amp;lt;/tt&amp;gt; attribute is present.&lt;br /&gt;
&lt;br /&gt;
== Proposed Erratum 3 ==&lt;br /&gt;
&lt;br /&gt;
Empty &amp;lt;tt&amp;gt;args&amp;lt;/tt&amp;gt; tag must be omitted in RIF/XML ([http://lists.w3.org/Archives/Public/public-rif-dev/2010Sep/0000.html reported here])&lt;br /&gt;
&lt;br /&gt;
* As discussed [http://lists.w3.org/Archives/Public/public-rif-dev/2010Sep/0002.html here] and [http://lists.w3.org/Archives/Public/public-rif-wg/2010Nov/0000.html] here, and as published to the dev community [http://lists.w3.org/Archives/Public/public-rif-dev/2012Feb/0000.html here]&lt;br /&gt;
* Requires corrections in BLD (as proposed by Harold [http://lists.w3.org/Archives/Public/public-rif-wg/2010Nov/0000.html here]) and in FLD&lt;br /&gt;
&lt;br /&gt;
Added 10 July 2012 by csma:&lt;br /&gt;
&lt;br /&gt;
We have the same pb with the &amp;lt;tt&amp;gt;items&amp;lt;/tt&amp;gt; role sub-element in &amp;lt;tt&amp;gt;List&amp;lt;/tt&amp;gt;. PRD says explicitely that an empty list has an empty &amp;lt;tt&amp;gt;items&amp;lt;/tt&amp;gt; sub-element ([http://www.w3.org/2005/rules/wiki/PRD#List section 8.3.1.3]), but the XML schema says that the empty &amp;lt;tt&amp;gt;items&amp;lt;/tt&amp;gt; sub-element must be omitted. BLD and FLD may have the same pb (I am not comfortable enough with the notation in the XML mapping to be sure :-).&lt;br /&gt;
&lt;br /&gt;
PROPOSED: correct:&lt;br /&gt;
* section 8.3.1.3 in PRD '''corrected (see [http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14463&amp;amp;oldid=12718 here])&lt;br /&gt;
* the empty &amp;lt;tt&amp;gt;args&amp;lt;/tt&amp;gt; XML mapping in BLD.&lt;br /&gt;
'''Corrected:''' http://www.w3.org/2005/rules/wiki/index.php?title=BLD&amp;amp;diff=14569&amp;amp;oldid=14564&lt;br /&gt;
* the empty &amp;lt;tt&amp;gt;args&amp;lt;/tt&amp;gt; XML mapping in FLD.&lt;br /&gt;
'''Corrected:''' http://www.w3.org/2005/rules/wiki/index.php?title=FLD&amp;amp;diff=14572&amp;amp;oldid=14451&lt;br /&gt;
&lt;br /&gt;
== Proposed Erratum 4 ==&lt;br /&gt;
&lt;br /&gt;
Possible typo in all RIF documents ([http://lists.w3.org/Archives/Public/public-rif-dev/2010Jun/0000.html reported here])&lt;br /&gt;
&lt;br /&gt;
* At the end of first paragraph in '''XML Schema Datatypes Dependency'''&lt;br /&gt;
 required as otherwise specified&lt;br /&gt;
should read?&lt;br /&gt;
 required unless otherwise specified&lt;br /&gt;
&lt;br /&gt;
PROPOSED: remove the XML Schema Datatypes Dependency section in all documents.&lt;br /&gt;
&lt;br /&gt;
== Proposed Erratum 5 ==&lt;br /&gt;
&lt;br /&gt;
'''No action''': it looks like that one had been corrected before REC already...&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
XML Schema VS presentation syntax mismatch ([http://lists.w3.org/Archives/Public/public-rif-comments/2009Oct/0009.html reported here] and [http://lists.w3.org/Archives/Public/public-rif-comments/2009Nov/0000.html here])&lt;br /&gt;
&lt;br /&gt;
* BLD and PRD presentation syntaxes say&lt;br /&gt;
  Import    ::= IRIMETA? 'Import' '(' LOCATOR PROFILE? ')'&lt;br /&gt;
  LOCATOR   ::= ANGLEBRACKIRI&lt;br /&gt;
  PROFILE   ::= ANGLEBRACKIRI&lt;br /&gt;
whereas the XML Schemata say&lt;br /&gt;
  &amp;lt;xs:element name=&amp;quot;Import&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;!--&lt;br /&gt;
  Import    ::= IRIMETA? 'Import' '(' IRICONST PROFILE? ')'&lt;br /&gt;
    --&amp;gt;&lt;br /&gt;
    &amp;lt;xs:complexType&amp;gt;&lt;br /&gt;
      &amp;lt;xs:sequence&amp;gt;&lt;br /&gt;
        &amp;lt;xs:group ref=&amp;quot;IRIMETA&amp;quot; minOccurs=&amp;quot;0&amp;quot; maxOccurs=&amp;quot;1&amp;quot;/&amp;gt; &lt;br /&gt;
        &amp;lt;xs:element ref=&amp;quot;location&amp;quot;/&amp;gt;&lt;br /&gt;
        &amp;lt;xs:element ref=&amp;quot;profile&amp;quot; minOccurs=&amp;quot;0&amp;quot; maxOccurs=&amp;quot;1&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;/xs:sequence&amp;gt;&lt;br /&gt;
    &amp;lt;/xs:complexType&amp;gt;&lt;br /&gt;
  &amp;lt;/xs:element&amp;gt;&lt;br /&gt;
  &lt;br /&gt;
  &amp;lt;xs:element name=&amp;quot;location&amp;quot; type=&amp;quot;xs:anyURI&amp;quot;/&amp;gt;&lt;br /&gt;
  &lt;br /&gt;
  &amp;lt;xs:element name=&amp;quot;profile&amp;quot; type=&amp;quot;xs:anyURI&amp;quot;/&amp;gt;&lt;br /&gt;
* In BLD, [[BLD#Mapping_of_the_Rule_Language|the mapping of the rule language]] must be corrected as well&lt;br /&gt;
* PS: there is a note in [[BLD#Formulas|section 2.3]] in BLD that says:&lt;br /&gt;
 Note that although Base, Prefix, and Import all use symbols of the form &amp;lt;iri&amp;gt; to indicate the connection of these symbols to IRIs, these symbols are not rif:iri constants, as semantically they are interpreted in a way that is quite different from constants.&lt;br /&gt;
So, it would be a clarification rather than an erratum properly said.&lt;br /&gt;
&lt;br /&gt;
== Proposed Erratum 6 ==&lt;br /&gt;
&lt;br /&gt;
PRD and BLD disagree on use of xml:base (see also the last item in [http://lists.w3.org/Archives/Public/public-rif-comments/2009Nov/0000.html this comment])&lt;br /&gt;
* PRD says ([[PRD#Relative_IRIs_and_XML_base|section 8.2]])&lt;br /&gt;
 Relative IRIs are allowed in RIF-PRD XML syntax, anywhere IRIs are allowed, including constant types, symbol spaces, location, and profile. The attribute &amp;lt;tt&amp;gt;xml:base&amp;lt;/tt&amp;gt; &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#xml-base|XML-Base]]] is used to make them absolute.&lt;br /&gt;
while BLD says ([[BLD#Formulas|section 2.3]])&lt;br /&gt;
 Like the Base directive, the Prefix directives define shorthands to allow more concise representation of constants that come from the symbol space rif:iri (we will call such constants rif:iri constants).&lt;br /&gt;
and ([[BLD#XML_for_the_Rule_Language|section 4.2]])&lt;br /&gt;
 A Base directive in the presentation syntax becomes an xml:base attribute [XML-Base] in the XML Document tag. The base IRI specified as the value of that attribute applies to content of the RIF/XML element that deals with rif:iri constants, namely to relative-IRI content of the &amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt; element.&lt;br /&gt;
* DTB is not specific on this, and says only ([[DTB#Relative_IRIs|section 2.2.3]])&lt;br /&gt;
 Relative IRIs in RIF documents are resolved with respect to the base IRI.&lt;br /&gt;
* Based on the discussion and resolution taken during the [http://lists.w3.org/Archives/Public/public-rif-wg/2010Feb/att-0010/2010-02-02-rif-minutes.html 2 Feb 2010 telecon], the intent seemed to be as specified in PRD:&lt;br /&gt;
 RESOLVED: We clarify that relative IRIs are allowed in RIF syntaxes (anywhere IRIs are allowed, including Const rif:iri, symbol spaces, location, and profile), and that xml:base is used in making them absolute; the absolute form is seen and used internally, so that's the lexical space.&lt;br /&gt;
* So does [http://lists.w3.org/Archives/Public/public-rif-comments/2010Mar/0004.html WG reply to comments] say.&lt;br /&gt;
&lt;br /&gt;
'''Corrected:''' http://www.w3.org/2005/rules/wiki/index.php?title=BLD&amp;amp;diff=14564&amp;amp;oldid=14558&lt;br /&gt;
&lt;br /&gt;
== Proposed Erratum 7 ==&lt;br /&gt;
&lt;br /&gt;
Remove editor's note in Core [http://www.w3.org/TR/rif-core/#Strong_Safeness_.28Informative.29 section 6.2] (reported [http://lists.w3.org/Archives/Public/public-rif-comments/2011Mar/0002.html here])&lt;br /&gt;
&lt;br /&gt;
'''Corrected+:''' http://www.w3.org/2005/rules/wiki/index.php?title=Core&amp;amp;diff=14456&amp;amp;oldid=13188&lt;br /&gt;
&lt;br /&gt;
== Proposed Errata for RIF-PRD ==&lt;br /&gt;
&lt;br /&gt;
=== Proposed Erratum 8 ===&lt;br /&gt;
&lt;br /&gt;
Handling of frame atomic formulas in RIF-PRD (reported [http://lists.w3.org/Archives/Public/public-rif-comments/2010Jun/0000.html here], item #1)&lt;br /&gt;
&lt;br /&gt;
 According to Definition of Matching Substitution (sect. 2.2.1) the empty substitution does not match the ground formula s[p1-&amp;gt;v1] to { s[p1-&amp;gt;v1 p2-&amp;gt;v2] } since s[p1-&amp;gt;v1] does not belong to { s[p1-&amp;gt;v1 p2-&amp;gt;v2] }.&lt;br /&gt;
 &lt;br /&gt;
 Is this the intended behaviour?&lt;br /&gt;
 &lt;br /&gt;
 A related problem is when the action is retract( s[p1-&amp;gt;v1] ) applied to state { s[p1-&amp;gt;v1 p2-&amp;gt;v2] }.&lt;br /&gt;
 &lt;br /&gt;
 The result according to the specification is apparently { s[p1-&amp;gt;v1 p2-&amp;gt;v2] }.&lt;br /&gt;
 &lt;br /&gt;
 Is this the intended behaviour?&lt;br /&gt;
 &lt;br /&gt;
 In summary, is { s[p1-&amp;gt;v1 ... pn -&amp;gt; vn] } equivalent to { s[p1-&amp;gt;v1], ..., s[pn-&amp;gt;vn]} or not?&lt;br /&gt;
&lt;br /&gt;
This not the intended behaviour: { s[p1-&amp;gt;v1 ... pn -&amp;gt; vn] } is intended to behave exactly like { s[p1-&amp;gt;v1], ..., s[pn-&amp;gt;vn]}.&lt;br /&gt;
&lt;br /&gt;
PROPOSED ('''corrected see [http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14468&amp;amp;oldid=14465 here]'''):&lt;br /&gt;
* to modify the definition of matching substitution, in [http://www.w3.org/TR/rif-prd/#Matching_substitution section 2.2.1], to read&lt;br /&gt;
&lt;br /&gt;
'''Definition (Matching substitution).''' Let ''&amp;amp;psi;'' be a RIF-PRD condition formula; let ''&amp;amp;sigma;'' be a ground substitution such that ''Var(&amp;amp;psi;)&amp;amp;nbsp;&amp;amp;sube;&amp;amp;nbsp;Dom(&amp;amp;sigma;)''; and let ''&amp;amp;Phi;'' be a set of ground RIF-PRD atomic formulas.&lt;br /&gt;
&lt;br /&gt;
We say that the ground substitution ''&amp;amp;sigma;'' '''''matches''''' ''&amp;amp;psi;'' to ''&amp;amp;Phi;'' if and only if one of the following is true:&lt;br /&gt;
* ''&amp;amp;psi;'' is an atomic formula and either&lt;br /&gt;
** ''&amp;amp;sigma;(&amp;amp;psi;)'' &amp;amp;isin; ''&amp;amp;Phi;'', or&lt;br /&gt;
** ''&amp;amp;psi;'' is a frame with multiple slots, &amp;lt;tt&amp;gt;o[s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;...s&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;]&amp;lt;/tt&amp;gt;, ''n &amp;amp;gt; 1'', and there is one ''i, 1&amp;amp;le;i&amp;amp;le;n'', such that ''&amp;amp;sigma;'' matches the conjunction &amp;lt;tt&amp;gt;And(o[s&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;] o[s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;...s&amp;lt;sub&amp;gt;i-1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;i-1&amp;lt;/sub&amp;gt; s&amp;lt;sub&amp;gt;i+1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;i+1&amp;lt;/sub&amp;gt;...s&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;]&amp;lt;/tt&amp;gt; to ''&amp;amp;Phi;''; or&lt;br /&gt;
** ...&lt;br /&gt;
&lt;br /&gt;
* to modify the definition of atomic action in [http://www.w3.org/TR/rif-prd/#Actions_2 section  3.1.1] to read&lt;br /&gt;
&lt;br /&gt;
'''Definition (Atomic action).''' ...&lt;br /&gt;
# ''Assert simple fact'': If &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; is ... a single slot [[#def-prd-atomic-formula|frame]] ...&lt;br /&gt;
# ''Retract simple fact'': If &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; is ... a single slot [[#def-prd-atomic-formula|frame]] ...&lt;br /&gt;
# ...&lt;br /&gt;
* to modify the definition of compound action in [http://www.w3.org/TR/rif-prd/#Actions_2 section  3.1.1] to read&lt;br /&gt;
&lt;br /&gt;
'''Definition (Compound action).''' A '''''compound action''''' is a construct that can be replaced equivalently by a pre-defined, and fixed, sequence of atomic actions. In RIF-PRD, a compound action can have three different forms, defined as follows:&lt;br /&gt;
# ''Assert compound fact'': If &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; is a [[#def-prd-atomic-formula|frame]] with multiple slots:  &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; = &amp;lt;tt&amp;gt;o[s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;...s&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;]&amp;lt;/tt&amp;gt;, ''n &amp;amp;gt; 1''; then &amp;lt;tt&amp;gt;Assert(&amp;amp;phi;)&amp;lt;/tt&amp;gt; is a compound action, defined by the sequence &amp;lt;tt&amp;gt;Assert(o[s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;]) ... Assert(o[s&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;])&amp;lt;/tt&amp;gt;. &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; is called the ''target'' of the action.&lt;br /&gt;
# ''Retract compound fact'': If &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; is a [[#def-prd-atomic-formula|frame]] with multiple slots:  &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; = &amp;lt;tt&amp;gt;o[s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;...s&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;]&amp;lt;/tt&amp;gt;, ''n &amp;amp;gt; 1''; then &amp;lt;tt&amp;gt;Retract(&amp;amp;phi;)&amp;lt;/tt&amp;gt; is a compound action, defined by the sequence &amp;lt;tt&amp;gt;Retract(o[s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;]) ... Retract(o[s&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;])&amp;lt;/tt&amp;gt;. &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; is called the ''target'' of the action.&lt;br /&gt;
# ''Modify fact'': if &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; is a [[#def-prd-atomic-formula|frame]] in the RIF-PRD condition language: &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; = &amp;lt;tt&amp;gt;o[s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;...s&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;]&amp;lt;/tt&amp;gt;, ''n &amp;amp;gt; 0''; then &amp;lt;tt&amp;gt;Modify(&amp;amp;phi;)&amp;lt;/tt&amp;gt; is a compound action, defined by the sequence: [[#def-atomic-action|&amp;lt;tt&amp;gt;Retract(o s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;)&amp;lt;/tt&amp;gt;]] ... &amp;lt;tt&amp;gt;Retract(o s&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;)&amp;lt;/tt&amp;gt;, followed by [[#def-atomic-action|&amp;lt;tt&amp;gt;Assert(&amp;amp;phi;)&amp;lt;/tt&amp;gt;]]. &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; is called the ''target'' of the action. &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
* to modify the definition of state of the fact base, [http://www.w3.org/2005/rules/wiki/PRD#Condition_satisfaction section 2.2.2], to restrict &amp;amp;Phi; to contain only single-slot frames&lt;br /&gt;
* and to add a note in the definition of frame, [http://www.w3.org/2005/rules/wiki/PRD#Atomic_formulas section 2.1.2], to say that frames with multiple slots are a shortcut for, and semantically equivalent to conjunctions of single slot frames with the same object.&lt;br /&gt;
&lt;br /&gt;
=== Proposed Erratum 9 ===&lt;br /&gt;
&lt;br /&gt;
Definition of rule variables in RIF-PRD (section 4.2.3) (reported [http://lists.w3.org/Archives/Public/public-rif-comments/2010Jun/0000.html here], item #2)&lt;br /&gt;
&lt;br /&gt;
 The concept of rule variable is never formally defined (the notion of  &lt;br /&gt;
 rule variable appears afterwards in Section 7.3 and 8.5.1.3 Forall).&lt;br /&gt;
 My interpretation is the following:&lt;br /&gt;
  for unconditional action blocks, rule variables are empty (i.e. free  &lt;br /&gt;
 variables).&lt;br /&gt;
 - for conditional action blocks, rule variables are the free variables.&lt;br /&gt;
 - for rules with variable declarations, the rule variables are the  &lt;br /&gt;
   universally quantified variables.&lt;br /&gt;
&lt;br /&gt;
 Is this correct? Wouldn't it make more sense to equate rule variables  &lt;br /&gt;
 to free variables in all cases?&lt;br /&gt;
 In this way, universally quantified variables would be ignored for  &lt;br /&gt;
 comparing instances of two rules, while free variables&lt;br /&gt;
 would be used for that purpose in all cases. This behaviour is  &lt;br /&gt;
 probably more coherent and easier to explain to users.&lt;br /&gt;
&lt;br /&gt;
The term &amp;quot;rule variables&amp;quot; is used to denote the variables that are universally quantified in a rule, to differentiate them from the variables that are existentially quantified in rule conditions, and from the action variables.&lt;br /&gt;
&lt;br /&gt;
Equivalently, the rule variables are the free variables in the conditional action block in a rule after steps 2 and 3 of Core-ification.&lt;br /&gt;
&lt;br /&gt;
'''Proposed modification (corrected see [http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14471&amp;amp;oldid=14468 here])''': Add the following sentence, after the definition of well-formed group, in [http://www.w3.org/TR/rif-prd/#Well-formed_rules_and_groups section 4.1.4]:&lt;br /&gt;
&lt;br /&gt;
&amp;quot;The variables that are universally quantified in a rule are sometimes called ''rule variables'' in the remainder of this document, to distinguish them from the action variables and from the existentially quantified variables. The function ''CVar'', that maps a rule to the set of its rule variables is defined as follows:&lt;br /&gt;
* if ''r'' is a conditional or unconditional action block, ''CVar(r) = &amp;amp;empty;''&lt;br /&gt;
* if ''r'' is a rule with variable declaration, &amp;lt;tt&amp;gt;Forall&amp;amp;nbsp;?v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;...?v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;amp;nbsp;(r')&amp;lt;/tt&amp;gt;, ''CVar(r) = CVar(r') &amp;amp;cup; {&amp;lt;tt&amp;gt;?v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;...&amp;lt;tt&amp;gt;?v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;}''.&lt;br /&gt;
&lt;br /&gt;
=== Proposed Erratum 10 ===&lt;br /&gt;
&lt;br /&gt;
Handling of variable name clashes in Core-ification of RIF-PRD rules (reported [http://lists.w3.org/Archives/Public/public-rif-comments/2010Jun/0000.html here], last paragraph in item #2)&lt;br /&gt;
&lt;br /&gt;
 A related problem occurs in Section 7.3, where in case 2 of the  &lt;br /&gt;
 algorithm clashes of names among rule variables are not taken care.&lt;br /&gt;
&lt;br /&gt;
Name clashes are not taken care of in the RIF-PRD spec, indeed: the assumption was that the variables would be renamed to avoid them, I assume.&lt;br /&gt;
&lt;br /&gt;
'''Proposed modification''': In step 2 of the Core-ification algorithm, section 7.3, change the sentence&lt;br /&gt;
&lt;br /&gt;
&amp;quot;If the rule inside a rule with variable delcaration, r1, is also a rule with variable declaration, r2, all the rule variable delarations and all the patterns that occur in r1 (and not in r2) should be added to the rule variable declarations and the patterns that occur in r2, and, after the transform, r1 should be replaced by r2, in the rule set&amp;quot;&lt;br /&gt;
&lt;br /&gt;
for (taking the opportunity to correct the typos as well)&lt;br /&gt;
&lt;br /&gt;
&amp;quot;If the &amp;lt;tt&amp;gt;rule&amp;lt;/tt&amp;gt; inside a rule with variable declaration, r1, is also a rule with variable declaration, r2, all the rule variable declarations and all the patterns that occur in r1 should be added to the rule variable declarations and the patterns that occur in r2, and, after the transform, r1 should be replaced by r2, in the rule set. If the names of some variables declared in r1 are the same as the names of some variables declared in r2, the former names must be changed prior to the transform.&amp;quot;&lt;br /&gt;
&lt;br /&gt;
'''Corrected (see [http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14488&amp;amp;oldid=14471 here])'''&lt;br /&gt;
&lt;br /&gt;
=== Proposed Erratum 11 ===&lt;br /&gt;
&lt;br /&gt;
Errors in the PS in the example 9.1 and issues wrt the PS EBNF (reported [http://lists.w3.org/Archives/Public/public-rif-comments/2011Jan/0000.html here])&lt;br /&gt;
&lt;br /&gt;
The proposed corrections are valid (checked 10 July 2012). Here is a shorter valid version:&lt;br /&gt;
&lt;br /&gt;
 Document(&lt;br /&gt;
 &lt;br /&gt;
 Prefix( ex1 &amp;lt;http://example.com/2009/prd2&amp;gt; )&lt;br /&gt;
 &lt;br /&gt;
 (* ex1:CheckoutRuleset *)&lt;br /&gt;
 Group  (&lt;br /&gt;
   (* ex1:GoldRule *)&lt;br /&gt;
   Group  (&lt;br /&gt;
     Forall ?customer such that And(?customer # ex1:Customer&lt;br /&gt;
                                    ?customer[ex1:status -&amp;gt; &amp;quot;Silver&amp;quot;])&lt;br /&gt;
       (Forall ?shoppingCart such that ?customer[ex1:shoppingCart -&amp;gt; ?shoppingCart]&lt;br /&gt;
          (If Exists ?value (And(?shoppingCart[ex1:value -&amp;gt; ?value]&lt;br /&gt;
                                 External(pred:numeric-greater-than-or-equal(?value 2000))))&lt;br /&gt;
           Then Do(Modify(?customer[ex1:status -&amp;gt; &amp;quot;Gold&amp;quot;])))))&lt;br /&gt;
 &lt;br /&gt;
   (* ex1:DiscountRule *)&lt;br /&gt;
   Group (&lt;br /&gt;
     Forall ?customer such that ?customer # ex1:Customer&lt;br /&gt;
       (If Or( ?customer[ex1:status -&amp;gt; &amp;quot;Silver&amp;quot;]&lt;br /&gt;
               ?customer[ex1:status -&amp;gt; &amp;quot;Gold&amp;quot;])&lt;br /&gt;
        Then Do ((?s ?customer[ex1:shoppingCart -&amp;gt;  ?s])&lt;br /&gt;
                 (?v ?s[ex1:value -&amp;gt; ?v])&lt;br /&gt;
                 Modify(?s [ex1:value -&amp;gt; External(func:numeric-multiply (?v 0.95))]))))&lt;br /&gt;
 &lt;br /&gt;
   (* ex1:NewCustomerAndWidgetRule *)&lt;br /&gt;
   Group (&lt;br /&gt;
     Forall ?customer such that And(?customer # ex1:Customer&lt;br /&gt;
                                     ?customer[ex1:status -&amp;gt; &amp;quot;New&amp;quot;] )&lt;br /&gt;
       (If Exists ?shoppingCart ?item&lt;br /&gt;
                  (And(?customer[ex1:shoppingCart -&amp;gt; ?shoppingCart]&lt;br /&gt;
                       ?shoppingCart[ex1:containsItem -&amp;gt; ?item]&lt;br /&gt;
                       ?item # ex1:Widget ) )&lt;br /&gt;
        Then Do( (?s ?customer[ex1:shoppingCart -&amp;gt; ?s])&lt;br /&gt;
                 (?val ?s[ex1:value -&amp;gt; ?val])&lt;br /&gt;
                 Retract(?customer ex1:voucher)&lt;br /&gt;
                 Modify(?s[ex1:value -&amp;gt; External(func:numeric-multiply(?val 0.90))]))))&lt;br /&gt;
 &lt;br /&gt;
   (* ex1:UnknownStatusRule *)&lt;br /&gt;
   Group (&lt;br /&gt;
     Forall ?customer such that ?customer # ex1:Customer&lt;br /&gt;
       (If Not(Exists ?status&lt;br /&gt;
                      (And(?customer[ex1:status -&amp;gt; ?status]&lt;br /&gt;
                           External(pred:list-contains(List(&amp;quot;New&amp;quot; &amp;quot;Bronze&amp;quot; &amp;quot;Silver&amp;quot; &amp;quot;Gold&amp;quot;) ?status)) )))&lt;br /&gt;
        Then Do( Execute(act:print(External(func:concat(&amp;quot;New customer: &amp;quot; ?customer))))&lt;br /&gt;
                 Assert(?customer[ex1:status -&amp;gt; &amp;quot;New&amp;quot;]))))&lt;br /&gt;
  )&lt;br /&gt;
 )&lt;br /&gt;
&lt;br /&gt;
'''Corrected (see [http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14490&amp;amp;oldid=14488 here])'''&lt;br /&gt;
&lt;br /&gt;
=== Proposed Erratum 12 ===&lt;br /&gt;
&lt;br /&gt;
Error in comment in XML Schema for PRD (reported [http://lists.w3.org/Archives/Public/public-rif-comments/2011Jan/0002.html here])&lt;br /&gt;
&lt;br /&gt;
 In a comment of RIF PRD XML Schema&lt;br /&gt;
 &lt;br /&gt;
 &amp;lt;xs:group name=&amp;quot;RULE&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;amp;lt;!--&lt;br /&gt;
     RULE      ::= (IRIMETA? 'Forall' Var+ '(' CLAUSE ')') | CLAUSE&lt;br /&gt;
    --&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
 should be&lt;br /&gt;
 &lt;br /&gt;
 &amp;lt;xs:group name=&amp;quot;RULE&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;amp;lt;!--&lt;br /&gt;
     RULE      ::= (IRIMETA? 'Forall' Var+ (' such that ' FORMULA+)?  '(' RULE ')') | CLAUSE&lt;br /&gt;
    --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Proposed modification''': correct the typo.&lt;br /&gt;
&lt;br /&gt;
'''Corrected (see [http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14493&amp;amp;oldid=14490 here])'''&lt;br /&gt;
&lt;br /&gt;
=== Proposed Erratum 13 ===&lt;br /&gt;
&lt;br /&gt;
Unbindable action variable in RIF-PRD (reported [http://lists.w3.org/Archives/Public/public-rif-comments/2012Jun/0000.html here])&lt;br /&gt;
&lt;br /&gt;
The RIF-PRD spec does not say what happens with a rule instance where the rule contains an action variable binding (?v ?o[?p-&amp;gt;?v]) and there is no substitution for ?v that matches ?o[?p-&amp;gt;?v] to the state of facts for the rule instance substitution of ?o and ?p.&lt;br /&gt;
&lt;br /&gt;
PROPOSED (see also discussion [http://lists.w3.org/Archives/Public/public-rif-wg/2012Jul/0002.html here]):&lt;br /&gt;
Add a clarification, after the definition of action instance, in [http://www.w3.org/2005/rules/wiki/PRD#Definitions_and_notational_conventions section 4.2.3], to the effect that RIF-PRD does not specify a semantics for that case, because the specification of the context where an otherwise valid RIF-PRD rule is validly applicable is out os the scope of RIF-PRD.&lt;br /&gt;
&lt;br /&gt;
'''Corrected (see [http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14496&amp;amp;oldid=14493 here])''': Added the following paragraph after the definiiton of action instance in section 4.2.3:&lt;br /&gt;
&lt;br /&gt;
Notice that RIF-PRD does not specify semantics for the case where there is no matching substitution for the binding frame formula o[s-&amp;gt;vi] in an action variable declaration (vi o[s-&amp;gt;vi]). Indeed, although the rule might be valid from an interchange viewpoint, applying it in a context where object o has no value for attribute s is applying it outside the domain where it is meaningful, and the specification of the context where an otherwise valid RIF-PRD rule is validly applicable is out of the scope of RIF-PRD.&lt;br /&gt;
&lt;br /&gt;
=== Proposed Erratum 14 ===&lt;br /&gt;
&lt;br /&gt;
Errors in the semantics of Assert and Retract (reported [http://lists.w3.org/Archives/Public/public-rif-comments/2011Mar/0000.html here])&lt;br /&gt;
&lt;br /&gt;
==== Erratum 14.1 ====&lt;br /&gt;
&lt;br /&gt;
 The semantics of the Assert atomic action is described as follows at:&lt;br /&gt;
 &lt;br /&gt;
 Rule 1 says that *all the condition formulas that were satisfied before an&lt;br /&gt;
 assertion will be satisfied after*, and that, in addition, the condition&lt;br /&gt;
 formulas that are satisfied by the asserted ground formula will be satisfied&lt;br /&gt;
 after the assertion. No other condition formula will be satisfied after the&lt;br /&gt;
 execution of the action.&lt;br /&gt;
 &lt;br /&gt;
 where, Rule 1 is formally defined as:&lt;br /&gt;
 α is Assert(φ), where φ is a ground atomic formula, and *w' = w ∪ {φ}*;&lt;br /&gt;
 &lt;br /&gt;
 But an assertion could change the satisfaction of negation formula,&lt;br /&gt;
 right? ie. a negation formula may be satisfied in w but not in w'.&lt;br /&gt;
 &lt;br /&gt;
 (A similar argument follows for Rule 2)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
PROPOSED (see also reply [http://lists.w3.org/Archives/Public/public-rif-comments/2012Jul/0000.html here]): Modify the text explaining the effect of rule 1 and rule 2 to read:&lt;br /&gt;
&lt;br /&gt;
'''Corrected (see [http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14498&amp;amp;oldid=14496 here])'''&lt;br /&gt;
&lt;br /&gt;
''Rule 1 says that all the ''atomic'' condition formulas that were satisfied ..., and that, in addition the ''atomic'' condition formula that are satisfied ... No other ''atomic'' condition formula will be satisfied after the execution of the action.''&lt;br /&gt;
&lt;br /&gt;
''Rule 2 says that all the ''atomic'' condition formulas that were satisfied ... No other ''atomic'' condition formula will be satisfied after the execution of the action.''&lt;br /&gt;
&lt;br /&gt;
==== Erratum 14.2 ====&lt;br /&gt;
&lt;br /&gt;
 Furthermore, the formal definition doesn't mention conditional formula while&lt;br /&gt;
 the description (referred above) does. Is something missing there?&lt;br /&gt;
&lt;br /&gt;
PROPOSED (see also [http://lists.w3.org/Archives/Public/public-rif-comments/2012Jul/0000.html here]): modify the definition of the RIF-PRD transition relation, in [http://www.w3.org/TR/rif-prd/#Operational_semantics_of_atomic_actions section 3.2] to read:&lt;br /&gt;
&lt;br /&gt;
'''Corrected (see [http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14500&amp;amp;oldid=14498 here])'''&lt;br /&gt;
&lt;br /&gt;
'''Definition (RIF-PRD transition relation).''' The semantics of RIF-PRD atomic actions is specified by the '''transition relation &amp;amp;rarr;&amp;lt;sub&amp;gt;&amp;lt;sub&amp;gt;RIF-PRD&amp;lt;/sub&amp;gt;&amp;lt;/sub&amp;gt;''' &amp;amp;sube; ''W'' &amp;amp;times; ''L'' &amp;amp;times; ''W''. ''(w, &amp;lt;tt&amp;gt;&amp;amp;alpha;&amp;lt;/tt&amp;gt;, w') &amp;amp;isin;  &amp;amp;rarr;&amp;lt;sub&amp;gt;&amp;lt;sub&amp;gt;RIF-PRD&amp;lt;/sub&amp;gt;&amp;lt;/sub&amp;gt;'' if and only if ''w'' &amp;amp;isin; ''W'', ''w' ''&amp;amp;isin; ''W'', &amp;lt;tt&amp;gt;&amp;amp;alpha;&amp;lt;/tt&amp;gt; is a ground atomic action, and one of the following is true, where ''&amp;amp;Phi;'' is a set of ground atomic formulas that represents ''w'' and ''&amp;amp;Phi;' '' is a set of ground atomic formulas that represent ''w' '':&lt;br /&gt;
# &amp;lt;tt&amp;gt;&amp;amp;alpha;&amp;lt;/tt&amp;gt; is &amp;lt;tt&amp;gt;Assert(&amp;amp;phi;)&amp;lt;/tt&amp;gt;, where &amp;amp;phi; is a ground atomic formula, and ''&amp;amp;Phi;'&amp;amp;nbsp;=&amp;amp;nbsp;&amp;amp;Phi;&amp;amp;nbsp;&amp;amp;cup;&amp;amp;nbsp;{&amp;amp;phi;}'';&lt;br /&gt;
# &amp;lt;tt&amp;gt;&amp;amp;alpha;&amp;lt;/tt&amp;gt; is &amp;lt;tt&amp;gt;Retract(&amp;amp;phi;)&amp;lt;/tt&amp;gt;, where &amp;amp;phi; is a ground atomic formula, and ''&amp;amp;Phi;'&amp;amp;nbsp;=&amp;amp;nbsp;&amp;amp;Phi;&amp;amp;nbsp;\&amp;amp;nbsp;{&amp;amp;phi;}'';&lt;br /&gt;
# &amp;lt;tt&amp;gt;&amp;amp;alpha;&amp;lt;/tt&amp;gt; is &amp;lt;tt&amp;gt;Retract(o s)&amp;lt;/tt&amp;gt;, where &amp;lt;tt&amp;gt;o&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;s&amp;lt;/tt&amp;gt; are constants, and ''&amp;amp;Phi;'&amp;amp;nbsp;=&amp;amp;nbsp;(&amp;amp;Phi;&amp;amp;nbsp;\&amp;amp;nbsp;{&amp;lt;tt&amp;gt;o[s-&amp;gt;v]&amp;lt;/tt&amp;gt;&amp;amp;nbsp;| for all the values of &amp;lt;tt&amp;gt;v&amp;lt;/tt&amp;gt;});&lt;br /&gt;
# &amp;lt;tt&amp;gt;&amp;amp;alpha;&amp;lt;/tt&amp;gt; is &amp;lt;tt&amp;gt;Retract(o)&amp;lt;/tt&amp;gt;, where &amp;lt;tt&amp;gt;o&amp;lt;/tt&amp;gt; is a constant, and ''&amp;amp;Phi;'&amp;amp;nbsp;=&amp;amp;nbsp;&amp;amp;Phi;&amp;amp;nbsp;\&amp;amp;nbsp;{&amp;lt;tt&amp;gt;o[s-&amp;gt;v]&amp;lt;/tt&amp;gt;&amp;amp;nbsp;| for all the values of terms &amp;lt;tt&amp;gt;s&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;v&amp;lt;/tt&amp;gt;}&amp;amp;nbsp;-&amp;amp;nbsp;{&amp;lt;tt&amp;gt;o#c&amp;lt;/tt&amp;gt;&amp;amp;nbsp;| for all the values of term &amp;lt;tt&amp;gt;c&amp;lt;/tt&amp;gt;}'';&lt;br /&gt;
# &amp;lt;tt&amp;gt;&amp;amp;alpha;&amp;lt;/tt&amp;gt; is &amp;lt;tt&amp;gt;Execute(&amp;amp;phi;)&amp;lt;/tt&amp;gt;, where &amp;amp;phi; is a ground atomic builtin action, and ''&amp;amp;Phi;'&amp;amp;nbsp;=&amp;amp;nbsp;&amp;amp;Phi;''. &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
&lt;br /&gt;
=== Proposed Erratum 15 ===&lt;br /&gt;
&lt;br /&gt;
In PRD, a matching substitution for an equality formula is defined wrt the value of ground terms ([http://www.w3.org/TR/rif-prd/#Matching_substitution section 2.2.1]). But the value of ground terms is not defined precisely, except for constants in a data types (reported [http://lists.w3.org/Archives/Public/public-rif-wg/2012Jul/0003.html here]).&lt;br /&gt;
&lt;br /&gt;
'''Corrected''': see Erratum 16.2, infra.&lt;br /&gt;
&lt;br /&gt;
=== Proposed Erratum 16 ===&lt;br /&gt;
&lt;br /&gt;
Possibly inconsistent matching substitutions for equality formulas due to incomplete definition in PRD (reported by Jesse Weaver in a private email).&lt;br /&gt;
&lt;br /&gt;
==== Erratum 16.1 ====&lt;br /&gt;
&lt;br /&gt;
RIF-PRD says ([[PRD#Matching_substitution|section 2.2.1]]):&lt;br /&gt;
&lt;br /&gt;
''Because RIF-PRD covers only externally defined interpreted functions, a ground functional term can always be replaced by its value. As a consequence, a ground substitution can always be restricted, without loss of generality, to assign only constants to the variable in its domain. In the remainder of this document, it will always be assumed that a ground substitution assigns only constants to the variables in its domain.''&lt;br /&gt;
&lt;br /&gt;
But a ground list can be assigned to a variable as well! The purpose of the above sentence is, really, to say that ground external terms can always be replaced by the (non-external) ground term to which they evaluate, and that it will be assumed in the remainder of the document that ground formulas never contain external ground terms (that is, that external ground terms are always replaced by their evaluation in ground formulas). As a consequence, a variable is never assigned an external ground term.&lt;br /&gt;
&lt;br /&gt;
PROPOSED: to replace above paragraph with the following:&lt;br /&gt;
&lt;br /&gt;
'''Corrected (see [http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14503&amp;amp;oldid=14500 here])'''&lt;br /&gt;
&lt;br /&gt;
''Because RIF-PRD covers only externally defined interpreted functions, a ground positional term can always be replaced by the (non-positional) ground term to which it evaluates. As a consequence, a ground RIF-PRD formula can always be restricted, without loss of generality, to contain no positional term; that is, to be such that any ground positional terms have been replaced with the non-positional ground terms to which they evaluate. In the remainder of this document, it will always be assumed that a ground condition formula never contains any positional term. As a consequence, a ground substitution never assigns a ground positional term to the variables in its domain.''&lt;br /&gt;
&lt;br /&gt;
==== Erratum 16.2 ====&lt;br /&gt;
&lt;br /&gt;
 a set of facts \Phi representing a state of the fact base may include&lt;br /&gt;
 ground, equality, atomic formulas.  In that case, the definition of&lt;br /&gt;
 matching substitution implies: \sigma matches t1=t2 to \Phi iff \sigma(t1)&lt;br /&gt;
 and \sigma(t2) &amp;quot;have the same value&amp;quot; ***OR*** \sigma(t1=t2) \in \Phi.&lt;br /&gt;
 &lt;br /&gt;
 So as things are currently defined, it seems there are two ways to match&lt;br /&gt;
 t1=t2 to \Phi.  One is for the two sides to be mapped to the same value,&lt;br /&gt;
 and the other is to match a fact.&lt;br /&gt;
&lt;br /&gt;
Correct. The problem is that the current definition of a state of the fact base ([[PRD#Condition_satisfaction|section 2.2.2]]) allows the two ways to match an equality to disagree (e.g. if the state of the fact base contains the atomic equality &amp;quot;1^^xs:integer=2^^xs:integer&amp;quot;).&lt;br /&gt;
&lt;br /&gt;
PROPOSED: change the definition of state of the fact base, [[PRD#Condition_satisfaction|section 2.2.2]], to read:&lt;br /&gt;
&lt;br /&gt;
'''Corrected (see [http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14506&amp;amp;oldid=14503 here])'''&lt;br /&gt;
&lt;br /&gt;
'''Definition (State of the fact base).''' A '''''state of the fact base''''', ''w&amp;lt;sub&amp;gt;&amp;amp;Phi;&amp;lt;/sub&amp;gt;'', is associated to every set of ground atomic formulas, ''&amp;amp;Phi;'', that contains no frame with multiple slots and that satisfies all the following conditions:&lt;br /&gt;
* for every equality formula &amp;lt;tt&amp;gt;t&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;=t&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; in ''&amp;amp;Phi;'', if ''t&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'' and ''t&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;'' are, both, constants in symbol spaces that are data types, then they have the same value;&lt;br /&gt;
* for all triple of constants ''c&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;, c&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;'', ''c&amp;lt;sub&amp;gt;3&amp;lt;/sub&amp;gt;''...'''&lt;br /&gt;
&lt;br /&gt;
And clarify the definition of matching substitution in [[PRD#Matching_substitution|section 2.2.1]] to read:&lt;br /&gt;
&lt;br /&gt;
'''Corrected (see [http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14508&amp;amp;oldid=14506 here])'''&lt;br /&gt;
&lt;br /&gt;
...&lt;br /&gt;
* ''&amp;amp;psi;'' is an atomic formula and either&lt;br /&gt;
** ''&amp;amp;sigma;(&amp;amp;psi;)'' &amp;amp;isin; ''&amp;amp;Phi;'', or&lt;br /&gt;
** ...&lt;br /&gt;
** ''&amp;amp;psi;'' is an equality formula, &amp;lt;tt&amp;gt;t&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; = t&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, and the ground terms ''&amp;amp;sigma;(t&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;)'' and ''&amp;amp;sigma;(t&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;)'' ''are constants in symbol spaces that are data types and they'' have the same value;&lt;br /&gt;
* ...&lt;br /&gt;
&lt;br /&gt;
==== Erratum 16.3 ====&lt;br /&gt;
&lt;br /&gt;
Jesse Weaver noticed that, while the above modifications corrected previously raised issues, it did not guaranty symmetry and transitivity of equality, see [http://lists.w3.org/Archives/Public/public-rif-comments/2012Sep/0000.html here] (neither reflexivity, by the way).&lt;br /&gt;
&lt;br /&gt;
PROPOSED ('''corrected [http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14647&amp;amp;oldid=14551 here]'''): Adding the following constraints to the definition of state of the fact base, [[PRD#Condition_satisfaction|section 2.2.2]]:&lt;br /&gt;
* for every pair of constants ''c&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'' and ''c&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;'', if ''c&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; = c&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;'' &amp;amp;isin; ''&amp;amp;Phi;'', then ''c&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt; = c&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'' &amp;amp;isin; ''&amp;amp;Phi;'';&lt;br /&gt;
* for every triple of constants ''c&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'', ''c&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;'' and ''c&amp;lt;sub&amp;gt;3&amp;lt;/sub&amp;gt;'', if ''c&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; = c&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;'' &amp;amp;isin; ''&amp;amp;Phi;'' and ''c&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt; = c&amp;lt;sub&amp;gt;3&amp;lt;/sub&amp;gt;'' &amp;amp;isin; ''&amp;amp;Phi;'', then ''c&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; = c&amp;lt;sub&amp;gt;3&amp;lt;/sub&amp;gt;'' &amp;amp;isin; ''&amp;amp;Phi;'';&amp;quot;&lt;br /&gt;
&lt;br /&gt;
and add the following condition in the definition of matching substitution in [[PRD#Matching_substitution|section 2.2.1]], under &amp;quot;''&amp;amp;psi;'' is an equality formula, &amp;lt;tt&amp;gt;t&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; = t&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; and either...&amp;quot;:&lt;br /&gt;
** or the ground terms ''&amp;amp;sigma;(t&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;)'' and ''&amp;amp;sigma;(t&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;)'' are the same ground term;&lt;br /&gt;
&lt;br /&gt;
==== Erratum 16.4 ====&lt;br /&gt;
&lt;br /&gt;
While correcting erratum 16.1 and 16.2, I (csma) realized that, as they were defined, matching substitutions did not handle list equality.&lt;br /&gt;
&lt;br /&gt;
PROPOSED: Modify the definition of matching substitution in [[PRD#Matching_substitution|section 2.2.1]] to read:&lt;br /&gt;
&lt;br /&gt;
'''corrected ([http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14511&amp;amp;oldid=14508 here])'''&lt;br /&gt;
&lt;br /&gt;
* ''&amp;amp;psi;'' is an atomic formula and either&lt;br /&gt;
** ''&amp;amp;sigma;(&amp;amp;psi;)'' &amp;amp;isin; ''&amp;amp;Phi;'', or&lt;br /&gt;
** ...&lt;br /&gt;
** ''&amp;amp;psi;'' is an equality formula, &amp;lt;tt&amp;gt;t&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; = t&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, and either&lt;br /&gt;
*** ''the ground terms ''&amp;amp;sigma;(t&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;)'' and ''&amp;amp;sigma;(t&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;)'' are list terms with the same length ''n&amp;amp;ge;0'' and, for all ''i, 0&amp;amp;le;i&amp;amp;le;n-1'', such that ''l&amp;lt;sub&amp;gt;1&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;&amp;lt;/sub&amp;gt;'' and ''l&amp;lt;sub&amp;gt;2&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;&amp;lt;/sub&amp;gt;'' are the ground terms of rank ''i'' in ''&amp;amp;sigma;(t&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;)'' and ''&amp;amp;sigma;(t&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;)'', respectively, either ''l&amp;lt;sub&amp;gt;1&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;&amp;lt;/sub&amp;gt;'' and ''l&amp;lt;sub&amp;gt;2&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;&amp;lt;/sub&amp;gt;'' are both constants in symbol spaces that are data types and they have the same value, or &amp;lt;tt&amp;gt;l&amp;lt;sub&amp;gt;1&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;&amp;lt;/sub&amp;gt; = l&amp;lt;sub&amp;gt;2&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; &amp;amp;isin; ''&amp;amp;Phi;'',''&lt;br /&gt;
*** or the ground terms ''&amp;amp;sigma;(t&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;)'' and ''&amp;amp;sigma;(t&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;)'' are constants in symbol spaces that are data types and they have the same value;&lt;br /&gt;
* ...&lt;br /&gt;
&lt;br /&gt;
==== Erratum 16.5 ====&lt;br /&gt;
&lt;br /&gt;
Jesse Weaver noticed that erratum 16.4 introduced the counter-intuitive possibility to equate a constant in a data type and a list, e.g. to a fact base may validly contain fact &amp;quot;3=List()&amp;quot; (see [http://lists.w3.org/Archives/Public/public-rif-comments/2012Sep/0000.html here])&lt;br /&gt;
&lt;br /&gt;
PROPOSED: add the following constraint in the definition of state of the fact base, [[PRD#Condition_satisfaction|section 2.2.2]]:&lt;br /&gt;
* for every equality formula ''c&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; = c&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;'' &amp;amp;isin; ''&amp;amp;Phi;'', either c&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; is not a constant in a symbol space that is a data type, of c&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt; is not a list term;.&lt;br /&gt;
&lt;br /&gt;
'''Corrected ([http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14649&amp;amp;oldid=14647 here])&lt;br /&gt;
&lt;br /&gt;
=== Proposed Erratum 17 ===&lt;br /&gt;
&lt;br /&gt;
Propagation of membership through class hierarchy when asserting class membership (reported by Jesse Weaver, see reply [http://lists.w3.org/Archives/Public/public-rif-wg/2012Jul/0005.html here]).&lt;br /&gt;
&lt;br /&gt;
 Consider a set of facts \Phi = {c_2##c_1} which represents a state of a fact base. &lt;br /&gt;
 &lt;br /&gt;
 Consider the following rule:&lt;br /&gt;
 &lt;br /&gt;
 Do( (?y New()]) Assert(?y#c_2) ) )&lt;br /&gt;
  &lt;br /&gt;
 By definition of RIF-PRD transition relation (section 3.2), assuming&lt;br /&gt;
 that the new frame object is identified as _new, the next&lt;br /&gt;
 state of the fact base is represented by \Phi* = \Phi \cup {_new#c_2},&lt;br /&gt;
 which is \Phi* = { _new#c_2, c_2##c_1 } .&lt;br /&gt;
 &lt;br /&gt;
 However, &lt;br /&gt;
 since _new#c_2 \in \Phi and c_2##c_1 \in \Phi and _new#c_1 \notin \Phi, &lt;br /&gt;
 then by definition of state of the fact base (section 2.2.2), \Phi* &lt;br /&gt;
 cannot represent a state of the fact base.&lt;br /&gt;
&lt;br /&gt;
PROPOSED: move the constraint that all members of a subclass must also be members of all the super classes from the definition of a state of the fact base to the definition of a matching substitution, that is&lt;br /&gt;
&lt;br /&gt;
'''Corrected (see [http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14516&amp;amp;oldid=14511 here])'''&lt;br /&gt;
&lt;br /&gt;
* remove from the definition of state of the fact base the condition that for all triple of constants ''c&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;, c&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;'', ''c&amp;lt;sub&amp;gt;3&amp;lt;/sub&amp;gt;'', if ''c&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;#c&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;&amp;amp;nbsp;&amp;amp;isin;&amp;amp;nbsp;&amp;amp;Phi;'' and ''c&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;##c&amp;lt;sub&amp;gt;3&amp;lt;/sub&amp;gt;&amp;amp;nbsp;&amp;amp;isin;&amp;amp;nbsp;&amp;amp;Phi;'', then ''c&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;#c&amp;lt;sub&amp;gt;3&amp;lt;/sub&amp;gt;&amp;amp;nbsp;&amp;amp;isin;&amp;amp;nbsp;&amp;amp;Phi;''&lt;br /&gt;
* modify the definition of matching substitution ([[PRD#Matching_substitution|section 2.2.1]]) to say&lt;br /&gt;
&lt;br /&gt;
...&lt;br /&gt;
* ''&amp;amp;psi;'' is an atomic formula and either&lt;br /&gt;
** ''&amp;amp;sigma;(&amp;amp;psi;)'' &amp;amp;isin; ''&amp;amp;Phi;'', or&lt;br /&gt;
** ''&amp;amp;psi;'' is a membership formula &amp;lt;tt&amp;gt;o&amp;amp;nbsp;#&amp;amp;nbsp;c&amp;lt;/tt&amp;gt;, and there is a ground term ''c' '' such that ''&amp;amp;sigma;'' matches the conjunction &amp;lt;tt&amp;gt;And(o#c' c'##c)&amp;lt;/tt&amp;gt; to ''&amp;amp;Phi;'', or&lt;br /&gt;
** ...&lt;br /&gt;
&lt;br /&gt;
=== Proposed Erratum 18 ===&lt;br /&gt;
&lt;br /&gt;
Action variable binding to a (ground) list (report by Jesse Weaver, see [http://lists.w3.org/Archives/Public/public-rif-wg/2012Jul/0004.html here], last comment).&lt;br /&gt;
&lt;br /&gt;
 the definition of action instance requires that d &lt;br /&gt;
 be a constant, which seems overly restrictive.  What if a[p-&amp;gt;List()]&lt;br /&gt;
 \in \Phi, which is allowed by definition of frame atomic formula &lt;br /&gt;
 (section 2.1.2) and definition of term (section 2.1.1).)&lt;br /&gt;
&lt;br /&gt;
PROPOSED: change the second bullet in the definition of action instance ([[PRD#Definitions_and_notational_conventions|section 4.2.3]]) to read:&lt;br /&gt;
&lt;br /&gt;
'''Corrected (see [http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14518&amp;amp;oldid=14516 here])'''&lt;br /&gt;
&lt;br /&gt;
* if vi is assigned the value of a frame's slot by the action variable  declaration: (vi o[s-&amp;gt;vi]), then σ(vi) is a ''ground term'' such that the  substitution σ matches the frame formula o[s-&amp;gt;vi] to w.&lt;br /&gt;
&lt;br /&gt;
=== Proposed Erratum 19 ===&lt;br /&gt;
&lt;br /&gt;
In PRD, [[PRD#Import|section 8.6.1]] seems to restrict the use of the RIF/XML element &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; to importing RDF or OWL, and to exclude the import of RIF PRD documents, as described in section 5.&lt;br /&gt;
&lt;br /&gt;
PROPOSED: Modify the first sentence in [[PRD#Import|section 8.6.1]] to read:&lt;br /&gt;
&lt;br /&gt;
'''Corrected (see [http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14520&amp;amp;oldid=14518 here])'''&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directive is used to serialize the reference to ''an RDF graph, an OWL ontology or another RIF document'' to be combined with a RIF document. The &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directive is inherited from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-core|RIF-Core]]]. ''The abstract syntax and semantics of RDF graph and OWL ontology imports'' are specified in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-rdf-owl|RIF-RDF-OWL]]].&lt;br /&gt;
&lt;br /&gt;
=== Typos, simplifications, clarifications ===&lt;br /&gt;
&lt;br /&gt;
* Various typos '''corrected (see [http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14551&amp;amp;oldid=14534 here])'''&lt;br /&gt;
* Remove the confusing and unnecessary condition that &amp;quot;there is at least one term, v, such that o[s-&amp;gt;v] is a well-formed frame atomic formula&amp;quot;, in the definition of a well-formed Retract with two arguments ('''see correction [http://www.w3.org/2005/rules/wiki/index.php?title=PRD&amp;amp;diff=14535&amp;amp;oldid=14534 here]''')&lt;br /&gt;
&lt;br /&gt;
== Proposed Erratum 20 ==&lt;br /&gt;
&lt;br /&gt;
In SWC, [http://www.w3.org/TR/2010/PR-rif-rdf-owl-20100511/#Appendix:_Embeddings_.28Informative.29 section 9 Appendix: Embeddings]&lt;br /&gt;
it is stated that &amp;quot;Simple, RDF, and RDFS entailment for RIF-RDF combinations are embedded in RIF Core&amp;quot;, therefore the above restriction holds. &lt;br /&gt;
This seems to be contradictory to &amp;quot;Forall ?x ?y (?x # ?y :- ?x[rdf:type -&amp;gt; ?y])&amp;quot; in SWC [http://www.w3.org/TR/2010/PR-rif-rdf-owl-20100511/#Embedding_Simple_Entailment section 9.1.3 Embedding simple entailment] (reported [http://lists.w3.org/Archives/Public/public-rif-comments/2010May/0004.html here]).&lt;br /&gt;
&lt;br /&gt;
PROPOSED (Dave Reynolds): Change the second paragraph of section 9 from:&lt;br /&gt;
&lt;br /&gt;
 Simple, RDF, and RDFS entailment for RIF-RDF combinations are embedded &lt;br /&gt;
 in RIF Core. RIF-OWL 2 RL combinations require reasoning with equality, &lt;br /&gt;
 and thus could not be embedded in RIF Core; they are embedded in RIF BLD.&lt;br /&gt;
&lt;br /&gt;
to&lt;br /&gt;
&lt;br /&gt;
 Simple, RDF, RDFS and OWL 2 RL entailment for RIF-RDF combinations are &lt;br /&gt;
 embedded in RIF BLD.&lt;br /&gt;
 &lt;br /&gt;
 Note that Simple, RDF and RDFS entailments are superficially embeddable &lt;br /&gt;
 within RIF Core. However, condition 7 of the semantics of RIF-RDF &lt;br /&gt;
 combinations cannot be axiomatized in RIF Core due to restrictions on &lt;br /&gt;
 the use isa (#) in rule heads. OWL 2 RL is not embeddable in RIF Core &lt;br /&gt;
 due the the need for equality reasoning.&lt;br /&gt;
&lt;br /&gt;
'''Corrected (see [http://www.w3.org/2005/rules/wiki/index.php?title=SWC&amp;amp;diff=14487&amp;amp;oldid=12901 here])'''&lt;br /&gt;
&lt;br /&gt;
== Proposed Erratum 21 ==&lt;br /&gt;
&lt;br /&gt;
* In [[RIF-BLD]]: Definitions in Section [http://www.w3.org/TR/rif-bld#sec-interpretation-of-documents Interpretation of Documents] have been rewritten and significantly simplified.&lt;br /&gt;
* In Section[http://www.w3.org/TR/rif-bld#sec-bld-specialization-semantics The Semantics of RIF-BLD as a Specialization of RIF-FLD], a paragraph added about specialization from RIF-FLD semantic multi-structures.&lt;br /&gt;
&lt;br /&gt;
'''corrected'''&lt;br /&gt;
&lt;br /&gt;
== Proposed Errata for RIF-FLD ==&lt;br /&gt;
&lt;br /&gt;
* Added anti-monotonicity requirement for &amp;lt;tt&amp;gt;~&amp;lt;/tt&amp;gt; in [http://www.w3.org/TR/rif-fld#def-fld-truth-value Definition (set of truth values)].&lt;br /&gt;
* Changed [http://www.w3.org/TR/rif-fld#def-fld-truth-documents Definition (truth valuation of document formulas)] to define truth valuation of not only document formulas but other formulas as well.&lt;br /&gt;
* Acknowledgements added.&lt;br /&gt;
* The old notion of semantic multi-structures has been changed to fix the problems with the semantics of document formulas found in [http://www.w3.org/TR/rif-fld Recommendation of June 22 2010]. These problems were pointed out in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[http://www.w3.org/2005/rules/wiki/FLD#ref-rif-modularity DAA]]. As a result, sections [http://www.w3.org/TR/rif-fld#sec-interpretation-of-documents Interpretation of Documents] and [http://www.w3.org/TR/rif-fld#sec-logical-entailment Logical Entailment] have largely been rewritten.&lt;br /&gt;
&lt;br /&gt;
'''Corrected:''' http://www.w3.org/2005/rules/wiki/index.php?title=FLD&amp;amp;diff=14451&amp;amp;oldid=14355&lt;br /&gt;
&lt;br /&gt;
== Proposed Errata in DTB ==&lt;br /&gt;
&lt;br /&gt;
(Proposed by Axel, who commented:&lt;br /&gt;
&amp;quot;Summarizing, I do understand that only 1)+5) are mandatory changes, &lt;br /&gt;
whereas the changes 2)- 4) are not necessarily mandatory, but would &lt;br /&gt;
make the RIF-DTB spec cleaner.&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
Any remaining issues would in my opinion depend on whether the Xpath working group sees any effects on [XPath-Functions], since we don't have any other direct dependencies on [XML Schema Datatypes], but only indirectly by reuse of definitions from [XPath-Functions].&lt;br /&gt;
&lt;br /&gt;
1. http://www.w3.org/TR/rif-dtb/&lt;br /&gt;
&lt;br /&gt;
-----------------------------------------------&lt;br /&gt;
&lt;br /&gt;
=== 1) ===&lt;br /&gt;
Firstly, a couple of references need to be fixed to the latest specs.&lt;br /&gt;
&lt;br /&gt;
[XML Schema Datatypes] --&amp;gt; http://www.w3.org/TR/xmlschema11-2/ (now points to the CR from 30 April 2009)&lt;br /&gt;
&lt;br /&gt;
'''Done:''' changed the template (see [http://www.w3.org/2005/rules/wiki/index.php?title=Template%3ARef-xml-schema2&amp;amp;diff=14615&amp;amp;oldid=10069 here])&lt;br /&gt;
&lt;br /&gt;
Further, &lt;br /&gt;
[XDM] +&lt;br /&gt;
[XPath] &lt;br /&gt;
[XPath-Functions] &lt;br /&gt;
 all point to the first edition recs and should probably be updated to the Dec 2010 Second Edition versions.&lt;br /&gt;
&lt;br /&gt;
=== 2) ===&lt;br /&gt;
In fact, it seems that the reference to [XDM] could be removed, since we only needed it because the two subtypes of duration we are referring to didn't appear in the earlier version of [XML Schema Datatypes].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As far as I know, the main question was whether the latest changes in [XML Schema Datatypes] do affect us, as shown in http://www.w3.org/2001/sw/CG/docs/XSD1.1-diffs.html,&lt;br /&gt;
as the other docs only had minor updates, I assume.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== 3) Section 2.2.1 Symbol Spaces ===&lt;br /&gt;
&lt;br /&gt;
-----------------------&lt;br /&gt;
The lexical spaces of the above symbol spaces are defined in the document [XML Schema Datatypes].&lt;br /&gt;
&lt;br /&gt;
.xs:dayTimeDuration (http://www.w3.org/2001/XMLSchema#dayTimeDuration), short name: dayTimeDuration&lt;br /&gt;
.xs:yearMonthDuration (http://www.w3.org/2001/XMLSchema#yearMonthDuration), short name: yearMonthDuration&lt;br /&gt;
&lt;br /&gt;
These two symbol spaces represent two subtypes of the XML Schema datatype xs:duration. The lexical spaces of the above symbol spaces are defined in the document [XDM].&lt;br /&gt;
-----------------------&lt;br /&gt;
&lt;br /&gt;
Although this is not wrong, the lexical spaces for these two datatypes are now defined in the last iteration of [XML Schema Datatypes], so this *could* be changed to simply&lt;br /&gt;
&lt;br /&gt;
-----------------------&lt;br /&gt;
.xs:dayTimeDuration (http://www.w3.org/2001/XMLSchema#dayTimeDuration), short name: dayTimeDuration&lt;br /&gt;
.xs:yearMonthDuration (http://www.w3.org/2001/XMLSchema#yearMonthDuration), short name: yearMonthDuration&lt;br /&gt;
&lt;br /&gt;
The lexical spaces of the above symbol spaces are defined in the document [XML Schema Datatypes].&lt;br /&gt;
-----------------------&lt;br /&gt;
&lt;br /&gt;
'''Done''' (see [http://www.w3.org/2005/rules/wiki/index.php?title=DTB&amp;amp;diff=14605&amp;amp;oldid=13226 here])&lt;br /&gt;
&lt;br /&gt;
=== 4) Section 2.3 ===&lt;br /&gt;
&lt;br /&gt;
Similarly, the following could be changed/simplified, if we refer to the leatest [XML Schema Datatypes] version:&lt;br /&gt;
&lt;br /&gt;
-----------------------&lt;br /&gt;
Their value spaces and the lexical-to-value-space mappings are defined as follows: &lt;br /&gt;
&lt;br /&gt;
.For the XML Schema datatypes of RIF, namely all RIF datatypes within the xs: namespace, except xs:dayTimeDuration and xs:yearMonthDuration, the value spaces and the lexical-to-value-space mappings are defined in the XML Schema specification [XML Schema Datatypes]. &lt;br /&gt;
.The value spaces and the lexical-to-value-space mappings for the datatypes xs:dayTimeDuration and xs:yearMonthDuration are defined in the XQuery 1.0 and XPath 2.0 Data Model [XDM]. &lt;br /&gt;
-----------------------&lt;br /&gt;
&lt;br /&gt;
to &lt;br /&gt;
&lt;br /&gt;
-----------------------&lt;br /&gt;
Their value spaces and the lexical-to-value-space mappings are defined as follows: &lt;br /&gt;
&lt;br /&gt;
.For the XML Schema datatypes of RIF, namely all RIF datatypes within the xs: namespace, the value spaces and the lexical-to-value-space mappings are defined in the XML Schema specification [XML Schema Datatypes]. &lt;br /&gt;
-----------------------&lt;br /&gt;
&lt;br /&gt;
'''Done''' (see [http://www.w3.org/2005/rules/wiki/index.php?title=DTB&amp;amp;diff=14607&amp;amp;oldid=14605 here])&lt;br /&gt;
&lt;br /&gt;
=== 5) Section  2.3.1 XML Schema Datatypes ===&lt;br /&gt;
&lt;br /&gt;
Although - again - it is not wrong, this section could be removed, I suppose.&lt;br /&gt;
&lt;br /&gt;
'''Done''' (see [http://www.w3.org/2005/rules/wiki/index.php?title=DTB&amp;amp;diff=14611&amp;amp;oldid=14607 here])&lt;br /&gt;
&lt;br /&gt;
== Proposed Errata in OWL2/RL ==&lt;br /&gt;
&lt;br /&gt;
Fixed typos and syntactic errors in the Template Rules algorithm of appendix 8 identified by Henrick Marx, reported ([http://lists.w3.org/Archives/Public/public-rif-comments/2012May/0002.html here] and [http://lists.w3.org/Archives/Public/public-rif-comments/2012Apr/0000.html here]). Rules affected: prp-adp, cax-adc, prp-spo2, prp-key, scm-int, cls-maxqc2, eq-diff2 and eq-diff3.&lt;br /&gt;
&lt;br /&gt;
== More To Investigate ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
# http://lists.w3.org/Archives/Public/public-rif-comments/2010Aug/0000.html (Not an error: Fitting's paper [1] is listed in the informative references but never cited in the spec =&amp;gt; no erratum?&lt;br /&gt;
# http://lists.w3.org/Archives/Public/public-rif-comments/2011Mar/0001.html (Not an error: request for explanation =&amp;gt; no erratum? Or should the spec be clarified?)&lt;/div&gt;</description>
			<pubDate>Wed, 06 Feb 2013 17:53:35 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Talk:Errata_First_Edition</comments>		</item>
		<item>
			<title>RIF FAQ</title>
			<link>http://www.w3.org/2005/rules/wiki/RIF_FAQ</link>
			<description>&lt;p&gt;Sandro:&amp;#32;/* How do I serialize RIF rules in RDF? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NUMBEREDHEADINGS__&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Please send comments or additional questions to [mailto:public-rif-comments@w3.org public-rif-comments@w3.org] ([http://lists.w3.org/Archives/Public/public-rif-wg/ public archive]).&lt;br /&gt;
&lt;br /&gt;
Answers have not necessarily been reviewed by the Working Group.  The question are real, having been asked via e-mail or in person.&lt;br /&gt;
&lt;br /&gt;
Some questions here have not yet been answered.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About RIF ==&lt;br /&gt;
&lt;br /&gt;
=== What is RIF? ===&lt;br /&gt;
&lt;br /&gt;
RIF is the W3C Rule Interchange Format.  It's an XML language for expressing rules which computers can execute.&lt;br /&gt;
&lt;br /&gt;
Because of the serious tradeoffs in the design of rule language, RIF provides multiple versions, called ''dialects''.   If you're not sure which dialect to use, start with RIF Core.   Then, if you need rule features that are not available in RIF Core, consider the other standard dialects and third-party dialects.&lt;br /&gt;
&lt;br /&gt;
=== What is RIF-BLD?  (and RIF-Core, PRD, FLD) ===&lt;br /&gt;
&lt;br /&gt;
The standard RIF dialects are ''Core'', ''BLD'', and ''PRD'':&lt;br /&gt;
&lt;br /&gt;
; Core&lt;br /&gt;
: This is the fundamental RIF language.  It is designed to be the common subset of most rule engines.   (It provides &amp;quot;safe&amp;quot; positive datalog with builtins.)&lt;br /&gt;
; BLD (Basic Logic Dialect)&lt;br /&gt;
: This adds a few things that Core doesn't have: logic functions, equality in the ''then''-part, and named arguments.   Each of these features can sort of be simulated in Core.   (This is positive Horn logic, with equality and builtins.)&lt;br /&gt;
; PRD (Production Rules Dialect)&lt;br /&gt;
: adds a notion of forward-chaining rules, where a rule ''fires'' and then performs some action, such as adding more information to the store or ''retracting'' some information.&lt;br /&gt;
&lt;br /&gt;
Note that '''FLD''' (the Framework for Logic Dialects) provides a menu for coherently assembling dialects more expressive than BLD.   Links to unofficial, community-contributed RIF dialects can be found&lt;br /&gt;
[http://www.w3.org/2005/rules/wiki/RIF_FLD_Dialects here].&lt;br /&gt;
&lt;br /&gt;
More generally, the [[Overview]] provides a guide to the RIF architecture.&lt;br /&gt;
&lt;br /&gt;
=== Is RIF only for interchange? ===&lt;br /&gt;
&lt;br /&gt;
No.  Although RIF dialects were designed primarily for interchange, each dialect is a standard rule language and can be used even when portability and interchange are not required.&lt;br /&gt;
&lt;br /&gt;
=== &amp;quot;Reduction In Force&amp;quot;? ===&lt;br /&gt;
&lt;br /&gt;
Yes, in some other situations, ''RIF'' stands for ''reduction in force'', a term for reducing headcount, downsizing, layoffs, etc. We're still waiting to hear a really good pun based on this double meaning.&lt;br /&gt;
&lt;br /&gt;
=== Can I use RIF to map between vocabularies? === &lt;br /&gt;
&lt;br /&gt;
Yes.  It should be good for this.   It's [http://www.w3.org/TR/rif-ucr/#Vocabulary_Mapping_for_Data_Integration one of the use cases].&lt;br /&gt;
&lt;br /&gt;
=== Which RIF syntax should I use? ===&lt;br /&gt;
&lt;br /&gt;
The XML syntax is the only one defined as a standard for interchange.&lt;br /&gt;
Various presentation syntaxes are used in the specification, but they&lt;br /&gt;
are not recommended for sending between different systems.&lt;br /&gt;
&lt;br /&gt;
=== Is there a mime type for RIF? ===&lt;br /&gt;
&lt;br /&gt;
Yes, it's &amp;quot;application/rif+xml&amp;quot;.   See [http://www.w3.org/TR/rif-core/#Appendix:_RIF_Media_Type_Registration RIF Media Type Registration].&lt;br /&gt;
&lt;br /&gt;
== RIF Software ==&lt;br /&gt;
&lt;br /&gt;
=== What tools (open source and commercial) currently support RIF? ===&lt;br /&gt;
&lt;br /&gt;
Implementation plans continue to evolve.   Please report any to public-rif-comments@w3.org.  We try to maintain this&lt;br /&gt;
on the [[Implementations]] page.&lt;br /&gt;
&lt;br /&gt;
=== How fast are RIF processors compared to RDFS inference and OWL inference? ===&lt;br /&gt;
&lt;br /&gt;
Since RIF can often be implemented&lt;br /&gt;
by translation to other rule languages, we can speculate that the&lt;br /&gt;
performance will differ only by the time need for translation.  Many&lt;br /&gt;
RDFS and OWL systems use underlying rule engines to do their&lt;br /&gt;
inference, so their performance is likely to be the same or better on&lt;br /&gt;
RIF.  On the other hand, there are some OWL inference tasks which can&lt;br /&gt;
be much more efficiently handled by DL algorithms.&lt;br /&gt;
&lt;br /&gt;
=== Are there any SPARQL stores that support RIF? ===&lt;br /&gt;
&lt;br /&gt;
Implementation plans continue to evolve.   Please report any to public-rif-comments@w3.org.  We try to maintain this&lt;br /&gt;
on the [[Implementations]] page.&lt;br /&gt;
&lt;br /&gt;
We expect that SPARQL systems which currently include rule engines, such as Jena, will implement support for RIF.&lt;br /&gt;
&lt;br /&gt;
=== Is there a Web Service for doing RIF? ===&lt;br /&gt;
&lt;br /&gt;
Implementation plans continue to evolve.   Please report any to public-rif-comments@w3.org.  We try to maintain this&lt;br /&gt;
on the [[Implementations]] page.&lt;br /&gt;
&lt;br /&gt;
=== Does any major technology software vendor (or project) include RIF-related libraries in their stack? IBM, Google, Microsoft, Oracle, KDE, GNOME, Apache, ...===&lt;br /&gt;
&lt;br /&gt;
Implementation plans continue to evolve.   Please report any to public-rif-comments@w3.org.  We try to maintain this&lt;br /&gt;
on the [[Implementations]] page.&lt;br /&gt;
&lt;br /&gt;
IBM &amp;amp; iLog, HP, Oracle, and TIBCO are active in the Working Group.&lt;br /&gt;
&lt;br /&gt;
== Relation to Other Technologies ==&lt;br /&gt;
&lt;br /&gt;
=== I'd like to know if it's possible to translate RIF into SPARQL Construct clause (and back) ===&lt;br /&gt;
&lt;br /&gt;
Some people have used SPARQL Construct clauses as a rule language, although no formal semantics have been specified for this.   Because SPARQL including non-monotonic features, the full language possible here would be very expressive and very hard to specify or implement correctly.   (What happens if you use !bound with some data that is provided by related rules?)&lt;br /&gt;
&lt;br /&gt;
There is a subset of SPARQL Construct clauses which corresponds to a subset of RIF Core.   For this common subset, SPARQL can be seen as just another presentation syntax for RIF Core.    It would probably be best to try to stay within this subset when using SPARQL Construct clauses as a rule language.&lt;br /&gt;
&lt;br /&gt;
=== How do I serialize or store RIF rules in RDF? ===&lt;br /&gt;
&lt;br /&gt;
See [http://www.w3.org/TR/rif-in-rdf RIF in RDF].&lt;br /&gt;
&lt;br /&gt;
=== What are the relationships between the OWL 2 profiles and the RIF dialects? ===&lt;br /&gt;
&lt;br /&gt;
There are several relationships between OWL 2 and RIF dialects.&lt;br /&gt;
&lt;br /&gt;
Firstly, RIF defines the notion of RIF/OWL combinations, providing a semantics for them and a syntactic mechanism for defining such combinations by importing OWL documents into RIF documents. This is specified in [http://www.w3.org/TR/rif-rdf-owl/ RIF RDF and OWL Compatibility]. This mechanism defines import profiles for both OWL 2 DL and OWL 2 Full semantics. Thus each OWL 2 Profile can be used in combination with any RIF dialect using this mechanism. There are no separate import profiles corresponding to the separate OWL 2 profiles.&lt;br /&gt;
&lt;br /&gt;
Secondly, OWL 2 defines a profile, OWL 2 RL, designed to be implementable by means of rule based systems. A partial axiomatization of the OWL 2 RL semantics is given in the [http://www.w3.org/TR/owl2-profiles/#Reasoning_in_OWL_2_RL_and_RDF_Graphs_using_Rules OWL Profiles document] as a set of first order rules. These rules can be translated into RIF Core rules either as a static rule set or on a per-ontology basis as discussed in [http://www.w3.org/2005/rules/wiki/OWLRL OWLRL]. This enables implementation of an OWL 2 RL entailment checker or query answering tool by using the RIF Core rule set in combination with the RDF document encoding an OWL 2 RL premise ontology to derive a set of entailed RDF assertions as RIF Frame formulae.&lt;br /&gt;
&lt;br /&gt;
Thirdly, RIF provides and Informative description of an [http://www.w3.org/TR/rif-rdf-owl/#Embedding_RIF-OWL_2_RL_Combinations embedding] of OWL 2 RL within RIF BLD. This enables the translation of an OWL 2 RL document directly into a RIF BLD document.&lt;br /&gt;
&lt;br /&gt;
=== What is the relationship between RuleML and RIF? ===&lt;br /&gt;
&lt;br /&gt;
RuleML has provided input for RIF on several levels, including the&lt;br /&gt;
use of 'striped' XML as well as&lt;br /&gt;
the structuring of rule classes into a family of sublanguages with, e.g.,&lt;br /&gt;
Datalog RuleML partially mappable to the RIF Core Dialect,&lt;br /&gt;
Derivation RuleML to the RIF Basic Logic Dialect, and&lt;br /&gt;
the production-rule sublanguage of Reaction RuleML to the RIF Production Rule Dialect.&lt;br /&gt;
Conversely, RuleML adopted some features that were developed&lt;br /&gt;
as part of the RIF Working Group such as role tags&lt;br /&gt;
&amp;lt;if&amp;gt; ... &amp;lt;then&amp;gt; instead of &amp;lt;body&amp;gt; ... &amp;lt;head&amp;gt;.&lt;br /&gt;
Shared RIF RuleML implementations and use cases are projected to lead to further convergence.&lt;br /&gt;
&lt;br /&gt;
=== How does RIF differ from SWRL? ===&lt;br /&gt;
&lt;br /&gt;
RIF was designed as an interchange format for exchanging rules between rule systems, such as those that implement SWRL.  SWRL is a rule language which was designed as an extension to OWL.  It is one of the simpler rule languages and most SWRL features are covered by RIF-BLD with the exception of &amp;quot;different-from&amp;quot;, thus it should be possible to exchange most SWRL rules via RIF.&lt;br /&gt;
&lt;br /&gt;
When viewed as a rule language and compared to SWRL, RIF-BLD supports multiple-arity predicates, and SWRL is limited to unary and binary predicates. RIF-BLD has functions, SWRL is function-free.  RIF-BLD has an extensive set of datatypes and builtins, SWRL supports most of the same datatypes but has no builtins.  [??? Yes, it does!  Under discussion.] RIF-BLD has a limited form of negation in datatype guard predicates (e.g. is-literal-not-integer), SWRL has a different limited form of negation in the &amp;quot;different-from&amp;quot; operator.  RIF-BLD interoperates with OWL through a special combination semantics, SWRL is designed to be a syntactic extension to OWL.  RIF-BLD allows disjunction in rules, SWRL does not.&lt;br /&gt;
&lt;br /&gt;
=== How can I encode RIF in HTML? ===&lt;br /&gt;
&lt;br /&gt;
RIF does not define a normative encoding in HTML. It was designed primarily for interchange of rules between rule engines, and the XML syntax is the only one defined as a standard for interchange.&lt;br /&gt;
&lt;br /&gt;
However, various text-based presentation syntaxes are used in the specification: although they are not recommended for interchange between different rule systems, they can be used for rendering by HTML processors.&lt;br /&gt;
&lt;br /&gt;
In general, any rule syntax that can be serialized in RIF XML in a semantics-preserving way can be used for that purpose. To avoid ambiguity, it is good practice to use only syntaxes for which a mapping to RIF XML is publicly available.&lt;br /&gt;
&lt;br /&gt;
=== What's the difference between RIF and having an RDF 2.0 that moves beyond binary relations? ===&lt;br /&gt;
&lt;br /&gt;
Such an RDF specification would probably look very much like RIF with RDF compatibility (see [http://www.w3.org/TR/rif-rdf-owl]).   Of course, RIF also provides for if/then rules, not just ground facts like RDF.&lt;br /&gt;
&lt;br /&gt;
=== Is RIF useful for reasoning about the provenance of claims expressed in RDF, eg. multiple named graphs in SPARQL that offer competing accounts of some situation? ===&lt;br /&gt;
&lt;br /&gt;
If the differing named graphs are located in different web documents, then RIF with RDF compatibility (see [http://www.w3.org/TR/rif-rdf-owl]) has an import mechanism that can be directed to the specific web documents and reason about them. More refined notions of import that allow to explicitly refer to facts from different imported documents per rule could be covered in extended RIF dialects.&lt;br /&gt;
&lt;br /&gt;
=== How do I embed RIF in an RDFS/OWL schema or ontology? ===&lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/TR/rif-rdf-owl RIF RDF and OWL Compatibility] specifies, formally, what it means to use RIF with RDFS and/or OWL, and provides a way, in RIF, to import RDFS and OWL.&lt;br /&gt;
&lt;br /&gt;
If you need to work in RDF triples, see [http://www.w3.org/TR/rif-in-rdf RIF In RDF].  This lets you physically embed RIF in an RDFS/OWL document, but notes that the embedded RIF is merely described, not asserted.  There is not currently a standard vocabulary saying, in RDFS/OWL, that you also want some RIF rules as part of your ontology.  Instead, for now, you must have RIF import RDFS/OWL.&lt;br /&gt;
&lt;br /&gt;
=== What's the relation between RIF and Functional-Logic Programming? ===&lt;br /&gt;
&lt;br /&gt;
Both are founded on Horn logic with equality. Functional-Logic Programming is built on Horn logic with ''oriented'' equations&lt;br /&gt;
in rule conclusions, used to define functions. In that sense it specializes RIF-BLD,&lt;br /&gt;
built on Horn logic with ''symmetric'' equations. However, Functional-Logic Programming permits higher-order functions, while RIF-BLD only permits first-order functions. For an introduction to functional-logic technology, with many examples, see&lt;br /&gt;
[http://www.cs.unb.ca/seminarseries/documents/Harold_Boley-03.17.10.pdf Visualizing Executable Functional-Logic Specifications].&lt;br /&gt;
&lt;br /&gt;
== Documentation ==&lt;br /&gt;
&lt;br /&gt;
=== Where are examples to the W3C semweb technology stack, using RIF properly along with RDF, RDFS, OWL[2], etc.? ===&lt;br /&gt;
&lt;br /&gt;
The [http://www.w3.org/TR/rif-rdf-owl/ RIF RDF and OWL Compatibility] document specifies how RIF works in combination with RDF, RDFS, OWL 1, and OWL 2, and there are small examples throughout the document of RIF-RDF and RIF-OWL combinations, explaining what is entailed (or not) from them.&lt;br /&gt;
&lt;br /&gt;
Two of the use cases presented in [http://www.w3.org/TR/rif-ucr/ RIF Use Cases and Requirements] provide motivating scenarios for RIF in combination with RDF and OWL:  [http://www.w3.org/TR/rif-ucr/#Interchanging_Rule_Extensions_to_OWL Interchanging Rule Extensions to OWL] and [http://www.w3.org/TR/rif-ucr/#Publishing_Rules_for_Interlinked_Metadata Publishing Rules for Interlinked Metadata].&lt;br /&gt;
&lt;br /&gt;
Also, see the [http://www.w3.org/2005/rules/wiki/Category:RIF-RDF_Combination RIF-RDF combination test cases] and the [http://www.w3.org/2005/rules/wiki/Category:RIF-OWL_Combination RIF-OWL combination test cases]. Among these,&lt;br /&gt;
[http://www.w3.org/2005/rules/wiki/YoungParentDiscount_1 Young Parent Discount] and [http://www.w3.org/2005/rules/wiki/UCR_4.7a UCR_4.7a] are in the style of small usage examples.&lt;br /&gt;
&lt;br /&gt;
=== Where are examples to existing RIF rules written using the simplest, bare-minimum markup and easiest logic/math? ===&lt;br /&gt;
&lt;br /&gt;
The set of RIF documents --- including the documents on [http://www.w3.org/2005/rules/wiki/BLD BLD], [http://www.w3.org/2005/rules/wiki/PRD PRD] and [http://www.w3.org/2005/rules/wiki/FLD FLD] --- and the set of [http://www.w3.org/2005/rules/wiki/Category:Test_Case test cases] both contain a variety of examples that involve almost no logic (sometimes not even modus ponens) and no math at all.&lt;br /&gt;
&lt;br /&gt;
For instance, Example 1 in [http://www.w3.org/2005/rules/wiki/BLD BLD] involves just a single application of modus ponens and no math; Example 4 shows several different ways of writing business rules that do not involve math, and require only a basic knowledge of quantifiers.&lt;br /&gt;
&lt;br /&gt;
Most of the examples in [http://www.w3.org/2005/rules/wiki/Category:Test_Case test cases] are quite simple, and involve nothing more than arithmetic. An example of a test case that involves simple inheritance is [http://www.w3.org/2005/rules/wiki/Classification-inheritance  Classification-inheritance.]&lt;br /&gt;
&lt;br /&gt;
=== Where can I find info on RIF for the &amp;quot;business rules&amp;quot; community, esp. to help convince management to start to consider RIF as the source format? ===&lt;br /&gt;
Half of the [http://www.w3.org/TR/rif-ucr/#Use_Cases RIF use cases] describe how RIF can serve the business rules community. RIF can help to avoid vendor lock-in, foster collaboration, support eBusiness and eCommerce, optimize the supply chain, and allow business rules to be bought, sold, and shared.&lt;br /&gt;
The [http://www.w3.org/TR/rif-prd production rule dialect] includes typical business rules features such as rule priority, negation, decimal numbers, and dates.&lt;br /&gt;
&lt;br /&gt;
=== What interesting things have been built using RIF? ===&lt;br /&gt;
&lt;br /&gt;
Support for RIF is just starting to become available (see [[Implementations]]), so there has not yet been much opportunity to develop applications that use RIF.&lt;br /&gt;
&lt;br /&gt;
This [http://www.ibm.com/developerworks/wikis/display/db2xml/Rules IBM developerWorks article] discusses storing and querying rules in an XML database, and includes a live demo with RIF rules.&lt;br /&gt;
&lt;br /&gt;
Some envisioned representative usage scenarios for RIF are outlined in the [http://www.w3.org/TR/rif-ucr/#Use_Cases RIF use cases]. &lt;br /&gt;
&lt;br /&gt;
Please report any applications or uses of RIF to public-rif-comments@w3.org.&lt;br /&gt;
&lt;br /&gt;
== Acknowledements ==&lt;br /&gt;
&lt;br /&gt;
Thanks to questions, comments, suggestions from:&lt;br /&gt;
&lt;br /&gt;
* Lee Feigenbaum &lt;br /&gt;
* David Booth &lt;br /&gt;
* Richard Cyganiak &lt;br /&gt;
* Frank Manola &lt;br /&gt;
* &amp;quot;Collette Hagert geb. Nauluta&amp;quot; &lt;br /&gt;
* Dan Brickley&lt;/div&gt;</description>
			<pubDate>Mon, 04 Feb 2013 17:27:44 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Talk:RIF_FAQ</comments>		</item>
		<item>
			<title>RIF FAQ</title>
			<link>http://www.w3.org/2005/rules/wiki/RIF_FAQ</link>
			<description>&lt;p&gt;Sandro:&amp;#32;/* How do I put RIF rules in RDF, so I can reason about them with more rules? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NUMBEREDHEADINGS__&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Please send comments or additional questions to [mailto:public-rif-comments@w3.org public-rif-comments@w3.org] ([http://lists.w3.org/Archives/Public/public-rif-wg/ public archive]).&lt;br /&gt;
&lt;br /&gt;
Answers have not necessarily been reviewed by the Working Group.  The question are real, having been asked via e-mail or in person.&lt;br /&gt;
&lt;br /&gt;
Some questions here have not yet been answered.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About RIF ==&lt;br /&gt;
&lt;br /&gt;
=== What is RIF? ===&lt;br /&gt;
&lt;br /&gt;
RIF is the W3C Rule Interchange Format.  It's an XML language for expressing rules which computers can execute.&lt;br /&gt;
&lt;br /&gt;
Because of the serious tradeoffs in the design of rule language, RIF provides multiple versions, called ''dialects''.   If you're not sure which dialect to use, start with RIF Core.   Then, if you need rule features that are not available in RIF Core, consider the other standard dialects and third-party dialects.&lt;br /&gt;
&lt;br /&gt;
=== What is RIF-BLD?  (and RIF-Core, PRD, FLD) ===&lt;br /&gt;
&lt;br /&gt;
The standard RIF dialects are ''Core'', ''BLD'', and ''PRD'':&lt;br /&gt;
&lt;br /&gt;
; Core&lt;br /&gt;
: This is the fundamental RIF language.  It is designed to be the common subset of most rule engines.   (It provides &amp;quot;safe&amp;quot; positive datalog with builtins.)&lt;br /&gt;
; BLD (Basic Logic Dialect)&lt;br /&gt;
: This adds a few things that Core doesn't have: logic functions, equality in the ''then''-part, and named arguments.   Each of these features can sort of be simulated in Core.   (This is positive Horn logic, with equality and builtins.)&lt;br /&gt;
; PRD (Production Rules Dialect)&lt;br /&gt;
: adds a notion of forward-chaining rules, where a rule ''fires'' and then performs some action, such as adding more information to the store or ''retracting'' some information.&lt;br /&gt;
&lt;br /&gt;
Note that '''FLD''' (the Framework for Logic Dialects) provides a menu for coherently assembling dialects more expressive than BLD.   Links to unofficial, community-contributed RIF dialects can be found&lt;br /&gt;
[http://www.w3.org/2005/rules/wiki/RIF_FLD_Dialects here].&lt;br /&gt;
&lt;br /&gt;
More generally, the [[Overview]] provides a guide to the RIF architecture.&lt;br /&gt;
&lt;br /&gt;
=== Is RIF only for interchange? ===&lt;br /&gt;
&lt;br /&gt;
No.  Although RIF dialects were designed primarily for interchange, each dialect is a standard rule language and can be used even when portability and interchange are not required.&lt;br /&gt;
&lt;br /&gt;
=== &amp;quot;Reduction In Force&amp;quot;? ===&lt;br /&gt;
&lt;br /&gt;
Yes, in some other situations, ''RIF'' stands for ''reduction in force'', a term for reducing headcount, downsizing, layoffs, etc. We're still waiting to hear a really good pun based on this double meaning.&lt;br /&gt;
&lt;br /&gt;
=== Can I use RIF to map between vocabularies? === &lt;br /&gt;
&lt;br /&gt;
Yes.  It should be good for this.   It's [http://www.w3.org/TR/rif-ucr/#Vocabulary_Mapping_for_Data_Integration one of the use cases].&lt;br /&gt;
&lt;br /&gt;
=== Which RIF syntax should I use? ===&lt;br /&gt;
&lt;br /&gt;
The XML syntax is the only one defined as a standard for interchange.&lt;br /&gt;
Various presentation syntaxes are used in the specification, but they&lt;br /&gt;
are not recommended for sending between different systems.&lt;br /&gt;
&lt;br /&gt;
=== Is there a mime type for RIF? ===&lt;br /&gt;
&lt;br /&gt;
Yes, it's &amp;quot;application/rif+xml&amp;quot;.   See [http://www.w3.org/TR/rif-core/#Appendix:_RIF_Media_Type_Registration RIF Media Type Registration].&lt;br /&gt;
&lt;br /&gt;
== RIF Software ==&lt;br /&gt;
&lt;br /&gt;
=== What tools (open source and commercial) currently support RIF? ===&lt;br /&gt;
&lt;br /&gt;
Implementation plans continue to evolve.   Please report any to public-rif-comments@w3.org.  We try to maintain this&lt;br /&gt;
on the [[Implementations]] page.&lt;br /&gt;
&lt;br /&gt;
=== How fast are RIF processors compared to RDFS inference and OWL inference? ===&lt;br /&gt;
&lt;br /&gt;
Since RIF can often be implemented&lt;br /&gt;
by translation to other rule languages, we can speculate that the&lt;br /&gt;
performance will differ only by the time need for translation.  Many&lt;br /&gt;
RDFS and OWL systems use underlying rule engines to do their&lt;br /&gt;
inference, so their performance is likely to be the same or better on&lt;br /&gt;
RIF.  On the other hand, there are some OWL inference tasks which can&lt;br /&gt;
be much more efficiently handled by DL algorithms.&lt;br /&gt;
&lt;br /&gt;
=== Are there any SPARQL stores that support RIF? ===&lt;br /&gt;
&lt;br /&gt;
Implementation plans continue to evolve.   Please report any to public-rif-comments@w3.org.  We try to maintain this&lt;br /&gt;
on the [[Implementations]] page.&lt;br /&gt;
&lt;br /&gt;
We expect that SPARQL systems which currently include rule engines, such as Jena, will implement support for RIF.&lt;br /&gt;
&lt;br /&gt;
=== Is there a Web Service for doing RIF? ===&lt;br /&gt;
&lt;br /&gt;
Implementation plans continue to evolve.   Please report any to public-rif-comments@w3.org.  We try to maintain this&lt;br /&gt;
on the [[Implementations]] page.&lt;br /&gt;
&lt;br /&gt;
=== Does any major technology software vendor (or project) include RIF-related libraries in their stack? IBM, Google, Microsoft, Oracle, KDE, GNOME, Apache, ...===&lt;br /&gt;
&lt;br /&gt;
Implementation plans continue to evolve.   Please report any to public-rif-comments@w3.org.  We try to maintain this&lt;br /&gt;
on the [[Implementations]] page.&lt;br /&gt;
&lt;br /&gt;
IBM &amp;amp; iLog, HP, Oracle, and TIBCO are active in the Working Group.&lt;br /&gt;
&lt;br /&gt;
== Relation to Other Technologies ==&lt;br /&gt;
&lt;br /&gt;
=== I'd like to know if it's possible to translate RIF into SPARQL Construct clause (and back) ===&lt;br /&gt;
&lt;br /&gt;
Some people have used SPARQL Construct clauses as a rule language, although no formal semantics have been specified for this.   Because SPARQL including non-monotonic features, the full language possible here would be very expressive and very hard to specify or implement correctly.   (What happens if you use !bound with some data that is provided by related rules?)&lt;br /&gt;
&lt;br /&gt;
There is a subset of SPARQL Construct clauses which corresponds to a subset of RIF Core.   For this common subset, SPARQL can be seen as just another presentation syntax for RIF Core.    It would probably be best to try to stay within this subset when using SPARQL Construct clauses as a rule language.&lt;br /&gt;
&lt;br /&gt;
=== How do I serialize RIF rules in RDF? ===&lt;br /&gt;
&lt;br /&gt;
See [http://www.w3.org/TR/rif-in-rdf RIF in RDF].&lt;br /&gt;
&lt;br /&gt;
=== What are the relationships between the OWL 2 profiles and the RIF dialects? ===&lt;br /&gt;
&lt;br /&gt;
There are several relationships between OWL 2 and RIF dialects.&lt;br /&gt;
&lt;br /&gt;
Firstly, RIF defines the notion of RIF/OWL combinations, providing a semantics for them and a syntactic mechanism for defining such combinations by importing OWL documents into RIF documents. This is specified in [http://www.w3.org/TR/rif-rdf-owl/ RIF RDF and OWL Compatibility]. This mechanism defines import profiles for both OWL 2 DL and OWL 2 Full semantics. Thus each OWL 2 Profile can be used in combination with any RIF dialect using this mechanism. There are no separate import profiles corresponding to the separate OWL 2 profiles.&lt;br /&gt;
&lt;br /&gt;
Secondly, OWL 2 defines a profile, OWL 2 RL, designed to be implementable by means of rule based systems. A partial axiomatization of the OWL 2 RL semantics is given in the [http://www.w3.org/TR/owl2-profiles/#Reasoning_in_OWL_2_RL_and_RDF_Graphs_using_Rules OWL Profiles document] as a set of first order rules. These rules can be translated into RIF Core rules either as a static rule set or on a per-ontology basis as discussed in [http://www.w3.org/2005/rules/wiki/OWLRL OWLRL]. This enables implementation of an OWL 2 RL entailment checker or query answering tool by using the RIF Core rule set in combination with the RDF document encoding an OWL 2 RL premise ontology to derive a set of entailed RDF assertions as RIF Frame formulae.&lt;br /&gt;
&lt;br /&gt;
Thirdly, RIF provides and Informative description of an [http://www.w3.org/TR/rif-rdf-owl/#Embedding_RIF-OWL_2_RL_Combinations embedding] of OWL 2 RL within RIF BLD. This enables the translation of an OWL 2 RL document directly into a RIF BLD document.&lt;br /&gt;
&lt;br /&gt;
=== What is the relationship between RuleML and RIF? ===&lt;br /&gt;
&lt;br /&gt;
RuleML has provided input for RIF on several levels, including the&lt;br /&gt;
use of 'striped' XML as well as&lt;br /&gt;
the structuring of rule classes into a family of sublanguages with, e.g.,&lt;br /&gt;
Datalog RuleML partially mappable to the RIF Core Dialect,&lt;br /&gt;
Derivation RuleML to the RIF Basic Logic Dialect, and&lt;br /&gt;
the production-rule sublanguage of Reaction RuleML to the RIF Production Rule Dialect.&lt;br /&gt;
Conversely, RuleML adopted some features that were developed&lt;br /&gt;
as part of the RIF Working Group such as role tags&lt;br /&gt;
&amp;lt;if&amp;gt; ... &amp;lt;then&amp;gt; instead of &amp;lt;body&amp;gt; ... &amp;lt;head&amp;gt;.&lt;br /&gt;
Shared RIF RuleML implementations and use cases are projected to lead to further convergence.&lt;br /&gt;
&lt;br /&gt;
=== How does RIF differ from SWRL? ===&lt;br /&gt;
&lt;br /&gt;
RIF was designed as an interchange format for exchanging rules between rule systems, such as those that implement SWRL.  SWRL is a rule language which was designed as an extension to OWL.  It is one of the simpler rule languages and most SWRL features are covered by RIF-BLD with the exception of &amp;quot;different-from&amp;quot;, thus it should be possible to exchange most SWRL rules via RIF.&lt;br /&gt;
&lt;br /&gt;
When viewed as a rule language and compared to SWRL, RIF-BLD supports multiple-arity predicates, and SWRL is limited to unary and binary predicates. RIF-BLD has functions, SWRL is function-free.  RIF-BLD has an extensive set of datatypes and builtins, SWRL supports most of the same datatypes but has no builtins.  [??? Yes, it does!  Under discussion.] RIF-BLD has a limited form of negation in datatype guard predicates (e.g. is-literal-not-integer), SWRL has a different limited form of negation in the &amp;quot;different-from&amp;quot; operator.  RIF-BLD interoperates with OWL through a special combination semantics, SWRL is designed to be a syntactic extension to OWL.  RIF-BLD allows disjunction in rules, SWRL does not.&lt;br /&gt;
&lt;br /&gt;
=== How can I encode RIF in HTML? ===&lt;br /&gt;
&lt;br /&gt;
RIF does not define a normative encoding in HTML. It was designed primarily for interchange of rules between rule engines, and the XML syntax is the only one defined as a standard for interchange.&lt;br /&gt;
&lt;br /&gt;
However, various text-based presentation syntaxes are used in the specification: although they are not recommended for interchange between different rule systems, they can be used for rendering by HTML processors.&lt;br /&gt;
&lt;br /&gt;
In general, any rule syntax that can be serialized in RIF XML in a semantics-preserving way can be used for that purpose. To avoid ambiguity, it is good practice to use only syntaxes for which a mapping to RIF XML is publicly available.&lt;br /&gt;
&lt;br /&gt;
=== What's the difference between RIF and having an RDF 2.0 that moves beyond binary relations? ===&lt;br /&gt;
&lt;br /&gt;
Such an RDF specification would probably look very much like RIF with RDF compatibility (see [http://www.w3.org/TR/rif-rdf-owl]).   Of course, RIF also provides for if/then rules, not just ground facts like RDF.&lt;br /&gt;
&lt;br /&gt;
=== Is RIF useful for reasoning about the provenance of claims expressed in RDF, eg. multiple named graphs in SPARQL that offer competing accounts of some situation? ===&lt;br /&gt;
&lt;br /&gt;
If the differing named graphs are located in different web documents, then RIF with RDF compatibility (see [http://www.w3.org/TR/rif-rdf-owl]) has an import mechanism that can be directed to the specific web documents and reason about them. More refined notions of import that allow to explicitly refer to facts from different imported documents per rule could be covered in extended RIF dialects.&lt;br /&gt;
&lt;br /&gt;
=== How do I embed RIF in an RDFS/OWL schema or ontology? ===&lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/TR/rif-rdf-owl RIF RDF and OWL Compatibility] specifies, formally, what it means to use RIF with RDFS and/or OWL, and provides a way, in RIF, to import RDFS and OWL.&lt;br /&gt;
&lt;br /&gt;
If you need to work in RDF triples, see [http://www.w3.org/TR/rif-in-rdf RIF In RDF].  This lets you physically embed RIF in an RDFS/OWL document, but notes that the embedded RIF is merely described, not asserted.  There is not currently a standard vocabulary saying, in RDFS/OWL, that you also want some RIF rules as part of your ontology.  Instead, for now, you must have RIF import RDFS/OWL.&lt;br /&gt;
&lt;br /&gt;
=== What's the relation between RIF and Functional-Logic Programming? ===&lt;br /&gt;
&lt;br /&gt;
Both are founded on Horn logic with equality. Functional-Logic Programming is built on Horn logic with ''oriented'' equations&lt;br /&gt;
in rule conclusions, used to define functions. In that sense it specializes RIF-BLD,&lt;br /&gt;
built on Horn logic with ''symmetric'' equations. However, Functional-Logic Programming permits higher-order functions, while RIF-BLD only permits first-order functions. For an introduction to functional-logic technology, with many examples, see&lt;br /&gt;
[http://www.cs.unb.ca/seminarseries/documents/Harold_Boley-03.17.10.pdf Visualizing Executable Functional-Logic Specifications].&lt;br /&gt;
&lt;br /&gt;
== Documentation ==&lt;br /&gt;
&lt;br /&gt;
=== Where are examples to the W3C semweb technology stack, using RIF properly along with RDF, RDFS, OWL[2], etc.? ===&lt;br /&gt;
&lt;br /&gt;
The [http://www.w3.org/TR/rif-rdf-owl/ RIF RDF and OWL Compatibility] document specifies how RIF works in combination with RDF, RDFS, OWL 1, and OWL 2, and there are small examples throughout the document of RIF-RDF and RIF-OWL combinations, explaining what is entailed (or not) from them.&lt;br /&gt;
&lt;br /&gt;
Two of the use cases presented in [http://www.w3.org/TR/rif-ucr/ RIF Use Cases and Requirements] provide motivating scenarios for RIF in combination with RDF and OWL:  [http://www.w3.org/TR/rif-ucr/#Interchanging_Rule_Extensions_to_OWL Interchanging Rule Extensions to OWL] and [http://www.w3.org/TR/rif-ucr/#Publishing_Rules_for_Interlinked_Metadata Publishing Rules for Interlinked Metadata].&lt;br /&gt;
&lt;br /&gt;
Also, see the [http://www.w3.org/2005/rules/wiki/Category:RIF-RDF_Combination RIF-RDF combination test cases] and the [http://www.w3.org/2005/rules/wiki/Category:RIF-OWL_Combination RIF-OWL combination test cases]. Among these,&lt;br /&gt;
[http://www.w3.org/2005/rules/wiki/YoungParentDiscount_1 Young Parent Discount] and [http://www.w3.org/2005/rules/wiki/UCR_4.7a UCR_4.7a] are in the style of small usage examples.&lt;br /&gt;
&lt;br /&gt;
=== Where are examples to existing RIF rules written using the simplest, bare-minimum markup and easiest logic/math? ===&lt;br /&gt;
&lt;br /&gt;
The set of RIF documents --- including the documents on [http://www.w3.org/2005/rules/wiki/BLD BLD], [http://www.w3.org/2005/rules/wiki/PRD PRD] and [http://www.w3.org/2005/rules/wiki/FLD FLD] --- and the set of [http://www.w3.org/2005/rules/wiki/Category:Test_Case test cases] both contain a variety of examples that involve almost no logic (sometimes not even modus ponens) and no math at all.&lt;br /&gt;
&lt;br /&gt;
For instance, Example 1 in [http://www.w3.org/2005/rules/wiki/BLD BLD] involves just a single application of modus ponens and no math; Example 4 shows several different ways of writing business rules that do not involve math, and require only a basic knowledge of quantifiers.&lt;br /&gt;
&lt;br /&gt;
Most of the examples in [http://www.w3.org/2005/rules/wiki/Category:Test_Case test cases] are quite simple, and involve nothing more than arithmetic. An example of a test case that involves simple inheritance is [http://www.w3.org/2005/rules/wiki/Classification-inheritance  Classification-inheritance.]&lt;br /&gt;
&lt;br /&gt;
=== Where can I find info on RIF for the &amp;quot;business rules&amp;quot; community, esp. to help convince management to start to consider RIF as the source format? ===&lt;br /&gt;
Half of the [http://www.w3.org/TR/rif-ucr/#Use_Cases RIF use cases] describe how RIF can serve the business rules community. RIF can help to avoid vendor lock-in, foster collaboration, support eBusiness and eCommerce, optimize the supply chain, and allow business rules to be bought, sold, and shared.&lt;br /&gt;
The [http://www.w3.org/TR/rif-prd production rule dialect] includes typical business rules features such as rule priority, negation, decimal numbers, and dates.&lt;br /&gt;
&lt;br /&gt;
=== What interesting things have been built using RIF? ===&lt;br /&gt;
&lt;br /&gt;
Support for RIF is just starting to become available (see [[Implementations]]), so there has not yet been much opportunity to develop applications that use RIF.&lt;br /&gt;
&lt;br /&gt;
This [http://www.ibm.com/developerworks/wikis/display/db2xml/Rules IBM developerWorks article] discusses storing and querying rules in an XML database, and includes a live demo with RIF rules.&lt;br /&gt;
&lt;br /&gt;
Some envisioned representative usage scenarios for RIF are outlined in the [http://www.w3.org/TR/rif-ucr/#Use_Cases RIF use cases]. &lt;br /&gt;
&lt;br /&gt;
Please report any applications or uses of RIF to public-rif-comments@w3.org.&lt;br /&gt;
&lt;br /&gt;
== Acknowledements ==&lt;br /&gt;
&lt;br /&gt;
Thanks to questions, comments, suggestions from:&lt;br /&gt;
&lt;br /&gt;
* Lee Feigenbaum &lt;br /&gt;
* David Booth &lt;br /&gt;
* Richard Cyganiak &lt;br /&gt;
* Frank Manola &lt;br /&gt;
* &amp;quot;Collette Hagert geb. Nauluta&amp;quot; &lt;br /&gt;
* Dan Brickley&lt;/div&gt;</description>
			<pubDate>Mon, 04 Feb 2013 17:27:28 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Talk:RIF_FAQ</comments>		</item>
		<item>
			<title>RIF FAQ</title>
			<link>http://www.w3.org/2005/rules/wiki/RIF_FAQ</link>
			<description>&lt;p&gt;Sandro:&amp;#32;/* How do I store RIF rules in my triplestore? */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NUMBEREDHEADINGS__&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Please send comments or additional questions to [mailto:public-rif-comments@w3.org public-rif-comments@w3.org] ([http://lists.w3.org/Archives/Public/public-rif-wg/ public archive]).&lt;br /&gt;
&lt;br /&gt;
Answers have not necessarily been reviewed by the Working Group.  The question are real, having been asked via e-mail or in person.&lt;br /&gt;
&lt;br /&gt;
Some questions here have not yet been answered.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About RIF ==&lt;br /&gt;
&lt;br /&gt;
=== What is RIF? ===&lt;br /&gt;
&lt;br /&gt;
RIF is the W3C Rule Interchange Format.  It's an XML language for expressing rules which computers can execute.&lt;br /&gt;
&lt;br /&gt;
Because of the serious tradeoffs in the design of rule language, RIF provides multiple versions, called ''dialects''.   If you're not sure which dialect to use, start with RIF Core.   Then, if you need rule features that are not available in RIF Core, consider the other standard dialects and third-party dialects.&lt;br /&gt;
&lt;br /&gt;
=== What is RIF-BLD?  (and RIF-Core, PRD, FLD) ===&lt;br /&gt;
&lt;br /&gt;
The standard RIF dialects are ''Core'', ''BLD'', and ''PRD'':&lt;br /&gt;
&lt;br /&gt;
; Core&lt;br /&gt;
: This is the fundamental RIF language.  It is designed to be the common subset of most rule engines.   (It provides &amp;quot;safe&amp;quot; positive datalog with builtins.)&lt;br /&gt;
; BLD (Basic Logic Dialect)&lt;br /&gt;
: This adds a few things that Core doesn't have: logic functions, equality in the ''then''-part, and named arguments.   Each of these features can sort of be simulated in Core.   (This is positive Horn logic, with equality and builtins.)&lt;br /&gt;
; PRD (Production Rules Dialect)&lt;br /&gt;
: adds a notion of forward-chaining rules, where a rule ''fires'' and then performs some action, such as adding more information to the store or ''retracting'' some information.&lt;br /&gt;
&lt;br /&gt;
Note that '''FLD''' (the Framework for Logic Dialects) provides a menu for coherently assembling dialects more expressive than BLD.   Links to unofficial, community-contributed RIF dialects can be found&lt;br /&gt;
[http://www.w3.org/2005/rules/wiki/RIF_FLD_Dialects here].&lt;br /&gt;
&lt;br /&gt;
More generally, the [[Overview]] provides a guide to the RIF architecture.&lt;br /&gt;
&lt;br /&gt;
=== Is RIF only for interchange? ===&lt;br /&gt;
&lt;br /&gt;
No.  Although RIF dialects were designed primarily for interchange, each dialect is a standard rule language and can be used even when portability and interchange are not required.&lt;br /&gt;
&lt;br /&gt;
=== &amp;quot;Reduction In Force&amp;quot;? ===&lt;br /&gt;
&lt;br /&gt;
Yes, in some other situations, ''RIF'' stands for ''reduction in force'', a term for reducing headcount, downsizing, layoffs, etc. We're still waiting to hear a really good pun based on this double meaning.&lt;br /&gt;
&lt;br /&gt;
=== Can I use RIF to map between vocabularies? === &lt;br /&gt;
&lt;br /&gt;
Yes.  It should be good for this.   It's [http://www.w3.org/TR/rif-ucr/#Vocabulary_Mapping_for_Data_Integration one of the use cases].&lt;br /&gt;
&lt;br /&gt;
=== Which RIF syntax should I use? ===&lt;br /&gt;
&lt;br /&gt;
The XML syntax is the only one defined as a standard for interchange.&lt;br /&gt;
Various presentation syntaxes are used in the specification, but they&lt;br /&gt;
are not recommended for sending between different systems.&lt;br /&gt;
&lt;br /&gt;
=== Is there a mime type for RIF? ===&lt;br /&gt;
&lt;br /&gt;
Yes, it's &amp;quot;application/rif+xml&amp;quot;.   See [http://www.w3.org/TR/rif-core/#Appendix:_RIF_Media_Type_Registration RIF Media Type Registration].&lt;br /&gt;
&lt;br /&gt;
== RIF Software ==&lt;br /&gt;
&lt;br /&gt;
=== What tools (open source and commercial) currently support RIF? ===&lt;br /&gt;
&lt;br /&gt;
Implementation plans continue to evolve.   Please report any to public-rif-comments@w3.org.  We try to maintain this&lt;br /&gt;
on the [[Implementations]] page.&lt;br /&gt;
&lt;br /&gt;
=== How fast are RIF processors compared to RDFS inference and OWL inference? ===&lt;br /&gt;
&lt;br /&gt;
Since RIF can often be implemented&lt;br /&gt;
by translation to other rule languages, we can speculate that the&lt;br /&gt;
performance will differ only by the time need for translation.  Many&lt;br /&gt;
RDFS and OWL systems use underlying rule engines to do their&lt;br /&gt;
inference, so their performance is likely to be the same or better on&lt;br /&gt;
RIF.  On the other hand, there are some OWL inference tasks which can&lt;br /&gt;
be much more efficiently handled by DL algorithms.&lt;br /&gt;
&lt;br /&gt;
=== Are there any SPARQL stores that support RIF? ===&lt;br /&gt;
&lt;br /&gt;
Implementation plans continue to evolve.   Please report any to public-rif-comments@w3.org.  We try to maintain this&lt;br /&gt;
on the [[Implementations]] page.&lt;br /&gt;
&lt;br /&gt;
We expect that SPARQL systems which currently include rule engines, such as Jena, will implement support for RIF.&lt;br /&gt;
&lt;br /&gt;
=== Is there a Web Service for doing RIF? ===&lt;br /&gt;
&lt;br /&gt;
Implementation plans continue to evolve.   Please report any to public-rif-comments@w3.org.  We try to maintain this&lt;br /&gt;
on the [[Implementations]] page.&lt;br /&gt;
&lt;br /&gt;
=== Does any major technology software vendor (or project) include RIF-related libraries in their stack? IBM, Google, Microsoft, Oracle, KDE, GNOME, Apache, ...===&lt;br /&gt;
&lt;br /&gt;
Implementation plans continue to evolve.   Please report any to public-rif-comments@w3.org.  We try to maintain this&lt;br /&gt;
on the [[Implementations]] page.&lt;br /&gt;
&lt;br /&gt;
IBM &amp;amp; iLog, HP, Oracle, and TIBCO are active in the Working Group.&lt;br /&gt;
&lt;br /&gt;
== Relation to Other Technologies ==&lt;br /&gt;
&lt;br /&gt;
=== I'd like to know if it's possible to translate RIF into SPARQL Construct clause (and back) ===&lt;br /&gt;
&lt;br /&gt;
Some people have used SPARQL Construct clauses as a rule language, although no formal semantics have been specified for this.   Because SPARQL including non-monotonic features, the full language possible here would be very expressive and very hard to specify or implement correctly.   (What happens if you use !bound with some data that is provided by related rules?)&lt;br /&gt;
&lt;br /&gt;
There is a subset of SPARQL Construct clauses which corresponds to a subset of RIF Core.   For this common subset, SPARQL can be seen as just another presentation syntax for RIF Core.    It would probably be best to try to stay within this subset when using SPARQL Construct clauses as a rule language.&lt;br /&gt;
&lt;br /&gt;
=== How do I serialize RIF rules in RDF? ===&lt;br /&gt;
&lt;br /&gt;
See [http://www.w3.org/TR/rif-in-rdf RIF in RDF].&lt;br /&gt;
&lt;br /&gt;
=== How do I put RIF rules in RDF, so I can reason about them with more rules? ===&lt;br /&gt;
&lt;br /&gt;
At present you cannot do this in a standardized fashion.&lt;br /&gt;
&lt;br /&gt;
If you map the RIF XML structure to an isomorphic RDF representation (for example, through use of GRDDL) then that RDF structure can be reasoned about with more rules. However, a normative such RDF representation has not be defined by the working group.&lt;br /&gt;
&lt;br /&gt;
=== What are the relationships between the OWL 2 profiles and the RIF dialects? ===&lt;br /&gt;
&lt;br /&gt;
There are several relationships between OWL 2 and RIF dialects.&lt;br /&gt;
&lt;br /&gt;
Firstly, RIF defines the notion of RIF/OWL combinations, providing a semantics for them and a syntactic mechanism for defining such combinations by importing OWL documents into RIF documents. This is specified in [http://www.w3.org/TR/rif-rdf-owl/ RIF RDF and OWL Compatibility]. This mechanism defines import profiles for both OWL 2 DL and OWL 2 Full semantics. Thus each OWL 2 Profile can be used in combination with any RIF dialect using this mechanism. There are no separate import profiles corresponding to the separate OWL 2 profiles.&lt;br /&gt;
&lt;br /&gt;
Secondly, OWL 2 defines a profile, OWL 2 RL, designed to be implementable by means of rule based systems. A partial axiomatization of the OWL 2 RL semantics is given in the [http://www.w3.org/TR/owl2-profiles/#Reasoning_in_OWL_2_RL_and_RDF_Graphs_using_Rules OWL Profiles document] as a set of first order rules. These rules can be translated into RIF Core rules either as a static rule set or on a per-ontology basis as discussed in [http://www.w3.org/2005/rules/wiki/OWLRL OWLRL]. This enables implementation of an OWL 2 RL entailment checker or query answering tool by using the RIF Core rule set in combination with the RDF document encoding an OWL 2 RL premise ontology to derive a set of entailed RDF assertions as RIF Frame formulae.&lt;br /&gt;
&lt;br /&gt;
Thirdly, RIF provides and Informative description of an [http://www.w3.org/TR/rif-rdf-owl/#Embedding_RIF-OWL_2_RL_Combinations embedding] of OWL 2 RL within RIF BLD. This enables the translation of an OWL 2 RL document directly into a RIF BLD document.&lt;br /&gt;
&lt;br /&gt;
=== What is the relationship between RuleML and RIF? ===&lt;br /&gt;
&lt;br /&gt;
RuleML has provided input for RIF on several levels, including the&lt;br /&gt;
use of 'striped' XML as well as&lt;br /&gt;
the structuring of rule classes into a family of sublanguages with, e.g.,&lt;br /&gt;
Datalog RuleML partially mappable to the RIF Core Dialect,&lt;br /&gt;
Derivation RuleML to the RIF Basic Logic Dialect, and&lt;br /&gt;
the production-rule sublanguage of Reaction RuleML to the RIF Production Rule Dialect.&lt;br /&gt;
Conversely, RuleML adopted some features that were developed&lt;br /&gt;
as part of the RIF Working Group such as role tags&lt;br /&gt;
&amp;lt;if&amp;gt; ... &amp;lt;then&amp;gt; instead of &amp;lt;body&amp;gt; ... &amp;lt;head&amp;gt;.&lt;br /&gt;
Shared RIF RuleML implementations and use cases are projected to lead to further convergence.&lt;br /&gt;
&lt;br /&gt;
=== How does RIF differ from SWRL? ===&lt;br /&gt;
&lt;br /&gt;
RIF was designed as an interchange format for exchanging rules between rule systems, such as those that implement SWRL.  SWRL is a rule language which was designed as an extension to OWL.  It is one of the simpler rule languages and most SWRL features are covered by RIF-BLD with the exception of &amp;quot;different-from&amp;quot;, thus it should be possible to exchange most SWRL rules via RIF.&lt;br /&gt;
&lt;br /&gt;
When viewed as a rule language and compared to SWRL, RIF-BLD supports multiple-arity predicates, and SWRL is limited to unary and binary predicates. RIF-BLD has functions, SWRL is function-free.  RIF-BLD has an extensive set of datatypes and builtins, SWRL supports most of the same datatypes but has no builtins.  [??? Yes, it does!  Under discussion.] RIF-BLD has a limited form of negation in datatype guard predicates (e.g. is-literal-not-integer), SWRL has a different limited form of negation in the &amp;quot;different-from&amp;quot; operator.  RIF-BLD interoperates with OWL through a special combination semantics, SWRL is designed to be a syntactic extension to OWL.  RIF-BLD allows disjunction in rules, SWRL does not.&lt;br /&gt;
&lt;br /&gt;
=== How can I encode RIF in HTML? ===&lt;br /&gt;
&lt;br /&gt;
RIF does not define a normative encoding in HTML. It was designed primarily for interchange of rules between rule engines, and the XML syntax is the only one defined as a standard for interchange.&lt;br /&gt;
&lt;br /&gt;
However, various text-based presentation syntaxes are used in the specification: although they are not recommended for interchange between different rule systems, they can be used for rendering by HTML processors.&lt;br /&gt;
&lt;br /&gt;
In general, any rule syntax that can be serialized in RIF XML in a semantics-preserving way can be used for that purpose. To avoid ambiguity, it is good practice to use only syntaxes for which a mapping to RIF XML is publicly available.&lt;br /&gt;
&lt;br /&gt;
=== What's the difference between RIF and having an RDF 2.0 that moves beyond binary relations? ===&lt;br /&gt;
&lt;br /&gt;
Such an RDF specification would probably look very much like RIF with RDF compatibility (see [http://www.w3.org/TR/rif-rdf-owl]).   Of course, RIF also provides for if/then rules, not just ground facts like RDF.&lt;br /&gt;
&lt;br /&gt;
=== Is RIF useful for reasoning about the provenance of claims expressed in RDF, eg. multiple named graphs in SPARQL that offer competing accounts of some situation? ===&lt;br /&gt;
&lt;br /&gt;
If the differing named graphs are located in different web documents, then RIF with RDF compatibility (see [http://www.w3.org/TR/rif-rdf-owl]) has an import mechanism that can be directed to the specific web documents and reason about them. More refined notions of import that allow to explicitly refer to facts from different imported documents per rule could be covered in extended RIF dialects.&lt;br /&gt;
&lt;br /&gt;
=== How do I embed RIF in an RDFS/OWL schema or ontology? ===&lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/TR/rif-rdf-owl RIF RDF and OWL Compatibility] specifies, formally, what it means to use RIF with RDFS and/or OWL, and provides a way, in RIF, to import RDFS and OWL.&lt;br /&gt;
&lt;br /&gt;
If you need to work in RDF triples, see [http://www.w3.org/TR/rif-in-rdf RIF In RDF].  This lets you physically embed RIF in an RDFS/OWL document, but notes that the embedded RIF is merely described, not asserted.  There is not currently a standard vocabulary saying, in RDFS/OWL, that you also want some RIF rules as part of your ontology.  Instead, for now, you must have RIF import RDFS/OWL.&lt;br /&gt;
&lt;br /&gt;
=== What's the relation between RIF and Functional-Logic Programming? ===&lt;br /&gt;
&lt;br /&gt;
Both are founded on Horn logic with equality. Functional-Logic Programming is built on Horn logic with ''oriented'' equations&lt;br /&gt;
in rule conclusions, used to define functions. In that sense it specializes RIF-BLD,&lt;br /&gt;
built on Horn logic with ''symmetric'' equations. However, Functional-Logic Programming permits higher-order functions, while RIF-BLD only permits first-order functions. For an introduction to functional-logic technology, with many examples, see&lt;br /&gt;
[http://www.cs.unb.ca/seminarseries/documents/Harold_Boley-03.17.10.pdf Visualizing Executable Functional-Logic Specifications].&lt;br /&gt;
&lt;br /&gt;
== Documentation ==&lt;br /&gt;
&lt;br /&gt;
=== Where are examples to the W3C semweb technology stack, using RIF properly along with RDF, RDFS, OWL[2], etc.? ===&lt;br /&gt;
&lt;br /&gt;
The [http://www.w3.org/TR/rif-rdf-owl/ RIF RDF and OWL Compatibility] document specifies how RIF works in combination with RDF, RDFS, OWL 1, and OWL 2, and there are small examples throughout the document of RIF-RDF and RIF-OWL combinations, explaining what is entailed (or not) from them.&lt;br /&gt;
&lt;br /&gt;
Two of the use cases presented in [http://www.w3.org/TR/rif-ucr/ RIF Use Cases and Requirements] provide motivating scenarios for RIF in combination with RDF and OWL:  [http://www.w3.org/TR/rif-ucr/#Interchanging_Rule_Extensions_to_OWL Interchanging Rule Extensions to OWL] and [http://www.w3.org/TR/rif-ucr/#Publishing_Rules_for_Interlinked_Metadata Publishing Rules for Interlinked Metadata].&lt;br /&gt;
&lt;br /&gt;
Also, see the [http://www.w3.org/2005/rules/wiki/Category:RIF-RDF_Combination RIF-RDF combination test cases] and the [http://www.w3.org/2005/rules/wiki/Category:RIF-OWL_Combination RIF-OWL combination test cases]. Among these,&lt;br /&gt;
[http://www.w3.org/2005/rules/wiki/YoungParentDiscount_1 Young Parent Discount] and [http://www.w3.org/2005/rules/wiki/UCR_4.7a UCR_4.7a] are in the style of small usage examples.&lt;br /&gt;
&lt;br /&gt;
=== Where are examples to existing RIF rules written using the simplest, bare-minimum markup and easiest logic/math? ===&lt;br /&gt;
&lt;br /&gt;
The set of RIF documents --- including the documents on [http://www.w3.org/2005/rules/wiki/BLD BLD], [http://www.w3.org/2005/rules/wiki/PRD PRD] and [http://www.w3.org/2005/rules/wiki/FLD FLD] --- and the set of [http://www.w3.org/2005/rules/wiki/Category:Test_Case test cases] both contain a variety of examples that involve almost no logic (sometimes not even modus ponens) and no math at all.&lt;br /&gt;
&lt;br /&gt;
For instance, Example 1 in [http://www.w3.org/2005/rules/wiki/BLD BLD] involves just a single application of modus ponens and no math; Example 4 shows several different ways of writing business rules that do not involve math, and require only a basic knowledge of quantifiers.&lt;br /&gt;
&lt;br /&gt;
Most of the examples in [http://www.w3.org/2005/rules/wiki/Category:Test_Case test cases] are quite simple, and involve nothing more than arithmetic. An example of a test case that involves simple inheritance is [http://www.w3.org/2005/rules/wiki/Classification-inheritance  Classification-inheritance.]&lt;br /&gt;
&lt;br /&gt;
=== Where can I find info on RIF for the &amp;quot;business rules&amp;quot; community, esp. to help convince management to start to consider RIF as the source format? ===&lt;br /&gt;
Half of the [http://www.w3.org/TR/rif-ucr/#Use_Cases RIF use cases] describe how RIF can serve the business rules community. RIF can help to avoid vendor lock-in, foster collaboration, support eBusiness and eCommerce, optimize the supply chain, and allow business rules to be bought, sold, and shared.&lt;br /&gt;
The [http://www.w3.org/TR/rif-prd production rule dialect] includes typical business rules features such as rule priority, negation, decimal numbers, and dates.&lt;br /&gt;
&lt;br /&gt;
=== What interesting things have been built using RIF? ===&lt;br /&gt;
&lt;br /&gt;
Support for RIF is just starting to become available (see [[Implementations]]), so there has not yet been much opportunity to develop applications that use RIF.&lt;br /&gt;
&lt;br /&gt;
This [http://www.ibm.com/developerworks/wikis/display/db2xml/Rules IBM developerWorks article] discusses storing and querying rules in an XML database, and includes a live demo with RIF rules.&lt;br /&gt;
&lt;br /&gt;
Some envisioned representative usage scenarios for RIF are outlined in the [http://www.w3.org/TR/rif-ucr/#Use_Cases RIF use cases]. &lt;br /&gt;
&lt;br /&gt;
Please report any applications or uses of RIF to public-rif-comments@w3.org.&lt;br /&gt;
&lt;br /&gt;
== Acknowledements ==&lt;br /&gt;
&lt;br /&gt;
Thanks to questions, comments, suggestions from:&lt;br /&gt;
&lt;br /&gt;
* Lee Feigenbaum &lt;br /&gt;
* David Booth &lt;br /&gt;
* Richard Cyganiak &lt;br /&gt;
* Frank Manola &lt;br /&gt;
* &amp;quot;Collette Hagert geb. Nauluta&amp;quot; &lt;br /&gt;
* Dan Brickley&lt;/div&gt;</description>
			<pubDate>Mon, 04 Feb 2013 17:27:12 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Talk:RIF_FAQ</comments>		</item>
		<item>
			<title>RIF FAQ</title>
			<link>http://www.w3.org/2005/rules/wiki/RIF_FAQ</link>
			<description>&lt;p&gt;Sandro:&amp;#32;/* How do I serialize RIF rules in RDF? */ updated!&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NUMBEREDHEADINGS__&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Please send comments or additional questions to [mailto:public-rif-comments@w3.org public-rif-comments@w3.org] ([http://lists.w3.org/Archives/Public/public-rif-wg/ public archive]).&lt;br /&gt;
&lt;br /&gt;
Answers have not necessarily been reviewed by the Working Group.  The question are real, having been asked via e-mail or in person.&lt;br /&gt;
&lt;br /&gt;
Some questions here have not yet been answered.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About RIF ==&lt;br /&gt;
&lt;br /&gt;
=== What is RIF? ===&lt;br /&gt;
&lt;br /&gt;
RIF is the W3C Rule Interchange Format.  It's an XML language for expressing rules which computers can execute.&lt;br /&gt;
&lt;br /&gt;
Because of the serious tradeoffs in the design of rule language, RIF provides multiple versions, called ''dialects''.   If you're not sure which dialect to use, start with RIF Core.   Then, if you need rule features that are not available in RIF Core, consider the other standard dialects and third-party dialects.&lt;br /&gt;
&lt;br /&gt;
=== What is RIF-BLD?  (and RIF-Core, PRD, FLD) ===&lt;br /&gt;
&lt;br /&gt;
The standard RIF dialects are ''Core'', ''BLD'', and ''PRD'':&lt;br /&gt;
&lt;br /&gt;
; Core&lt;br /&gt;
: This is the fundamental RIF language.  It is designed to be the common subset of most rule engines.   (It provides &amp;quot;safe&amp;quot; positive datalog with builtins.)&lt;br /&gt;
; BLD (Basic Logic Dialect)&lt;br /&gt;
: This adds a few things that Core doesn't have: logic functions, equality in the ''then''-part, and named arguments.   Each of these features can sort of be simulated in Core.   (This is positive Horn logic, with equality and builtins.)&lt;br /&gt;
; PRD (Production Rules Dialect)&lt;br /&gt;
: adds a notion of forward-chaining rules, where a rule ''fires'' and then performs some action, such as adding more information to the store or ''retracting'' some information.&lt;br /&gt;
&lt;br /&gt;
Note that '''FLD''' (the Framework for Logic Dialects) provides a menu for coherently assembling dialects more expressive than BLD.   Links to unofficial, community-contributed RIF dialects can be found&lt;br /&gt;
[http://www.w3.org/2005/rules/wiki/RIF_FLD_Dialects here].&lt;br /&gt;
&lt;br /&gt;
More generally, the [[Overview]] provides a guide to the RIF architecture.&lt;br /&gt;
&lt;br /&gt;
=== Is RIF only for interchange? ===&lt;br /&gt;
&lt;br /&gt;
No.  Although RIF dialects were designed primarily for interchange, each dialect is a standard rule language and can be used even when portability and interchange are not required.&lt;br /&gt;
&lt;br /&gt;
=== &amp;quot;Reduction In Force&amp;quot;? ===&lt;br /&gt;
&lt;br /&gt;
Yes, in some other situations, ''RIF'' stands for ''reduction in force'', a term for reducing headcount, downsizing, layoffs, etc. We're still waiting to hear a really good pun based on this double meaning.&lt;br /&gt;
&lt;br /&gt;
=== Can I use RIF to map between vocabularies? === &lt;br /&gt;
&lt;br /&gt;
Yes.  It should be good for this.   It's [http://www.w3.org/TR/rif-ucr/#Vocabulary_Mapping_for_Data_Integration one of the use cases].&lt;br /&gt;
&lt;br /&gt;
=== Which RIF syntax should I use? ===&lt;br /&gt;
&lt;br /&gt;
The XML syntax is the only one defined as a standard for interchange.&lt;br /&gt;
Various presentation syntaxes are used in the specification, but they&lt;br /&gt;
are not recommended for sending between different systems.&lt;br /&gt;
&lt;br /&gt;
=== Is there a mime type for RIF? ===&lt;br /&gt;
&lt;br /&gt;
Yes, it's &amp;quot;application/rif+xml&amp;quot;.   See [http://www.w3.org/TR/rif-core/#Appendix:_RIF_Media_Type_Registration RIF Media Type Registration].&lt;br /&gt;
&lt;br /&gt;
== RIF Software ==&lt;br /&gt;
&lt;br /&gt;
=== What tools (open source and commercial) currently support RIF? ===&lt;br /&gt;
&lt;br /&gt;
Implementation plans continue to evolve.   Please report any to public-rif-comments@w3.org.  We try to maintain this&lt;br /&gt;
on the [[Implementations]] page.&lt;br /&gt;
&lt;br /&gt;
=== How fast are RIF processors compared to RDFS inference and OWL inference? ===&lt;br /&gt;
&lt;br /&gt;
Since RIF can often be implemented&lt;br /&gt;
by translation to other rule languages, we can speculate that the&lt;br /&gt;
performance will differ only by the time need for translation.  Many&lt;br /&gt;
RDFS and OWL systems use underlying rule engines to do their&lt;br /&gt;
inference, so their performance is likely to be the same or better on&lt;br /&gt;
RIF.  On the other hand, there are some OWL inference tasks which can&lt;br /&gt;
be much more efficiently handled by DL algorithms.&lt;br /&gt;
&lt;br /&gt;
=== Are there any SPARQL stores that support RIF? ===&lt;br /&gt;
&lt;br /&gt;
Implementation plans continue to evolve.   Please report any to public-rif-comments@w3.org.  We try to maintain this&lt;br /&gt;
on the [[Implementations]] page.&lt;br /&gt;
&lt;br /&gt;
We expect that SPARQL systems which currently include rule engines, such as Jena, will implement support for RIF.&lt;br /&gt;
&lt;br /&gt;
=== Is there a Web Service for doing RIF? ===&lt;br /&gt;
&lt;br /&gt;
Implementation plans continue to evolve.   Please report any to public-rif-comments@w3.org.  We try to maintain this&lt;br /&gt;
on the [[Implementations]] page.&lt;br /&gt;
&lt;br /&gt;
=== Does any major technology software vendor (or project) include RIF-related libraries in their stack? IBM, Google, Microsoft, Oracle, KDE, GNOME, Apache, ...===&lt;br /&gt;
&lt;br /&gt;
Implementation plans continue to evolve.   Please report any to public-rif-comments@w3.org.  We try to maintain this&lt;br /&gt;
on the [[Implementations]] page.&lt;br /&gt;
&lt;br /&gt;
IBM &amp;amp; iLog, HP, Oracle, and TIBCO are active in the Working Group.&lt;br /&gt;
&lt;br /&gt;
== Relation to Other Technologies ==&lt;br /&gt;
&lt;br /&gt;
=== I'd like to know if it's possible to translate RIF into SPARQL Construct clause (and back) ===&lt;br /&gt;
&lt;br /&gt;
Some people have used SPARQL Construct clauses as a rule language, although no formal semantics have been specified for this.   Because SPARQL including non-monotonic features, the full language possible here would be very expressive and very hard to specify or implement correctly.   (What happens if you use !bound with some data that is provided by related rules?)&lt;br /&gt;
&lt;br /&gt;
There is a subset of SPARQL Construct clauses which corresponds to a subset of RIF Core.   For this common subset, SPARQL can be seen as just another presentation syntax for RIF Core.    It would probably be best to try to stay within this subset when using SPARQL Construct clauses as a rule language.&lt;br /&gt;
&lt;br /&gt;
=== How do I serialize RIF rules in RDF? ===&lt;br /&gt;
&lt;br /&gt;
See [http://www.w3.org/TR/rif-in-rdf RIF in RDF].&lt;br /&gt;
&lt;br /&gt;
=== How do I store RIF rules in my triplestore? ===&lt;br /&gt;
&lt;br /&gt;
See 3.2 above.&lt;br /&gt;
&lt;br /&gt;
=== How do I put RIF rules in RDF, so I can reason about them with more rules? ===&lt;br /&gt;
&lt;br /&gt;
At present you cannot do this in a standardized fashion.&lt;br /&gt;
&lt;br /&gt;
If you map the RIF XML structure to an isomorphic RDF representation (for example, through use of GRDDL) then that RDF structure can be reasoned about with more rules. However, a normative such RDF representation has not be defined by the working group.&lt;br /&gt;
&lt;br /&gt;
=== What are the relationships between the OWL 2 profiles and the RIF dialects? ===&lt;br /&gt;
&lt;br /&gt;
There are several relationships between OWL 2 and RIF dialects.&lt;br /&gt;
&lt;br /&gt;
Firstly, RIF defines the notion of RIF/OWL combinations, providing a semantics for them and a syntactic mechanism for defining such combinations by importing OWL documents into RIF documents. This is specified in [http://www.w3.org/TR/rif-rdf-owl/ RIF RDF and OWL Compatibility]. This mechanism defines import profiles for both OWL 2 DL and OWL 2 Full semantics. Thus each OWL 2 Profile can be used in combination with any RIF dialect using this mechanism. There are no separate import profiles corresponding to the separate OWL 2 profiles.&lt;br /&gt;
&lt;br /&gt;
Secondly, OWL 2 defines a profile, OWL 2 RL, designed to be implementable by means of rule based systems. A partial axiomatization of the OWL 2 RL semantics is given in the [http://www.w3.org/TR/owl2-profiles/#Reasoning_in_OWL_2_RL_and_RDF_Graphs_using_Rules OWL Profiles document] as a set of first order rules. These rules can be translated into RIF Core rules either as a static rule set or on a per-ontology basis as discussed in [http://www.w3.org/2005/rules/wiki/OWLRL OWLRL]. This enables implementation of an OWL 2 RL entailment checker or query answering tool by using the RIF Core rule set in combination with the RDF document encoding an OWL 2 RL premise ontology to derive a set of entailed RDF assertions as RIF Frame formulae.&lt;br /&gt;
&lt;br /&gt;
Thirdly, RIF provides and Informative description of an [http://www.w3.org/TR/rif-rdf-owl/#Embedding_RIF-OWL_2_RL_Combinations embedding] of OWL 2 RL within RIF BLD. This enables the translation of an OWL 2 RL document directly into a RIF BLD document.&lt;br /&gt;
&lt;br /&gt;
=== What is the relationship between RuleML and RIF? ===&lt;br /&gt;
&lt;br /&gt;
RuleML has provided input for RIF on several levels, including the&lt;br /&gt;
use of 'striped' XML as well as&lt;br /&gt;
the structuring of rule classes into a family of sublanguages with, e.g.,&lt;br /&gt;
Datalog RuleML partially mappable to the RIF Core Dialect,&lt;br /&gt;
Derivation RuleML to the RIF Basic Logic Dialect, and&lt;br /&gt;
the production-rule sublanguage of Reaction RuleML to the RIF Production Rule Dialect.&lt;br /&gt;
Conversely, RuleML adopted some features that were developed&lt;br /&gt;
as part of the RIF Working Group such as role tags&lt;br /&gt;
&amp;lt;if&amp;gt; ... &amp;lt;then&amp;gt; instead of &amp;lt;body&amp;gt; ... &amp;lt;head&amp;gt;.&lt;br /&gt;
Shared RIF RuleML implementations and use cases are projected to lead to further convergence.&lt;br /&gt;
&lt;br /&gt;
=== How does RIF differ from SWRL? ===&lt;br /&gt;
&lt;br /&gt;
RIF was designed as an interchange format for exchanging rules between rule systems, such as those that implement SWRL.  SWRL is a rule language which was designed as an extension to OWL.  It is one of the simpler rule languages and most SWRL features are covered by RIF-BLD with the exception of &amp;quot;different-from&amp;quot;, thus it should be possible to exchange most SWRL rules via RIF.&lt;br /&gt;
&lt;br /&gt;
When viewed as a rule language and compared to SWRL, RIF-BLD supports multiple-arity predicates, and SWRL is limited to unary and binary predicates. RIF-BLD has functions, SWRL is function-free.  RIF-BLD has an extensive set of datatypes and builtins, SWRL supports most of the same datatypes but has no builtins.  [??? Yes, it does!  Under discussion.] RIF-BLD has a limited form of negation in datatype guard predicates (e.g. is-literal-not-integer), SWRL has a different limited form of negation in the &amp;quot;different-from&amp;quot; operator.  RIF-BLD interoperates with OWL through a special combination semantics, SWRL is designed to be a syntactic extension to OWL.  RIF-BLD allows disjunction in rules, SWRL does not.&lt;br /&gt;
&lt;br /&gt;
=== How can I encode RIF in HTML? ===&lt;br /&gt;
&lt;br /&gt;
RIF does not define a normative encoding in HTML. It was designed primarily for interchange of rules between rule engines, and the XML syntax is the only one defined as a standard for interchange.&lt;br /&gt;
&lt;br /&gt;
However, various text-based presentation syntaxes are used in the specification: although they are not recommended for interchange between different rule systems, they can be used for rendering by HTML processors.&lt;br /&gt;
&lt;br /&gt;
In general, any rule syntax that can be serialized in RIF XML in a semantics-preserving way can be used for that purpose. To avoid ambiguity, it is good practice to use only syntaxes for which a mapping to RIF XML is publicly available.&lt;br /&gt;
&lt;br /&gt;
=== What's the difference between RIF and having an RDF 2.0 that moves beyond binary relations? ===&lt;br /&gt;
&lt;br /&gt;
Such an RDF specification would probably look very much like RIF with RDF compatibility (see [http://www.w3.org/TR/rif-rdf-owl]).   Of course, RIF also provides for if/then rules, not just ground facts like RDF.&lt;br /&gt;
&lt;br /&gt;
=== Is RIF useful for reasoning about the provenance of claims expressed in RDF, eg. multiple named graphs in SPARQL that offer competing accounts of some situation? ===&lt;br /&gt;
&lt;br /&gt;
If the differing named graphs are located in different web documents, then RIF with RDF compatibility (see [http://www.w3.org/TR/rif-rdf-owl]) has an import mechanism that can be directed to the specific web documents and reason about them. More refined notions of import that allow to explicitly refer to facts from different imported documents per rule could be covered in extended RIF dialects.&lt;br /&gt;
&lt;br /&gt;
=== How do I embed RIF in an RDFS/OWL schema or ontology? ===&lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/TR/rif-rdf-owl RIF RDF and OWL Compatibility] specifies, formally, what it means to use RIF with RDFS and/or OWL, and provides a way, in RIF, to import RDFS and OWL.&lt;br /&gt;
&lt;br /&gt;
If you need to work in RDF triples, see [http://www.w3.org/TR/rif-in-rdf RIF In RDF].  This lets you physically embed RIF in an RDFS/OWL document, but notes that the embedded RIF is merely described, not asserted.  There is not currently a standard vocabulary saying, in RDFS/OWL, that you also want some RIF rules as part of your ontology.  Instead, for now, you must have RIF import RDFS/OWL.&lt;br /&gt;
&lt;br /&gt;
=== What's the relation between RIF and Functional-Logic Programming? ===&lt;br /&gt;
&lt;br /&gt;
Both are founded on Horn logic with equality. Functional-Logic Programming is built on Horn logic with ''oriented'' equations&lt;br /&gt;
in rule conclusions, used to define functions. In that sense it specializes RIF-BLD,&lt;br /&gt;
built on Horn logic with ''symmetric'' equations. However, Functional-Logic Programming permits higher-order functions, while RIF-BLD only permits first-order functions. For an introduction to functional-logic technology, with many examples, see&lt;br /&gt;
[http://www.cs.unb.ca/seminarseries/documents/Harold_Boley-03.17.10.pdf Visualizing Executable Functional-Logic Specifications].&lt;br /&gt;
&lt;br /&gt;
== Documentation ==&lt;br /&gt;
&lt;br /&gt;
=== Where are examples to the W3C semweb technology stack, using RIF properly along with RDF, RDFS, OWL[2], etc.? ===&lt;br /&gt;
&lt;br /&gt;
The [http://www.w3.org/TR/rif-rdf-owl/ RIF RDF and OWL Compatibility] document specifies how RIF works in combination with RDF, RDFS, OWL 1, and OWL 2, and there are small examples throughout the document of RIF-RDF and RIF-OWL combinations, explaining what is entailed (or not) from them.&lt;br /&gt;
&lt;br /&gt;
Two of the use cases presented in [http://www.w3.org/TR/rif-ucr/ RIF Use Cases and Requirements] provide motivating scenarios for RIF in combination with RDF and OWL:  [http://www.w3.org/TR/rif-ucr/#Interchanging_Rule_Extensions_to_OWL Interchanging Rule Extensions to OWL] and [http://www.w3.org/TR/rif-ucr/#Publishing_Rules_for_Interlinked_Metadata Publishing Rules for Interlinked Metadata].&lt;br /&gt;
&lt;br /&gt;
Also, see the [http://www.w3.org/2005/rules/wiki/Category:RIF-RDF_Combination RIF-RDF combination test cases] and the [http://www.w3.org/2005/rules/wiki/Category:RIF-OWL_Combination RIF-OWL combination test cases]. Among these,&lt;br /&gt;
[http://www.w3.org/2005/rules/wiki/YoungParentDiscount_1 Young Parent Discount] and [http://www.w3.org/2005/rules/wiki/UCR_4.7a UCR_4.7a] are in the style of small usage examples.&lt;br /&gt;
&lt;br /&gt;
=== Where are examples to existing RIF rules written using the simplest, bare-minimum markup and easiest logic/math? ===&lt;br /&gt;
&lt;br /&gt;
The set of RIF documents --- including the documents on [http://www.w3.org/2005/rules/wiki/BLD BLD], [http://www.w3.org/2005/rules/wiki/PRD PRD] and [http://www.w3.org/2005/rules/wiki/FLD FLD] --- and the set of [http://www.w3.org/2005/rules/wiki/Category:Test_Case test cases] both contain a variety of examples that involve almost no logic (sometimes not even modus ponens) and no math at all.&lt;br /&gt;
&lt;br /&gt;
For instance, Example 1 in [http://www.w3.org/2005/rules/wiki/BLD BLD] involves just a single application of modus ponens and no math; Example 4 shows several different ways of writing business rules that do not involve math, and require only a basic knowledge of quantifiers.&lt;br /&gt;
&lt;br /&gt;
Most of the examples in [http://www.w3.org/2005/rules/wiki/Category:Test_Case test cases] are quite simple, and involve nothing more than arithmetic. An example of a test case that involves simple inheritance is [http://www.w3.org/2005/rules/wiki/Classification-inheritance  Classification-inheritance.]&lt;br /&gt;
&lt;br /&gt;
=== Where can I find info on RIF for the &amp;quot;business rules&amp;quot; community, esp. to help convince management to start to consider RIF as the source format? ===&lt;br /&gt;
Half of the [http://www.w3.org/TR/rif-ucr/#Use_Cases RIF use cases] describe how RIF can serve the business rules community. RIF can help to avoid vendor lock-in, foster collaboration, support eBusiness and eCommerce, optimize the supply chain, and allow business rules to be bought, sold, and shared.&lt;br /&gt;
The [http://www.w3.org/TR/rif-prd production rule dialect] includes typical business rules features such as rule priority, negation, decimal numbers, and dates.&lt;br /&gt;
&lt;br /&gt;
=== What interesting things have been built using RIF? ===&lt;br /&gt;
&lt;br /&gt;
Support for RIF is just starting to become available (see [[Implementations]]), so there has not yet been much opportunity to develop applications that use RIF.&lt;br /&gt;
&lt;br /&gt;
This [http://www.ibm.com/developerworks/wikis/display/db2xml/Rules IBM developerWorks article] discusses storing and querying rules in an XML database, and includes a live demo with RIF rules.&lt;br /&gt;
&lt;br /&gt;
Some envisioned representative usage scenarios for RIF are outlined in the [http://www.w3.org/TR/rif-ucr/#Use_Cases RIF use cases]. &lt;br /&gt;
&lt;br /&gt;
Please report any applications or uses of RIF to public-rif-comments@w3.org.&lt;br /&gt;
&lt;br /&gt;
== Acknowledements ==&lt;br /&gt;
&lt;br /&gt;
Thanks to questions, comments, suggestions from:&lt;br /&gt;
&lt;br /&gt;
* Lee Feigenbaum &lt;br /&gt;
* David Booth &lt;br /&gt;
* Richard Cyganiak &lt;br /&gt;
* Frank Manola &lt;br /&gt;
* &amp;quot;Collette Hagert geb. Nauluta&amp;quot; &lt;br /&gt;
* Dan Brickley&lt;/div&gt;</description>
			<pubDate>Mon, 04 Feb 2013 17:26:37 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Talk:RIF_FAQ</comments>		</item>
		<item>
			<title>UCR</title>
			<link>http://www.w3.org/2005/rules/wiki/UCR</link>
			<description>&lt;p&gt;Sandro:&amp;#32;remove extra explicit &amp;lt;P&amp;gt; tag&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NUMBEREDHEADINGS__&lt;br /&gt;
{{TR|title=RIF Use Cases and Requirements}}&lt;br /&gt;
&amp;lt;div id='editors'&amp;gt;&lt;br /&gt;
; Editors:&lt;br /&gt;
: Adrian Paschke, Freie Universitaet Berlin&lt;br /&gt;
: Leora Morgenstern, SAIC&lt;br /&gt;
: David Hirtle, National Research Council Canada&lt;br /&gt;
: Allen Ginsberg, Mitre&lt;br /&gt;
: Paula-Lavinia Patranjan, REWERSE&lt;br /&gt;
: Frank &amp;lt;nowiki&amp;gt;McCabe&amp;lt;/nowiki&amp;gt;, Fujitsu&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
; Abstract&lt;br /&gt;
: &amp;lt;div id='abstract'&amp;gt;&amp;lt;p&amp;gt;&amp;lt;/p&amp;gt; &amp;lt;p&amp;gt;&amp;lt;/p&amp;gt; &amp;lt;p&amp;gt;&amp;lt;/p&amp;gt; &amp;lt;p&amp;gt;This document, developed by the [http://www.w3.org/2005/rules/wg Rule Interchange Format (RIF) Working Group], specifies use cases and requirements for the W3C Rule Interchange Format, a family of rule interchange dialects that allows rules to be translated between rule languages and thus transferred between rule systems. &amp;lt;/p&amp;gt; &amp;lt;/div&amp;gt;&lt;br /&gt;
; Status of this Document&lt;br /&gt;
: 3rd revised version of the UCR document&lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/Consortium/Legal/ipr-notice#Copyright Copyright] © 2010 [http://www.w3.org/ W3C]&amp;lt;sup&amp;gt;®&amp;lt;/sup&amp;gt; ([http://www.csail.mit.edu/ MIT], [http://www.ercim.org/ ERCIM], [http://www.keio.ac.jp/ Keio]), All Rights Reserved. W3C [http://www.w3.org/Consortium/Legal/ipr-notice#Legal_Disclaimer liability], [http://www.w3.org/Consortium/Legal/ipr-notice#W3C_Trademarks trademark] and [http://www.w3.org/Consortium/Legal/copyright-documents document use] rules apply.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id='docbody'&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;html&amp;gt;&lt;br /&gt;
&amp;lt;script type=&amp;quot;text/javascript&amp;quot;&amp;gt;/*&amp;lt;![CDATA[*/&lt;br /&gt;
/*&lt;br /&gt;
	Written by Jonathan Snook, http://www.snook.ca/jonathan&lt;br /&gt;
	Add-ons by Robert Nyman, http://www.robertnyman.com&lt;br /&gt;
	Author says &amp;quot;The credit comment is all it takes, no license. Go crazy with it!:-)&amp;quot;&lt;br /&gt;
	From http://www.robertnyman.com/2005/11/07/the-ultimate-getelementsbyclassname/&lt;br /&gt;
*/&lt;br /&gt;
&lt;br /&gt;
var displayed = [];&lt;br /&gt;
displayed[&amp;quot;bld&amp;quot;] = 1;&lt;br /&gt;
displayed[&amp;quot;prd&amp;quot;] = 1;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
function display(syntax,status) {&lt;br /&gt;
  var howmany = 0;&lt;br /&gt;
  if (status=='none') {&lt;br /&gt;
    displayed[syntax] = 0; &lt;br /&gt;
  } else { &lt;br /&gt;
    displayed[syntax] = 1;&lt;br /&gt;
  }&lt;br /&gt;
  for ( i in displayed ) {&lt;br /&gt;
       howmany = howmany + displayed[i];&lt;br /&gt;
  }&lt;br /&gt;
  set_display_by_class('p',syntax,status);&lt;br /&gt;
  if ( howmany == 1 ) {&lt;br /&gt;
      set_display_by_class('b','syntax-head','none');&lt;br /&gt;
  } else {&lt;br /&gt;
      set_display_by_class('b','syntax-head','');&lt;br /&gt;
  }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
function getElementsByClassName(oElm, strTagName, oClassNames){&lt;br /&gt;
	var arrElements = (! (! (strTagName == &amp;quot;*&amp;quot;) || ! (oElm.all)))? oElm.all : oElm.getElementsByTagName(strTagName);&lt;br /&gt;
	var arrReturnElements = new Array();&lt;br /&gt;
	var arrRegExpClassNames = new Array();&lt;br /&gt;
	if(typeof oClassNames == &amp;quot;object&amp;quot;){&lt;br /&gt;
		for(var i=0; !(i&amp;gt;=oClassNames.length); i++){ /*&amp;gt;*/&lt;br /&gt;
			arrRegExpClassNames.push(new RegExp(&amp;quot;(^|\\s)&amp;quot; + oClassNames[i].replace(/\-/g, &amp;quot;\\-&amp;quot;) + &amp;quot;(\\s|$)&amp;quot;));&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
	else{&lt;br /&gt;
		arrRegExpClassNames.push(new RegExp(&amp;quot;(^|\\s)&amp;quot; + oClassNames.replace(/\-/g, &amp;quot;\\-&amp;quot;) + &amp;quot;(\\s|$)&amp;quot;));&lt;br /&gt;
	}&lt;br /&gt;
	var oElement;&lt;br /&gt;
	var bMatchesAll;&lt;br /&gt;
	for(var j=0; !(j&amp;gt;=arrElements.length); j++){ /*&amp;gt;*/&lt;br /&gt;
		oElement = arrElements[j];&lt;br /&gt;
		bMatchesAll = true;&lt;br /&gt;
		for(var k=0; !(k&amp;gt;=arrRegExpClassNames.length); k++){ /*&amp;gt;*/&lt;br /&gt;
			if(!arrRegExpClassNames[k].test(oElement.className)){&lt;br /&gt;
				bMatchesAll = false;&lt;br /&gt;
				break;&lt;br /&gt;
			}&lt;br /&gt;
		}&lt;br /&gt;
		if(bMatchesAll){&lt;br /&gt;
			arrReturnElements.push(oElement);&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
	return (arrReturnElements)&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
function set_display_by_class(el, cls, newValue) {&lt;br /&gt;
   var e = getElementsByClassName(document, el, cls);&lt;br /&gt;
   if (e != null) {&lt;br /&gt;
      for (var i=0; !(i&amp;gt;=e.length); i++) {&lt;br /&gt;
        e[i].style.display = newValue;&lt;br /&gt;
      }&lt;br /&gt;
   }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
function set_display_by_id(id, newValue) {&lt;br /&gt;
   var e = document.getElementById(id);&lt;br /&gt;
   if (e != null) {&lt;br /&gt;
     e.style.display = newValue;&lt;br /&gt;
   }&lt;br /&gt;
}&lt;br /&gt;
/*]]&amp;gt;*/&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/html&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;   &amp;lt;!-- because there seems to be a close-div after the intro --&amp;gt;&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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 existing rule-based technologies to interoperate according to standards-based methodologies and processes. The primary goal of the Rule Interchange Format (RIF) Working Group has been 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. RIF's mission is part of W3C's larger goal of enabling the sharing of information in forms suited to machine processing: &lt;br /&gt;
&lt;br /&gt;
*# 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 [http://www.ruleml.org/ RuleML Initiative] and elsewhere. &lt;br /&gt;
*# Rules provide a powerful business logic representation, as business rules, in many modern information systems. &lt;br /&gt;
*# Rules are often the technology of choice for creating maintainable adapters between information systems. &lt;br /&gt;
*# As part of the Semantic Web architecture, rules can extend or complement the [[#ref-owl-reference|OWL Web Ontology Language]] to more thoroughly cover a broader set of applications, with knowledge being encoded in OWL or rules or both. &lt;br /&gt;
&lt;br /&gt;
The purpose of this RIF-UCR document is to describe the use cases that guided the design of RIF and to document the design requirements that were derived from both the use cases and from the basic goals of RIF. RIF-UCR also delivers a structured context for formulating future technical specifications of further RIF dialects. Each dialect targets a cluster of similar rule languages and enables platform-independent interoperation between them (via interchange of RIF rules). The use cases presented 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. Finally, RIF can promote the growth of knowledge by enabling reasoning with merged sets of rules originating from disparate knowledge sources.&lt;br /&gt;
&lt;br /&gt;
The RIF-UCR document is structured as follows: Section 2 formulates the overall goals of RIF. Section 3 summarizes the released RIF dialects and the structure of RIF. Section 4 discusses several important requirements for RIF dialects. Section 5 presents a set of use cases that are representative of the types of application scenarios that RIF is intended to support. The use cases illustrate the utilization of the current RIF dialects.  More importantly, the functionality specified in the use cases, together with the requirements discussed in the previous section, serves as input for both the technical specification for future RIF dialects and the implementation of various variants of these scenarios by RIF-compliant applications and systems. &lt;br /&gt;
&lt;br /&gt;
Although in this document the discussion of requirements precedes the discussion of use cases,  the development of the use cases preceded, and in fact motivated, the development of the requirements. For the most part, requirements were not established unless there was at least one use case, or straightforward modification of a use case, from which that requirement could be derived.  There are some exceptions to this rule: for example, some requirements were already defined as constraints in the working group charter and were not necessarily derived from any specific use case. The fulfillment of such requirements is discussed with respect to the existing RIF dialects. &lt;br /&gt;
&lt;br /&gt;
Note that in fact not all use cases can be represented in a straightforward manner within all RIF dialects. In particular, several use cases cannot be represented within the RIF dialect [[#ref-rif-bld|BLD]] . This is due first, to the fact that BLD is strictly less expressive than first-order logic (since negation is not expressible), and second, to the fact that some use cases are most naturally represented in languages more powerful than first-order logic, such as modal logics. Some use cases that cannot be represented within BLD can be represented within the RIF dialect [[#ref-rif-prd|PRD]], which includes the construct of negation as failure. Following the presentation of each use case in Section 5 is a note indicating in which of the current RIF dialects a use case can be represented naturally, sometimes accompanied by discussion.&lt;br /&gt;
&lt;br /&gt;
It should be noted that even for use cases which cannot be represented in a straightforward manner within some RIF dialect, there may be other approaches that would enable representation. For example, although epistemic operators such as &amp;lt;tt&amp;gt;Know&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;Believe&amp;lt;/tt&amp;gt; are most straightforwardly represented within a modal logic, it is generally possible to represent such operators in a first-order logic using a possible-worlds semantics. For certain use cases which cannot be naturally represented within some dialect, the extent to which this can be done will be discussed.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Goals ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
RIF is primarily intended 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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;goal-exchange-of-rules&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
==== Exchange of Rules ====&lt;br /&gt;
&lt;br /&gt;
The primary goal of RIF is to facilitate the exchange of rules. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;goal-w3c-consistency&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
==== Consistency with W3C specifications ====&lt;br /&gt;
&lt;br /&gt;
RIF is intended to be a W3C specification that builds on and further develops the existing range of specifications that have been developed by the W3C. This implies that existing W3C technologies should fit well with RIF. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;goal-widescale-adoption&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
==== Widescale Adoption ====&lt;br /&gt;
&lt;br /&gt;
It is an explicit goal of the W3C that RIF will have maximal potential for widescale adoption. The wider the adoption of the specification, the more effective rule interchange becomes. This is known as the &amp;quot;network effect.&amp;quot; &lt;br /&gt;
&lt;br /&gt;
These goals, along with the use cases in Section 5, motivate the requirements in Section 4.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Structure of RIF ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
RIF is described by a set of documents, each fulfilling a different purpose and catering to possibly different audiences. The three RIF dialects that are part of the W3C recommendation and that can be used to represent RIF use cases are:&lt;br /&gt;
&lt;br /&gt;
* [[#ref-rif-core|RIF Core Dialect]], which provides a standard, base level of functionality for interchange.&lt;br /&gt;
* [[#ref-rif-bld|Basic Logic Dialect]] and [[#ref-rif-prd|Production Rule Dialect]]  provide extended functionality matching two common classes of rule engines, namely derivation rules and production rules.&lt;br /&gt;
&lt;br /&gt;
Along with these three dialects, RIF includes related documents: [http://www.w3.org/TR/rif-fld RIF Framework for Logic Dialects], [http://www.w3.org/TR/rif-dtb RIF Datatypes and Built-Ins 1.0], [http://www.w3.org/TR/rif-test RIF Test Cases], [http://www.w3.org/TR/rif-rdf-owl RIF RDF and OWL Compatibility], [http://www.w3.org/TR/rif-ucr/ RIF Use Cases and Requirements], [http://www.w3.org/TR/rif-owl-rl OWL 2 RL in RIF], [http://www.w3.org/2007/OWL/wiki/PlainLiteral rdf:PlainLiteral], [http://www.w3.org/TR/rif-xml-data RIF Combination with XML data], [http://www.w3.org/TR/rif-primer RIF Primer], and [http://www.w3.org/TR/rif-in-rdf/ RIF In RDF]. For an overview of RIF, see the [http://www.w3.org/TR/rif-overview RIF Overview].&lt;br /&gt;
&lt;br /&gt;
RIF is designed as a family of RIF dialects as shown in the following Venn diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image: RIF_DIALECTS_VENN.jpg | Venn Diagram of RIF Dialects]]&lt;br /&gt;
&lt;br /&gt;
Each dialect is a collection of components that work together, forming an interlingua. New dialects are needed for those cases in which no existing dialect provides the required rule-language features for interchange.&lt;br /&gt;
&lt;br /&gt;
The RIF Framework for Logic-based Dialects ([http://www.w3.org/TR/rif-fld RIF-FLD]) describes mechanisms for specifying the syntax and semantics of logic-based RIF dialects through a number of generic concepts. In general, a logic-based RIF dialect should specialize these general mechanisms; justifications should be provided for cases where this is not done. This specialization may include leaving out some elements of RIF-FLD in order to produce a dialect's concrete syntax and model-theoretic semantics. The RIF dialects that are part of the W3C RIF recommendation are RIF Basic Logic Dialect (RIF-BLD), which is fully specified using RIF-FLD, and RIF Production Rules Dialect (RIF-PRD), which is partially specified using RIF-FLD and supplemented by an operational semantics.&lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/TR/rif-bld RIF-BLD] (Basic Logic Dialect) is a specialization of RIF-FLD capable of representing definite Horn rules with equality and enhanced with a number of syntactic extensions to support expressive features such as objects and frames, internationalized resource identifiers (IRIs) as identifiers for concepts, and XML Schema data types.&lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/TR/rif-prd RIF-PRD] (Production Rules Dialect) specifies a production rules dialect to enable the interchange of production rules. The condition language of RIF-PRD is defined in Core as a common subset of RIF-BLD and RIF-PRD. &lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/TR/rif-core RIF-Core] (Core Dialect) specifies a common subset of RIF-BLD and RIF-PRD that includes RIF-DTB.&lt;br /&gt;
&lt;br /&gt;
The normative syntax for RIF dialects is a concrete XML syntax. A non-normative presentation syntax is additionally specified for each dialect to allow a more easily readable and compact presentation of language fragments (such as examples).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Requirements ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-semantic-tagging&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
The goals and use cases motivate a number of requirements for a Rule Interchange Format. The Working Group has approved the following requirements:  &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-implementability&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Implementability ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-semantic-precision&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Semantic precision ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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 extend RIF-Core.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-extensible&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Extensible Format ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''It must be possible to create new RIF dialects that extend existing dialects (thus providing backward compatibility) and are handled gracefully by systems which support existing dialects (thus providing forward compatibility).'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-translators&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Translators ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-standard-components&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Standard components ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-coverage&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Rule language coverage ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''Because of the great diversity of rule languages, no single interchange language is likely to be able to bridge between all. Instead, RIF provides dialects each of which targets a cluster of similar rule languages. RIF must allow intra-dialect interoperability, i.e. interoperability between semantically similar rule languages (via interchange of RIF rules) within one dialect, and should support inter-dialect interoperability, i.e. interoperability between dialects with maximum overlap.''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-compliance-model&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Compliance model ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''The RIF specifications must provide clear conformance criteria that define what is and what is not a conformant RIF implementation.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-default-behavior&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Default behavior ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-different-semantics&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Different semantics ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must cover rule languages having different semantics.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-dialects&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Limited number of dialects ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must have a standard core, and a limited number of standard dialects based upon that core.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-comments&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Embedded comments ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must be able to pass comments.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-metadata&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Embedded metadata ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must support metadata such as author and rule name.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-owl-data&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== OWL data ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must cover OWL knowledge bases as data where compatible with RIF semantics.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-rdf-data&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== RDF data ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must cover RDF triples as data where compatible with RIF semantics.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-dialect-identification&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Dialect Identification ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''The semantics of a RIF document must be uniquely determined by the content of the document, without out-of-band data.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-xml-syntax&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== XML syntax ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must have an XML syntax as its primary normative syntax.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-xml-types&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== XML types ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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 [http://www.w3.org/2005/rules/wg/charter#datatype0 Datatype support]. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-merge&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Merge Rule Sets ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must support the ability to merge rule sets.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-rulesets&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Identify Rule Sets ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must support the identification of rule sets.''  &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-xml-data&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== XML data ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF should be able to accept XML elements as data.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-rif-text&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Internationalized text ===&lt;br /&gt;
&lt;br /&gt;
''RIF must support internationalized text — that is, text that conveys additional information in terms of a language tag.''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Use Cases ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
A use case for RIF consists of a description of a problem together with a description of a solution. Most of these solutions often can be implemented using one of the existing RIF dialects in the W3C recommendation (Core, BLD, or PRD); others require the specification of a new RIF dialect.&lt;br /&gt;
&lt;br /&gt;
The set of use cases is intended to do the following:&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;motivate the need for a rule interchange format in a broad range of application domains and industrial sectors;&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;provide scenarios that explain the benefits of a rule interchange format in such scenarios and motivate the design of RIF;&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;motivate the working group's set of requirements for a rule interchange format; and&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;guide users to RIF's specified dialects.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The set of use cases was developed over several years.&lt;br /&gt;
Nearly [http://www.w3.org/2005/rules/wg/wiki/Use_Cases fifty use cases] documenting the need for a RIF were originally submitted by RIF working group members. These were grouped into  general categories and then synthesized as much as possible. The goal was to come up with a relatively small set of use cases that would refer to popular application domains and industrial sectors, and that would cover a broad range of possible requirements. Following the presentation of each use case, we briefly discuss whether it can be covered  by the existing three RIF dialects (Core, BLD, and PRD). All use cases except for 5.2 and 5.4 can be covered at least in part by at least one of the dialects. The reader will note that several cases which require negation are covered only by PRD; negation is not expressible in either BLD or Core.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- do not skip a line &lt;br /&gt;
&amp;lt;html&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px dotted black; padding:0.5em; margin: 1em; &amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;The button below can be used to show or hide the RIF examples.&amp;lt;/p&amp;gt;&amp;lt;form action=&amp;quot;&amp;quot;&amp;gt;&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;input id=&amp;quot;hide-rif&amp;quot; type=&amp;quot;button&amp;quot; value=&amp;quot;Hide Examples&amp;quot; style=&amp;quot;display:none&amp;quot;&lt;br /&gt;
  onclick=&amp;quot;display('rif', 'none');&lt;br /&gt;
           set_display_by_id('hide-rif', 'none'); &lt;br /&gt;
           set_display_by_id('show-rif', '');&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;input id=&amp;quot;show-rif&amp;quot; type=&amp;quot;button&amp;quot; value=&amp;quot;Show Examples&amp;quot; &lt;br /&gt;
  onclick=&amp;quot;display('rif','');&lt;br /&gt;
     set_display_by_id('hide-rif', ''); &lt;br /&gt;
     set_display_by_id('show-rif', 'none');&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&amp;lt;/form&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;/html&amp;gt;--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Negotiating eBusiness Contracts Across Rule Platforms ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This use case illustrates a fundamental use of RIF: to supply a vendor-neutral representation of rules. This enables rule-system developers and stakeholders to do their work: for example, to make product investments without concern for vendor lock-in, and without concern that a business partner does not have the same vendor technology. It also illustrates the fact that RIF can be used to foster collaborative work. Each developer and stakeholder can make a contribution to the joint effort without being forced to adopt the tools or platforms of the other contributors. &lt;br /&gt;
&lt;br /&gt;
John is negotiating an electronic business contract regarding the supply of various types of items that Jane's company is manufacturing. Jane and John interchange the contract-related data and rules involved in the negotiation 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 goods and services involved. In this case an XML schema and appropriate test XML documents are interchanged with their rules. Since John and Jane run applications based on different vendors' rule engines and rule languages, they interchange the rules using RIF; both vendors used can interpret the XML schema and data, and produce the results as an amended XML document. John's company defines its purchase orders in terms of an XML description of goods, packaging, delivery location, and date with delivery and payment rules. A rule proposed by John might be the following: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If an item is perishable and is delivered to John more than 10 days after the scheduled delivery date, then he will reject the item.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
This rule set can be adequately represented in RIF-Core using (ordered) relations as e.g. in standard Logic Programming, or using unordered relations using named arguments, or in a more object-oriented encoding using frames.&amp;lt;br /&amp;gt;   &lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
''Ordered representation in RIF Core presentation syntax using relations:'' &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&lt;br /&gt;
 &lt;br /&gt;
  Group &lt;br /&gt;
  (&lt;br /&gt;
      Forall ?item ?deliverydate ?scheduledate ?diffdays (&lt;br /&gt;
      ex:reject(&amp;quot;John&amp;quot; ?item) :-&lt;br /&gt;
          ex:perishable(?item)&lt;br /&gt;
          ex:delivered(?item ?deliverydate &amp;quot;John&amp;quot;)&lt;br /&gt;
          ex:scheduled(?item ?scheduledate)&lt;br /&gt;
          ?diffdays = External(func:days-from-duration(&lt;br /&gt;
                                  External(func:subtract-dateTimes(?deliverydate ?scheduledate))  &lt;br /&gt;
                               )) &lt;br /&gt;
          External(pred:numeric-greater-than(?diffdays  10)) &lt;br /&gt;
      ) &lt;br /&gt;
   ) &lt;br /&gt;
) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
Note, the nesting of external built-in functions and operations and the assignment/binding of (intermediate) result (sets) from functions to variables by equality in this example.&amp;lt;br /&amp;gt;    &lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
''Unordered representation in RIF Core presentation syntax using namened arguments:'' &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#) &lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#) &lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#) &lt;br /&gt;
 &lt;br /&gt;
  Group &lt;br /&gt;
  ( &lt;br /&gt;
      Forall ?item ?deliverydate ?scheduledate ?diffdays ( &lt;br /&gt;
      ex:reject(ex:ware -&amp;gt; ?item ex:receiver -&amp;gt; &amp;quot;John&amp;quot;) :- &lt;br /&gt;
         ex:perishable(ex:ware -&amp;gt; ?item) &lt;br /&gt;
         ex:delivered(ex:ware -&amp;gt; ?item  ex:datetime -&amp;gt; ?deliverydate  ex:receiver -&amp;gt; &amp;quot;John&amp;quot;) &lt;br /&gt;
         ex:scheduled(ex:datetime -&amp;gt; ?scheduledate  ex:ware -&amp;gt; ?item) &lt;br /&gt;
         ?diffdays = External(func:days-from-duration( &lt;br /&gt;
                                  External(func:subtract-dateTimes(?deliverydate ?scheduledate))  &lt;br /&gt;
                               )) &lt;br /&gt;
          External(pred:numeric-greater-than(?diffdays  10)) &lt;br /&gt;
      ) &lt;br /&gt;
   ) &lt;br /&gt;
) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
Note, the arbitrarily unordered named argument arguments of the user-defined relations, in contrast to external built-in functions and operations, which must have a predefined order. &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
''Object-Oriented Representation in RIF Core presentation syntax using frames:'' &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt;  Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#) &lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#) &lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#) &lt;br /&gt;
 &lt;br /&gt;
  Group &lt;br /&gt;
  ( &lt;br /&gt;
      Forall ?item ?deliverydate ?scheduledate ?diffdays ( &lt;br /&gt;
      ?item[ex:status -&amp;gt; &amp;quot;rejected&amp;quot;] :- &lt;br /&gt;
         ?item[ex:perishable -&amp;gt; true]  &lt;br /&gt;
         ?item[ex:deliveredOn -&amp;gt; ?deliverydate ex:delivered -&amp;gt; &amp;quot;John&amp;quot;]  &lt;br /&gt;
         ?item[ex:scheduledOn -&amp;gt; ?scheduledate ex:delivered -&amp;gt; &amp;quot;John&amp;quot;]  &lt;br /&gt;
         External(pred:numeric-greater-than(         &lt;br /&gt;
             External(func:days-from-duration( &lt;br /&gt;
                                  External(func:subtract-dateTimes(?deliverydate ?scheduledate))  &lt;br /&gt;
                      )) &lt;br /&gt;
             10 &lt;br /&gt;
         ) &lt;br /&gt;
      ) &lt;br /&gt;
   ) &lt;br /&gt;
) &lt;br /&gt;
&amp;lt;/code&amp;gt;  &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Jane replies with some suggested rule changes: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
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 then a discount of 18.7% will be applied to the delivered item.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
''Representation in RIF Core presentation syntax using positional relations:'' &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#) &lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#) &lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#) &lt;br /&gt;
 &lt;br /&gt;
  Group &lt;br /&gt;
  ( &lt;br /&gt;
     Forall ?item ?deliverydate ?scheduledate ?diffdays ( &lt;br /&gt;
     ex:discount(&amp;quot;John&amp;quot; ?item 18.7 ) :- &lt;br /&gt;
           ex:perishable(?item) &lt;br /&gt;
           ex:delivered(?item ?deliverydate &amp;quot;John&amp;quot;) &lt;br /&gt;
           ex:scheduled(?item ?scheduledate) &lt;br /&gt;
           ?diffdays = External(func:days-from-duration( &lt;br /&gt;
                                  External(func:subtract-dateTimes(?deliverydate ?scheduledate))  &lt;br /&gt;
                               )) &lt;br /&gt;
           External(pred:numeric-greater-than(?diffdays  7)) &lt;br /&gt;
           External(pred:numeric-less-than(?diffdays  14)) &lt;br /&gt;
     ) &lt;br /&gt;
   ) &lt;br /&gt;
) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binding of the intermeditate results to the variable &amp;quot;?diffdays&amp;quot; avoids repetition, as it used twice in the subsequent rule conditions. As demonstrated in the previous examples, similar representations for this rule can be given using slots or frames and as a production rule which asserts the conclusion as a new fact. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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 order and determine contract compliance. &lt;br /&gt;
&lt;br /&gt;
Future requests for the supply of items by John's company are defined on their purchasing web site, as the appropriate XML schema and a RIF rule set (or rule sets). This allows Jane's company and its competitors to respond electronically with XML cost sheets. Suppliers respond with multiple cost sheets with different variations on the RIF rules proposed by John's company, allowing John's company to review the alternative rules with their associated costs to determine whether they, as a business, would benefit by relaxing or adding new rules as proposed by suppliers. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by: RIF-Core, RIF-BLD, RIF-PRD'''&lt;br /&gt;
&lt;br /&gt;
The rules of this use case can be adequately represented in RIF-Core (and likewise, in RIF-BLD and RIF-PRD) by using (ordered) relations, as e.g. in standard Logic Programming,  or by using unordered relations and named arguments, or in a more object-oriented encoding using frames. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Negotiating eCommerce Transactions Through Disclosure of Buyer and Seller Policies and Preferences ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This use case concerns the ability of parties involved in formal transactions or procedures, e.g., credit card authorization of a purchase or access of private medical records, to express and protect their interests within a policy-governed framework. The goal is to formally encode the preferences, priorities, and responses of the parties in such a way that the overall policy can work as intended while still providing opportunity for automatic negotiation of terms as long as it is allowed by the policy. Utilizing RIF in this use case would extend the scope of this technology, affording a higher degree of interoperability, as well as enabling re-use and sharing of preferences through interchange. The detailed scenario below shows how this would work. &lt;br /&gt;
&lt;br /&gt;
Alice wants to buy a device at an online site called &amp;quot;eShop.&amp;quot; Alice employs software called &amp;quot;Emptor&amp;quot; that functions as automated negotiating agent for buyers. eShop employs software called &amp;quot;Venditor&amp;quot; as automated negotiating agent for sellers. &lt;br /&gt;
&lt;br /&gt;
Alice's and eShop's policies describe whom they trust and for what purposes. The negotiation is based both on their policies, which are specified as rules, and on Emptor's and Venditor's credentials. These policies and credentials are disclosed (interchanged) in order to automatically establish trust with the goal of successfully completing the transaction. &lt;br /&gt;
&lt;br /&gt;
Policies are themselves subject to access control. Thus, rule interchange is necessarily done during negotiation and in general depends on the current level of mutual trust. Since Emptor and Venditor might use different rule languages and/or engines for evaluating their own as well as imported rules, a standard rule interchange format needs to be employed for enabling the rule interchange between the two systems. &lt;br /&gt;
&lt;br /&gt;
When Alice clicks on a &amp;quot;buy it&amp;quot; button at 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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
In order to grant access a buyer must provide valid credit card information together with delivery information (address, postal code, city, and country).&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF-Core presentation syntax using relations and frames in combination: &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&lt;br /&gt;
&lt;br /&gt;
  Group&lt;br /&gt;
  (&lt;br /&gt;
    Forall ?buyer ?creditCard ?address (&lt;br /&gt;
    ex:permit_access(&amp;quot;eShop&amp;quot; ?buyer) :-&lt;br /&gt;
      ex:provide(&amp;quot;eShop&amp;quot; ?buyer)&lt;br /&gt;
      ?buyer[ex:card -&amp;gt; ?creditCard ex:deliveryAddr -&amp;gt; ?address]&lt;br /&gt;
      ex:valid_payment_method(?creditCard)&lt;br /&gt;
      ex:valid_delivery_address(?address)&lt;br /&gt;
    )   &lt;br /&gt;
 &lt;br /&gt;
    Forall ?type ?person ?first ?last ?number ?code ?date ?month ?year (&lt;br /&gt;
    ex:valid_payment_method(?card)   :-&lt;br /&gt;
        ?card[type -&amp;gt; ?type&lt;br /&gt;
              ex:holder -&amp;gt; ?person  &lt;br /&gt;
              ex:number -&amp;gt; ?number &lt;br /&gt;
              ex:code -&amp;gt; ?code&lt;br /&gt;
              ex:expiry -&amp;gt; ?date]&lt;br /&gt;
        ?person[ex:lastname -&amp;gt; ?last ex:firstname -&amp;gt; ?first]&lt;br /&gt;
        ?date[ex:month -&amp;gt; ?month ex:year -&amp;gt; ?year]&lt;br /&gt;
        ex:credential(?type ?person ?number ?code ?date)&lt;br /&gt;
    ) &lt;br /&gt;
 &lt;br /&gt;
    Forall ?address ?last ?first ?street ?strname ?number ?code ?city ?country (&lt;br /&gt;
    ex:valid_delivery_address(?address)   :-&lt;br /&gt;
       ?address[ex:name -&amp;gt; ?person ex:street -&amp;gt; ?street ex:postal_code -&amp;gt; ?code ex:city -&amp;gt; ?city ex:country -&amp;gt; ?country ]&lt;br /&gt;
       ?person[ex:lastname -&amp;gt; ?last ex:firstname -&amp;gt; ?first] &lt;br /&gt;
       ?street[name -&amp;gt; ?strname ex:number -&amp;gt; ?number] &lt;br /&gt;
       ex:declaration(?person ?street ?number ?code ?city ?country)&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
  )&lt;br /&gt;
)&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that in this example relational representation is used in combination with frame representation. Such mixing of representation styles is supported by RIF. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Rules compactly express possible ways in which a resource can be accessed; by exchanging them negotiations are shorter and privacy protection is improved. In this example, Venditor reveals part of its policy in the form of rules to enable Emptor to choose how to answer, i.e., to decide which credentials and required information to disclose. &lt;br /&gt;
&lt;br /&gt;
To determine whether Venditor's request for information is consistent with Alice's policy, Emptor takes its own rules into account. One of these rules states: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
Disclose Alice's credit card information only to online shops belonging to the Better Business Bureau.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF Core presentation syntax: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&lt;br /&gt;
&lt;br /&gt;
  Group&lt;br /&gt;
  (&lt;br /&gt;
    Forall ?Shop ?card ?Credential ?Buyer  (&lt;br /&gt;
      ex:provide(?Shop ?Buyer )  :-  &lt;br /&gt;
         ?Buyer[ex:card -&amp;gt; ?creditCard ex:deliveryAddr -&amp;gt; ?address]&lt;br /&gt;
         ex:belongs_to(?Shop  &amp;quot;Better Business Bureau&amp;quot;) &lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
    Forall ?deliveryAddr ?card ?Date ?Person ?Street  (&lt;br /&gt;
      ex:Alice[ex:card -&amp;gt; ?card ex:deliveryAddr -&amp;gt; ?deliveryAddr] :-&lt;br /&gt;
                  ?Date = ex:Date[ex:month -&amp;gt; 12 ex:year -&amp;gt; 2012]&lt;br /&gt;
                  ?Person = ex:Person[ex:lastname -&amp;gt; &amp;quot;Sure&amp;quot; ex:firstname -&amp;gt; &amp;quot;Alice&amp;quot;]&lt;br /&gt;
                  ?Street = ex:Street[name -&amp;gt; &amp;quot;North Street&amp;quot; number -&amp;gt; 111]&lt;br /&gt;
                  ?card= ex:Card[ ex:type -&amp;gt; &amp;quot;Visa&amp;quot;&lt;br /&gt;
                                  ex:holder -&amp;gt;  ?Person &lt;br /&gt;
                                  ex:number -&amp;gt; &amp;quot;123456789&amp;quot; &lt;br /&gt;
                                  ex:code -&amp;gt; &amp;quot;123&amp;quot;&lt;br /&gt;
                                  ex:expiry -&amp;gt; ?Date &lt;br /&gt;
                                 ]&lt;br /&gt;
                  ?deliveryAddr = ex:DeliveryAddress[ ex:name -&amp;gt; ?Person &lt;br /&gt;
                                                      ex:street -&amp;gt; ?Street&lt;br /&gt;
                                                      ex:postal_code -&amp;gt; &amp;quot;NE3456&amp;quot; &lt;br /&gt;
                                                      ex:city -&amp;gt; &amp;quot;New York&amp;quot; &lt;br /&gt;
                                                      ex:country -&amp;gt; &amp;quot;USA&amp;quot; &lt;br /&gt;
                                                    ]&lt;br /&gt;
     )&lt;br /&gt;
&lt;br /&gt;
   )&lt;br /&gt;
)&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
By disclosing (interchanging) the above rule, Emptor asks Venditor to provide credentials saying that it belongs to the Better Business Bureau, Alice's most trusted source of information on online shops. eShop has these credentials. Moreover, its policy contains a rule authorizing release of this credential to any potential purchaser. Hence, Venditor passes the credential to Emptor.  However, before Emptor can disclose Alice's credit card information to Venditor, it must still check whether disclosing all requested information breaks Alice's denial constraints. Alice has stated the following constraint: &lt;br /&gt;
 &lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
For purposes of anonymity, never provide both the person's birth date and postal code.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
The current RIF dialects do not specify explicit constructs for integrity constraints. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Since for this purchase, Alice birth date is not necessary, Alice's constraints are respected. Emptor therefore provides Alice's credit card information to Venditor. &lt;br /&gt;
&lt;br /&gt;
Companies that provide software such as Venditor and Emptor can make use of RIF in several ways. First, the rules expressing Alice's and/or eShop's policies could be expressed in different rule languages but still work with a common software, using RIF-based interchanges. Second, RIF would enable &lt;br /&gt;
Venditor and Emptor to work together in real time, even if these automated agents are products of different companies using different internal rule languages. When these two systems would need to exchange policy or preference information of their respective clients, they would use RIF to enable the interchange in real time. When Venditor sends its initial policy information to Emptor, it would use RIF; likewise, Emptor would take that policy and translate it from RIF to its internal representation in order to determine what it needs to do. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Not currently supported by existing RIF dialects (Core, BLD, PRD) '''&lt;br /&gt;
&lt;br /&gt;
Current RIF dialects  do not specify explicit constructs for integrity constraints; thus, this use case is not adequately supported by any of these dialects. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Collaborative Policy Development for Dynamic Spectrum Access ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This use case demonstrates how RIF leads to increased flexibility in matching the goals of end-users of a service/device, with the goals of providers and regulators of such services/devices. RIF can do that because it enables deployment of third party systems that can generate various suitable interpretations and/or translations of the sanctioned rules governing a service/device. &lt;br /&gt;
&lt;br /&gt;
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 a device to absorb the rules defining the policies of a region, or the operational protocols required to dynamically access available spectrum, is contingent upon those rules being in a form that the device can use, as well as their being tailored to work with devices in the same class having different capabilities. &lt;br /&gt;
&lt;br /&gt;
In this use-case we suppose a region adopts a policy that allows certain wireless devices to opportunistically use frequency bands that are normally reserved for certain high-priority users. The decision by the European Union to allow &amp;quot;Dynamic Frequency Selection&amp;quot; (DFS) use of the 5 GHz frequency band by wireless systems, a band intermittently used by military and weather radar, is a recent example.) &lt;br /&gt;
&lt;br /&gt;
Suppose the policy states: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
A wireless device can transmit on a 5 GHz band if no priority user is currently using that band.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
&amp;lt;!-- Representation in RIF Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt; &lt;br /&gt;
     Forall ?device ?band ?user (&amp;lt;br /&amp;gt;&lt;br /&gt;
     ex:transmit(?device ?band 5) :- &amp;lt;br /&amp;gt;&lt;br /&gt;
         not(ex:used(?user ?band))&amp;lt;br /&amp;gt;&lt;br /&gt;
      )&amp;lt;br /&amp;gt;&lt;br /&gt;
   )&amp;lt;br /&amp;gt;&lt;br /&gt;
)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt; --&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;Note, since default negation (not) such as negation as failure is not supported by RIF-BLD there is no adequate way to represent that &amp;quot;no priority user is currently using the band&amp;quot;. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
How does a device know that no priority user is currently using a band it wants to use? The answer will depend on the specific capabilities of the device. One type of device may answer this question by sensing the amount of energy it is receiving on that band. That is, it might employ the rule: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If no energy is detected on a desired band then assume no other device is using the band.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF-BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt;&lt;br /&gt;
      Forall ?device ?band ?level  (&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:used(?device ?band) :- &amp;lt;br /&amp;gt;&lt;br /&gt;
                   ex:detect(ex:energy(?level ?band))&amp;lt;br /&amp;gt;&lt;br /&gt;
                   External(pred:numeric-greater-than(?level  0))&amp;lt;br /&amp;gt;&lt;br /&gt;
      )&amp;lt;br /&amp;gt;&lt;br /&gt;
   )&amp;lt;br /&amp;gt;&lt;br /&gt;
)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;Note, the engergy detection function would require an external call for sensing  the level of energy. Such procedural attachments cannot be specified in BLD. Reaction rules provide event detection capabilities. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A second type of device may get information from a control channel that lets it know whether the desired band is being used by a priority user. That is, it might employ the rule: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If no control signal indicating use of a desired band by a priority user is detected then assume the band is available.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt;&lt;br /&gt;
      Forall ?device ?band ?user  (&amp;lt;br /&amp;gt;&lt;br /&gt;
       ex:used(?device ?band) :- &amp;lt;br /&amp;gt;&lt;br /&gt;
                   ex:detect(ex:signal(?user ?band))&amp;lt;br /&amp;gt;&lt;br /&gt;
                   ex:priority(?user,&amp;quot;high&amp;quot;).&amp;lt;br /&amp;gt;&lt;br /&gt;
      )&amp;lt;br /&amp;gt;&lt;br /&gt;
   )&amp;lt;br /&amp;gt;&lt;br /&gt;
)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
So each type of device will need to employ different &amp;quot;interpretations&amp;quot; or &amp;quot;operational definitions&amp;quot; of the policy in question. &lt;br /&gt;
&lt;br /&gt;
Now assume that there are 10 manufacturers of these 2 different types of wireless devices. Suppose that each of these manufacturers uses a distinct rule-based platform in designing its devices. Each manufacturer needs to write 2 interpretations of the policy (for each of the two types of device). That means that 20 different versions of the policy must be written, tested, and maintained. &lt;br /&gt;
&lt;br /&gt;
Enter RIF. The 10 manufacturers form a consortium. This is a third-party group that is responsible for translating regional policies into RIF. When it does so, however, it provides different versions corresponding to the possible interpretations (operational definitions) of the policy. So in this case, 2 RIF versions of the DFS policy are provided for the 2 types of device mentioned above. Each of these RIF specifications can be automatically translated into the appropriate rule-platform provided that a RIF-Compiler for the target device architecture exists. Clearly it will be in the interest of each device manufacturer to develop such compilers. That is because the manufacturer only needs to develop such a compiler ''once'' for every architecture it owns. Contrast that investment with having to produce, test, and maintain different versions of various policies over the lifetime of a product. &lt;br /&gt;
&lt;br /&gt;
This arrangement also allows the overall process to be organized in a fashion that maintains the natural division of labor in the corresponding division of artifacts produced by that labor. The policy and its various interpretations are written and maintained in platform-independent artifacts (RIF); knowledge about how to translate from 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; and the implementation implications for the various device architectures is generated automatically at the lowest level. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Partly supported by: RIF-PRD'''&lt;br /&gt;
&lt;br /&gt;
The energy detection function specified in this use case would require an external call to a device that would sense  the level of energy. Such procedural attachments cannot be specified in the current RIF dialects. Reaction rules support (complex) event detection capabilities on, e.g., event streams over sensor data. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This use case is not supported at all by RIF-BLD, and by extension, by RIF-Core. These dialects do not support negation, and&lt;br /&gt;
the use case makes explicit mention of negation, e.g. for representing that &amp;quot;no priority user is currently using the band.&amp;quot;&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Access to Business Rules of Supply Chain Partners ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. When business logic is represented in different rule languages, designing an integrated process presents a significant burden to the BP designer. &lt;br /&gt;
&lt;br /&gt;
Two primary integration modalities are possible: importing the different rule sets into a single engine and processing them in a uniform manner, or accessing the rule sets by querying remote engines and processing the results. Each modality has its uses and contra-indications. Merging rule sets of partners may not be permitted in cases where there are strong ownership boundaries. &lt;br /&gt;
&lt;br /&gt;
For example, in an insurance adjustment process, the inspection of a damaged vehicle is often performed by independent inspectors. The critical factor in determining how an insurance claim will proceed is whether the damage results in a total loss or whether a repair is feasible: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If an inspector believes a vehicle is repairable then process the claim as a repair; otherwise process the claim  as a total loss.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Determining whether a vehicle is repairable depends on the processes executed by the inspector and therefore cannot be directly integrated into the insurance company's own adjustment process. The insurance company effectively queries the inspector's logic rather than incorporating the inspector's logic into its rule set. Moreover, within the adjustment process, the overall flow will be quite different for repairable claims and total loss claims. &lt;br /&gt;
&lt;br /&gt;
Even in the case of a single company, which is nominally under a common ownership domain, information and business logic are often controlled by multiple stakeholders. For example, a large company will often be organized into semi-independent profit centers (often known as 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 when one company acquires another company. &lt;br /&gt;
&lt;br /&gt;
RIF could 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 and their own technologies. &lt;br /&gt;
&lt;br /&gt;
Realizing this sort of unified view of business rules in a deployed BP will depend on both technical and non-technical factors. Even when all parties are required to use a common rule language, there may be compelling ownership issues that mitigate against a simple merge of rule sets. When merging rule sets is not possible, a query-style access to partners' business rules may be used. In this way, RIF permits a unified dynamic view of the business rule logic independent of the rules' original form. &lt;br /&gt;
&lt;br /&gt;
For this to be viable from a business perspective  the semantics of the rules and query exchange must be completely predictable and should be loss-less. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Not supported, in a straightforward manner, by the current RIF dialects'''&lt;br /&gt;
&lt;br /&gt;
The example business rule in this use case makes explicit reference to belief, which as the discussion below indicates, is not supported by either BLD or PRD (and thus by implication not supported by Core). The reader may note that this business rule could be changed to use another term such as &amp;quot;determine&amp;quot;: e.g., &lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If an inspector determines that a vehicle is repairable then process the claim as a repair; otherwise process the claim  as a total loss.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Using another term that has a similar semantics --- i.e., indicating in some way the inspector's thought process and mental state --- does not alleviate the problem.&lt;br /&gt;
&lt;br /&gt;
BLD and PRD do not support modal operators or predicates on quoted sentences; therefore standard representations of knowledge, belief, and/or uncertainty cannot be specified in BLD and PRD. Even without such constructs, it can be possible to represent knowledge or belief using the semantics of possible worlds &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#moore|Moore1980]]]. That is, one can get the effect of saying that an agent A believes proposition P by saying that P holds in all worlds that are belief-accessible to P. For example, to get the effect of saying &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;Believe(john,overCreditLimit(bill,t))&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
one says instead&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
holds(overCreditLimit(bill),t1) :- beliefAccessible(john,t,t1)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The translation between sentences involve operators such as Know and Believe and sentences that make direct use of possible worlds relies on the possible-worlds semantics, which posits properties on the knowledge-accessibility or belief-accessibility relation. These relations correspond to axioms on the Know and Believe operators.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Such a strategy could work, to a certain extent, in RIF-PRD, but would not work in RIF-BLD. This is because expressing the standard axioms on belief or knowledge would require the use of negation, which is not supported by BLD.&lt;br /&gt;
&lt;br /&gt;
For both PRD and BLD there is an additional consideration, which is that the notion of reification is in general not supported by the dialects of RIF.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Managing Inter-Organizational Business Policies and Practices ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This use case concerns organizations that acquire rule sets from external sources and have to integrate these new rule sets into their existing rule bases. Such rule sets may be acquired in the following ways: &lt;br /&gt;
&lt;br /&gt;
* An organization may buy rule sets from expert sources &lt;br /&gt;
* An organization may use rule sets from shared interest groups such as trade associations &lt;br /&gt;
* A component of a distributed organization may acquire 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. &lt;br /&gt;
&lt;br /&gt;
The following scenario examines these different methods of acquisition and the various types of integration and management issues that may arise. &lt;br /&gt;
&lt;br /&gt;
''This scenario uses the (fictitious) car rental company, EU-Rent, used as the case study in the [http://www.omg.org/spec/SBVR/1.0/ Semantics of Business Vocabulary and Business Rules Specification]. The EU legislation discussed is also fictitious, as are the consulting companies CarWise and AutoLaw.''&lt;br /&gt;
&lt;br /&gt;
EU-Rent's corporate HQ deals with CarWise, a consulting company with expertise in managing fleets of vehicles. One service CarWise offers to its clients is negotiating with EU regulators to clarify regulations. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
* A business policy, stating that every car rental must be insured for damages to third parties.&lt;br /&gt;
* 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.&lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
Each tax schedule must have electronic signatures from two EU-Rent employees who are at least at the level of manager.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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; this will 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: &lt;br /&gt;
&lt;br /&gt;
* The rule set for car rental insurance (from CarWise), including the basic policy and the supporting rule set.&lt;br /&gt;
* The rule set for electronic compliance documentation (also from CarWise).&lt;br /&gt;
* Its own rule set for building insurance into the basic rental cost.&lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
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.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
Insurance policies that provide separate third-party coverage must not be renewed.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
EU-Rent HQ is also concerned about meeting deadlines for electronic filing. It introduces a new rule that it distributes to operating companies: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
Each electronic compliance document must have its required electronic signatures 48 hours before its filing deadline.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This rule is meant to be implemented as follows: If '48 hours before its 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.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Partially supported by RIF-PRD'''&lt;br /&gt;
&lt;br /&gt;
The business rules in this use case express norms which requires the representation of deontic operators for obligations and permissions. Deontic operators are generally represented by modal operators, as in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-Horty-deontic-logic|Horty2001]]]. As was discussed above for knowledge and belief, it is not possible to express modal operators directly within RIF dialects. However, one can use the technique discussed above, of reasoning directly within possible worlds. This is possible within PRD though not within BLD or Core. &lt;br /&gt;
&lt;br /&gt;
Moreover, in a meta programming approach it is possible to express deontic reasoning rules with RIF-PRD.  Using this approach, too, one would not be able to use BLD or Core, since some business rules express negated deontic norms.&lt;br /&gt;
&lt;br /&gt;
=== Rule set Integration for Medical Decision Support ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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 RIF makes it possible to merge rule sets from diverse sources in diverse formats into one rule-based system, thereby enabling inferences that might otherwise have remained implicit. &lt;br /&gt;
&lt;br /&gt;
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 [http://www.snomed.org 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. &lt;br /&gt;
&lt;br /&gt;
The following scenario illustrates how rule-interchange would be used in various medical decision support systems to support the following functionalities: &lt;br /&gt;
&lt;br /&gt;
* Improving situation assessment, e.g., determining when a patient needs to be put on medication, or have his medication switched. &lt;br /&gt;
* Prescribing a course of action, e.g., determining which drug is best for a patient in a particular circumstance. &lt;br /&gt;
* Improving event planning, e.g., determining whether a patient can be scheduled for a procedure given the medication that he is currently taking. &lt;br /&gt;
&lt;br /&gt;
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 &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt; system to help him decide when to switch to medications and which drugs to prescribe. The &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt; 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 RIF. Here are two specific examples of such synergistic effects. &lt;br /&gt;
&lt;br /&gt;
''This scenario discusses the fictitious expert systems &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt; 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.'' &lt;br /&gt;
&lt;br /&gt;
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 &amp;lt;tt&amp;gt;HbA1c&amp;lt;/tt&amp;gt; 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 &amp;lt;tt&amp;gt;HbA1c&amp;lt;/tt&amp;gt; level. The following rule from the ''laboratory knowledge base'' suggests that Bob's treatment at that time was not effective: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If a Type II diabetes patient's current level of HbA1c is high, then the patient's current treatment is considered to be ineffective.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD  Presentation Syntax using relations and an event calculus axiomatization:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt;&lt;br /&gt;
    Forall ?Patient ?Treatment ?Level ?T (&amp;lt;br /&amp;gt;&lt;br /&gt;
    ex:holdsAt(ex:ineffective(?Patient ?Treatment) ?T) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:holdsAt(ex:hasDisease(?Patient &amp;quot;diabetesTypeII&amp;quot;) ?T)&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:holdsAt(ex:elevated(levelOf(?Patient &amp;quot;hbA1c&amp;quot; ?Level)) ?T)&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:holdsAt(ex:treatmentPlan(?Treatment ?Patient) ?T)&amp;lt;br /&amp;gt;&lt;br /&gt;
      )&amp;lt;br /&amp;gt;&lt;br /&gt;
   )&amp;lt;br /&amp;gt;&lt;br /&gt;
)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;Note, the example requires the formalization of changeable states which can be represented by an event calculus axiomatization. [[#event-calculus|KS86]]] The EC axioms can then be represented using RIF BLD.   &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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 &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt; 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. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
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.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Based on the recommendation from &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt;, Dr. Rosen switched Bob's prescription to Glucophage and Avandia (rosiglitazone, one of the thiazolidinediones). &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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.). &lt;br /&gt;
&lt;br /&gt;
MEDIC uses a variety of sources in its reasoning, including: &lt;br /&gt;
&lt;br /&gt;
* the pharmaceutical knowledge base, described above &lt;br /&gt;
* the patient databases, which gives the patient record, including the medications a patient is currently taking &lt;br /&gt;
* the hospital medical event protocol knowledge base, which details the protocol used for different medical procedures &lt;br /&gt;
&lt;br /&gt;
In this case, MEDIC uses all three sources and pulls up the following information: &lt;br /&gt;
&lt;br /&gt;
* Metformin is contraindicated with contrast dye. &lt;br /&gt;
* Metformin is the generic form of Glucophage. &lt;br /&gt;
* Bob is taking Glucophage. &lt;br /&gt;
* The contrast MRI requires as one of its steps injecting the patient with contrast dye. &lt;br /&gt;
&lt;br /&gt;
MEDIC therefore determines that Bob should not be taking the contrast MRI at this time. &lt;br /&gt;
&lt;br /&gt;
For MEDIC to work, the rules from these different sources must be mapped to a unified interchange format. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF-PRD'''&lt;br /&gt;
&lt;br /&gt;
The use case requires the formalization of changeable states (fluents) which can be represented by e.g. an event calculus axiomatization &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#event-calculus|KS86]]]. However, to formulate the classical event calculus as a set of Horn clause rules so that it could be run as a Prolog program, negation as failure is needed, which is not supported by RIF-BLD or Core. &lt;br /&gt;
The use case can be represented in RIF-PRD which supports changeable states (modifications) and assertions and retractions of knowledge.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Interchanging Rule Extensions to OWL ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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 provide a richer language for describing dependencies between properties (binary predicates), and may also support higher-arity predicates. &lt;br /&gt;
&lt;br /&gt;
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 may need 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 labeling 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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If MAE X is bounded by Z and MAE Y is also bounded by Z then X is connected to Y.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF-Core, RIF-BLD and RIF-PRD'''&lt;br /&gt;
&lt;br /&gt;
The use case uses RIF-SWC to combine RIF Rules with OWL ontologies.&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Vocabulary Mapping for Data Integration ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
* a report on application services and associated servers, databases, and networks (from the IT department) &lt;br /&gt;
* a maintenance contracts database (from the finance department) &lt;br /&gt;
* a registry indicating which business processes use which IT services (from the business planning group) &lt;br /&gt;
&lt;br /&gt;
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 while 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. &lt;br /&gt;
&lt;br /&gt;
First, Vlad creates simple mapping rules to create a uniform, simplified view of the data in terms of a small number of concepts -- Server, Business&amp;lt;tt&amp;gt;&amp;lt;/tt&amp;gt;Process, and Dependency. This involves rules such as: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 If x is a ComputeNode in Rack r&lt;br /&gt;
    and Rack r is in Cage c&lt;br /&gt;
    and mc is a MaintenanceContract for Cage c&lt;br /&gt;
       then x is a Server with MaintenanceContract mc&lt;br /&gt;
 &lt;br /&gt;
 If x is a ComputeNode with a NetworkInterface with Port p&lt;br /&gt;
    and app is an Application running on Port p&lt;br /&gt;
       then x is a Server that hosts app&lt;br /&gt;
 &lt;br /&gt;
 If bp is a BusinessProcess that uses Application app&lt;br /&gt;
       then bp has a Dependency on app&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF-BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Forall ?X ?MC ?R ?C(&lt;br /&gt;
  ?X[rdf:type-&amp;gt;ex:Server ex:maintenanceContract-&amp;gt;?MC] :- And(&lt;br /&gt;
    ?X[rdf:type-&amp;gt;ex:ComputeNode ex:location-&amp;gt;?R] ?R#ex:Rack &lt;br /&gt;
    ?R[ex:location-&amp;gt;?C] ?C#ex:Cage&lt;br /&gt;
    ?C[ex:maintenanceContract-&amp;gt;?MC] ?MC#ex:MaintenanceContract )) &lt;br /&gt;
&lt;br /&gt;
  Forall ?X ?Ni ?P ?App (&lt;br /&gt;
   ?X[rdf:type-&amp;gt;ex:Server ex:hosts-&amp;gt;?App] :- And( &lt;br /&gt;
     ?X[rdf:type-&amp;gt;ex:ComputeNode ex:networkInterface-&amp;gt;?Ni] &lt;br /&gt;
     ?Ni[ex:port-&amp;gt;?P]  ?P#ex:Port&lt;br /&gt;
     ?App[rdf:type-&amp;gt;ex:Application ex:onPort-&amp;gt;?P])) &lt;br /&gt;
&lt;br /&gt;
  Forall ?App ?BP ( &lt;br /&gt;
   ?BP[ex:dependsOn-&amp;gt;?App] :- &lt;br /&gt;
     ?BP[rdf:type-&amp;gt;ex:BusinessProcess ex:processUses-&amp;gt;?App] )) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt; &lt;br /&gt;
 &lt;br /&gt;
He then creates rules that combine the data across his now simplified data sources, e.g. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 If bp is a BusinessProcess that has a Dependency on Application app&lt;br /&gt;
   and x is a Server with MaintenanceContract mc that hosts Application app&lt;br /&gt;
      then bp has a Dependency on mc&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF-BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt;   Forall ?App ?BP ?App ?MC( &lt;br /&gt;
   ?BP[ex:dependsOn-&amp;gt;?MC] :- &amp;lt;&lt;br /&gt;
     ?BP[rdf:type-&amp;gt;ex:BusinessProcess ex:dependsOn-&amp;gt;?App] ?App#ex:Application &lt;br /&gt;
     ?X[rdf:type-&amp;gt;ex:Server ex:hosts-&amp;gt;?App ex:maintenanceContract-&amp;gt;?MC] )) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF-BLD, RID-PRD, and RIF-Core'''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== BPEL Orchestration of Rule-Based Web Services ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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 (Social Security number, 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. &lt;br /&gt;
&lt;br /&gt;
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. Using RIF would further improve the situation. 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. &lt;br /&gt;
&lt;br /&gt;
The credit evaluation rules are themselves grouped into three rule sets that are executed sequentially. Rules in the first rule set apply thresholds to several &amp;quot;red flag&amp;quot; quantities in the credit report, such as: &lt;br /&gt;
&lt;br /&gt;
* number of times a payment was 60 days late &lt;br /&gt;
* debt-to-income ratio &lt;br /&gt;
* number of foreclosures or repossessions &lt;br /&gt;
* number of garnishments &lt;br /&gt;
* number of liens &lt;br /&gt;
* bankruptcy &lt;br /&gt;
&lt;br /&gt;
A red flag above the threshold results in denial of credit. &lt;br /&gt;
&lt;br /&gt;
Rules in the second rule set increment a credit score variable. For example: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 If applicant owns residence then add 40.&lt;br /&gt;
 If applicant rents then add 30.&lt;br /&gt;
 If applicant has lived at current address 2 to 4 years then add 20.&lt;br /&gt;
 If applicant's income is under 20000 then add 10.&lt;br /&gt;
 If applicant's income is between 40000 and 50000 then add 40.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt;Document(&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(prolog_func &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/2007/rif-prolog-builtin-function#)&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt;&lt;br /&gt;
     ex:score(0)&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
     ex:score(?Applicant ?Score) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:increment(?Applicant)&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
      prolog_func:retract(ex:score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
      prolog_func:assert(ex:score(0)).   &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant) :-   &amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:owns(?Applicant)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:retract(ex:score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 40&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(ex:score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant):-   &amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:rents(?Applicant)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:retract(score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 30&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant):-&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:lives(?Applicant ?Date),&amp;lt;br /&amp;gt;&lt;br /&gt;
   $sysTime(?CurrentDateTime)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?CurrentYear = $fn:year-from-dateTime(?CurrentDateTime)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Year = $fn:year-from-dateTime(?Date)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Diff = ?CurrentYear - ?Year&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Diff &amp;gt; 1&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Diff &amp;lt; 5&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:retract(score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 20&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(ex:score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant):-   &amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:income(?Applicant ?Income)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Income &amp;lt; 20000&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:retract(score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 10&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(ex:score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant):-&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:income(?Applicant ?Income)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Income &amp;lt; 50000&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Income &amp;gt; 40000&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:retract(ex:score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 40&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(ex:score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;A goal-driven solution which makes use of assert and retract (not supported by BLD) to update a global score value, which is stored in a fact.&lt;br /&gt;
&amp;lt;/p&amp;gt; &lt;br /&gt;
&lt;br /&gt;
The third and final rule set compares the applicant's credit score and income to threshold values, and makes the final decision to approve or deny credit to the applicant. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF-PRD'''&lt;br /&gt;
&lt;br /&gt;
This use case requires a goal-driven solution which makes use of assert and retract  to update a global score value. Assert and retract are not supported by BLD or Core; indeed, there is no such similar notion within BLD or Core.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Publishing Rules for Interlinked Metadata ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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 &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;imd.example.org. Besides the ground facts, which can be expressed in RDF, the metadata might also have general rules like the following: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 Every science fiction movie is a movie.&lt;br /&gt;
 Every movie produced before 1930 is black and white.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD (Abridged) Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; ?Movie#ex:Movie :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Movie#ex:ScienceFictionMovie.&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ?Movie#ex:BlackWhiteMovie :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Movie#ex:Movie[ex:date -&amp;gt; ?Date]&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Date &amp;lt; &amp;quot;1930&amp;quot;^^xs:dateTime.&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;  &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
Published rules also allow combining data from different sources to exploit this knowledge. Consider an alternative database of movies published at &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;altmd.example.org. In addition to metadata, it again publishes its own rules: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 All movies listed at &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;altmd.example.org but not listed at &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;imd.example.org are independent movies.&lt;br /&gt;
 All movies with budgets below 5 million USD are low-budget movies.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD (Abridged) Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; ?Movie#ex:IndependentMovie :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    listed(?Movie#ex:Movie,&amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//altmd.example.org&amp;gt;)&amp;lt;br /&amp;gt;&lt;br /&gt;
    not(listed(?Movie#ex:Movie,&amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//imd.example.org&amp;gt;)). 	&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ?Movie#ex:LowBudgetMovie :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Movie#ex:Movie [date -&amp;gt; ?Date, budget -&amp;gt; ?Budget]&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Budget &amp;lt; 5000000^^xs:long.&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;  &lt;br /&gt;
&lt;br /&gt;
Publication of rules with explicit references to other rule sets 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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 If Charlie is currently attending a public talk according to &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;charlie.example.org/calender.ical&lt;br /&gt;
     then leave him a voicemail message&lt;br /&gt;
 &lt;br /&gt;
 If Charlie is currently in a meeting according to &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;charlie.example.org/calender.ical&lt;br /&gt;
   and the importance is high&lt;br /&gt;
     then call his cell number&lt;br /&gt;
 &lt;br /&gt;
 If Charlie currently has no appointments according to &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;charlie.example.org/calender.ical&lt;br /&gt;
     then call his office number&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD (Abridged) Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; contactInfo(&amp;quot;Charlie&amp;quot; ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    sysTime(?Time)&amp;lt;br /&amp;gt;&lt;br /&gt;
    attending(&amp;quot;Charlie&amp;quot; &amp;quot;talk&amp;quot; ?Time)&amp;lt;br /&amp;gt;&lt;br /&gt;
    contact(&amp;quot;Charlie&amp;quot; &amp;quot;voicemail&amp;quot; ?ContactInfo).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contactInfo(&amp;quot;Charlie&amp;quot; ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    sysTime(?Time)&amp;lt;br /&amp;gt;&lt;br /&gt;
    attending(&amp;quot;Charlie&amp;quot; &amp;quot;meeting&amp;quot; ?Time)&amp;lt;br /&amp;gt;&lt;br /&gt;
    contact(&amp;quot;Charlie&amp;quot; &amp;quot;cell number&amp;quot; ?ContactInfo).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contactInfo(&amp;quot;Charlie&amp;quot;, ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    sysTime(?Time),&amp;lt;br /&amp;gt;&lt;br /&gt;
    not(attending(&amp;quot;Charlie&amp;quot;,?Event, ?Time)),&amp;lt;br /&amp;gt;&lt;br /&gt;
    contact(&amp;quot;Charlie&amp;quot;, &amp;quot;office number&amp;quot;, ?ContactInfo).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 sysTime(?Time) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    % get the actual system time e.g. via a built-in&amp;lt;br /&amp;gt;&lt;br /&gt;
    % or procedural attachment call to Java or C++.&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Time = External(call(java.util.Calendar().getInstance())).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 attending(&amp;quot;Charlie&amp;quot;,&amp;quot;talk&amp;quot;, ?CurrentTime) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    % getEventData would implement the functionality to dynamically access and query&amp;lt;br /&amp;gt;&lt;br /&gt;
    % &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/calender.ical&amp;lt;br /&amp;gt;&lt;br /&gt;
    getEventData(&amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/calender.ical&amp;gt;,?EventTitle,?Type,?StartDate,?EndDate),&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Type = &amp;quot;talk&amp;quot;,&amp;lt;br /&amp;gt;&lt;br /&gt;
    External(op:dateTime-less-than(?CurrentTime,?EndDate),&amp;lt;br /&amp;gt;&lt;br /&gt;
    External(op:dateTime-greater-than(?CurrentTime,?StartDate).&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;        &lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
 attending(&amp;quot;Charlie&amp;quot;,&amp;quot;meeting&amp;quot;, ?CurrentTime) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    getEventData(&amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/calender.ical&amp;gt;,?EventTitle,?Type,?StartDate,?EndDate),&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Type = &amp;quot;meeting&amp;quot;,&amp;lt;br /&amp;gt;&lt;br /&gt;
    External(op:dateTime-less-than(?CurrentTime,?EndDate),&amp;lt;br /&amp;gt;&lt;br /&gt;
    External(op:dateTime-greater-than(?CurrentTime,?StartDate).&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;       &lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contact(&amp;quot;Charlie&amp;quot;, &amp;quot;voicemail&amp;quot;, ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    % retrieve the Voice mail number, e.g. from&amp;lt;br /&amp;gt;&lt;br /&gt;
    % Charlie's vCard, &amp;lt;br /&amp;gt;&lt;br /&gt;
    % e.g. xmlns:vCard = &amp;quot;&amp;lt;nowiki&amp;gt;http://www.w3.org/2001/vcard-rdf/3.0#&amp;quot;&amp;lt;/nowiki&amp;gt;&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard:FN&amp;gt; -&amp;gt; &amp;quot;Charlie&amp;quot;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard_TEL&amp;gt; -&amp;gt; ?Telephone],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf:type&amp;gt; -&amp;gt; &amp;lt;nowiki&amp;gt;&amp;lt;http://www.w3.org/2001/vcard-rdf/3.0#voice&amp;gt;&amp;lt;/nowiki&amp;gt;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf_value&amp;gt; -&amp;gt; ?ContactInfo].&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contact(&amp;quot;Charlie&amp;quot;, &amp;quot;cell number&amp;quot;, ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard:FN&amp;gt; -&amp;gt; &amp;quot;Charlie&amp;quot;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard_TEL&amp;gt; -&amp;gt; ?Telephone],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf:type&amp;gt; -&amp;gt; &amp;lt;nowiki&amp;gt;&amp;lt;http://www.w3.org/2001/vcard-rdf/3.0#cell&amp;gt;&amp;lt;/nowiki&amp;gt;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf_value&amp;gt; -&amp;gt; ?ContactInfo].&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contact(&amp;quot;Charlie&amp;quot;, &amp;quot;office number&amp;quot;, ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard:FN&amp;gt; -&amp;gt; &amp;quot;Charlie&amp;quot;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard_TEL&amp;gt; -&amp;gt; ?Telephone],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf:type&amp;gt; -&amp;gt; &amp;lt;nowiki&amp;gt;&amp;lt;http://www.w3.org/2001/vcard-rdf/3.0#work&amp;gt;&amp;lt;/nowiki&amp;gt;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf_value&amp;gt; -&amp;gt; ?ContactInfo]. &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;intelligent&amp;quot; crawling and search. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF-PRD'''&lt;br /&gt;
&lt;br /&gt;
Since negation is not supported by RIF-BLD or RIF-Core it is not possible to express ''... but not listed at ...''.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Conclusion ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
The goal of the RIF working group is to provide representational 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. &lt;br /&gt;
&lt;br /&gt;
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, for example, to perform and 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, and determine the need for human intervention. &lt;br /&gt;
&lt;br /&gt;
In light of this diversity, rather than being a single all-encompassing format, RIF consists 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. &lt;br /&gt;
&lt;br /&gt;
RIF has been designed in such a way that it is possible to create new dialects (extensibility) according to the overall 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. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
&lt;br /&gt;
; [Horty2001]&lt;br /&gt;
: ''Agency and Deontic Logic'', John F. Horty, Oxford University Press, 2001.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;event-calculus&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
; [KS86]&lt;br /&gt;
: Kowalski, R.A. and M.J. Sergot, ''A logic-based calculus of events.'' New Generation Computing, 1986. 4: p. 67-95.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;moore&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
; [Moore80]&lt;br /&gt;
: Moore, R.C., ''Reasoning about Knowledge and Action,'' SRI TR-191, 1980.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-owl-reference&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
; [OWL-Reference]&lt;br /&gt;
: ''OWL Web Ontology Language Reference'', M. Dean, G. Schreiber, Editors, W3C Recommendation, 10 February 2004. Latest version available at http://www.w3.org/TR/owl-ref/.&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-Horty-deontic-logic&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-rif-bld&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
; [RIF-BLD]&lt;br /&gt;
: ''RIF Basic Logic Dialect'', Boley H. and Kifer M. (Editors), W3C Rule Interchange Format Working Group Draft. Latest Version available at http://www.w3.org/2005/rules/wiki/BLD.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-rif-core&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
; [RIF-Core]&lt;br /&gt;
: ''RIF Core Dialect'', Harold Boley, Gary Hallmark, Michael Kifer, Adrian Paschke, Axel Polleres and Dave Reynolds (Editors), W3C Rule Interchange Format Working Group Draft. Latest Version available at http://www.w3.org/2005/rules/wiki/Core.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-rif-prd&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
; [RIF-PRD]&lt;br /&gt;
: ''RIF Production Rule Dialect'', de Sainte Marie C., Paschke A., and Hallmark G. (Editors), W3C Rule Interchange Format Working Group Draft. Latest Version available at http://www.w3.org/2005/rules/wiki/PRD.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Appendix: Change Log (Informative) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This appendix summarizes the main changes to this document since its publication as a Working Draft.&lt;br /&gt;
&lt;br /&gt;
Changes since the [http://www.w3.org/TR/rif-ucr/ draft of December 18th, 2008]:&lt;br /&gt;
* [[#Structure_of_RIF|the section describing the structure of RIF]] has been updated with newer RIF documents;&lt;br /&gt;
* all code examples have been removed from the document;&lt;br /&gt;
* each use case concludes by indicating the support of the use case by the current RIF dialects Core, BLD, and PRD. In addition, a brief discussion of the features of the use case that may affect a dialect's support for that use case is sometimes included;&lt;br /&gt;
* an informative change log section has been added;&lt;br /&gt;
* the distinction between general and basic requirements has been removed, thereby flattening the list of requirements.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;/div&gt;</description>
			<pubDate>Mon, 04 Feb 2013 16:42:26 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Talk:UCR</comments>		</item>
		<item>
			<title>XML-Data</title>
			<link>http://www.w3.org/2005/rules/wiki/XML-Data</link>
			<description>&lt;p&gt;Sandro:&amp;#32;added changelog id, needed for SOTD&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NUMBEREDHEADINGS__&lt;br /&gt;
{{TR|title=RIF Combination with XML data}}&lt;br /&gt;
&amp;lt;div id='editors'&amp;gt;&lt;br /&gt;
; Editors:&lt;br /&gt;
: Christian de Sainte Marie, IBM&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
; Abstract&lt;br /&gt;
: &amp;lt;div id='abstract'&amp;gt;&amp;lt;p&amp;gt;&amp;lt;/p&amp;gt; &amp;lt;p&amp;gt;&amp;lt;/p&amp;gt; &amp;lt;p&amp;gt;&amp;lt;/p&amp;gt; &amp;lt;p&amp;gt;This document, developed by the [http://www.w3.org/2005/rules/wiki/RIF_Working_Group Rule Interchange Format (RIF) Working Group], specifies how a RIF document can be combined with XML data. &amp;lt;/p&amp;gt; &amp;lt;p&amp;gt;&amp;lt;/p&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
; Status of this Document&lt;br /&gt;
: @@update This is an automatically generated Mediawiki page, made from some sort of W3C-style spec.&lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/Consortium/Legal/ipr-notice#Copyright Copyright] &amp;amp;copy; 2009 [http://www.w3.org/ W3C]&amp;lt;sup&amp;gt;&amp;amp;reg;&amp;lt;/sup&amp;gt; ([http://www.csail.mit.edu/ MIT], [http://www.ercim.eu/ ERCIM], [http://www.keio.ac.jp/ Keio]), All Rights Reserved. W3C [http://www.w3.org/Consortium/Legal/ipr-notice#Legal_Disclaimer liability], [http://www.w3.org/Consortium/Legal/ipr-notice#W3C_Trademarks trademark] and [http://www.w3.org/Consortium/Legal/copyright-documents document use] rules apply.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id='docbody'&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-overview&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
== Overview ==&lt;br /&gt;
&lt;br /&gt;
The Rule Interchange Format (RIF) is a format for interchanging rules over the Web. Rules that are exchanged using RIF may refer to external data sources and may be based on data models that are represented using a language different from RIF. This document specifies how combinations of RIF documents and XML data, possibly associated with XML schemas, are interpreted.&lt;br /&gt;
&lt;br /&gt;
Extensible Markup Language (XML) is a simple, flexible text format derived from SGML (ISO 8879). Originally designed to meet the challenges of large-scale electronic publishing, XML is also playing an increasingly important role in the exchange of a wide variety of data on the Web and elsewhere. The XML Schema Definition Language offers facilities for describing the structure and constraining the contents of XML documents. The schema language, which is itself represented in an XML vocabulary, provides a way to describe and to share the data model that is associated with the data in an XML document.&lt;br /&gt;
&lt;br /&gt;
This document specifies a standard semantics for combinations of RIF documents and XML data, with or without an associated XML schema. The specification relies on the abstract XQuery 1.0 and XPath 2.0 Data Model &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xdm|XDM]]] to specify what information is accessible in the data, and on XPath 2.0 expressions &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xpath-20|XPath 2.0]]] to select pieces of that information. It relies on XML Schema Component Designators &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xsd-cd|XSD-CD]]] expressions to provide unambiguous designators for XML schema types and schema elements in combinations where the XML data is associated with an XML schema.&lt;br /&gt;
&lt;br /&gt;
[[#ref-xpath-20|XPath 2.0]] is a non-XML expression language that allows the processing of values conforming to the data model defined in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xdm|XDM]]]. The result of an XPath expression may be a selection of nodes from the input data model, or an atomic value, or more generally, any sequence allowed by the data model. The name of the language derives from its most distinctive feature, the path expression, which provides a means of hierarchic addressing of the nodes in an XML tree.&lt;br /&gt;
&lt;br /&gt;
[[#ref-xsd-cd|XML Schema Component Designators]] (XSD-CD) is a non-XML expression language that provides reliable and unambiguous designators for XML schema components. The specification divides the problem of constructing schema component designators into two parts: defining a designator for an assembled schema, and defining a designator for a particular schema component or schema components, understood relative to a designated schema. This specification uses only a limited subset of the schema component path expression language, from the second part.&lt;br /&gt;
&lt;br /&gt;
According to this specification, XPath and component designator expressions are represented as string constants in RIF formulas. Although the semantics of RIF and XML data combinations is specified with respect to any valid [[#ref-xpath-20|XPath 2.0]] expression, conforming implementations are required to support only a limited subset. Future versions of this specification may extend that subset.&lt;br /&gt;
&lt;br /&gt;
The [[#ref-xdm|XQuery 1.0 and XPath 2.0 Data Model]] (XDM) is based on the ''infoset'' &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-infoset|Infoset]]], possibly augmented with information resulting from the validation of the XML data against an XML schema, or ''post-schema validation infoset'' (PSVI), according to the specification W3C XML Schema Definition Language (XSD) 1.1 Part 1: Structures &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xsd11-1|XSD 1.1 Part 1]]]. An instance of the data model can also be constructed directly through application APIs, or from non-XML sources such as relational tables in a database. The semantics for the combination of RIF documents with XML data applies, therefore, to the combination of RIF documents with non-XML data as well, where the XML binding of the data is only used to refer to it in the interchanged rules. This is likely to be of particular interest when an XML schema is interchanged along with the RIF document. &lt;br /&gt;
&lt;br /&gt;
Like the [[#ref-xdm|XQuery 1.0 and XPath 2.0 Data Model]], the semantics of combinations of RIF documents and XML data that is specified in this document supports the following classes of XML data:&lt;br /&gt;
* Well-formed documents conforming to [Namespaces in XML] or [Namespaces in XML 1.1].&lt;br /&gt;
* DTD-valid documents conforming to [Namespaces in XML] or [Namespaces in XML 1.1], and&lt;br /&gt;
* W3C XML Schema-validated documents.&lt;br /&gt;
&lt;br /&gt;
Accordingly, this document specifies how a RIF document is combined with well-formed -- and, where an XML schema is specified, schema-valid --  XML documents. The semantics is independent on the provenance of the XML data in a combination: it can be imported explicitly in a RIF document, or combined on the consumer-side, or a combination of both. However, only XML schemas that are explicitly imported in the RIF document are taken into account for the interpretation of the combination. This provides a way to communicate the data model that is intended, in a RIF document, for the data source, without specifying an actual data source.&lt;br /&gt;
&lt;br /&gt;
Section 2 specifies a normative standard semantics for RIF combinations with XML data: first, an XPath 2.0 and XSD-CD based syntax is specified, that is used to relate RIF formulas to XML data items in a combinations (section 2.1). Then, a model-theoretics semantics is given to RIF BLD combination with XML data, with and without associated XML schema (section 2.2); the operational semantics of RIF PRD combinations with XML data is, then, defined, based on the definition of a RIF BLD+XML data combined interpretation (section 2.3); finally, the semantics of RIF Core combinations with XML data is defined with respect to the model-theoretic semantics of the combination of RIF BLD and XML data and the operational semantics of the combination of RIF PRD and XML data (section 2.4).&lt;br /&gt;
&lt;br /&gt;
Section 3 specifies how the &amp;lt;tt&amp;gt;rif:Import&amp;lt;/tt&amp;gt; directive is extended to support the import of XML data and XML schemas in a RIF document.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
The semantics of RIF combinations with XML data imports the semantics of the XPath2.0 expressions that are used to relate RIF formulas to XML data: as a consequence, the interpretation of RIF formulas in a combination with XML data is more restrictive than their interpretation outside of a combination, even if the XML data in the combination is empty. Notice, however, that, in practice, there can never be an ambiguity regarding under what semantics a RIF document must be interpreted: a RIF document is interpreted under the combined semantics specified in the document if and only if it imports XML data or XML schemas explicitly.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Combination with XML data and/or schema constrains the interpretation of RIF formulas and give them special semantics. As a result, the semantics of RIF when XML data and schema is imported is not the same as the semantics of RIF alone, even if the imported XML data and schema are empty.&lt;br /&gt;
&lt;br /&gt;
Section 4 specifies the conformance criteria for this specification.&lt;br /&gt;
&lt;br /&gt;
Implementation of this specification requires a good understanding of [[#ref-xpath-20|XPath 2.0]] and the [[#ref-xdm|XQuery 1.0 and XPath 2.0 Data Model]]. However, this document can be read and understood without a deep knowledge of these two specifications. For the convenience of the reader, the definition of terms from the [[#ref-xpath-20|XPath 2.0]], [[#ref-xsd-cd|XSD-CD]] and the [[#ref-xdm|XDM]] specifications, that are of particular importance for this document, are repeated in the [[#appendix-glossary|Appendix A: Glossary]]. However, the definition in the glossary are non-normative: the only normative definitions are as specified in the &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xpath-20|XPath 2.0]]] and the &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xdm|XDM]]] recommendations, and in the [[#ref-xsd-cd|XSD-CD]] specification.&lt;br /&gt;
Such terms are shown in square bracket, with a superscript indicating ''XP'' if the term is defined in [[#ref-xpath-20|XPath 2.0]]: [thus]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;; or with a superscript indicating ''XDM'' if the term is defined in [[#ref-xdm|XDM]]:  [thus]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;; or with a superscript indicating ''CD'' if the term is defined in [[#ref-xsd-cd|XSD-CD]]:  [thus]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;CD&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
This document follows the convention used in other RIF specifications, to start definition with: '''Definition''' and end them with the symbol &amp;amp;#9744;. In the same way, examples start with: '''Example''' and end with &amp;amp;#9744;. The end symbol may be omitted if the definition or example ends with the section. &lt;br /&gt;
&lt;br /&gt;
Several prefixes are used throughout this document for notational convenience. The following bindings are assumed.&lt;br /&gt;
&lt;br /&gt;
# &amp;lt;tt&amp;gt;rif&amp;lt;/tt&amp;gt; bound to &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://www.w3.org/2007/rif&amp;lt;/nowiki&amp;gt;&amp;lt;/tt&amp;gt;&lt;br /&gt;
# &amp;lt;tt&amp;gt;xs&amp;lt;/tt&amp;gt; bound to &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://www.w3.org/2001/XMLSchema&amp;lt;/nowiki&amp;gt;&amp;lt;/tt&amp;gt;&lt;br /&gt;
# &amp;lt;tt&amp;gt;xml&amp;lt;/tt&amp;gt; bound to &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://www.w3.org/XML/1998/namespace&amp;lt;/nowiki&amp;gt;&amp;lt;/tt&amp;gt;&lt;br /&gt;
# &amp;lt;tt&amp;gt;fn&amp;lt;/tt&amp;gt; bound to &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://www.w3.org/2005/xpath-functions&amp;lt;/nowiki&amp;gt;&amp;lt;/tt&amp;gt;&lt;br /&gt;
# &amp;lt;tt&amp;gt;pred&amp;lt;/tt&amp;gt; bound to &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://www.w3.org/2007/rif-builtin-predicate&amp;lt;/nowiki&amp;gt;&amp;lt;/tt&amp;gt;&lt;br /&gt;
# &amp;lt;tt&amp;gt;func&amp;lt;/tt&amp;gt; bound to &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://www.w3.org/2007/rif-builtin-function&amp;lt;/nowiki&amp;gt;&amp;lt;/tt&amp;gt;&lt;br /&gt;
# &amp;lt;tt&amp;gt;xscd&amp;lt;/tt&amp;gt; bound to &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://www.w3.org/2009/xmlschema-ref&amp;lt;/nowiki&amp;gt;&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-combination&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== RIF combination with XML data ==&lt;br /&gt;
&lt;br /&gt;
This section specifies the normative semantics of the combination of RIF formulas and XML data, for RIF Core, RIF PRD and RIF BLD, where the XML data may be associated with an XML schema.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-rif+xml-data-combination&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
'''Definition (RIF+XML data combination).''' A '''''RIF+XML data combination''''' is a triple &amp;lt;''R'', ''E'', ''S''&amp;gt;, where ''R'' is a RIF formula (document or non-document), ''E'' is a, possibly empty, set of data model [nodes]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; that contains the information that is represented in the XML data, and ''S'' is a, possibly empty, set of XML schema definitions.&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
&lt;br /&gt;
For the purpose of evaluating the XPath 2.0 expressions that are used, in ''R'', to access the XML data that is represented in ''E'', the [in-scope schema definitions]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; are the schema definitions in ''S'' and all their components.&lt;br /&gt;
&lt;br /&gt;
This specification does not describe or prescribe how the set of data model [nodes]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;, in a RIF+XML data combination, is obtained: it may result from parsing one or more XML documents and/or validating them against one or more XML schemas, or it may be created by methods other than parsing and/or schema-validating XML documents.&lt;br /&gt;
&lt;br /&gt;
However, in a RIF+XML data combination &amp;lt;''R, E, S''&amp;gt;, any information item in ''E'' that represents an instance of a schema definition that is an element of ''S'' or a component in an element of ''S'', must be valid with respect to that schema definition.&lt;br /&gt;
&lt;br /&gt;
This specification does not prescribe the behaviour of a conformant implementation when the set of data model [nodes]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; in a RIF+XML data combination does not satisfy the above validity constraint, or any relevant constraint from the XPath 2.0, XDM or XSD-CD specifications.&lt;br /&gt;
&lt;br /&gt;
=== Syntax ===&lt;br /&gt;
&lt;br /&gt;
This section addresses how a RIF formula interacts with the XML data, in a RIF+XML data combination; that is, this section specifies how the access to XML data, and to XML schema information, if available, is represented in RIF formulas, for the purpose of combining them.&lt;br /&gt;
&lt;br /&gt;
The basic idea is that the object-attribute-value semantics of RIF frame formulas is used, in the combination of RIF formulas and XML data, to exploit the intended semantics of the relation between a [context node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;, an XPath 2.0 expression and the sequence that the expression matches in the context of the node: in the context of a RIF+XML data combination &amp;lt;''R, E, S''&amp;gt;, frame formulas of the form &amp;lt;tt&amp;gt;object[&amp;quot;''some XPath expression''&amp;quot;-&amp;gt;val]&amp;lt;/tt&amp;gt;, where the &amp;lt;tt&amp;gt;object&amp;lt;/tt&amp;gt; term is interpreted as an data model [node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; in ''E'', mean that &amp;lt;tt&amp;gt;val&amp;lt;/tt&amp;gt; can be derived, in a way to be specified in this document, from the sequence of items that the XPath expression matches in the context of the node denoted by &amp;lt;tt&amp;gt;object&amp;lt;/tt&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
This document specifies the semantics of RIF+XML data combinations, in general terms, for any valid XPath 2.0 expression. But some of the details are specified normatively for a limited subset of XPath 2.0 expressions only. Namely, conforming implementations must support the XPath 2.0 expressions specified by the following EBNF grammar:&lt;br /&gt;
 RIFexpr               ::= StepExpr | ValueExpr | AbbreviatedExpr&lt;br /&gt;
 AbbreviatedExpr       ::= ElementName | '@' AttributeName&lt;br /&gt;
 ValueExpr             ::= 'fn:data(' ( StepExpr | '.' ) ')'&lt;br /&gt;
 StepExpr              ::= StepAxis ( NameTest | KindTest ) ('[' Position ']')?&lt;br /&gt;
 StepAxis              ::= 'self::' | 'child::' | 'attribute::'&lt;br /&gt;
 NameTest              ::= ElementName | AttributeName&lt;br /&gt;
 KindTest              ::= ElementTest&lt;br /&gt;
                           | AttributeTest&lt;br /&gt;
                           | SchemaElementTest&lt;br /&gt;
                           | SchemaAttributeTest&lt;br /&gt;
 ElementTest           ::= 'element' '(' (ElementNameOrWildcard (',' TypeName '?'?)?)? ')'&lt;br /&gt;
 SchemaElementTest     ::= 'schema-element' '(' ElementDeclaration ')'&lt;br /&gt;
 ElementDeclaration    ::= ElementName&lt;br /&gt;
 AttributeTest         ::= 'attribute' '(' (AttribNameOrWildcard (',' TypeName)?)? ')'&lt;br /&gt;
 SchemaAttributeTest   ::= 'schema-attribute' '(' AttributeDeclaration ')'&lt;br /&gt;
 AttributeDeclaration  ::= AttributeName&lt;br /&gt;
 ElementNameOrWildcard ::= ElementName | '*'&lt;br /&gt;
 ElementName           ::= QName&lt;br /&gt;
 AttribNameOrWildcard  ::= AttributeName | '*'&lt;br /&gt;
 AttributeName         ::= QName&lt;br /&gt;
 TypeName              ::= QName&lt;br /&gt;
 Position              ::= [1..9] [0..9]*&lt;br /&gt;
&lt;br /&gt;
Future versions of this specification may extend that subset.&lt;br /&gt;
&lt;br /&gt;
XPath expressions are represented in RIF as &amp;lt;tt&amp;gt;xs:string&amp;lt;/tt&amp;gt; constants.&lt;br /&gt;
&lt;br /&gt;
{{EdNote|text=Alternatively, an additional symbol space, &amp;lt;tt&amp;gt;rif:xpath&amp;lt;/tt&amp;gt;, could be added to [[#ref-dtb|RIF built-in data types]]: in that case, XPath expressions would be represented as &amp;lt;tt&amp;gt;rif:xpath&amp;lt;/tt&amp;gt; constants.}}&lt;br /&gt;
&lt;br /&gt;
XPath 2.0 unabbreviated syntax must be used in the normative RIF/XML syntax, except when the expression is a simple &amp;lt;tt&amp;gt;StepExpr&amp;lt;/tt&amp;gt; and the test is a &amp;lt;tt&amp;gt;NameTest&amp;lt;/tt&amp;gt;: in that case, the abbreviated syntax must be used in the normative RIF/XML syntax.&lt;br /&gt;
&lt;br /&gt;
Both syntaxes, abbreviated and unabbreviated, are allowed in the non-normative RIF presentation syntax.&lt;br /&gt;
&lt;br /&gt;
When a string constant is evaluated as an XPath expression, the [statically known namespaces]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; are the in-scope namespaces for the containing element in the RIF formula.&lt;br /&gt;
&lt;br /&gt;
Likewise, the object-class and subclass-superclass semantics of RIF member and subclass formulas is used to exploit the intended semantics of the relation between an XML element and its XML schema type, and of the relation between two XML schema types, when information on classes and types definitions is available from imported XML schemas. RIF member formulas of the form: &amp;lt;tt&amp;gt;object&amp;amp;nbsp;#&amp;amp;nbsp; &amp;quot;''an XSD-CD component path expression''&amp;quot;&amp;lt;/tt&amp;gt;, where the &amp;lt;tt&amp;gt;object&amp;lt;/tt&amp;gt; term is interpreted as a element [node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; ''e &amp;amp;isin; E'', mean that the XML fragment represented by ''e'' satisfies the XML schema definition designated by the XSD-CD component path expression.&lt;br /&gt;
&lt;br /&gt;
In the same way, subclass expressions of the form: &amp;lt;tt&amp;gt;&amp;quot;''sub''&amp;quot;&amp;amp;nbsp;##&amp;amp;nbsp;&amp;quot;''SUP''&amp;quot;&amp;lt;/tt&amp;gt; where, both, &amp;lt;tt&amp;gt;&amp;quot;''sub''&amp;quot;&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;&amp;quot;''SUP''&amp;quot;&amp;lt;/tt&amp;gt; are XSD-CD schema component path expressions, mean that the schema types ''T&amp;lt;sub&amp;gt;sub&amp;lt;/sub&amp;gt;'' and ''T&amp;lt;sub&amp;gt;SUP&amp;lt;/sub&amp;gt;'', whose definitions are designated by the XSD-CD expressions &amp;lt;tt&amp;gt;&amp;quot;''sub''&amp;quot;&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;&amp;quot;''SUP''&amp;quot;&amp;lt;/tt&amp;gt;, respectively, satisfy ''[derived-from]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;(T&amp;lt;sub&amp;gt;sub&amp;lt;/sub&amp;gt;, T&amp;lt;sub&amp;gt;SUP&amp;lt;/sub&amp;gt;)'', where the pseudo-function ''derives-from'' is defined as in [[#ref-xpath-20|XPath 2.0, section 2.5.4 - Sequence type matching]].&lt;br /&gt;
&lt;br /&gt;
This specification specifies the semantics of RIF+XML data combinations that contains such member or subclass formulas for a limited subset of XSD-CD expressions, only. Namely, conforming implementations must support absolute XSD-CD expressions that designate schema types, as specified by the following EBNF grammar:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-RIFSchemaComponentPath&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
 RIFSchemaComponentDesignator ::=  SchemaDesignator '#' 'xscd' '(' SchemaComponentPath ')'&lt;br /&gt;
 SchemaDesignator             ::=  AnyURI&lt;br /&gt;
 AnyURI                       ::=  Char*	/* IRI reference: no fragment identifier */&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
 RIFSchemaComponentPath       ::=  StepSepator RelativeSchemaComponentPath &lt;br /&gt;
 RelativeSchemaComponentPath  ::=  Step (StepSeparator RelativeSchemaComponentPath)?&lt;br /&gt;
 StepSeparator                ::=  '/'&lt;br /&gt;
 Step                         ::=  AbbrevStep&lt;br /&gt;
 AbbrevStep                   ::=  AbbrevElementStep | AbbrevTypeStep&lt;br /&gt;
 AbbrevElementStep            ::=  NameTest&lt;br /&gt;
 AbbrevTypeStep               ::=  '~' NameTest&lt;br /&gt;
 NameTest                     ::=  QName | '0'&lt;br /&gt;
&lt;br /&gt;
XSD-CD component path expressions are represented in RIF as &amp;lt;tt&amp;gt;xs:string&amp;lt;/tt&amp;gt; constants.&lt;br /&gt;
&lt;br /&gt;
{{EdNote|text=Alternatively, an additional symbol space, &amp;lt;tt&amp;gt;rif:xsd-cd&amp;lt;/tt&amp;gt;, could be added to [[#ref-dtb|RIF built-in data types]]: in that case, XSD-CD expressions would be represented as &amp;lt;tt&amp;gt;rif:xsd-cd&amp;lt;/tt&amp;gt; constants.}}&lt;br /&gt;
&lt;br /&gt;
XSD-CD abbreviated syntax must be used in the normative RIF/XML syntax. Both abbreviated and unabbreviated syntaxes are allowed in the non-normative RIF presentation syntax.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
{{EdNote|text=Alternatively, classes could be represented by complete &amp;lt;tt&amp;gt;SchemaComponentDesignators&amp;lt;/tt&amp;gt; expressions as &amp;lt;tt&amp;gt;rif:iri&amp;lt;/tt&amp;gt; constants, if there were reasons to prefer the use of &amp;lt;tt&amp;gt;rif:iri&amp;lt;/tt&amp;gt; constants over &amp;lt;tt&amp;gt;xs:string&amp;lt;/tt&amp;gt; ones. In this version, we choose to keep it simple and to use only the component path part, as a string, since all the top-level schema components can be retireved in ''S'' (and the schema designator is, thus, useless).}}&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For the purpose of expanding QNames in &amp;lt;tt&amp;gt;NameTest&amp;lt;/tt&amp;gt;s, the in-scope namespace bindings are defined as all the namespace declaration in the scope of which the string is.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
{{EdNote|text=Notice that, if we choose to use complete schema component designators as &amp;lt;tt&amp;gt;rif:iri&amp;lt;/tt&amp;gt; constants, we should probably follow the XSD-CD specification, and include the namespace bindings in the XMLns pointer part of the component designator, instead.}}&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ex21&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
'''Example 2.1.''' Consider, for instance, the following rule, that says that an ''EarlyCustomer'' is a ''Customer'' whose ''Account'' number is lower than 1000 (using the RIF presentation syntax and XPath abbreviated syntax):&lt;br /&gt;
 Forall ?x, ?y&lt;br /&gt;
    (_EarlyCustomer(?y) :-&lt;br /&gt;
    And( ?x[&amp;quot;ex:Name&amp;quot; -&amp;gt; ?y]&lt;br /&gt;
         Exists ?z (And ?x[&amp;quot;ex:Account&amp;quot; -&amp;gt; ?z]&lt;br /&gt;
                        External(pred:numeric-less-or-equal(External(xs:integer(?z)) 1000)))))&lt;br /&gt;
&lt;br /&gt;
Consider, further, the following XML fragment, representing data about customers:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;CustomerTable xmlns=&amp;quot;&amp;lt;nowiki&amp;gt;http://example.org/customertable&amp;lt;/nowiki&amp;gt;&amp;quot;&lt;br /&gt;
                xmlns:xml=&amp;quot;&amp;lt;nowiki&amp;gt;http://www.w3.org/XML/1998/namespace&amp;lt;/nowiki&amp;gt;&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;Customer xml:lang=&amp;quot;en&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;Name&amp;gt; John &amp;lt;/Name&amp;gt;&lt;br /&gt;
     &amp;lt;Account&amp;gt; 111 &amp;lt;/Account&amp;gt;&lt;br /&gt;
   &amp;lt;/Customer&amp;gt;&lt;br /&gt;
   &amp;lt;Customer xml:lang=&amp;quot;fr&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;Name&amp;gt; Jane &amp;lt;/Name&amp;gt;&lt;br /&gt;
     &amp;lt;Account&amp;gt; 222 &amp;lt;/Account&amp;gt;&lt;br /&gt;
     &amp;lt;PIN&amp;gt; 222 &amp;lt;/PIN&amp;gt;&lt;br /&gt;
   &amp;lt;/Customer&amp;gt;&lt;br /&gt;
 &amp;lt;/CustomerTable&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Assuming, like in all further examples, that the pair ''(&amp;lt;tt&amp;gt;ex&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;&amp;lt;&amp;lt;nowiki&amp;gt;http://example.org/customertable&amp;lt;/nowiki&amp;gt;&amp;gt;&amp;lt;/tt&amp;gt;)'' belongs to the statically known namespaces when the XPath expressions are evaluated, the combination, under the semantics described below, of the above rule and XML data, with no associated XML schema, will entail two new facts, namely:&lt;br /&gt;
  _EarlyCustomer(&amp;quot;John&amp;quot;)&lt;br /&gt;
  _EarlyCustomer(&amp;quot;Jane&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
This rule shows how an XPath expression is used, in the rule, as an &amp;lt;tt&amp;gt;xs:string&amp;lt;/tt&amp;gt; constant, e.g.: &amp;lt;tt&amp;gt;&amp;quot;ex:Name&amp;quot;&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;&amp;quot;ex:Account&amp;quot;&amp;lt;/tt&amp;gt;, to access the children of an element [node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; as frame slots.&lt;br /&gt;
&lt;br /&gt;
Notice that, in the absence of classes and types definitions as would be provided by an associated XML schema, &amp;lt;tt&amp;gt;NameTest&amp;lt;/tt&amp;gt; are enough to exploit all the information that is avalable in the XML data, in the combination. Notice further that, with no typing information available, atomic values retrieved from the XML data can only be interpreted as strings. A consequence is that such values have to be cast into the required types when used as arguments to RIF buit-in functions and predicates.&lt;br /&gt;
&lt;br /&gt;
Notice, also, that, for the same reason, member (or subclass) formulas cannot be used in combination with the XML data: the only way (based only on the information that is available in the example) to ensure that only the &amp;lt;tt&amp;gt;ex:Name&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;ex:Account&amp;lt;/tt&amp;gt; sub-elements of &amp;lt;tt&amp;gt;ex:Customer&amp;lt;/tt&amp;gt; elements are taken into account would be to add a frame formula to the condition, to check that the variable &amp;lt;tt&amp;gt;?x&amp;lt;/tt&amp;gt; is bound to an element that is, itself, named &amp;lt;tt&amp;gt;ex:Customer&amp;quot;&amp;lt;/tt&amp;gt;:&lt;br /&gt;
 Forall ?x, ?y&lt;br /&gt;
    (_EarlyCustomer(?y) :-&lt;br /&gt;
    And( ?x[&amp;quot;ex:Name&amp;quot; -&amp;gt; ?y]&lt;br /&gt;
         ?x[&amp;quot;self::ex:Customer&amp;quot;-&amp;gt;?x]&lt;br /&gt;
         Exists ?z (And ?x[&amp;quot;ex:Account&amp;quot; -&amp;gt; ?z]&lt;br /&gt;
                        External(pred:numeric-less-or-equal(External(xs:integer(?z)) 1000)))))&lt;br /&gt;
&lt;br /&gt;
Notice that, in the absence of an XML schema against which the data must be valid, the fact &amp;lt;tt&amp;gt;?x[&amp;quot;self::ex:Customer&amp;quot;-&amp;gt;?x]&amp;lt;/tt&amp;gt; does not entail anything with respect to other properties of &amp;lt;tt&amp;gt;?x&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Now, assume that the following XML schema is associated with the above XML fragment:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;xs:schema xmlns:xs=&amp;quot;&amp;lt;nowiki&amp;gt;http://www.w3.org/2001/XMLSchema&amp;lt;/nowiki&amp;gt;&amp;quot;&lt;br /&gt;
            xmlns:xml=&amp;quot;&amp;lt;nowiki&amp;gt;http://www.w3.org/XML/1998/namespace&amp;lt;/nowiki&amp;gt;&amp;quot;&lt;br /&gt;
            targetNamespace=&amp;quot;&amp;lt;nowiki&amp;gt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.org/customertable&amp;lt;/nowiki&amp;gt;&amp;quot;&lt;br /&gt;
            xmlns=&amp;quot;&amp;lt;nowiki&amp;gt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.org/customertable&amp;lt;/nowiki&amp;gt;&amp;quot;&amp;gt;  &lt;br /&gt;
 &lt;br /&gt;
   &amp;lt;xs:simpleType name=&amp;quot;PIN&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;xs:restriction base=&amp;quot;xs:integer&amp;quot;&amp;gt;&lt;br /&gt;
       &amp;lt;xs:minInclusive value=&amp;quot;100&amp;quot;/&amp;gt;&lt;br /&gt;
       &amp;lt;xs:maxExclusive value=&amp;quot;1000&amp;quot;/&amp;gt;&lt;br /&gt;
     &amp;lt;/xs:restriction&amp;gt;&lt;br /&gt;
   &amp;lt;/xs:simpleType&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
   &amp;lt;xs:element name=&amp;quot;Name&amp;quot; type=&amp;quot;xs:string&amp;quot;/&amp;gt;&lt;br /&gt;
   &amp;lt;xs:element name=&amp;quot;Account&amp;quot; type=&amp;quot;xs:integer&amp;quot;/&amp;gt;&lt;br /&gt;
   &amp;lt;xs:element name=&amp;quot;PIN&amp;quot; type=&amp;quot;PIN&amp;quot;/&amp;gt;&lt;br /&gt;
   &lt;br /&gt;
   &amp;lt;xs:element name=&amp;quot;Customer&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;xs:complexType&amp;gt;&lt;br /&gt;
       &amp;lt;xs:sequence&amp;gt;&lt;br /&gt;
         &amp;lt;xs:element ref=&amp;quot;Name&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;xs:element ref=&amp;quot;Account&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;xs:element ref=&amp;quot;PIN&amp;quot; minOccurs=&amp;quot;0&amp;quot;/&amp;gt;&lt;br /&gt;
       &amp;lt;/xs:sequence&amp;gt;&lt;br /&gt;
     &amp;lt;/xs:complexType&amp;gt;&lt;br /&gt;
     &amp;lt;xs:attribute ref=&amp;quot;xml:lang&amp;quot;/&amp;gt;&lt;br /&gt;
   &amp;lt;/xs:element&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
   &amp;lt;xs:element name=&amp;quot;CustomerTable&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;xs:complexType&amp;gt;&lt;br /&gt;
       &amp;lt;xs:all&amp;gt;&lt;br /&gt;
         &amp;lt;xs:element ref=&amp;quot;Customer&amp;quot; minOccurs=&amp;quot;0&amp;quot;/&amp;gt;&lt;br /&gt;
       &amp;lt;/xs:all&amp;gt;&lt;br /&gt;
     &amp;lt;/xs:complexType&amp;gt;&lt;br /&gt;
   &amp;lt;/xs:element&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
 &amp;lt;/xs:schema&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When the XML schema is associated with the data, in the RIF+XML data combination, typing information can be taken into account, both, to focus on the data that represent customer information (that is, information represented in &amp;lt;tt&amp;gt;ex:Customer&amp;lt;/tt&amp;gt; elements), and to ensure that arguments to built-in functions and predicates are properly typed. The example rule could, then, be written as follows (notice that this version of the rule uses unabbreviated XPath syntax):&lt;br /&gt;
&lt;br /&gt;
 Forall ?x, ?y&lt;br /&gt;
     (_EarlyCustomer(?y) :-&lt;br /&gt;
     And( ?x # &amp;quot;/ex:Customer&amp;quot;&lt;br /&gt;
          ?x[&amp;quot;child::schema-element(ex:Name)&amp;quot; -&amp;gt; ?y]&lt;br /&gt;
          Exists ?z (And ?x[&amp;quot;child::schema-element(ex:Account)&amp;quot; -&amp;gt; ?z]&lt;br /&gt;
                         External(pred:numeric-less-or-equal(?z 1000)))))&lt;br /&gt;
&lt;br /&gt;
In that case, the assertion of the class membership: &amp;lt;tt&amp;gt;?x # &amp;quot;/ex:Customer&amp;quot;&amp;lt;/tt&amp;gt;, entails that &amp;lt;tt&amp;gt;?x&amp;lt;/tt&amp;gt; has all the properties that are required to validate against the schema definition of the element &amp;lt;tt&amp;gt;ex:Customer&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Another rule example, below, shows how another kind of XPath expression, used as an &amp;lt;tt&amp;gt;xs:string&amp;lt;/tt&amp;gt; constant: &amp;lt;tt&amp;gt;&amp;quot;@xml:lang&amp;quot;&amp;lt;/tt&amp;gt;, is used, in a RIF+XML data combination, to access an attribute [node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; as a frame slot:&lt;br /&gt;
 Forall ?x, ?y&lt;br /&gt;
    (_SpeaksEnglish(?y) :-&lt;br /&gt;
    And( ?x[&amp;quot;@xml:lang&amp;quot; -&amp;gt; &amp;quot;en&amp;quot;^^xs:language])&lt;br /&gt;
         ?x[&amp;quot;ex:Name&amp;quot; -&amp;gt; ?y])&lt;br /&gt;
&lt;br /&gt;
Assuming that the pair ''(&amp;lt;tt&amp;gt;xml&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;&amp;lt;&amp;lt;nowiki&amp;gt;http://www.w3.org/XML/1998/namespace&amp;lt;/nowiki&amp;gt;&amp;gt;&amp;lt;/tt&amp;gt;)'' is also in the statically known namespaces, that rule, combined with the example XML data and XML schema, entails a single new fact:&lt;br /&gt;
 _SpeaksEnglish(&amp;quot;John&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
Notice that all the rules, above, are well-formed RIF formulas, that can be validly consumed without being combined with any XML data and/or XML schemas. In that case, of course, this specification adds nothing to the specification of the [[#ref-core|RIF Core Dialect]], as regards the semantics of the rules.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-model-theoretic-semantics-of-rif-bld+xml-data-combinations&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Model-theoretic semantics of RIF BLD+XML data combinations ===&lt;br /&gt;
&lt;br /&gt;
The specification of the model-theoretic semantics of a RIF BLD+XML data combination -- a [[#def-rif+xml-data-combination|RIF+XML data combination]], ''&amp;lt;R, E, S&amp;gt;''  where ''R'' is a RIF-BLD (document or non-document) formula -- follows closely the specification of the semantics of a RIF BLD formula, except that the notion of semantic structures is replaced by the notion of ''RIF BLD+XML data combined interpretations'': informally, RIF BLD+XML data combined interpretations are [[BLD#Semantic_Structures|RIF BLD semantic structures]], extended with an additional mapping, '''''I'''''&amp;lt;sub&amp;gt;DM&amp;lt;/sub&amp;gt;, that interprets data model [nodes]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;, and constrained with additional conditions, derived from the information in ''E'' and ''S''.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-semantic-structures&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
==== Semantic structures ====&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-semantic-structure&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
'''Definition (Semantic structure).''' For the purpose of defining the model-theoretic semantics of a RIF BLD+XML data combination &amp;lt;''R, E, S''&amp;gt;, a semantic structure is as a tuple ''I'' =&lt;br /&gt;
&amp;amp;lt;'''''TV''''', '''''DTS''''', '''''D''''', '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;,&lt;br /&gt;
'''''D'''''&amp;lt;sub&amp;gt;func&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;DM&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;C&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;V&amp;lt;/sub&amp;gt;,&lt;br /&gt;
'''''I'''''&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;NF&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;tail&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;frame&amp;lt;/sub&amp;gt;,&lt;br /&gt;
'''''I'''''&amp;lt;sub&amp;gt;sub&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;isa&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;=&amp;lt;/sub&amp;gt;,&lt;br /&gt;
'''''I'''''&amp;lt;sub&amp;gt;external&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;truth&amp;lt;/sub&amp;gt;&amp;gt;, where '''''TV''''', '''''DTS''''', '''''D''''', '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;,&lt;br /&gt;
'''''D'''''&amp;lt;sub&amp;gt;func&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;C&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;V&amp;lt;/sub&amp;gt;,&lt;br /&gt;
'''''I'''''&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;NF&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;tail&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;frame&amp;lt;/sub&amp;gt;,&lt;br /&gt;
'''''I'''''&amp;lt;sub&amp;gt;sub&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;isa&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;=&amp;lt;/sub&amp;gt;,&lt;br /&gt;
'''''I'''''&amp;lt;sub&amp;gt;external&amp;lt;/sub&amp;gt; and '''''I'''''&amp;lt;sub&amp;gt;truth&amp;lt;/sub&amp;gt; are defined as in RIF-BLD (&amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-bld|RIF-BLD]]], section 3.2, Semantic structures), and where&lt;br /&gt;
* '''''I'''''&amp;lt;sub&amp;gt;DM&amp;lt;/sub&amp;gt; is a total mapping from ''E'' to '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;, that interprets data model [nodes]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-combined-interpretation-of-rif-bld+schemaless-xml-data&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== Combined interpretation of RIF BLD non-document formulas and XML data ====&lt;br /&gt;
&lt;br /&gt;
Let ''Classifiers(S)'' denote the set of all the well-formed [[#def-RIFSchemaComponentPath|&amp;lt;tt&amp;gt;RIFSchemaComponentPath&amp;lt;/tt&amp;gt;]] expressions, ''expr'', such that one of the following holds, where ''c'' is the component selected by ''expr'' in the context of ''S'':&lt;br /&gt;
* either ''c'' defines a named complex type, that is, the [component-kind()]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;CD&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; of ''c'' is &amp;lt;tt&amp;gt;xscd:complex-type-definition&amp;lt;/tt&amp;gt; and its [component-name()]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;CD&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; is a QName;&lt;br /&gt;
* or ''c'' is the declaration of or a reference to an element with an anonymous complex type, that is: the [component-kind()]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;CD&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; of ''c'' is &amp;lt;tt&amp;gt;xscd:element-declaration&amp;lt;/tt&amp;gt;, its [component-name()]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;CD&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; is a QName, the [component-kind()]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;CD&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; of the child component of ''c'' along the [type axis]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;CD&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; is &amp;lt;tt&amp;gt;xscd:complex-type-declaration&amp;lt;/tt&amp;gt; and its [component-name()]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;CD&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; is '0' (indicating an anonymous component).&lt;br /&gt;
&lt;br /&gt;
Let, further, ''Classes(S) &amp;amp;sube; Classifiers(S)'' denote the subset of classifier XSD-CD expressions that select the declarations of named complex types.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-rif-bld+xml-data+schema-combined-interpretation&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
'''Definition (RIF BLD+XML data combined interpretation).''' A '''''RIF BLD+XML data combined interpretation''''' is a triple (''E'', ''I'', ''S''), where ''E'' is a set of data model [nodes]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;, possibly empty; ''S'' is a set of XML schema definitions, possibly empty; and ''I'' is a [[#def-semantic-structure|semantic structure]], such that all the following holds:&lt;br /&gt;
# For all the [nodes]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; ''e &amp;amp;isin; E'', '''''I'''''&amp;lt;sub&amp;gt;truth&amp;lt;/sub&amp;gt;(''I''&amp;lt;sub&amp;gt;frame&amp;lt;/sub&amp;gt;(''I''&amp;lt;sub&amp;gt;DM&amp;lt;/sub&amp;gt;(''e''))(''I''&amp;lt;sub&amp;gt;C&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;quot;&amp;lt;/tt&amp;gt;''expr''&amp;lt;tt&amp;gt;&amp;quot;^^xs:string&amp;lt;/tt&amp;gt;), ''RIFValue(e, expr)'')) = '''t''' (true) for any well-formed XPath expression, ''expr'', for which ''RIFValue(e, expr)'' is defined; and&lt;br /&gt;
# For all the individuals ''o &amp;amp;isin; D&amp;lt;sub&amp;gt;Ind&amp;lt;/sub&amp;gt;'', there is an element [node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; with a complex type, ''e &amp;amp;isin; E'', such that ''I''&amp;lt;sub&amp;gt;DM&amp;lt;/sub&amp;gt;(''e'') = ''o'', if and only if there is an XSD-CD component path expression, ''expr &amp;amp;isin; Classifiers(S)'', such that '''''I'''''&amp;lt;sub&amp;gt;truth&amp;lt;/sub&amp;gt;(''I''&amp;lt;sub&amp;gt;isa&amp;lt;/sub&amp;gt;(''o'', ''I''&amp;lt;sub&amp;gt;C&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;quot;&amp;lt;/tt&amp;gt;''expr''&amp;lt;tt&amp;gt;&amp;quot;^^xs:string&amp;lt;/tt&amp;gt;))) = '''t''' (true) and&lt;br /&gt;
#* either ''expr &amp;amp;isin; Classes(S)'' and the expanded QName of the type in the selected definition is equal to the [declared type]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; of ''e'';&lt;br /&gt;
#* or ''e'' represents an XML element that satisfies the element definition selected by ''expr'';&lt;br /&gt;
# '''''DTS''''' is extended to include all the named atomic types defined in the [in-scope schema definitions]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;;&lt;br /&gt;
# '''''I'''''&amp;lt;sub&amp;gt;truth&amp;lt;/sub&amp;gt;(''I''&amp;lt;sub&amp;gt;sub&amp;lt;/sub&amp;gt;(''I''&amp;lt;sub&amp;gt;C&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;quot;&amp;lt;/tt&amp;gt;''T&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''&amp;lt;tt&amp;gt;&amp;quot;^^xs:string&amp;lt;/tt&amp;gt;), ''I''&amp;lt;sub&amp;gt;C&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;quot;&amp;lt;/tt&amp;gt;''T&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;''&amp;lt;tt&amp;gt;&amp;quot;^^xs:string&amp;lt;/tt&amp;gt;)) = '''t''' (true) for all the pairs of XSD-CD component expressions, ''(T&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;, T&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;) &amp;amp;isin; Classes(S) &amp;amp;times; Classes(S)'', that select two complex types, ''t&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'' and ''t&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;'', such that ''[derives-from]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;(t&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;, t&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;)'' is true;&lt;br /&gt;
&lt;br /&gt;
&amp;amp;#9744;&lt;br /&gt;
&lt;br /&gt;
Notice that clause 2, in the above definition, implies that, if the class membership of an object that interprets the [context node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; ''e'', in a classifier amongst the schema definitions in the combined interpretation is asserted, then the object must have all the properties that are mandated by the classifier, and no property that the definition of the classifier does not allow. This is a consequence of the constraint that all the schema element [node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;, in ''E'', must be schema valid.&lt;br /&gt;
&lt;br /&gt;
{{EdNote|text=Another possibility, to resolve the issue of incomplete instances, would be to introduce one or more null values in the RIF vocabulary, e.g. &amp;lt;tt&amp;gt;rif:null&amp;lt;/tt&amp;gt;.}}&lt;br /&gt;
&lt;br /&gt;
''RIFValue'' is a total mapping from ''E &amp;amp;times; EXPR'' to ''D''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;, where ''EXPR'' is the set of all the well-formed XPath expressions. ''RIFValue(e, expr)'' associates a value in ''D''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt; to the sequence of data model [nodes]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;, in ''E'', that are matched by the XPath expression ''expr'' when the [context node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; is ''e'' and ''S'' contains the [in-scope schema definitions]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
''RIFValue'' is defined as follows.&lt;br /&gt;
&lt;br /&gt;
Let ''seq = (i&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;,...,i&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;)'' be the sequence of items matched by ''expr &amp;amp;isin; EXPR'' in the context of ''e &amp;amp;isin; E'', where ''n &amp;amp;ge; 0'' is the number of items in ''seq'':&lt;br /&gt;
* if ''n &amp;amp;gt; 1'', ''val'' = ''I''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt;(''Val(i&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;)'',...,''Val(i&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;)'')&lt;br /&gt;
* if ''n = 1'',&lt;br /&gt;
*# if ''seq = (i)'' is the [typed value]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; of an element or attribute [node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; with a list type, then ''val'' = ''I''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt;(''Val(i)'');&lt;br /&gt;
*# else, if ''expr'' selects an schema attribute or child element that is optional (that is, zero or one occurrence) in the context of ''e'', then ''val = Val(i)'';&lt;br /&gt;
*# else, if ''i'' is a schema element [node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;, and the schema definition of ''e'' allows for multiple occurrences of that schema element, then ''val'' = ''I''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt;(''Val(i)'');&lt;br /&gt;
*# otherwise, ''val'' = ''I''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt;(''Val(i)'') or ''val = Val(i)'': according to the XPath 2.0 specification, an item is identical to a singleton sequence containing that item. Except for the multiple occurences and list type cases, that must be handled as specified above, the decision to handle a singleton as a single item or as a singleton sequence that contains that item is left to the implementation, but it must be consistent: that is, the sequence matched by the same XPath expression, ''expr &amp;amp;isin; EXPR'', must be handled the same way, as a sequence or as an item, for all the [context nodes]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;, ''e &amp;amp;isin; E'';&lt;br /&gt;
* if ''n = 0'', that is, if ''expr'' matches no item in the context of ''e'',&lt;br /&gt;
*# if ''expr'' selects a schema element for which the schema allows zero to more than one occurences in the context of ''e'', then ''val'' = ''I''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt;(''&amp;amp;empty;'');&lt;br /&gt;
*# otherwise, ''RIFValue(e, expr)'' is undefined.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
Notice that the semantics of XPath 2.0 expressions may entail that two different expressions, evaluated with respect to two different [context nodes]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;, must select the same sequence; and, therefore, that the two different pairs of [context node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; and XPath expression must have the same ''RIFValue''. This implies, per clause 1, in the [[#def-rif-bld+xml-data+schema-combined-interpretation|definition of a RIF BLD+XML data combined interpretation]], above, that the RIF BLD+XML data combined interpretation of frames with different objects and attributes may be constrained by the semantics of XPath 2.0 expression, even in the absence of XML data in the combination (see, for instance, [[#ex24|example 2.4]], below).&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
''Val'' interprets items as follows:&lt;br /&gt;
* if ''i'' is an atomic value with type &amp;lt;tt&amp;gt;xs:untypedAtomic&amp;lt;/tt&amp;gt;, then ''Val(i)'' is the value of ''i'' as an &amp;lt;tt&amp;gt;xs:string&amp;lt;/tt&amp;gt;;&lt;br /&gt;
* else, if ''i'' is an atomic value, ''Val(i) = i'';&lt;br /&gt;
* else, if ''i'' is a [node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; without a type name, or whose type name is &amp;lt;tt&amp;gt;xs:untyped&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;xs:untypedAtomic&amp;lt;/tt&amp;gt;, with no attributes and with no or only text [node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; children, then ''Val(i)'' is the [string value]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; of ''i'': ''Val(i)'' = &amp;lt;tt&amp;gt;fn:string(&amp;lt;/tt&amp;gt;''i''&amp;lt;tt&amp;gt;)&amp;lt;/tt&amp;gt;;&lt;br /&gt;
* else, if ''i'' is a [node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; with a simple type, then&lt;br /&gt;
** if ''i'' is a [node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; with a list type, then ''val'' is the [typed value]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; of ''i'' as a RIF list: ''Val(i) = I''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;fn:data(&amp;lt;/tt&amp;gt;''i''&amp;lt;tt&amp;gt;)&amp;lt;/tt&amp;gt;);&lt;br /&gt;
** otherwise ''Val(i)'' is the [typed value]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; of ''i'': ''Val(i)'' = &amp;lt;tt&amp;gt;fn:data(&amp;lt;/tt&amp;gt;''i''&amp;lt;tt&amp;gt;)&amp;lt;/tt&amp;gt;;&lt;br /&gt;
* otherwise, that is, if ''i'' is a [node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; with a complex type, then ''Val(i)'' is the interpretation of ''i'' according to ''I''&amp;lt;sub&amp;gt;DM&amp;lt;/sub&amp;gt;: ''Val(i)'' = ''I''&amp;lt;sub&amp;gt;DM&amp;lt;/sub&amp;gt;(''i'').&lt;br /&gt;
&lt;br /&gt;
In the above, &amp;lt;tt&amp;gt;fn:string&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;fn:data&amp;lt;/tt&amp;gt; are the accessors defined in the [[#ref-xfo|Xpath 2.0 and XQuery 1.0 Functions and Operators]] recommendation &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xfo|XFO]]], sections 2.3 and 2.4 (for the reader's convenience, the definitions are copied, non-normatively, in the [[#appendix-glossary|Glossary]].)&lt;br /&gt;
&lt;br /&gt;
A RIF BLD+XML data combined interpretation (''E, I, S'') determines the truth value, ''TVal&amp;lt;sub&amp;gt;(E,I,S)&amp;lt;/sub&amp;gt;(&amp;amp;phi;)'', of a RIF-BLD non-document formula &amp;amp;phi; combined with the XML data in ''E'' and XML schema definitions in ''S'', like a RIF BLD semantic structure, ''I&amp;lt;sub&amp;gt;BLD&amp;lt;/sub&amp;gt;'', determines the truth value ''TVal&amp;lt;sub&amp;gt;I&amp;lt;sub&amp;gt;BLD&amp;lt;/sub&amp;gt;&amp;lt;/sub&amp;gt;(&amp;amp;phi;)'', of a RIF-BLD non-document formula &amp;amp;phi;. The mapping ''TVal&amp;lt;sub&amp;gt;(E,I,S)&amp;lt;/sub&amp;gt;'' is defined from the set of all non-document formulas to '''TV''', the set of truth values in ''I'', as follows.&lt;br /&gt;
&lt;br /&gt;
'''Definition (Truth valuation of RIF BLD non-document formulas combined with XML data).''' '''''Truth valuation''''' of RIF BLD non-document formulas combined with XML data is determined using the function ''TVal&amp;lt;sub&amp;gt;(E,I,S)&amp;lt;/sub&amp;gt;'', such that for all RIF BLD+XMl data combination, &amp;lt;''&amp;amp;phi;, E, S''&amp;gt;, where ''&amp;amp;phi;'' is a non-document RIF BLD formula, ''TVal&amp;lt;sub&amp;gt;(E,I,S)&amp;lt;/sub&amp;gt;(&amp;amp;phi;) = TVal&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;amp;phi;)'', where ''TVal&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;'' is as defined in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-bld|RIF-BLD]]], section 3.4 - Interpretation of non-document formulas, with ''I'' being the semantic structure in the RIF BLD+XML data combined interpretation (''E, I, S'').&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ex22&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
'''Example 2.2.''' Assuming that ''E'' contains all the data model [nodes]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; in the data model instance that describes the XML sample fragment in [[#ex21|example 2.1]]; that ''e&amp;lt;sub&amp;gt;table&amp;lt;/sub&amp;gt;'' denotes the element node, in ''E'', that represents the information that is serialized in the &amp;lt;tt&amp;gt;CustomerTable&amp;lt;/tt&amp;gt; element, in the example XML fragment; and that ''e&amp;lt;sub&amp;gt;John&amp;lt;/sub&amp;gt;'' denotes the element node, in ''E'', that represents the information that is serialized in the first &amp;lt;tt&amp;gt;Customer&amp;lt;/tt&amp;gt; sub-element (the one whose &amp;lt;tt&amp;gt;Name&amp;lt;/tt&amp;gt; sub-element contains ''John''), the following ground frames must be true in all the RIF BLD+XML data combined interpretations, (''E, I, &amp;amp;empty;''), that is, where ''E'' is constructed from the infoset only, and where ''I''&amp;lt;sub&amp;gt;C&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;_John&amp;lt;/tt&amp;gt;) = ''I''&amp;lt;sub&amp;gt;DM&amp;lt;/sub&amp;gt;(''e&amp;lt;sub&amp;gt;John&amp;lt;/sub&amp;gt;'') and ''I''&amp;lt;sub&amp;gt;C&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;_Table&amp;lt;/tt&amp;gt;) = ''I''&amp;lt;sub&amp;gt;DM&amp;lt;/sub&amp;gt;(''e&amp;lt;sub&amp;gt;table&amp;lt;/sub&amp;gt;''):&lt;br /&gt;
&lt;br /&gt;
# &amp;lt;tt&amp;gt;_John [&amp;quot;@xml:lang&amp;quot; -&amp;gt; &amp;quot;en&amp;quot;]&amp;lt;/tt&amp;gt; &lt;br /&gt;
# &amp;lt;tt&amp;gt;_John [&amp;quot;ex:Name&amp;quot; -&amp;gt; &amp;quot;John&amp;quot;]&amp;lt;/tt&amp;gt;&lt;br /&gt;
# &amp;lt;tt&amp;gt;_John [&amp;quot;ex:Account&amp;quot; -&amp;gt; &amp;quot;111&amp;quot; ]&amp;lt;/tt&amp;gt;&lt;br /&gt;
# &amp;lt;tt&amp;gt;_Table [&amp;quot;ex:Customer[1]&amp;quot; -&amp;gt; _John ]&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Assuming that ''S'' contains all the top-level schema definitions in the sample schema in [[#ex21|example 2.1]], ground frames #1 and #3 above must be false in all the RIF BLD+XML data combined interpretations, (''E, I, S''), everything else being equal; instead, ground frames #1 and #2, below, must be true: &lt;br /&gt;
&lt;br /&gt;
# &amp;lt;tt&amp;gt;_John [&amp;quot;@xml:lang&amp;quot; -&amp;gt; &amp;quot;en&amp;quot;^^xs:language]&amp;lt;/tt&amp;gt;&lt;br /&gt;
# &amp;lt;tt&amp;gt;_John [&amp;quot;ex:Account&amp;quot; -&amp;gt; 111 ]&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The class membership formula #1, below, may be true in a RIF BLD+XML data combined interpretation, (''E, I, &amp;amp;empty;''), but, in the absence of an associated schema definition, the string &amp;lt;tt&amp;gt;/ex:Customer&amp;lt;/tt&amp;gt; does not represent a component designator, and the class membership formula has no meaning specific to the RIF BLD+XML data combined interpretation. However, that same class membership formula must be true in every RIF BLD+XML data combined interpretations, (''E, I, S''): &lt;br /&gt;
# &amp;lt;tt&amp;gt;_John # &amp;quot;/ex:Customer&amp;quot;&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On the other hand, the class membership formula: &amp;lt;tt&amp;gt;_PIN_Jane # &amp;quot;/ex:PIN&amp;quot;&amp;lt;/tt&amp;gt; must never be true as a consequence of being interpreted under a RIF BLD+XML data combined interpretations, (''E, I, S''). Indeed, &amp;lt;tt&amp;gt;ex:PIN&amp;lt;/tt&amp;gt; is defined as a simple type: as such it is not in ''Classes(S)'' (nor in ''Classifiers(S)''); but it is, instead, added to '''''DTS'''''.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ex23&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
'''Example 2.3.''' Consider the following element with mixed-content, where the prefix &amp;lt;tt&amp;gt;ex&amp;lt;/tt&amp;gt; is associated with the IRI ''&amp;lt;nowiki&amp;gt;http://example.org/&amp;lt;/nowiki&amp;gt;'', and assume that an element [node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;, ''e'', that represents it is included in ''E''.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;ex:letterBody&amp;gt;&lt;br /&gt;
   Thank you for ordering the &amp;lt;ex:item&amp;gt;widget&amp;lt;/ex:item&amp;gt;.&lt;br /&gt;
   It should arrive by &amp;lt;ex:arrivalDate&amp;gt;09-09-09&amp;lt;/ex:arrivalDate&amp;gt;&lt;br /&gt;
 &amp;lt;/ex:letterBody&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The following fact must be true in any RIF BLD+XML data combined interpretation, ''(E, I, S)'', such that ''I''&amp;lt;sub&amp;gt;C&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;_myLetter&amp;lt;/tt&amp;gt;) = ''I''&amp;lt;sub&amp;gt;DM&amp;lt;/sub&amp;gt;(''e''):&lt;br /&gt;
* &amp;lt;tt&amp;gt;_myLetter[&amp;quot;fn:data(.)&amp;quot; -&amp;gt; &amp;quot;Thank you for ordering the Widget. It should arrive by 09-09-09&amp;quot;]&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Indeed, the element has a mixed content: per &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xdm|XDM]]] (section 6.2), its [typed value]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; is, therefore, its string value as an &amp;lt;tt&amp;gt;xs;untypedAtomic&amp;lt;/tt&amp;gt;, which is represented, per the definition of ''RIFValue'', above, by that same [string value]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; as an &amp;lt;tt&amp;gt;xs:string&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-combined-interpretation-rif-bld-document+xml-data&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== Combined interpretation of RIF BLD documents and XML data ====&lt;br /&gt;
&lt;br /&gt;
For the purpose of the interpretation of imported documents, RIF BLD defines the notion of semantic multi-structures, which are nonempty sets, {''J,I; I&amp;lt;sup&amp;gt;i&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/sup&amp;gt;, I&amp;lt;sup&amp;gt;i&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;&amp;lt;/sup&amp;gt;, ...''},  of semantic structures that differ only in interpretation of local constants.&lt;br /&gt;
&lt;br /&gt;
In the same way, a RIF-BLD+XML data combination &amp;lt;''R, E, S''&amp;gt;, is interpreted using a RIF BLD+XML data combined multi-interpretation (''E'', ''&amp;amp;Icirc;'', ''S''), where ''&amp;amp;Icirc;'' is a nonempty set, {''J,I; I&amp;lt;sup&amp;gt;i&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/sup&amp;gt;, I&amp;lt;sup&amp;gt;i&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;&amp;lt;/sup&amp;gt;, ...''}, of semantic structures that determine a non-empty set, {(''E, J, S''), (''E, I, S''); (''E, I&amp;lt;sup&amp;gt;i&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/sup&amp;gt;, S''), (''E, I&amp;lt;sup&amp;gt;i&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;&amp;lt;/sup&amp;gt;, S''), ...} of RIF BLD+XML data combined interpretations that differ only in the interpretation of local constants.&lt;br /&gt;
&lt;br /&gt;
To keep this document simple, and in the same way the definition of truth valuation of RIF BLD formulas combined with XML data, above, refers to the definition of truth valuation in the [[#ref-bld|RIF-BLD recommendation]], the definition of a RIF BLD+XML data combined multi-interpretation refers to the definition of a semantic multi-structure in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-bld|RIF-BLD]]]. &lt;br /&gt;
&lt;br /&gt;
'''Definition (RIF BLD+XML data combined multi-interpretation).'''&lt;br /&gt;
A '''''RIF BLD+XML data combined multi-interpretation''''' is a triple, (''E'', ''&amp;amp;Icirc;'', ''S''), where ''&amp;amp;Icirc;'' is a [http://www.w3.org/TR/rif-bld/#def-bld-semantic-multistruct semantic multi-structures] as defined in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-bld|RIF-BLD]]] (section 3.5 - Interpretation of documents), with the additional condition that for each semantic suctrure, ''i &amp;amp;isin; &amp;amp;Icirc;'', (''E, i, S'') is a RIF BLD+XML data combined interpretation.&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744; &lt;br /&gt;
&lt;br /&gt;
Similarly, the truth valuation of a RIF+XML data combination &amp;lt;''R, E, S''&amp;gt;, is specified with reference to the truth valuation of a RIF BLD document formulas, using the RIF BLD+XML data combined multi-interpretation (''E'', ''Î'', ''S'') in place of a RIF-BLD semantic multi-structure.&lt;br /&gt;
&lt;br /&gt;
'''Definition (Truth valuation of RIF BLD document formulas combined with XML data).''' '''''Truth valuation''''' of RIF BLD document formulas combined with XML data is determined using the function ''TVal&amp;lt;sub&amp;gt;(E,&amp;amp;Icirc;,S)&amp;lt;/sub&amp;gt;'', such that for all RIF BLD+XML data combination &amp;lt;''&amp;amp;Rho;, E, S''&amp;gt;, where ''&amp;amp;Rho;'' is a document RIF BLD formula, ''TVal&amp;lt;sub&amp;gt;(E,&amp;amp;Icirc;,S)&amp;lt;/sub&amp;gt;(&amp;amp;Rho;) = TVal&amp;lt;sub&amp;gt;&amp;amp;Icirc;&amp;lt;/sub&amp;gt;(&amp;amp;Rho;)'', where ''TVal&amp;lt;sub&amp;gt;&amp;amp;Icirc;&amp;lt;/sub&amp;gt;'' is as defined in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-bld|RIF-BLD]]], section 3.5 - Interpretation of documents, with ''&amp;amp;Icirc;'' being the semantic multi-structure in the RIF BLD+XML data combined multi-interpretation (''E, &amp;amp;Icirc;, S'').&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
&lt;br /&gt;
The notions of model and of logical entailment can be defined for a RIF BLD+XML data combination, based on the definitions of model and of logical entailment for RIF BLD (document and non-document) formulas: (''E, &amp;amp;Icirc;, S'') is a model of a RIF BLD+XML data combination &amp;lt;''R, E, S''&amp;gt;, if and only if ''&amp;amp;Icirc;'' is a model of ''R'', in the sense defined in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-bld|RIF-BLD]]] (section 3.6 - Logical entailment), and (''E, &amp;amp;Icirc;, S'') is a RIF BLD+Xml data combined multi-interpretation.&lt;br /&gt;
&lt;br /&gt;
'''Definition (Model of a RIF BLD+XML data combination).''' A RIF BLD+XML data combined multi-interpretation (''E'', ''&amp;amp;Icirc;'', ''S'') is a '''''model''''' of a RIF BLD+XML data combination &amp;lt;''R, E, S''&amp;gt;, where ''R'' is a RIF BLD document or non-document formula, if and only if ''TVal&amp;lt;sub&amp;gt;(E,&amp;amp;Icirc;,S)&amp;lt;/sub&amp;gt;(R)'' = '''t''' (true).&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
&lt;br /&gt;
'''Definition (Logical entailment of a RIF BLD+XML data combination).'''&lt;br /&gt;
Let &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;&amp;amp;psi;&amp;lt;/tt&amp;gt; be (document or non-document) formulas. We say that a RIF BLD+XML data combination &amp;lt;''&amp;amp;phi;, E, S''&amp;gt; &amp;lt;i&amp;gt;&amp;lt;b&amp;gt;entails&amp;lt;/b&amp;gt;&amp;lt;/i&amp;gt; the RIF BLD+XML data combination &amp;lt;''&amp;amp;psi;, E, S''&amp;gt;, denoted &amp;lt;''&amp;amp;phi;,&amp;amp;nbsp;E,&amp;amp;nbsp;S''&amp;gt;&amp;amp;nbsp;|=&amp;amp;nbsp;&amp;lt;''&amp;amp;psi;,&amp;amp;nbsp;E,&amp;amp;nbsp;S''&amp;gt;, if and only if every model of the RIF BLD+XML data combination &amp;lt;''&amp;amp;phi;, E, S''&amp;gt; is also a model of the RIF BLD+XML data combination &amp;lt;''&amp;amp;psi;, E, S''&amp;gt;.&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
&lt;br /&gt;
Notice that, in the case where ''E'' and ''S'' are empty, that is, if a RIF-BLD formula is combined with an empty XML data set and an empty set of XML schema definitions, the interpretation of that RIF BLD formula under a RIF BLD+XML data combined multi-interpretation (''&amp;amp;empty;'', ''&amp;amp;Icirc;'', ''&amp;amp;empty;'') is still different from its interpretation under the standard RIF BLD semantics as defined in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-bld|RIF BLD]]].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ex24&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
'''Example 2.4.''' Let ''expr'' be a well-formed XPath 2.0 expression, and let&lt;br /&gt;
* &amp;amp;phi; = &amp;lt;tt&amp;gt;Forall ?x ?y ?z (?x[&amp;quot;fn:data(expr)&amp;quot;-&amp;gt;?z] :- ?x[&amp;quot;expr&amp;quot;-&amp;gt;?y])&amp;lt;/tt&amp;gt;&lt;br /&gt;
* &amp;amp;psi; = &amp;lt;tt&amp;gt;Forall ?x ?y ?z (?y[&amp;quot;fn:data(.)&amp;quot;-&amp;gt;?z] :- ?x[&amp;quot;expr&amp;quot;-&amp;gt;?y])&amp;lt;/tt&amp;gt;&lt;br /&gt;
Notice that &amp;lt;''&amp;amp;phi;,&amp;amp;nbsp;&amp;amp;empty;,&amp;amp;nbsp;&amp;amp;empty;''&amp;gt;&amp;amp;nbsp;|=&amp;amp;nbsp;&amp;lt;''&amp;amp;psi;,&amp;amp;nbsp;&amp;amp;empty;,&amp;amp;nbsp;&amp;amp;empty;''&amp;gt;, provided that the pair ''(&amp;lt;tt&amp;gt;fn&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://www.w3.org/2005/xpath-functions&amp;lt;/nowiki&amp;gt;&amp;lt;/tt&amp;gt;)'' belongs to the statically known namespaces when the XPath expressions are evaluated; but ''&amp;amp;phi;''&amp;amp;nbsp;|&amp;amp;ne;&amp;amp;nbsp;''&amp;amp;psi;''. This is because the &amp;lt;tt&amp;gt;xs:string&amp;lt;/tt&amp;gt; constants &amp;lt;tt&amp;gt;&amp;quot;expr&amp;quot;&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;&amp;quot;fn:data(expr)&amp;quot;&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;&amp;quot;fn:data(.)&amp;quot;&amp;lt;/tt&amp;gt; are interpreted as simple string constants under the standard RIF BLD semantics, whereas they are interpreted according to the XPath 2.0 semantics under the semantics of RIF+XML data combination.&lt;br /&gt;
&lt;br /&gt;
{{EdNote|text=An alternative, less conservative definition for logical entailment in a RIF BLD+XML data combination would be: ''Let &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;&amp;amp;psi;&amp;lt;/tt&amp;gt; be (document or non-document) formulas. We say that &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; entails &amp;lt;tt&amp;gt;&amp;amp;psi;&amp;lt;/tt&amp;gt; in a RIF BLD+XML data combination if and only if every model (''E, &amp;amp;Icirc;, S'') of any RIF BLD+XML data combination &amp;lt;''&amp;amp;phi;, E, S''&amp;gt; is also a model of the RIF BLD+XML data combination &amp;lt;''&amp;amp;psi;, E, S''&amp;gt;.''&amp;amp;#9744; The use cases for the broader definition remain to be examined.}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-semantics-of-rif-prd+xml-data-combinations&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Operational semantics of RIF PRD+XML data combinations ===&lt;br /&gt;
&lt;br /&gt;
The effect on the operational semantics of a RIF PRD formula of the combination with XML data, with or without an associated XML schema, is that all the ground facts that must be true under a [[#def-rif-bld+xml-data+schema-combined-interpretation|RIF BLD+XML data combined interpretation]], must be added to the set of ground facts that represents the [[PRD#def-state|state of the fact base]].&lt;br /&gt;
&lt;br /&gt;
Notice that, whereas the other clauses affect only the initial state of the fact base, clause 2 in the definition of a [[#def-rif-bld+xml-data+schema-combined-interpretation|RIF BLD+XML data combined interpretation]] modifies the semantics of the &amp;lt;tt&amp;gt;Assert&amp;lt;/tt&amp;gt; action, when the action asserts the membership of a new object in a class that is interpreted as a schema classifier. Indeed, clause 2, in the definition, implies that the object in a membership relationship with an XML schema classifier (element or type) must interpret an instance of the class: that is, the new member object must validate against the schema definition associated to the class. As a consequence, in the context of a RIF PRD+XML data combination, &amp;lt;''R, E, S''&amp;gt;,&lt;br /&gt;
 Assert( object # ClassExpr )&lt;br /&gt;
where ''&amp;lt;tt&amp;gt;ClassExpr&amp;lt;/tt&amp;gt; &amp;amp;isin; Classifiers(S)'', requires, as a prerequisite, that, for all the XPath 2.0 expressions, ''&amp;lt;tt&amp;gt;expr&amp;lt;/tt&amp;gt;'', that select a mandatory sub-element or attribute of the class, the following fact be true:&lt;br /&gt;
 object [ &amp;quot;expr&amp;quot; -&amp;gt; value ]&lt;br /&gt;
where &amp;lt;tt&amp;gt;value&amp;lt;/tt&amp;gt; has a value that is valid with respect to the schema definition of the selected sub-element or attribute.&lt;br /&gt;
&lt;br /&gt;
Formally, that means that the definition of the RIF-PRD transition relation, defined in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-prd|RIF-PRD]]] (section 3.2, Operational semantics of atomic actions), is modified as follows.&lt;br /&gt;
&lt;br /&gt;
Let ''W'' denote the set of all the states of the fact base, and ''L'' denote the set of all the ground atomic actions in the RIF-PRD action language, as defined in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-prd|RIF-PRD]]].&lt;br /&gt;
&lt;br /&gt;
Let, further, ''expr''-valid&amp;lt;sub&amp;gt;&amp;lt;''R,E,S''&amp;gt;&amp;lt;/sub&amp;gt;, denote a property of a constant, ''&amp;lt;tt&amp;gt;o&amp;lt;/tt&amp;gt; &amp;amp;isin; &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt;'', with respect to a state of the fact base, ''w &amp;amp;isin; W'', in the context of a RIF PRD+XML data combination &amp;lt;''R, E, S''&amp;gt;. We say that &amp;lt;tt&amp;gt;o&amp;lt;/tt&amp;gt; is ''expr''-valid&amp;lt;sub&amp;gt;&amp;lt;''R,E,S''&amp;gt;&amp;lt;/sub&amp;gt; in ''w'' if and only if ''expr &amp;amp;isin; Classifiers(S)'' and all the following are true, where ''&amp;amp;Phi;'' is a set of ground atomic formulas that represents ''w'':&lt;br /&gt;
* for each child element, ''c'', with QName: ''&amp;lt;tt&amp;gt;name&amp;lt;/tt&amp;gt;'', that is required in the content model defined by the schema definition designated by ''expr'' in ''S'', there is a frame: ''&amp;lt;tt&amp;gt;o[&amp;quot;child::&amp;lt;/tt&amp;gt;''&amp;lt;tt&amp;gt;name&amp;lt;/tt&amp;gt;''&amp;lt;tt&amp;gt;&amp;quot;-&amp;gt;value]&amp;lt;/tt&amp;gt;'', in ''&amp;amp;Phi;'', such that ''&amp;lt;tt&amp;gt;value&amp;lt;/tt&amp;gt;'' has a value that is valid for ''c'' according to the schema definition;&lt;br /&gt;
* for each attribute, ''a'', with QName: ''&amp;lt;tt&amp;gt;name&amp;lt;/tt&amp;gt;'', that is required in the content model defined by the schema definition designated by ''expr'' in ''S'', there is a frame: ''&amp;lt;tt&amp;gt;o[&amp;quot;attribute::&amp;lt;/tt&amp;gt;''&amp;lt;tt&amp;gt;name&amp;lt;/tt&amp;gt;''&amp;lt;tt&amp;gt;&amp;quot;-&amp;gt;value]&amp;lt;/tt&amp;gt;'', in ''&amp;amp;Phi;'', such that ''&amp;lt;tt&amp;gt;value&amp;lt;/tt&amp;gt;'' has a value that is valid for ''a'' according to the schema definition;&lt;br /&gt;
* there is no subset, ''F = { &amp;lt;tt&amp;gt;o[&amp;quot;e&amp;quot;-&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;],..., o[&amp;quot;e&amp;quot;-&amp;gt;v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;]&amp;lt;/tt&amp;gt;} &amp;amp;sube; &amp;amp;Phi;, n &amp;amp;ge; 0'', of frames with object: ''&amp;lt;tt&amp;gt;o&amp;lt;/tt&amp;gt;'', and slot name: ''&amp;lt;tt&amp;gt;&amp;quot;e&amp;quot;&amp;lt;/tt&amp;gt;'', where ''e'' is an XPath 2.0 child or attribute step expression, such that&lt;br /&gt;
** either the child element or attribute designated by ''e'' is not allowed by the schema definition;&lt;br /&gt;
** or the set of values, {''v&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;''}, contains a value that is not valid, according to the schema definition, for the child element or attribute designated by ''e'';&lt;br /&gt;
** or the number of facts in ''F'', ''n'', is not within the bounds set in the schema definition for the multiplicity of the child element or attribute designated by ''e''.&lt;br /&gt;
&lt;br /&gt;
'''Definition (RIF-PRD transition relation in a RIF-PRD+XML data combination).''' In a RIF-PRD+XML data combination &amp;lt;''R, E, S''&amp;gt;, the semantics of RIF-PRD atomic actions is specified by the transition relation &amp;amp;rarr;&amp;lt;sub&amp;gt;&amp;lt;''R,E,S''&amp;gt;&amp;lt;/sub&amp;gt; &amp;amp;sube; ''W &amp;amp;times; L &amp;amp;times; W''. A triple ''(w, &amp;lt;tt&amp;gt;&amp;amp;alpha;&amp;lt;/tt&amp;gt;, w')'' &amp;amp;isin; &amp;amp;rarr;&amp;lt;sub&amp;gt;&amp;lt;''R,E,S''&amp;gt;&amp;lt;/sub&amp;gt; if and only if ''w &amp;amp;isin; W'', ''w' &amp;amp;isin; W'', &amp;lt;tt&amp;gt;&amp;amp;alpha;&amp;lt;/tt&amp;gt; is a ground atomic action, and  &lt;br /&gt;
* if &amp;lt;tt&amp;gt;&amp;amp;alpha;&amp;lt;/tt&amp;gt; is &amp;lt;tt&amp;gt;Assert(&amp;amp;phi;)&amp;lt;/tt&amp;gt;, where  &amp;amp;phi; = &amp;lt;tt&amp;gt;o # &amp;quot;''expr''&amp;quot;&amp;lt;/tt&amp;gt; and ''expr &amp;amp;isin; Classifiers(S)'', then &amp;lt;tt&amp;gt;o&amp;lt;/tt&amp;gt; is ''expr''-valid&amp;lt;sub&amp;gt;&amp;lt;''R,E,S''&amp;gt;&amp;lt;/sub&amp;gt; in ''w'' and ''w'&amp;amp;nbsp;=&amp;amp;nbsp;w&amp;amp;nbsp;&amp;amp;cup;&amp;amp;nbsp;{&amp;amp;phi;};&lt;br /&gt;
* Otherwise, that is, if &amp;lt;tt&amp;gt;&amp;amp;alpha;&amp;lt;/tt&amp;gt; is an &amp;lt;tt&amp;gt;Assert&amp;lt;/tt&amp;gt; whose target has a different form, or a &amp;lt;tt&amp;gt;Retract&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;Modify&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;Execute&amp;lt;/tt&amp;gt; ground atomic action, then ''(w, &amp;lt;tt&amp;gt;&amp;amp;alpha;&amp;lt;/tt&amp;gt;, w')'' &amp;amp;isin; &amp;amp;rarr;&amp;lt;sub&amp;gt;&amp;lt;''R,E,S''&amp;gt;&amp;lt;/sub&amp;gt; if and only if ''(w, &amp;lt;tt&amp;gt;&amp;amp;alpha;&amp;lt;/tt&amp;gt;, w')'' &amp;amp;isin; &amp;amp;rarr;&amp;lt;sub&amp;gt;RIF-PRD&amp;lt;/sub&amp;gt;, where &amp;amp;rarr;&amp;lt;sub&amp;gt;RIF-PRD&amp;lt;/sub&amp;gt; is the standard RIF-PRD transition relation as defined in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-prd|RIF-PRD]]] (section 3.2, Operational semantics of atomic actions).&lt;br /&gt;
&lt;br /&gt;
&amp;amp;#9744;&lt;br /&gt;
&lt;br /&gt;
The operational semantics of a RIF PRD+XML data combination is, then, exactly as specified in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-prd|RIF-PRD]]], except that &amp;amp;rarr;&amp;lt;sub&amp;gt;&amp;lt;''R,E,S''&amp;gt;&amp;lt;/sub&amp;gt; replaces &amp;amp;rarr;&amp;lt;sub&amp;gt;RIF-PRD&amp;lt;/sub&amp;gt; in the definition of the transition relation, &amp;amp;rarr;&amp;lt;sub&amp;gt;PRS&amp;lt;/sub&amp;gt;, that is one of the components of a RIF-PRD production rule system, ''PRS'' (cf. &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-prd|RIF-PRD]]], Section 4.2.4, Operation semantics of a production rule system).&lt;br /&gt;
&lt;br /&gt;
Notice, further, that, since RIF-PRD, unlike RIF-BLD, allows class membership to be asserted for new objects only, the object in such an assertion cannot have some or all the required properties already. As a consequence, all the mandatory properties must be asserted in the same action block where the class membership is asserted.&lt;br /&gt;
&lt;br /&gt;
Formally, the consequence is that the combination with schema-valid XML data puts an additional well-formedness constraints on RIF-PRD action blocks.&lt;br /&gt;
&lt;br /&gt;
'''Definition (Well-formed action block in a RIF-PRD+XML data combination).''' In a RIF-PRD+XML data combination &amp;lt;''R, E, S''&amp;gt;, an action block is '''''well-formed''''' if and only if it is a well-formed RIF-PRD action block, according to the definition in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-prd|RIF-PRD]]] (section 3.1.3 - Well-formed action blocks) and it satisfies the following additional constraint:&lt;br /&gt;
* if an action in the action block asserts a membership atomic formula, &amp;lt;tt&amp;gt;Assert(o # &amp;quot;expr&amp;quot;)&amp;lt;/tt&amp;gt;, where ''expr &amp;amp;isin; Classifiers(S)'', then the other actions in the action block are sufficient to make &amp;lt;tt&amp;gt;o&amp;lt;/tt&amp;gt; ''expr''-valid&amp;lt;sub&amp;gt;&amp;lt;''R,E,S''&amp;gt;&amp;lt;/sub&amp;gt; in any state of facts resulting from the execution of the action block, that is: all the ground frame formulas that are required to make &amp;lt;tt&amp;gt;o&amp;lt;/tt&amp;gt; ''expr''-valid&amp;lt;sub&amp;gt;&amp;lt;''R,E,S''&amp;gt;&amp;lt;/sub&amp;gt; in a state of facts, are asserted in the action block.&lt;br /&gt;
&lt;br /&gt;
&amp;amp;#9744;&lt;br /&gt;
&lt;br /&gt;
{{EdNote|text=Strictly speaking, since actions are ordered in RIF-PRD action blocks, and since the operational semantics of atomic actions is defined with respect to a production rule system state, independently from the system state being a system cycle state or a system transitional state, the ground frame formulas that are required to make &amp;lt;tt&amp;gt;o&amp;lt;/tt&amp;gt; ''expr''-valid&amp;lt;sub&amp;gt;&amp;lt;''R,E,S''&amp;gt;&amp;lt;/sub&amp;gt; in a state of facts should be asserted before the membership formula is. However, it is conjectured that the atomic actions in an action block that satisfies the weaker constraint can, always, be re-ordered to satisfy the stronger constraint, without otherwise affecting the semantics of the action block as a whole; whence the absence of the ordering constraint in the above definition.}}&lt;br /&gt;
&lt;br /&gt;
See also the (non-normative) appendix on embedding XML data as RIF facts for an exhaustive description of the facts to be added to the initial state of the fact base that is to be combined with the XML data.&lt;br /&gt;
&lt;br /&gt;
'''Example 2.5.''' In a RIF-PRD+XML data combination &amp;lt;''R, E, S''&amp;gt;, where ''S'' contains all the top-level definitions in the XML schema in [[#ex21|example 2.1]] (all the examples assume that the pair ''(&amp;lt;tt&amp;gt;ex&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;http://example.org/customertable&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/tt&amp;gt;)'' belongs to the [statically known namespaces]&amp;lt;sup&amp;gt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; when the XPath and XSD-CD expressions are evaluated):&lt;br /&gt;
* the following action blocks are well-formed as the action part of rules in ''R''&lt;br /&gt;
 Do ((?newPin New())&lt;br /&gt;
     Assert(?newPin[&amp;quot;self::ex:PIN&amp;quot;-&amp;gt;999]) )&lt;br /&gt;
&lt;br /&gt;
 Do ((?newPin New())&lt;br /&gt;
     Assert(?newPin[&amp;quot;self::ex:PIN&amp;quot;-&amp;gt;&amp;quot;999&amp;quot;^^ex:PIN]) )&lt;br /&gt;
''(&amp;lt;tt&amp;gt;ex:PIN&amp;lt;/tt&amp;gt; is an atomic type defined in ''S''. As a consequence, it is included, per clause 3 in the definition of a RIF BLD+XML data combined interpretation, in the set of data types that are taken into account to interpret RIF formulas.)''&lt;br /&gt;
 Do ((?newPin New())&lt;br /&gt;
     Assert(?newPIN # &amp;quot;/ex:PIN&amp;quot;) )&lt;br /&gt;
''(Since &amp;lt;tt&amp;gt;ex:PIN&amp;lt;/tt&amp;gt; is a simple type, the XSD-CD expression ''/ex:PIN'' is not in ''Classifiers(S)''. As a consequence, the class membership assertion, in the example above, adds no well-formedness constraint that is specific to the RIF PRD+XML data combination: its semantics are standard.)''&lt;br /&gt;
 Do ((?newCust New())&lt;br /&gt;
     Assert(?newCust # &amp;quot;/ex:Customer&amp;quot;)&lt;br /&gt;
     Assert(?newCust[&amp;quot;ex:Name&amp;quot;-&amp;gt;&amp;quot;Jojo&amp;quot;])&lt;br /&gt;
     Assert(?newCust[&amp;quot;ex:Account&amp;quot;-&amp;gt;1111])&lt;br /&gt;
     Assert(?newPin[&amp;quot;ex:PIN&amp;quot;-&amp;gt;999])&lt;br /&gt;
     Assert(?newCust[&amp;quot;@xml/lang&amp;quot;-&amp;gt;&amp;quot;fr&amp;quot;^^xs:language]) )&lt;br /&gt;
&lt;br /&gt;
 Do ((?newCust New())&lt;br /&gt;
     Assert(?newCust # &amp;quot;/ex:Customer&amp;quot;)&lt;br /&gt;
     Assert(?newCust[&amp;quot;ex:Name&amp;quot;-&amp;gt;&amp;quot;Jojo&amp;quot;])&lt;br /&gt;
     Assert(?newCust[&amp;quot;ex:Account&amp;quot;-&amp;gt;1111])&lt;br /&gt;
     Assert(?newCust[&amp;quot;@xml/lang&amp;quot;-&amp;gt;&amp;quot;fr&amp;quot;^^xs:language]) )&lt;br /&gt;
* the following action blocks are not well-formed as the action part of rules in ''R''&lt;br /&gt;
 Do ((?newCust New())&lt;br /&gt;
     Assert(?newCust # &amp;quot;/ex:Customer&amp;quot;)&lt;br /&gt;
     Assert(?newCust[&amp;quot;ex:Name&amp;quot;-&amp;gt;&amp;quot;Jojo&amp;quot;])&lt;br /&gt;
     Assert(?newCust[&amp;quot;ex:Account&amp;quot;-&amp;gt;1111])&lt;br /&gt;
     Assert(?newPin[&amp;quot;ex:PIN&amp;quot;-&amp;gt;-5])&lt;br /&gt;
     Assert(?newCust[&amp;quot;@xml/lang&amp;quot;-&amp;gt;&amp;quot;fr&amp;quot;^^xs:language]) )&lt;br /&gt;
''(-5 is out of range for an &amp;lt;tt&amp;gt;ex:PIN&amp;lt;/tt&amp;gt; value)''&lt;br /&gt;
 Do ((?newCust New())&lt;br /&gt;
     Assert(?newCust # &amp;quot;/ex:Customer&amp;quot;)&lt;br /&gt;
     Assert(?newCust[&amp;quot;ex:Name&amp;quot;-&amp;gt;&amp;quot;Jojo&amp;quot;])&lt;br /&gt;
     Assert(?newCust[&amp;quot;ex:Name&amp;quot;-&amp;gt;&amp;quot;Le balafré&amp;quot;])&lt;br /&gt;
     Assert(?newCust[&amp;quot;ex:Account&amp;quot;-&amp;gt;1111])&lt;br /&gt;
     Assert(?newCust[&amp;quot;@xml/lang&amp;quot;-&amp;gt;&amp;quot;fr&amp;quot;^^xs:language]) )&lt;br /&gt;
''(The schema definition requires a single &amp;lt;tt&amp;gt;ex:Name&amp;lt;/tt&amp;gt; value for each &amp;lt;tt&amp;gt;ex:Customer&amp;lt;/tt&amp;gt; information item)''.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-semantics-of-rif-core+xml-data-combinations&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Semantics of RIF Core+XML data combinations ===&lt;br /&gt;
&lt;br /&gt;
RIF Core is a syntactic subset of RIF BLD, and the semantics of RIF Core+XML data combinations is identical to the semantics of RIF BLD+XML data combinations for that subset.&lt;br /&gt;
&lt;br /&gt;
RIF Core is also a syntactic subset of RIF PRD, and the semantics of RIF Core+XML data combinations is also identical to the semantics of RIF PRD+XML data combinations for that subset.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-importing&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Importing XML data and XML schemas in RIF ==&lt;br /&gt;
&lt;br /&gt;
In RIF, the &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directive is used to communicate the location of an external document to be combined with the RIF document that contains the directive and, optionally, a profile that governs the combination.&lt;br /&gt;
&lt;br /&gt;
In &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-core|RIF-Core]]], &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-prd|RIF-PRD]]] and &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-bld|RIF-BLD]]], the use of the &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directive is limited to identifying an imported RIF document. &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-swc|RIF-RDF-OWL]]] extends it to permit the identification of an RDF graph or an OWL ontology to be combined with a RIF document. An optional profile that governs the combination of a RIF document with an RDF graph or an OWL ontology can also be provided, as specified in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-swc|RIF-RDF-OWL]]]. &lt;br /&gt;
&lt;br /&gt;
This specification extends the &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directive further to permit the identification of XML data and/or XML schemas to be combined with a RIF document. &lt;br /&gt;
&lt;br /&gt;
One use case for the combination of RIF and XML data is when a RIF document imports explicitly the data with which the rules are to be combined: in that case, the combination is imposed by the producer of the RIF document, as well as the data to be combined with the rules that the RIF document contains. We call that case: ''producer-side combination'', and the XML data to be combined with the RIF document: ''imported XML data''.&lt;br /&gt;
&lt;br /&gt;
However, a significant use case for RIF is rules being published or shared as a RIF document for consumers to combine them with their own data: in that case, the consumer of a RIF document decides independently of the producer to combine the rules contained in the RIF document with the data of his choice. We refer to that case as: ''consumer-side combination'', and to the data that is combined with a RIF document as: ''consumer-side data''.&lt;br /&gt;
&lt;br /&gt;
=== The extended &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directive ===&lt;br /&gt;
&lt;br /&gt;
Specifically, the &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directive is extended as follows:&lt;br /&gt;
* The import of any XML document is allowed; that is, the IRI of any XML document is allowed in the &amp;lt;tt&amp;gt;location&amp;lt;/tt&amp;gt; sub-element of the &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directive. The IRI identifies the imported data document);&lt;br /&gt;
* Two new profiles are defined:&lt;br /&gt;
*# the value &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://www.w3.org/2007/rif-import-profile#xml-data&amp;lt;/nowiki&amp;gt;&amp;lt;/tt&amp;gt; is allowed in the &amp;lt;tt&amp;gt;profile&amp;lt;/tt&amp;gt; sub-element of the &amp;lt;tt&amp;gt;import&amp;lt;/tt&amp;gt; directive, to indicate that no XML schema is associated with the imported XML data;&lt;br /&gt;
*# any IRI that identifies an XML schema is allowed in the &amp;lt;tt&amp;gt;profile&amp;lt;/tt&amp;gt; sub-element of the &amp;lt;tt&amp;gt;import&amp;lt;/tt&amp;gt; directive, to indicate that the schema definitions in the XML schema are part of the combination;&lt;br /&gt;
* Finally, a new value: &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://www.w3.org/2007/rif-import-location#consumer-side-data&amp;lt;/nowiki&amp;gt;&amp;lt;/tt&amp;gt;, is allowed for the location of an import. That value indicates that the &amp;lt;tt&amp;gt;profile&amp;lt;/tt&amp;gt; in the &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directive applies to consumer-side data only.&lt;br /&gt;
&lt;br /&gt;
The following constraints must be satisfied:&lt;br /&gt;
* If the content of the &amp;lt;tt&amp;gt;location&amp;lt;/tt&amp;gt; in an &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directive is &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://www.w3.org/2007/rif-import-location#consumer-side-data&amp;lt;/nowiki&amp;gt;&amp;lt;/tt&amp;gt;, the &amp;lt;tt&amp;gt;profile&amp;lt;/tt&amp;gt; must contain the IRI of an XML schema;&lt;br /&gt;
* Conversely, if the profile is &amp;lt;tt&amp;gt;rif:xml-data&amp;lt;/tt&amp;gt;, the &amp;lt;tt&amp;gt;location&amp;lt;/tt&amp;gt; must identify an XML document;&lt;br /&gt;
* If the &amp;lt;tt&amp;gt;profile&amp;lt;/tt&amp;gt; of an &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directive contains the IRI of an XML Schema and if the XML document identified in the &amp;lt;tt&amp;gt;location&amp;lt;/tt&amp;gt; sub-element of that &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directive provides a &amp;lt;tt&amp;gt;schema-location&amp;lt;/tt&amp;gt;, the &amp;lt;tt&amp;gt;profile&amp;lt;/tt&amp;gt; must identify the same XML schema as the &amp;lt;tt&amp;gt;schema-location&amp;lt;/tt&amp;gt; IRI.&lt;br /&gt;
&lt;br /&gt;
This specification does not prescribe the behaviour of a conformant implementation when one of the above constraints is not satisfied.&lt;br /&gt;
&lt;br /&gt;
This specification does not prescribe the behaviour of a conformant implementation when an &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directive contains a &amp;lt;tt&amp;gt;location&amp;lt;/tt&amp;gt; that is neither &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://www.w3.org/2007/rif-import-location#consumer-side-data&amp;lt;/nowiki&amp;gt;&amp;lt;/tt&amp;gt; nor an IRI that identifies an XML document. And this specification does not prescribe the behaviour of a conformant implementation when an &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directive contains a &amp;lt;tt&amp;gt;profile&amp;lt;/tt&amp;gt; that is neither &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://www.w3.org/2007/rif-import-profile#xml-data&amp;lt;/nowiki&amp;gt;&amp;lt;/tt&amp;gt; nor an IRI that identifies an XML schema.&lt;br /&gt;
&lt;br /&gt;
'''Example 3.1.''' The first three import directives, below, are valid; the fourth is not:&lt;br /&gt;
# &amp;lt;tt&amp;gt;Import(&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.org/customertable.xml &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2007/rif-import-profile#xml-data)&amp;lt;/tt&amp;gt;&lt;br /&gt;
# &amp;lt;tt&amp;gt;Import(&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.org/customertable.xml &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.org/customertable.xsd)&amp;lt;/tt&amp;gt;&lt;br /&gt;
# &amp;lt;tt&amp;gt;Import(&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2007/rif-import-location#consumer-side-data &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.org/customertable.xsd)&amp;lt;/tt&amp;gt;&lt;br /&gt;
# &amp;lt;tt&amp;gt;Import(&amp;lt;nowiki&amp;gt;http://www.w3.org/2007/rif-import-location#consumer-side-data&amp;lt;/nowiki&amp;gt; &amp;lt;nowiki&amp;gt;http://www.w3.org/2007/rif-import-profile#xml-data&amp;lt;/nowiki&amp;gt;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The first directive says that the rules in the importing RIF document are to be combined with the data in the XML document identified by the IRI: &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.org/customertable.xml&amp;lt;/tt&amp;gt; and that there is no data model associated with the imported data in the form of an XML schema.&lt;br /&gt;
&lt;br /&gt;
The second directive says that the rules in the importing RIF document are to be combined with the data in the XML document identified by the IRI: &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.org/customertable.xml&amp;lt;/tt&amp;gt; and that there is a data model associated with the imported data, in the form of the XML schema that is identified by the IRI: &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.org/customertable.xsd&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The third directive says the data that is combined with the rules is expected to be an instance of the data model that is imported as the XML schema identified by the IRI: &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.org/customertable.xsd&amp;lt;/tt&amp;gt;; but the directive does not say what data is to be combined with the rules.&lt;br /&gt;
&lt;br /&gt;
The fourth directive violates the first and second constraints: the dummy location &amp;lt;tt&amp;gt;consumer-side-data&amp;lt;/tt&amp;gt;, that indicates that the profile is to be applied to consumer-side data, is incompatible with the profile &amp;lt;tt&amp;gt;xml-data&amp;lt;/tt&amp;gt;. Therefore, the directive is out of the scope of this specification.&lt;br /&gt;
&lt;br /&gt;
=== Interpretation of Imports ===&lt;br /&gt;
&lt;br /&gt;
For the purpose of interpreting the combination of a RIF document, ''R'', and XML data, let ''dataLocation(R)'' denote the set of the URIs in the &amp;lt;tt&amp;gt;location&amp;lt;/tt&amp;gt; sub-elements of the &amp;lt;tt&amp;gt;import&amp;lt;/tt&amp;gt; directives, in ''R'' and in the RIF documents that are imported, directly or indirectly, in ''R'', whose &amp;lt;tt&amp;gt;profile&amp;lt;/tt&amp;gt; is either &amp;lt;tt&amp;gt;rif:xml-data&amp;lt;/tt&amp;gt; or identifies an XML schema; and let ''dataDocuments(R)'' denote the set of the document [nodes]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; in the instances of the data model that encapsulate the information in all the XML documents that are identified by an URI in ''dataLocation(R)''. If ''dataLocation(R)'' contains the dummy URI &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://www.w3.org/2007/rif-import-location#consumer-side-data&amp;lt;/nowiki&amp;gt;&amp;lt;/tt&amp;gt;, ''dataDocuments(R)'' includes, also, the document [node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; in an instance of the data model that encapsulates the consumer-side data. In the absence of consumer-side data, the document node bears no information.&lt;br /&gt;
&lt;br /&gt;
If an &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directive identifies an XML schema as its &amp;lt;tt&amp;gt;profile&amp;lt;/tt&amp;gt;, the corresponding instance of the data model includes the information from the PSVI that results from validating the XML data referenced in the &amp;lt;tt&amp;gt;location&amp;lt;/tt&amp;gt; against that schema. Otherwise, the instance of the data model is built from the infoset.&lt;br /&gt;
&lt;br /&gt;
If an &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directive has the value: &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://www.w3.org/2007/rif-import-location#consumer-side-data&amp;lt;/nowiki&amp;gt;&amp;lt;/tt&amp;gt; as a locator, the instance of the data model that encapsulates the consumer-side data, if any, includes the information from the PSVI that results from validating the data against the XML schema identified in the profile of that directive.&lt;br /&gt;
&lt;br /&gt;
As a consequence, if different &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directives associate different XML schemas to the consumer-side data, the instance of the data model that encapsulates the consumer-side data, if any, includes the information from the PSVI that results from validating the data against the XML schema that results from importing or including, into an otherwise empty schema, all the XML schemas identified in the &amp;lt;tt&amp;gt;profile&amp;lt;/tt&amp;gt; sub-elements of &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directives with the value: &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://www.w3.org/2007/rif-import-location#consumer-side-data&amp;lt;/nowiki&amp;gt;&amp;lt;/tt&amp;gt; as a locator.&lt;br /&gt;
&lt;br /&gt;
Given a RIF document, ''R'', the set of data model nodes, ''E'', in the RIF+XML data combination &amp;lt;''R, E, S''&amp;gt; is the set of all the document nodes in ''dataDocuments(R)'', and of all the data model nodes that can be reached from those document nodes.&lt;br /&gt;
&lt;br /&gt;
In the same way, ''S'', the schema definitions component in the RIF+XML data combination &amp;lt;''R, E, S''&amp;gt;, includes all the top level schema definitions found in the XML schemas that are imported as the &amp;lt;tt&amp;gt;profile&amp;lt;/tt&amp;gt; of an &amp;lt;tt&amp;gt;import&amp;lt;/tt&amp;gt; directive in ''R'' or in a RIF document that is imported, directly or indirectly, in ''R''.&lt;br /&gt;
&lt;br /&gt;
For the purpose of evaluating XPath 2.0 expressions, when interpreting a RIF+XML data combination &amp;lt;''R, E, S''&amp;gt;, the [in-scope schema definitions]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; include all the schema definitions in ''S'', all the schema type, schema element and schema attribute definitions that are components of the top level definitions in ''S'', and all the schema types defined in [XSD 1.1 Part2].&lt;br /&gt;
&lt;br /&gt;
'''Example 3.2.''' Continuing example 3.1, above, notice that none of the three valid directives is incompatible with the other two, but that combining the first two is confusing and error-prone, since directive #2 supersedes directive #1. Including effectively useless directives should be avoided.&lt;br /&gt;
&lt;br /&gt;
Combining directive #2 and #3 says that the rules in the importing document are meant to be applied only to data that validates against the XML schema in example 2.1, where the data is imported or from the consumer-side.&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-infoset&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; [Infoset]&lt;br /&gt;
: ''[http://www.w3.org/TR/xml-infoset/ XML Information Set (Second Edition)]'', John Cowan and Richard Tobin, Editors. World Wide Web Consortium, 04 Feb 2004. This version is http://www.w3.org/TR/2004/REC-xml-infoset-20040204/. The latest version is available at http://www.w3.org/TR/xml-infoset/.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-uri&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; [RFC 3986]&lt;br /&gt;
: ''[http://www.ietf.org/rfc/rfc3986.txt RFC 3986: Uniform Resource Identifier (URI): Generic Syntax]'', T. Berners-Lee, R. Fielding, and L. Masinter. January 2005.  Available at: http://www.ietf.org/rfc/rfc3986.txt&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-iri&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; [RFC 3987]&lt;br /&gt;
: ''[http://www.ietf.org/rfc/rfc3987.txt RFC 3987: Internationalized Resource Identifiers (IRIs)]'',  M. Duerst and M. Suignard. January 2005.  Available at: http://www.ietf.org/rfc/rfc3987.txt&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-core&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; [RIF-Core]&lt;br /&gt;
: ''[http://www.w3.org/TR/rif-core/ RIF Core Dialect]'', H. Boley, G. Hallmark, M. Kifer, A. Paschke, A. Polleres, D. Reynolds, Editors. W3C Recommendation 22 June 2010. This version is http://www.w3.org/TR/2009/WD-rif-core-20090703/. The latest version is available at http://www.w3.org/TR/rif-core/.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-bld&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; [RIF-BLD]&lt;br /&gt;
: ''[http://www.w3.org/TR/rif-bld/ RIF Basic Logic Dialect]'', H. Boley, M. Kifer, Editors. W3C Recommendation 22 June 2010. This version is http://www.w3.org/TR/2009/WD-rif-bld-20090703/. The latest version is available at http://www.w3.org/TR/rif-bld/.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-dtb&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; [RIF-DTB]&lt;br /&gt;
: ''[http://www.w3.org/TR/rif-dtb/ RIF Datatypes and Built-Ins 1.0]'', Polleres A., Boley H. and Kifer M. (Editors), W3C Rule Interchange Format Working Group Draft. This version is http://www.w3.org/TR/2010/REC-rif-dtb-20100622/. The latest Version is available at http://www.w3.org/TR/rif-dtb/.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-prd&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; [RIF-PRD]&lt;br /&gt;
: ''[http://www.w3.org/TR/rif-prd/ RIF Production Rule Dialect]'', Ch. de Sainte Marie, A. Paschke, G. Hallmark, Editors. W3C Recommendation 22 June 2010. This version is http://www.w3.org/TR/2009/WD-rif-prd-20090703/. The latest version is available at http://www.w3.org/TR/rif-prd/.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-swc&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; [RIF-RDF-OWL]&lt;br /&gt;
: ''[http://www.w3.org/TR/rif-rdf-owl/ RIF RDF and OWL Compatibility]'', J. de Bruijn, Editor. W3C Recommendation 22 June 2010. This version is http://www.w3.org/TR/2009/WD-rif-rdf-owl-20090703/. The latest version is available at http://www.w3.org/TR/rif-rdf-owl/.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-xdm&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; [XDM]&lt;br /&gt;
: ''[http://www.w3.org/TR/xpath-datamodel/ XQuery 1.0 and XPath 2.0 Data Model (XDM)]'',  M. Fernández, A. Malhotra, J. Marsh, M. Nagy, N. Walsh, Editors. W3C Recommendation 23 January 2007. This version is http://www.w3.org/TR/2007/REC-xpath-datamodel-20070123/. The latest version is available at http://www.w3.org/TR/xpath-datamodel/.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-xfo&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; [XFO]&lt;br /&gt;
: ''[http://www.w3.org/TR/xpath-functions/ XQuery 1.0 and XPath 2.0 Functions and Operators]'', Ashok Malhotra, Jim Melton, and Norman Walsh, Editors. World Wide Web Consortium, 23 Jan 2007. This version is http://www.w3.org/TR/2007/REC-xpath-functions-20070123/. The latest version is available at http://www.w3.org/TR/xpath-functions/.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-xml&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; [XML]&lt;br /&gt;
: ''[http://www.w3.org/TR/REC-xml/ Extensible Markup Language (XML) 1.0 (Fifth Edition)]'', T. Bray, J. Paoli, C. M. Sperberg-McQueen, E. Maler, F. Yergeau, Editor. W3C Recommendation 26 November 2008. This version is http://www.w3.org/TR/2005/REC-xml-id-20050909/. The latest version is available at http://www.w3.org/TR/REC-xml/.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-xml-id&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; [xml&amp;lt;nowiki&amp;gt;:&amp;lt;/nowiki&amp;gt;id]&lt;br /&gt;
: ''[http://www.w3.org/TR/xml-id/ xml:id Version 1.0]'', J. Marsh, D. Veillard, N. Walsh, Editors. W3C Recommendation 9 September 2005. This version is http://www.w3.org/TR/2008/REC-xml-20081126/. The latest version is available at http://www.w3.org/TR/xml-id/.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-xpath-20&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; [XPath 2.0]&lt;br /&gt;
: ''[http://www.w3.org/TR/xpath20/ XML Path Language (XPath) 2.0]'', D. Chamberlin , A. Berglund, S. Boag, et. al., Editors. W3C Recommendation 23 Jan 2007. This version is http://www.w3.org/TR/2007/REC-xpath20-20070123/. The latest version is available at http://www.w3.org/TR/xpath20/.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-xquery&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; [XQuery 1.0]&lt;br /&gt;
: ''[http://www.w3.org/TR/xquery/ XQuery 1.0: An XML Query Language]'', D. Chamberlin , A. Berglund, S. Boag, et. al., Editors. W3C Recommendation 23 Jan 2007. This version is http://www.w3.org/TR/2007/REC-xquery-20070123/. The latest version is available at http://www.w3.org/TR/xquery/.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-xsd11-1&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; [XSD 1.1 Part 1]&lt;br /&gt;
: &amp;lt;cite&amp;gt;[http://www.w3.org/TR/2012/REC-xmlschema11-1-20120405/ W3C XML Schema Definition Language (XSD) 1.1 Part 1: Structures]&amp;lt;/cite&amp;gt;, D. Beech, M. Maloney, H. S. Thompson, C. M. Sperberg-McQueen, S. Gao Gao, N. Mendelsohn,  Editors, W3C Recommendation, 5 April 2012, http://www.w3.org/TR/2012/REC-xmlschema11-1-20120405/.  Latest version available at http://www.w3.org/TR/xmlschema11-1.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-xsd11-2&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; [XSD 1.1 Part 2]&lt;br /&gt;
: &amp;lt;cite&amp;gt;[http://www.w3.org/TR/2012/REC-xmlschema11-2-20120405/ W3C XML Schema Definition Language (XSD) 1.1 Part 2: Datatypes]&amp;lt;/cite&amp;gt;, D. Peterson, S. Gao Gao, H. S. Thompson, P. V. Biron, A. Malhotra, A. Malhotra, C. M. Sperberg-McQueen,  Editors, W3C Recommendation, 5 April 2012, http://www.w3.org/TR/2012/REC-xmlschema11-2-20120405/. Latest version available at http://www.w3.org/TR/xmlschema11-2/.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-xsd-cd&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; [XSD-CD]&lt;br /&gt;
: ''[http://www.w3.org/TR/2010/CR-xmlschema-ref-20100119/ W3C XML Schema Definition Language (XSD): Component Designators]'', , Editors. W3C Candidate Recommandation 19 January 2010. W3C Recommendation 23 Jan 2007. This version is http://www.w3.org/TR/2010/CR-xmlschema-ref-20100119/. The latest version is available at http://www.w3.org/TR/xmlschema-ref/.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;appendix-glossary&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Appendix A: Glossary (non-normative) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-actual-member-type-definition&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''Actual member type definition''' ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xsd11-1|XSD 1.1 Part 1]]])''&lt;br /&gt;
: The transitive membership of a union type is the set of its own member types, and the member types of its members, and so on.&lt;br /&gt;
: Those members of the transitive membership of a union datatype, U, which are themselves not union datatypes are the basic members of U.&lt;br /&gt;
: If the [[#glos-normalized-value|initial value]] of an attribute is valid with respect to the [[#glos-governing-type-definition|governing type definition]] as defined by String Valid (§3.16.4) and the [[#glos-governing-type-definition|governing type definition]] has {variety} ''union'', then the actual member type definition is that basic member of its transitive membership which actually validated the attribute item's [[#glos-normalized-value|normalized value]].&lt;br /&gt;
: If the [[#glos-schema-normalized-value|schema normalized value]] of an element is not absent and the [[#glos-governing-type-definition|governing type definition]] is a simple type definition with {variety} ''union'', or its {content type} has {variety} ''simple'' and {simple type definition} a simple type definition with {variety} ''union'', then the actual member type definition is that basic member of its transitive membership which actually validated the [[#glos-schema-normalized-value|schema normalized value]].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-actual-value&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''Actual value''' ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xsd11-1|XSD 1.1 Part 1]]], section 3.1.3)''&lt;br /&gt;
: With reference to any string, interpreted as denoting an instance of a given datatype, the term actual value denotes the value to which the lexical mapping of that datatype maps the string.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-atomic-type&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''Atomic type'''&lt;br /&gt;
: A simple type whose definition has {variety}: ''atomic'', that is, a simple type that is neither a list nor an union type. An atomic type is one of the 20 primitive simple types defined in [http://www.w3.org/TR/xmlschema11-2/#built-in-primitive-datatypes Section 3.3 Primitive Datatypes] of &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xsd11-2|XSD 1.1 Part 2]]] or a type derived by restriction from another atomic type.&lt;br /&gt;
: An '''atomic value''' is a value in the value space of an atomic type&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-component&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''Component'''  ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xsd11-1|XSD 1.1 Part 1]]], section 2.2)''&lt;br /&gt;
: Component covers all the different kinds of schema component defined in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xsd11-1|XSD 1.1 Part 1]]]. Schema component is the generic term for the building blocks that make up the abstract data model of the schema.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-component-kind&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''component-kind()'''  ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xsd-cd|XSD-CD]]], section 4.5.1)''&lt;br /&gt;
: The component-kind accessor returns an expanded name identifying the kind of the schema component.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-component-name&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''component-name()'''  ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xsd-cd|XSD-CD]]], section 4.5.2)''&lt;br /&gt;
: The component-name accessor returns zero or one xs:QName values giving the name of the component.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-context-node&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''Context node''' ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xpath-20|XPath 2.0]]], section 2.1.1)''&lt;br /&gt;
: The context item is the item currently being processed. An item is either an atomic value or a node. When the context item is a node, it can also be referred to as the context node.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-declared-type&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''Declared type''' ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xdm|XDM]]], section 3.3.1.1)''&lt;br /&gt;
: The precise definition of the schema type of an element or attribute information item depends on the properties of the PSVI. In the PSVI, [[#ref-xsd11-1|Schema Part 1]] defines a '''[type definition]''' property as well as the '''[type definition namespace]''', '''[type definition name]''' and '''[type definition anonymous]''' properties, which are effectively short-cut terms for properties of the type definition. Further, the '''[element declaration]''' and '''[attribute declaration]''' properties are defined for elements and attributes, respectively. These declarations in turn will identify the '''[type definition]''' declared for the element or attribute. To distinguish the '''[type definition]''' given in the PSVI for the element or attribute instance from the '''[type definition]''' associated with the declaration, the former is referred to below as the '''actual type''' and the latter as the '''declared type''' of the element or attribute instance in question.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-derived-from&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''derived-from''' ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xpath-20|XPath 2.0]]], section 2.5.4)''&lt;br /&gt;
: [The] pseudo-function named ''derives-from(AT, ET)'' [...] takes an actual simple or complex schema type ''AT'' and an expected simple or complex schema type ''ET'', and either returns a boolean value or raises [an error].&lt;br /&gt;
:* ''derives-from(AT, ET)'' returns ''true'' if ''ET'' is a known type and any of the following three conditions is true:&lt;br /&gt;
:*# ''AT'' is a schema type found in the [in-scope schema definitions]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;, and is the same as ''ET'' or is derived by restriction or extension from ''ET''&lt;br /&gt;
:*# ''AT'' is a schema type not found in the [in-scope schema definitions]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;, and an implementation-dependent mechanism is able to determine that ''AT'' is derived by restriction from ''ET''&lt;br /&gt;
:*# There exists some schema type ''IT'' such that ''derives-from(IT, ET)'' and ''derives-from(AT, IT)'' are ''true''.&lt;br /&gt;
:* ''derives-from(AT, ET)'' returns ''false'' if ''ET'' is a known type and either the first and third or the second and third of the following conditions are true:&lt;br /&gt;
:*# ''AT'' is a schema type found in the [in-scope schema definitions]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;, and is not the same as ''ET'', and is not derived by restriction or extension from ''ET''&lt;br /&gt;
:*# ''AT'' is a schema type not found in the [in-scope schema definitions]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;, and an implementation-dependent mechanism is able to determine that ''AT'' is not derived by restriction from ''ET''&lt;br /&gt;
:*# No schema type ''IT'' exists such that ''derives-from(IT, ET)'' and ''derives-from(AT, IT)'' are ''true''.&lt;br /&gt;
:* ''derives-from(AT, ET)'' raises [an error] if:&lt;br /&gt;
:*# ''ET'' is an unknown type, or&lt;br /&gt;
:*# ''AT'' is an unknown type, and the implementation is not able to determine whether ''AT'' is derived by restriction from ''ET''.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-document-order&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''Document order''' ''(derived from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xdm|XDM]]], section 2.4)''&lt;br /&gt;
: A document order is defined among all the element information items that describe a given XML document. Document order is a total ordering. Informally, document order is the order in which nodes appear in the XML serialization of a document.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-fn-data&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''&amp;lt;tt&amp;gt;fn:data&amp;lt;/tt&amp;gt;''' ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xfo|XFO]]], section 2.4)''&lt;br /&gt;
: &amp;lt;tt&amp;gt;fn:data&amp;lt;/tt&amp;gt; takes a sequence of items and returns a sequence of atomic values.&lt;br /&gt;
: The result of fn:data is the sequence of atomic values produced by applying the following rules to each argument:&lt;br /&gt;
:* If the item is an atomic value, it is returned.&lt;br /&gt;
:* If the item is a [node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;:&lt;br /&gt;
:** If the [node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; does not have a [typed value]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; an error is raised.&lt;br /&gt;
:** Otherwise, &amp;lt;tt&amp;gt;fn:data()&amp;lt;/tt&amp;gt; returns the [typed value]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; of the [node]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-fn-string&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''&amp;lt;tt&amp;gt;fn:string&amp;lt;/tt&amp;gt;''' ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xfo|XFO]]], section 2.3)''&lt;br /&gt;
: &amp;lt;tt&amp;gt;fn:string&amp;lt;/tt&amp;gt; returns the value of its arguments represented as a &amp;lt;tt&amp;gt;xs:string&amp;lt;/tt&amp;gt;. If no argument is supplied, the [context item]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; is used as the default argument. The behavior of the function if the argument is omitted is exactly the same as if the [context item]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; had been passed as the argument.&lt;br /&gt;
: If the [context item]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XP&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; is undefined, an error is raised.&lt;br /&gt;
: If the list of arguments is the empty sequence, the zero-length string is returned.&lt;br /&gt;
: If the argument is a node, the function returns the [string-value]&amp;lt;sup&amp;gt;&amp;lt;small&amp;gt;XDM&amp;lt;/small&amp;gt;&amp;lt;/sup&amp;gt; of the node.&lt;br /&gt;
: If the argument is an atomic value, then the function returns the value of the argument cast as a &amp;lt;tt&amp;gt;xs:string&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-governing-type-definition&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''Governing type definition'''  ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xsd11-1|XSD 1.1 Part 1]]], section 3.2.4.2 for an attribute, section 3.3.4.6 for an element)''&lt;br /&gt;
:  The governing type definition of an attribute, in a given schema-validity ·assessment· episode, is the {type definition} of the ·governing attribute declaration·, unless the processor has stipulated another type definition at the start of ·assessment· (see Assessing Schema-Validity (§5.2)), in which case it is the stipulated type definition.&lt;br /&gt;
: The governing type definition of an element information item E, in a given schema-validity ·assessment· episode, is the first of the following which applies:&lt;br /&gt;
:# An ·instance-specified type definition· which ·overrides· a type definition stipulated by the processor (see Assessing Schema-Validity (§5.2)).&lt;br /&gt;
:# A type definition stipulated by the processor (see Assessing Schema-Validity (§5.2)).&lt;br /&gt;
:# An ·instance-specified type definition· which ·overrides· the ·selected type definition· of E.&lt;br /&gt;
:# The ·selected type definition· of E.&lt;br /&gt;
:# The value ·absent· if E is ·skipped·.&lt;br /&gt;
:# An ·instance-specified type definition· which ·overrides· the ·locally declared type·.&lt;br /&gt;
:# The ·locally declared type·.&lt;br /&gt;
:# An ·instance-specified type definition·.&lt;br /&gt;
: If none of these apply, there is no ·governing type definition· (or, in equivalent words, it is ·absent·). &lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-information-item-type&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''Information item type'''&lt;br /&gt;
: An information item is said to have a simple type if its [type definition type]&amp;lt;sub&amp;gt;&amp;lt;small&amp;gt;PSVI&amp;lt;/small&amp;gt;&amp;lt;/sub&amp;gt; is ''simple'', or a complex type if its [type definition type]&amp;lt;sub&amp;gt;&amp;lt;small&amp;gt;PSVI&amp;lt;/small&amp;gt;&amp;lt;/sub&amp;gt; is ''complex'';&lt;br /&gt;
: An information item is said to have an empty, simple, element-only or mixed content, if it has a complex type and the {content type} of its [type definition]&amp;lt;sub&amp;gt;&amp;lt;small&amp;gt;PSVI&amp;lt;/small&amp;gt;&amp;lt;/sub&amp;gt; has {variety}: ''empty'', ''simple'', ''element-only'' or ''mixed'', respectively;&lt;br /&gt;
: An information item is said to have a list or a nunion type if has a simple type and its [type definition]&amp;lt;sub&amp;gt;&amp;lt;small&amp;gt;PSVI&amp;lt;/small&amp;gt;&amp;lt;/sub&amp;gt; has {variety}: ''list'' or ''union'', respectively, or if it has a complex type and a simple content, and the {content type} of its [type definition]&amp;lt;sub&amp;gt;&amp;lt;small&amp;gt;PSVI&amp;lt;/small&amp;gt;&amp;lt;/sub&amp;gt; has a {simple type definition} that has {variety}: ''list'', or ''union'', respectively.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-in-scope-schema-definitions&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''In-scope schema definitions''' ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xpath-20|XPath 2.0]]], section 2.1.1)''&lt;br /&gt;
: This is a generic term for all the element declarations, attribute declarations, and schema type definitions that are in scope during processing of an expression.] It includes ''[the In-scope schema types, the In-scope element declarations, the substitution groups and the In-scope attribute declarations]''.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-item-isomorphic&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''Item isomorphic''' ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xsd11-1|XSD 1.1 Part 1]]], section 3.17.5.1)''&lt;br /&gt;
:  By an item isomorphic to a component is meant an information item whose type is equivalent to the component's, with one property per property of the component, with the same name, and value either the same atomic value, or an information item corresponding in the same way to its component value, recursively, as necessary.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-node&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''Node''' ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xdm|XDM]]], section 2.1)''&lt;br /&gt;
: ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xdm|XDM]]], section 2.1)'' There are seven kinds of Nodes in the data model: document, element, attribute, text, namespace, processing instruction, and comment.&lt;br /&gt;
: ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xpath-20|XPath 2.0]]], section 2)'' Each node has a unique node identity, a typed value, and a string value. In addition, some nodes have a name. The typed value of a node is a sequence of zero or more atomic values. The string value of a node is a value of type &amp;lt;tt&amp;gt;xs:string&amp;lt;/tt&amp;gt;. The name of a node is a value of type &amp;lt;tt&amp;gt;xs:QName&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-normalized-value&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''Normalized value ''' ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xsd11-1|XSD 1.1 Part 1]]], section 3.1.4)&lt;br /&gt;
: The normalized value of an element or attribute information item is an initial value which has been normalized according to the value of the whiteSpace facet, and the values of any other pre-lexical facets, associated with the simple type definition used in its validation.&lt;br /&gt;
: The initial value of an attribute information item is the normalized attribute value, as specified in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xml|XML]]], section 3.3.3 (Attribute-value normalization). Similarly, the initial value of an element information item is the string composed of, in [[#glos-document-order|document order]], the character code of each character information item in the [children]&amp;lt;sub&amp;gt;&amp;lt;small&amp;gt;info&amp;lt;/small&amp;gt;&amp;lt;/sub&amp;gt; of that element information item.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-schema-normalized-value&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''Schema normalized value''' ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xsd11-1|XSD 1.1 Part 1]]], section 3.2.5.4 for attributes, section 3.3.5.4 for elements)''&lt;br /&gt;
: If an attribute's [[#glos-normalized-value|normalized value]] is valid with respect to the governing type definition, then the schema normalized value of the attribute is the [[#glos-normalized-value|normalized value]] as validated, otherwise it is absent.&lt;br /&gt;
: If an element information item is not nilled and either the [[#glos-governing-type-definition|governing type definition]] is a simple type definition or its {content type} has {variety} ''simple'', then the schema normalized value of the element is the lexical form of its value constraint if applicable; else, if the element's [[#glos-normalized-value|initial value]] is valid with respect to the simple type definition as defined by String Valid (&amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xsd11-1|XSD 1.1 Part 1]]], section 3.16.4), then the schema normalized value is the [[#glos-normalized-value|normalized value]] of the item as validated; otherwise it is absent.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-statically-known-namespaces&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''Statically-known namespaces''' ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xpath-20|XPath 2.0]]], section 2.1.1)''&lt;br /&gt;
: This is a set of (prefix, URI) pairs that define all the namespaces that are known during static processing of a given expression.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-string-value&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''String value'''&lt;br /&gt;
: The string value of a node is a string and can be extracted by applying the &amp;lt;tt&amp;gt;fn:string&amp;lt;/tt&amp;gt; function to the node.&lt;br /&gt;
: ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xdm|XDM]]], section 3.3.1.3)'' Element and attribute nodes have both typed-value and string-value properties. However, implementations are allowed some flexibility in how these properties are stored. An implementation may choose to store the string-value only and derive the typed-value from it, or to store the typed-value only and derive the string-value from it, or to store both the string-value and the typed-value.&lt;br /&gt;
: In order to permit these various implementation strategies, some variations in the string value of a node are defined as insignificant. Implementations that store only the typed value of a node are permitted to return a string value that is different from the original lexical form of the node content.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-type-axis&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''type-axis()'''  ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xsd-cd|XSD-CD]]], section 4.4.5)''&lt;br /&gt;
: The type axis contains simple type definition and complex type definition components linked to the current component through {type definition}, {type definitions}, {content type}, or {simple type definition} arcs&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;glos-typed-value&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
; '''Typed value'''&lt;br /&gt;
: The typed value of a node is a sequence of atomic values and can be extracted by applying the &amp;lt;tt&amp;gt;fn:data&amp;lt;/tt&amp;gt; function to the node.&lt;br /&gt;
: ''(from &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xdm|XDM]]], section 3.3.1.2)'' This section describes how the typed value of an Element or Attribute Node is computed from an element or attribute PSVI information item, where the information item has either a simple type or a complex type with simple content. [...]&lt;br /&gt;
: The typed value of Attribute Nodes and some Element Nodes is a sequence of atomic values. The types of the items in the typed value of a node may differ from the type of the node itself. [...]&lt;br /&gt;
: The types of the items in the typed value of a node are determined as follows. The process begins with T, the schema type of the node itself, as represented in the PSVI. For each primitive or ordinary simple type T, the W3C XML Schema specification defines a function M mapping the lexical representation of a value onto the value itself.&lt;br /&gt;
: The typed value is determined as follows:&lt;br /&gt;
:* If the nilled property of the node in question is true, then the typed value is the empty sequence.&lt;br /&gt;
:* If T is xs:anySimpleType or xs:anyAtomicType, the typed value is the [[#glos-schema-normalized-value|schema normalized value]] as an instance of xs:untypedAtomic.&lt;br /&gt;
:* Otherwise, the typed value is the result of applying M to the string value as an instance of the appropriate value type, where the appropriate value type is the [member type definition] if T is a union type, otherwise it is simply T.&lt;br /&gt;
: The typed value determination process is guaranteed to result in a sequence of atomic values, each having a well-defined atomic type.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;appendix-embedding&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Appendix B: Change Log (non-normative) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;changelog&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Complete rework of the semantics&lt;br /&gt;
&lt;br /&gt;
Since the [http://www.w3.org/TR/2010/WD-rif-xml-data-20100622/ WD published 22 June 2010]:&lt;br /&gt;
&lt;br /&gt;
* Completed the semantics&lt;br /&gt;
* Replaced the ad hoc syntax with [[#ref-xpath-20|XPath 2.0]] and [[#ref-xsd-cd|XML schema component designator syntaxes]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</description>
			<pubDate>Mon, 04 Feb 2013 16:36:59 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Talk:XML-Data</comments>		</item>
		<item>
			<title>Template:TR</title>
			<link>http://www.w3.org/2005/rules/wiki/Template:TR</link>
			<description>&lt;p&gt;Sandro:&amp;#32;Adding &amp;quot;Second Edition&amp;quot; to everything's title.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{#css:CSS/tr.css}}           &lt;br /&gt;
&lt;br /&gt;
;Document title''':'''&lt;br /&gt;
:&amp;lt;span id=&amp;quot;full-title&amp;quot;&amp;gt;&amp;lt;span id=&amp;quot;short-title&amp;quot;&amp;gt;{{{title}}} (Second Edition)&amp;lt;/span&amp;gt;&amp;lt;/span&amp;gt;&lt;/div&gt;</description>
			<pubDate>Mon, 04 Feb 2013 16:14:15 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Template_talk:TR</comments>		</item>
		<item>
			<title>Round 16</title>
			<link>http://www.w3.org/2005/rules/wiki/Round_16</link>
			<description>&lt;p&gt;Sandro:&amp;#32;/* Per-Document &amp;quot;Summary of Changes&amp;quot; */ change to &amp;quot;none&amp;quot; except for UCR&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page has information about a round of publication of&lt;br /&gt;
working group documents.&lt;br /&gt;
&lt;br /&gt;
{{#css:CSS/datatable.css}}&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
== General Information ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;open-data-table form-table&amp;quot;&lt;br /&gt;
!{{snapper|Target_Date|Target Date}}&lt;br /&gt;
|2013-02-05&lt;br /&gt;
|-&lt;br /&gt;
![http://opendatatables.org/property/selfLink This Round]&lt;br /&gt;
|[http://www.w3.org/2005/rules/wiki/Round_16 Round 16]&lt;br /&gt;
|-&lt;br /&gt;
!{{snapper|Previous_Round|Previous Round}}&lt;br /&gt;
|[http://www.w3.org/2005/rules/wiki/Round_15 Round 15]&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Announcements ==&lt;br /&gt;
&lt;br /&gt;
=== Included in All Documents ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;The following text (if any), with its header, will be included in the status&lt;br /&gt;
section of each document.   This may be left empty.&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id=&amp;quot;all-status&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;(Nothing for this round.)&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Per-Document &amp;quot;Summary of Changes&amp;quot; ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;The text provided here for each document will be extracted, during publication, and&lt;br /&gt;
placed in the &amp;quot;status of the document&amp;quot; section, under the sub-heading&lt;br /&gt;
&amp;quot;First Public Draft&amp;quot; or &amp;quot;Summary of Changes&amp;quot; (as appropriate).  This&lt;br /&gt;
text should usually be one or two paragraphs, and link into the body&lt;br /&gt;
of the draft (make it a working link, please) for more details on the&lt;br /&gt;
changes.&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id=&amp;quot;each-status&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== [[Overview]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
==== [[UCR]] ====&lt;br /&gt;
&lt;br /&gt;
The document was reorganized, sections were re-written, and an analysis was added of how the use cases are addressed by the current RIF specifications.&lt;br /&gt;
&lt;br /&gt;
==== [[Core]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
==== [[BLD]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
==== [[FLD]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
==== [[SWC]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
==== [[DTB]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
==== [[PRD]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
==== [[Test]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
==== [[XML-Data]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
==== [[OWLRL]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
==== [[RIF_In_RDF]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
==== [[Primer]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
=== Announcements of the Round ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;This text can be used as is, or modified to suit the particular forum&lt;br /&gt;
where an announcement is sent.  Feel free to add an other versions&lt;br /&gt;
that might be useful.&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== For W3C News ====&lt;br /&gt;
&lt;br /&gt;
'''Draft:'''&lt;br /&gt;
&lt;br /&gt;
RIF Supports Data Integration, Enterprise Agility&lt;br /&gt;
&lt;br /&gt;
W3C is pleased to publish the Rule Interchange Format (RIF), an extensible interlingua for rule systems, as a W3C Recommendation.  RIF was developed with participation from the Business Rules, Logic Programming, and Semantic Web communities to provide interoperability and portability between many different systems using declarative technologies. Today's publication is the largest milestone since the [http://www.w3.org/2004/12/rules-ws/ W3C Workshop on Rule Languages for Interoperability] initially surveyed the field, five years ago.&lt;br /&gt;
&lt;br /&gt;
The specification consists of six Recommendations: [http://www.w3.org/TR/2010/REC-rif-core-20100622/ RIF Core Dialect] provides a standard, base level of functionality for interchange; [http://www.w3.org/TR/2010/REC-rif-bld-20100622/ RIF Basic Logic Dialect] and [http://www.w3.org/TR/2010/REC-rif-prd-20100622/ RIF Production Rule Dialect] provided extended functionality matching two common classes of rule engines; [http://www.w3.org/TR/2010/REC-rif-fld-20100622/ RIF Framework for Logic Dialects] describes how to extend RIF for use with a large class of systems; [http://www.w3.org/TR/2010/REC-rif-dtb-20100622/ RIF Datatypes and Built-Ins 1.0] borrows heavily from XQuery and XPath for a set of basic operations; and [http://www.w3.org/TR/2010/REC-rif-rdf-owl-20100622/ RIF RDF and OWL Compatibility] specifies how RIF works with RDF data and OWL ontologies.&lt;br /&gt;
&lt;br /&gt;
Along with these documents, the RIF Working Group is today publishing five other documents: [http://www.w3.org/TR/2010/NOTE-rif-overview-20100622/ RIF Overview], [http://www.w3.org/TR/2010/WD-rif-test-20100622/ RIF Test Cases], [http://www.w3.org/TR/2010/NOTE-rif-owl-rl-20100622/ OWL 2 RL in RIF], [http://www.w3.org/TR/2010/WD-rif-xml-data-20100622/ RIF Combination with XML data], and [http://www.w3.org/TR/2010/WD-rif-in-rdf-20100622/ RIF In RDF].&lt;br /&gt;
The group is also preparing a primer and a revision of its outdated [http://www.w3.org/TR/2008/WD-rif-ucr-20081218/ Use Cases and Requirements].&lt;br /&gt;
For more information see the [[RIF FAQ]] and the [http://www.w3.org/2001/sw Semantic Web Activity].&lt;br /&gt;
&lt;br /&gt;
== Publicity Tracking ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;Please record all publicity activities here.  This is useful to avoid&lt;br /&gt;
overlap and help ensure that we've announced the round in all the&lt;br /&gt;
appropriate places.   Copied and modified from [[Round 6#Publicity]].&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;open-data-table form-table&amp;quot;&lt;br /&gt;
!{{snapper|Forum}}&lt;br /&gt;
!{{snapper|Coordinator}}&lt;br /&gt;
!{{snapper|Posting|Date or Link-to-Posting}}&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.w3.org/News/ W3C News]&lt;br /&gt;
|[[Sandro]]&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* [http://lists.w3.org/Archives/Public/semantic-web semantic-web@w3.org]&lt;br /&gt;
* [http://lists.w3.org/Archives/Public/public-owl-dev public-owl-dev@w3.org]&lt;br /&gt;
|[[Sandro]]&lt;br /&gt;
|&lt;br /&gt;
|}&lt;br /&gt;
[[Category:Publication Round]]&lt;/div&gt;</description>
			<pubDate>Mon, 04 Feb 2013 16:10:53 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Talk:Round_16</comments>		</item>
		<item>
			<title>Round 16</title>
			<link>http://www.w3.org/2005/rules/wiki/Round_16</link>
			<description>&lt;p&gt;Sandro:&amp;#32;/* General Information */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page has information about a round of publication of&lt;br /&gt;
working group documents.&lt;br /&gt;
&lt;br /&gt;
{{#css:CSS/datatable.css}}&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
== General Information ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;open-data-table form-table&amp;quot;&lt;br /&gt;
!{{snapper|Target_Date|Target Date}}&lt;br /&gt;
|2013-02-05&lt;br /&gt;
|-&lt;br /&gt;
![http://opendatatables.org/property/selfLink This Round]&lt;br /&gt;
|[http://www.w3.org/2005/rules/wiki/Round_16 Round 16]&lt;br /&gt;
|-&lt;br /&gt;
!{{snapper|Previous_Round|Previous Round}}&lt;br /&gt;
|[http://www.w3.org/2005/rules/wiki/Round_15 Round 15]&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Announcements ==&lt;br /&gt;
&lt;br /&gt;
=== Included in All Documents ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;The following text (if any), with its header, will be included in the status&lt;br /&gt;
section of each document.   This may be left empty.&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id=&amp;quot;all-status&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;(Nothing for this round.)&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Per-Document &amp;quot;Summary of Changes&amp;quot; ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;The text provided here for each document will be extracted, during publication, and&lt;br /&gt;
placed in the &amp;quot;status of the document&amp;quot; section, under the sub-heading&lt;br /&gt;
&amp;quot;First Public Draft&amp;quot; or &amp;quot;Summary of Changes&amp;quot; (as appropriate).  This&lt;br /&gt;
text should usually be one or two paragraphs, and link into the body&lt;br /&gt;
of the draft (make it a working link, please) for more details on the&lt;br /&gt;
changes.&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id=&amp;quot;each-status&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== [[Overview]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[UCR]] ====&lt;br /&gt;
&lt;br /&gt;
The document was reorganized, sections were re-written, and an analysis was added of how the use cases are addressed by the current RIF specifications.&lt;br /&gt;
&lt;br /&gt;
==== [[Core]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[BLD]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[FLD]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[SWC]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[DTB]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[PRD]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[Test]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
==== [[XML-Data]] ====&lt;br /&gt;
&lt;br /&gt;
auto&lt;br /&gt;
&lt;br /&gt;
==== [[OWLRL]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[RIF_In_RDF]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
==== [[Primer]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
=== Announcements of the Round ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;This text can be used as is, or modified to suit the particular forum&lt;br /&gt;
where an announcement is sent.  Feel free to add an other versions&lt;br /&gt;
that might be useful.&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== For W3C News ====&lt;br /&gt;
&lt;br /&gt;
'''Draft:'''&lt;br /&gt;
&lt;br /&gt;
RIF Supports Data Integration, Enterprise Agility&lt;br /&gt;
&lt;br /&gt;
W3C is pleased to publish the Rule Interchange Format (RIF), an extensible interlingua for rule systems, as a W3C Recommendation.  RIF was developed with participation from the Business Rules, Logic Programming, and Semantic Web communities to provide interoperability and portability between many different systems using declarative technologies. Today's publication is the largest milestone since the [http://www.w3.org/2004/12/rules-ws/ W3C Workshop on Rule Languages for Interoperability] initially surveyed the field, five years ago.&lt;br /&gt;
&lt;br /&gt;
The specification consists of six Recommendations: [http://www.w3.org/TR/2010/REC-rif-core-20100622/ RIF Core Dialect] provides a standard, base level of functionality for interchange; [http://www.w3.org/TR/2010/REC-rif-bld-20100622/ RIF Basic Logic Dialect] and [http://www.w3.org/TR/2010/REC-rif-prd-20100622/ RIF Production Rule Dialect] provided extended functionality matching two common classes of rule engines; [http://www.w3.org/TR/2010/REC-rif-fld-20100622/ RIF Framework for Logic Dialects] describes how to extend RIF for use with a large class of systems; [http://www.w3.org/TR/2010/REC-rif-dtb-20100622/ RIF Datatypes and Built-Ins 1.0] borrows heavily from XQuery and XPath for a set of basic operations; and [http://www.w3.org/TR/2010/REC-rif-rdf-owl-20100622/ RIF RDF and OWL Compatibility] specifies how RIF works with RDF data and OWL ontologies.&lt;br /&gt;
&lt;br /&gt;
Along with these documents, the RIF Working Group is today publishing five other documents: [http://www.w3.org/TR/2010/NOTE-rif-overview-20100622/ RIF Overview], [http://www.w3.org/TR/2010/WD-rif-test-20100622/ RIF Test Cases], [http://www.w3.org/TR/2010/NOTE-rif-owl-rl-20100622/ OWL 2 RL in RIF], [http://www.w3.org/TR/2010/WD-rif-xml-data-20100622/ RIF Combination with XML data], and [http://www.w3.org/TR/2010/WD-rif-in-rdf-20100622/ RIF In RDF].&lt;br /&gt;
The group is also preparing a primer and a revision of its outdated [http://www.w3.org/TR/2008/WD-rif-ucr-20081218/ Use Cases and Requirements].&lt;br /&gt;
For more information see the [[RIF FAQ]] and the [http://www.w3.org/2001/sw Semantic Web Activity].&lt;br /&gt;
&lt;br /&gt;
== Publicity Tracking ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;Please record all publicity activities here.  This is useful to avoid&lt;br /&gt;
overlap and help ensure that we've announced the round in all the&lt;br /&gt;
appropriate places.   Copied and modified from [[Round 6#Publicity]].&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;open-data-table form-table&amp;quot;&lt;br /&gt;
!{{snapper|Forum}}&lt;br /&gt;
!{{snapper|Coordinator}}&lt;br /&gt;
!{{snapper|Posting|Date or Link-to-Posting}}&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.w3.org/News/ W3C News]&lt;br /&gt;
|[[Sandro]]&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* [http://lists.w3.org/Archives/Public/semantic-web semantic-web@w3.org]&lt;br /&gt;
* [http://lists.w3.org/Archives/Public/public-owl-dev public-owl-dev@w3.org]&lt;br /&gt;
|[[Sandro]]&lt;br /&gt;
|&lt;br /&gt;
|}&lt;br /&gt;
[[Category:Publication Round]]&lt;/div&gt;</description>
			<pubDate>Mon, 04 Feb 2013 15:47:13 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Talk:Round_16</comments>		</item>
		<item>
			<title>Round 16</title>
			<link>http://www.w3.org/2005/rules/wiki/Round_16</link>
			<description>&lt;p&gt;Sandro:&amp;#32;/* Primer */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page has information about a round of publication of&lt;br /&gt;
working group documents.&lt;br /&gt;
&lt;br /&gt;
{{#css:CSS/datatable.css}}&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
== General Information ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;open-data-table form-table&amp;quot;&lt;br /&gt;
!{{snapper|Target_Date|Target Date}}&lt;br /&gt;
|2012-12-11&lt;br /&gt;
|-&lt;br /&gt;
![http://opendatatables.org/property/selfLink This Round]&lt;br /&gt;
|[http://www.w3.org/2005/rules/wiki/Round_15 Round 15]&lt;br /&gt;
|-&lt;br /&gt;
!{{snapper|Previous_Round|Previous Round}}&lt;br /&gt;
|[http://www.w3.org/2005/rules/wiki/Round_14 Round 14]&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Announcements ==&lt;br /&gt;
&lt;br /&gt;
=== Included in All Documents ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;The following text (if any), with its header, will be included in the status&lt;br /&gt;
section of each document.   This may be left empty.&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id=&amp;quot;all-status&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;(Nothing for this round.)&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Per-Document &amp;quot;Summary of Changes&amp;quot; ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;The text provided here for each document will be extracted, during publication, and&lt;br /&gt;
placed in the &amp;quot;status of the document&amp;quot; section, under the sub-heading&lt;br /&gt;
&amp;quot;First Public Draft&amp;quot; or &amp;quot;Summary of Changes&amp;quot; (as appropriate).  This&lt;br /&gt;
text should usually be one or two paragraphs, and link into the body&lt;br /&gt;
of the draft (make it a working link, please) for more details on the&lt;br /&gt;
changes.&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id=&amp;quot;each-status&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== [[Overview]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[UCR]] ====&lt;br /&gt;
&lt;br /&gt;
The document was reorganized, sections were re-written, and an analysis was added of how the use cases are addressed by the current RIF specifications.&lt;br /&gt;
&lt;br /&gt;
==== [[Core]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[BLD]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[FLD]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[SWC]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[DTB]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[PRD]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[Test]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
==== [[XML-Data]] ====&lt;br /&gt;
&lt;br /&gt;
auto&lt;br /&gt;
&lt;br /&gt;
==== [[OWLRL]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[RIF_In_RDF]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
==== [[Primer]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
=== Announcements of the Round ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;This text can be used as is, or modified to suit the particular forum&lt;br /&gt;
where an announcement is sent.  Feel free to add an other versions&lt;br /&gt;
that might be useful.&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== For W3C News ====&lt;br /&gt;
&lt;br /&gt;
'''Draft:'''&lt;br /&gt;
&lt;br /&gt;
RIF Supports Data Integration, Enterprise Agility&lt;br /&gt;
&lt;br /&gt;
W3C is pleased to publish the Rule Interchange Format (RIF), an extensible interlingua for rule systems, as a W3C Recommendation.  RIF was developed with participation from the Business Rules, Logic Programming, and Semantic Web communities to provide interoperability and portability between many different systems using declarative technologies. Today's publication is the largest milestone since the [http://www.w3.org/2004/12/rules-ws/ W3C Workshop on Rule Languages for Interoperability] initially surveyed the field, five years ago.&lt;br /&gt;
&lt;br /&gt;
The specification consists of six Recommendations: [http://www.w3.org/TR/2010/REC-rif-core-20100622/ RIF Core Dialect] provides a standard, base level of functionality for interchange; [http://www.w3.org/TR/2010/REC-rif-bld-20100622/ RIF Basic Logic Dialect] and [http://www.w3.org/TR/2010/REC-rif-prd-20100622/ RIF Production Rule Dialect] provided extended functionality matching two common classes of rule engines; [http://www.w3.org/TR/2010/REC-rif-fld-20100622/ RIF Framework for Logic Dialects] describes how to extend RIF for use with a large class of systems; [http://www.w3.org/TR/2010/REC-rif-dtb-20100622/ RIF Datatypes and Built-Ins 1.0] borrows heavily from XQuery and XPath for a set of basic operations; and [http://www.w3.org/TR/2010/REC-rif-rdf-owl-20100622/ RIF RDF and OWL Compatibility] specifies how RIF works with RDF data and OWL ontologies.&lt;br /&gt;
&lt;br /&gt;
Along with these documents, the RIF Working Group is today publishing five other documents: [http://www.w3.org/TR/2010/NOTE-rif-overview-20100622/ RIF Overview], [http://www.w3.org/TR/2010/WD-rif-test-20100622/ RIF Test Cases], [http://www.w3.org/TR/2010/NOTE-rif-owl-rl-20100622/ OWL 2 RL in RIF], [http://www.w3.org/TR/2010/WD-rif-xml-data-20100622/ RIF Combination with XML data], and [http://www.w3.org/TR/2010/WD-rif-in-rdf-20100622/ RIF In RDF].&lt;br /&gt;
The group is also preparing a primer and a revision of its outdated [http://www.w3.org/TR/2008/WD-rif-ucr-20081218/ Use Cases and Requirements].&lt;br /&gt;
For more information see the [[RIF FAQ]] and the [http://www.w3.org/2001/sw Semantic Web Activity].&lt;br /&gt;
&lt;br /&gt;
== Publicity Tracking ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;Please record all publicity activities here.  This is useful to avoid&lt;br /&gt;
overlap and help ensure that we've announced the round in all the&lt;br /&gt;
appropriate places.   Copied and modified from [[Round 6#Publicity]].&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;open-data-table form-table&amp;quot;&lt;br /&gt;
!{{snapper|Forum}}&lt;br /&gt;
!{{snapper|Coordinator}}&lt;br /&gt;
!{{snapper|Posting|Date or Link-to-Posting}}&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.w3.org/News/ W3C News]&lt;br /&gt;
|[[Sandro]]&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* [http://lists.w3.org/Archives/Public/semantic-web semantic-web@w3.org]&lt;br /&gt;
* [http://lists.w3.org/Archives/Public/public-owl-dev public-owl-dev@w3.org]&lt;br /&gt;
|[[Sandro]]&lt;br /&gt;
|&lt;br /&gt;
|}&lt;br /&gt;
[[Category:Publication Round]]&lt;/div&gt;</description>
			<pubDate>Mon, 04 Feb 2013 15:46:25 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Talk:Round_16</comments>		</item>
		<item>
			<title>Round 16</title>
			<link>http://www.w3.org/2005/rules/wiki/Round_16</link>
			<description>&lt;p&gt;Sandro:&amp;#32;copy 15; now edit....&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page has information about a round of publication of&lt;br /&gt;
working group documents.&lt;br /&gt;
&lt;br /&gt;
{{#css:CSS/datatable.css}}&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
== General Information ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;open-data-table form-table&amp;quot;&lt;br /&gt;
!{{snapper|Target_Date|Target Date}}&lt;br /&gt;
|2012-12-11&lt;br /&gt;
|-&lt;br /&gt;
![http://opendatatables.org/property/selfLink This Round]&lt;br /&gt;
|[http://www.w3.org/2005/rules/wiki/Round_15 Round 15]&lt;br /&gt;
|-&lt;br /&gt;
!{{snapper|Previous_Round|Previous Round}}&lt;br /&gt;
|[http://www.w3.org/2005/rules/wiki/Round_14 Round 14]&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Announcements ==&lt;br /&gt;
&lt;br /&gt;
=== Included in All Documents ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;The following text (if any), with its header, will be included in the status&lt;br /&gt;
section of each document.   This may be left empty.&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id=&amp;quot;all-status&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;(Nothing for this round.)&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Per-Document &amp;quot;Summary of Changes&amp;quot; ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;The text provided here for each document will be extracted, during publication, and&lt;br /&gt;
placed in the &amp;quot;status of the document&amp;quot; section, under the sub-heading&lt;br /&gt;
&amp;quot;First Public Draft&amp;quot; or &amp;quot;Summary of Changes&amp;quot; (as appropriate).  This&lt;br /&gt;
text should usually be one or two paragraphs, and link into the body&lt;br /&gt;
of the draft (make it a working link, please) for more details on the&lt;br /&gt;
changes.&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id=&amp;quot;each-status&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== [[Overview]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[UCR]] ====&lt;br /&gt;
&lt;br /&gt;
The document was reorganized, sections were re-written, and an analysis was added of how the use cases are addressed by the current RIF specifications.&lt;br /&gt;
&lt;br /&gt;
==== [[Core]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[BLD]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[FLD]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[SWC]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[DTB]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[PRD]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[Test]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
==== [[XML-Data]] ====&lt;br /&gt;
&lt;br /&gt;
auto&lt;br /&gt;
&lt;br /&gt;
==== [[OWLRL]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[RIF_In_RDF]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
==== [[Primer]] ====&lt;br /&gt;
&lt;br /&gt;
This is the first publication of this material.&lt;br /&gt;
&lt;br /&gt;
=== Announcements of the Round ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;This text can be used as is, or modified to suit the particular forum&lt;br /&gt;
where an announcement is sent.  Feel free to add an other versions&lt;br /&gt;
that might be useful.&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== For W3C News ====&lt;br /&gt;
&lt;br /&gt;
'''Draft:'''&lt;br /&gt;
&lt;br /&gt;
RIF Supports Data Integration, Enterprise Agility&lt;br /&gt;
&lt;br /&gt;
W3C is pleased to publish the Rule Interchange Format (RIF), an extensible interlingua for rule systems, as a W3C Recommendation.  RIF was developed with participation from the Business Rules, Logic Programming, and Semantic Web communities to provide interoperability and portability between many different systems using declarative technologies. Today's publication is the largest milestone since the [http://www.w3.org/2004/12/rules-ws/ W3C Workshop on Rule Languages for Interoperability] initially surveyed the field, five years ago.&lt;br /&gt;
&lt;br /&gt;
The specification consists of six Recommendations: [http://www.w3.org/TR/2010/REC-rif-core-20100622/ RIF Core Dialect] provides a standard, base level of functionality for interchange; [http://www.w3.org/TR/2010/REC-rif-bld-20100622/ RIF Basic Logic Dialect] and [http://www.w3.org/TR/2010/REC-rif-prd-20100622/ RIF Production Rule Dialect] provided extended functionality matching two common classes of rule engines; [http://www.w3.org/TR/2010/REC-rif-fld-20100622/ RIF Framework for Logic Dialects] describes how to extend RIF for use with a large class of systems; [http://www.w3.org/TR/2010/REC-rif-dtb-20100622/ RIF Datatypes and Built-Ins 1.0] borrows heavily from XQuery and XPath for a set of basic operations; and [http://www.w3.org/TR/2010/REC-rif-rdf-owl-20100622/ RIF RDF and OWL Compatibility] specifies how RIF works with RDF data and OWL ontologies.&lt;br /&gt;
&lt;br /&gt;
Along with these documents, the RIF Working Group is today publishing five other documents: [http://www.w3.org/TR/2010/NOTE-rif-overview-20100622/ RIF Overview], [http://www.w3.org/TR/2010/WD-rif-test-20100622/ RIF Test Cases], [http://www.w3.org/TR/2010/NOTE-rif-owl-rl-20100622/ OWL 2 RL in RIF], [http://www.w3.org/TR/2010/WD-rif-xml-data-20100622/ RIF Combination with XML data], and [http://www.w3.org/TR/2010/WD-rif-in-rdf-20100622/ RIF In RDF].&lt;br /&gt;
The group is also preparing a primer and a revision of its outdated [http://www.w3.org/TR/2008/WD-rif-ucr-20081218/ Use Cases and Requirements].&lt;br /&gt;
For more information see the [[RIF FAQ]] and the [http://www.w3.org/2001/sw Semantic Web Activity].&lt;br /&gt;
&lt;br /&gt;
== Publicity Tracking ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;Please record all publicity activities here.  This is useful to avoid&lt;br /&gt;
overlap and help ensure that we've announced the round in all the&lt;br /&gt;
appropriate places.   Copied and modified from [[Round 6#Publicity]].&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;open-data-table form-table&amp;quot;&lt;br /&gt;
!{{snapper|Forum}}&lt;br /&gt;
!{{snapper|Coordinator}}&lt;br /&gt;
!{{snapper|Posting|Date or Link-to-Posting}}&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.w3.org/News/ W3C News]&lt;br /&gt;
|[[Sandro]]&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* [http://lists.w3.org/Archives/Public/semantic-web semantic-web@w3.org]&lt;br /&gt;
* [http://lists.w3.org/Archives/Public/public-owl-dev public-owl-dev@w3.org]&lt;br /&gt;
|[[Sandro]]&lt;br /&gt;
|&lt;br /&gt;
|}&lt;br /&gt;
[[Category:Publication Round]]&lt;/div&gt;</description>
			<pubDate>Mon, 04 Feb 2013 15:16:29 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Talk:Round_16</comments>		</item>
		<item>
			<title>Round 15</title>
			<link>http://www.w3.org/2005/rules/wiki/Round_15</link>
			<description>&lt;p&gt;Sandro:&amp;#32;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page has information about a round of publication of&lt;br /&gt;
working group documents.&lt;br /&gt;
&lt;br /&gt;
{{#css:CSS/datatable.css}}&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
== General Information ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;open-data-table form-table&amp;quot;&lt;br /&gt;
!{{snapper|Target_Date|Target Date}}&lt;br /&gt;
|2012-12-11&lt;br /&gt;
|-&lt;br /&gt;
![http://opendatatables.org/property/selfLink This Round]&lt;br /&gt;
|[http://www.w3.org/2005/rules/wiki/Round_15 Round 15]&lt;br /&gt;
|-&lt;br /&gt;
!{{snapper|Previous_Round|Previous Round}}&lt;br /&gt;
|[http://www.w3.org/2005/rules/wiki/Round_14 Round 14]&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Announcements ==&lt;br /&gt;
&lt;br /&gt;
=== Included in All Documents ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;The following text (if any), with its header, will be included in the status&lt;br /&gt;
section of each document.   This may be left empty.&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id=&amp;quot;all-status&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;(Nothing for this round.)&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Per-Document &amp;quot;Summary of Changes&amp;quot; ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;The text provided here for each document will be extracted, during publication, and&lt;br /&gt;
placed in the &amp;quot;status of the document&amp;quot; section, under the sub-heading&lt;br /&gt;
&amp;quot;First Public Draft&amp;quot; or &amp;quot;Summary of Changes&amp;quot; (as appropriate).  This&lt;br /&gt;
text should usually be one or two paragraphs, and link into the body&lt;br /&gt;
of the draft (make it a working link, please) for more details on the&lt;br /&gt;
changes.&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id=&amp;quot;each-status&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== [[Overview]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[UCR]] ====&lt;br /&gt;
&lt;br /&gt;
The document was reorganized, sections were re-written, and an analysis was added of how the use cases are addressed by the current RIF specifications.&lt;br /&gt;
&lt;br /&gt;
==== [[Core]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[BLD]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[FLD]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[SWC]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[DTB]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[PRD]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[Test]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
==== [[XML-Data]] ====&lt;br /&gt;
&lt;br /&gt;
auto&lt;br /&gt;
&lt;br /&gt;
==== [[OWLRL]] ====&lt;br /&gt;
&lt;br /&gt;
auto/minor&lt;br /&gt;
&lt;br /&gt;
==== [[RIF_In_RDF]] ====&lt;br /&gt;
&lt;br /&gt;
auto/none&lt;br /&gt;
&lt;br /&gt;
==== [[Primer]] ====&lt;br /&gt;
&lt;br /&gt;
This is the first publication of this material.&lt;br /&gt;
&lt;br /&gt;
=== Announcements of the Round ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;This text can be used as is, or modified to suit the particular forum&lt;br /&gt;
where an announcement is sent.  Feel free to add an other versions&lt;br /&gt;
that might be useful.&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== For W3C News ====&lt;br /&gt;
&lt;br /&gt;
'''Draft:'''&lt;br /&gt;
&lt;br /&gt;
RIF Supports Data Integration, Enterprise Agility&lt;br /&gt;
&lt;br /&gt;
W3C is pleased to publish the Rule Interchange Format (RIF), an extensible interlingua for rule systems, as a W3C Recommendation.  RIF was developed with participation from the Business Rules, Logic Programming, and Semantic Web communities to provide interoperability and portability between many different systems using declarative technologies. Today's publication is the largest milestone since the [http://www.w3.org/2004/12/rules-ws/ W3C Workshop on Rule Languages for Interoperability] initially surveyed the field, five years ago.&lt;br /&gt;
&lt;br /&gt;
The specification consists of six Recommendations: [http://www.w3.org/TR/2010/REC-rif-core-20100622/ RIF Core Dialect] provides a standard, base level of functionality for interchange; [http://www.w3.org/TR/2010/REC-rif-bld-20100622/ RIF Basic Logic Dialect] and [http://www.w3.org/TR/2010/REC-rif-prd-20100622/ RIF Production Rule Dialect] provided extended functionality matching two common classes of rule engines; [http://www.w3.org/TR/2010/REC-rif-fld-20100622/ RIF Framework for Logic Dialects] describes how to extend RIF for use with a large class of systems; [http://www.w3.org/TR/2010/REC-rif-dtb-20100622/ RIF Datatypes and Built-Ins 1.0] borrows heavily from XQuery and XPath for a set of basic operations; and [http://www.w3.org/TR/2010/REC-rif-rdf-owl-20100622/ RIF RDF and OWL Compatibility] specifies how RIF works with RDF data and OWL ontologies.&lt;br /&gt;
&lt;br /&gt;
Along with these documents, the RIF Working Group is today publishing five other documents: [http://www.w3.org/TR/2010/NOTE-rif-overview-20100622/ RIF Overview], [http://www.w3.org/TR/2010/WD-rif-test-20100622/ RIF Test Cases], [http://www.w3.org/TR/2010/NOTE-rif-owl-rl-20100622/ OWL 2 RL in RIF], [http://www.w3.org/TR/2010/WD-rif-xml-data-20100622/ RIF Combination with XML data], and [http://www.w3.org/TR/2010/WD-rif-in-rdf-20100622/ RIF In RDF].&lt;br /&gt;
The group is also preparing a primer and a revision of its outdated [http://www.w3.org/TR/2008/WD-rif-ucr-20081218/ Use Cases and Requirements].&lt;br /&gt;
For more information see the [[RIF FAQ]] and the [http://www.w3.org/2001/sw Semantic Web Activity].&lt;br /&gt;
&lt;br /&gt;
== Publicity Tracking ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;em&amp;gt;Please record all publicity activities here.  This is useful to avoid&lt;br /&gt;
overlap and help ensure that we've announced the round in all the&lt;br /&gt;
appropriate places.   Copied and modified from [[Round 6#Publicity]].&amp;lt;/em&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;open-data-table form-table&amp;quot;&lt;br /&gt;
!{{snapper|Forum}}&lt;br /&gt;
!{{snapper|Coordinator}}&lt;br /&gt;
!{{snapper|Posting|Date or Link-to-Posting}}&lt;br /&gt;
|-&lt;br /&gt;
|[http://www.w3.org/News/ W3C News]&lt;br /&gt;
|[[Sandro]]&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* [http://lists.w3.org/Archives/Public/semantic-web semantic-web@w3.org]&lt;br /&gt;
* [http://lists.w3.org/Archives/Public/public-owl-dev public-owl-dev@w3.org]&lt;br /&gt;
|[[Sandro]]&lt;br /&gt;
|&lt;br /&gt;
|}&lt;br /&gt;
[[Category:Publication Round]]&lt;/div&gt;</description>
			<pubDate>Tue, 11 Dec 2012 14:19:58 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Talk:Round_15</comments>		</item>
		<item>
			<title>UCR</title>
			<link>http://www.w3.org/2005/rules/wiki/UCR</link>
			<description>&lt;p&gt;Sandro:&amp;#32;fix pre inside p&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NUMBEREDHEADINGS__&lt;br /&gt;
{{TR|title=RIF Use Cases and Requirements}}&lt;br /&gt;
&amp;lt;div id='editors'&amp;gt;&lt;br /&gt;
; Editors:&lt;br /&gt;
: Adrian Paschke, Freie Universitaet Berlin&lt;br /&gt;
: Leora Morgenstern, SAIC&lt;br /&gt;
: David Hirtle, National Research Council Canada&lt;br /&gt;
: Allen Ginsberg, Mitre&lt;br /&gt;
: Paula-Lavinia Patranjan, REWERSE&lt;br /&gt;
: Frank &amp;lt;nowiki&amp;gt;McCabe&amp;lt;/nowiki&amp;gt;, Fujitsu&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
; Abstract&lt;br /&gt;
: &amp;lt;div id='abstract'&amp;gt;&amp;lt;p&amp;gt;&amp;lt;/p&amp;gt; &amp;lt;p&amp;gt;&amp;lt;/p&amp;gt; &amp;lt;p&amp;gt;&amp;lt;/p&amp;gt; &amp;lt;p&amp;gt;This document, developed by the [http://www.w3.org/2005/rules/wg Rule Interchange Format (RIF) Working Group], specifies use cases and requirements for the W3C Rule Interchange Format, a family of rule interchange dialects that allows rules to be translated between rule languages and thus transferred between rule systems. &amp;lt;/p&amp;gt; &amp;lt;/div&amp;gt;&lt;br /&gt;
; Status of this Document&lt;br /&gt;
: 3rd revised version of the UCR document&lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/Consortium/Legal/ipr-notice#Copyright Copyright] © 2010 [http://www.w3.org/ W3C]&amp;lt;sup&amp;gt;®&amp;lt;/sup&amp;gt; ([http://www.csail.mit.edu/ MIT], [http://www.ercim.org/ ERCIM], [http://www.keio.ac.jp/ Keio]), All Rights Reserved. W3C [http://www.w3.org/Consortium/Legal/ipr-notice#Legal_Disclaimer liability], [http://www.w3.org/Consortium/Legal/ipr-notice#W3C_Trademarks trademark] and [http://www.w3.org/Consortium/Legal/copyright-documents document use] rules apply.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id='docbody'&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;html&amp;gt;&lt;br /&gt;
&amp;lt;script type=&amp;quot;text/javascript&amp;quot;&amp;gt;/*&amp;lt;![CDATA[*/&lt;br /&gt;
/*&lt;br /&gt;
	Written by Jonathan Snook, http://www.snook.ca/jonathan&lt;br /&gt;
	Add-ons by Robert Nyman, http://www.robertnyman.com&lt;br /&gt;
	Author says &amp;quot;The credit comment is all it takes, no license. Go crazy with it!:-)&amp;quot;&lt;br /&gt;
	From http://www.robertnyman.com/2005/11/07/the-ultimate-getelementsbyclassname/&lt;br /&gt;
*/&lt;br /&gt;
&lt;br /&gt;
var displayed = [];&lt;br /&gt;
displayed[&amp;quot;bld&amp;quot;] = 1;&lt;br /&gt;
displayed[&amp;quot;prd&amp;quot;] = 1;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
function display(syntax,status) {&lt;br /&gt;
  var howmany = 0;&lt;br /&gt;
  if (status=='none') {&lt;br /&gt;
    displayed[syntax] = 0; &lt;br /&gt;
  } else { &lt;br /&gt;
    displayed[syntax] = 1;&lt;br /&gt;
  }&lt;br /&gt;
  for ( i in displayed ) {&lt;br /&gt;
       howmany = howmany + displayed[i];&lt;br /&gt;
  }&lt;br /&gt;
  set_display_by_class('p',syntax,status);&lt;br /&gt;
  if ( howmany == 1 ) {&lt;br /&gt;
      set_display_by_class('b','syntax-head','none');&lt;br /&gt;
  } else {&lt;br /&gt;
      set_display_by_class('b','syntax-head','');&lt;br /&gt;
  }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
function getElementsByClassName(oElm, strTagName, oClassNames){&lt;br /&gt;
	var arrElements = (! (! (strTagName == &amp;quot;*&amp;quot;) || ! (oElm.all)))? oElm.all : oElm.getElementsByTagName(strTagName);&lt;br /&gt;
	var arrReturnElements = new Array();&lt;br /&gt;
	var arrRegExpClassNames = new Array();&lt;br /&gt;
	if(typeof oClassNames == &amp;quot;object&amp;quot;){&lt;br /&gt;
		for(var i=0; !(i&amp;gt;=oClassNames.length); i++){ /*&amp;gt;*/&lt;br /&gt;
			arrRegExpClassNames.push(new RegExp(&amp;quot;(^|\\s)&amp;quot; + oClassNames[i].replace(/\-/g, &amp;quot;\\-&amp;quot;) + &amp;quot;(\\s|$)&amp;quot;));&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
	else{&lt;br /&gt;
		arrRegExpClassNames.push(new RegExp(&amp;quot;(^|\\s)&amp;quot; + oClassNames.replace(/\-/g, &amp;quot;\\-&amp;quot;) + &amp;quot;(\\s|$)&amp;quot;));&lt;br /&gt;
	}&lt;br /&gt;
	var oElement;&lt;br /&gt;
	var bMatchesAll;&lt;br /&gt;
	for(var j=0; !(j&amp;gt;=arrElements.length); j++){ /*&amp;gt;*/&lt;br /&gt;
		oElement = arrElements[j];&lt;br /&gt;
		bMatchesAll = true;&lt;br /&gt;
		for(var k=0; !(k&amp;gt;=arrRegExpClassNames.length); k++){ /*&amp;gt;*/&lt;br /&gt;
			if(!arrRegExpClassNames[k].test(oElement.className)){&lt;br /&gt;
				bMatchesAll = false;&lt;br /&gt;
				break;&lt;br /&gt;
			}&lt;br /&gt;
		}&lt;br /&gt;
		if(bMatchesAll){&lt;br /&gt;
			arrReturnElements.push(oElement);&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
	return (arrReturnElements)&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
function set_display_by_class(el, cls, newValue) {&lt;br /&gt;
   var e = getElementsByClassName(document, el, cls);&lt;br /&gt;
   if (e != null) {&lt;br /&gt;
      for (var i=0; !(i&amp;gt;=e.length); i++) {&lt;br /&gt;
        e[i].style.display = newValue;&lt;br /&gt;
      }&lt;br /&gt;
   }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
function set_display_by_id(id, newValue) {&lt;br /&gt;
   var e = document.getElementById(id);&lt;br /&gt;
   if (e != null) {&lt;br /&gt;
     e.style.display = newValue;&lt;br /&gt;
   }&lt;br /&gt;
}&lt;br /&gt;
/*]]&amp;gt;*/&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/html&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;   &amp;lt;!-- because there seems to be a close-div after the intro --&amp;gt;&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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 existing 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. This mission of RIF is part of W3C's larger goal of enabling the sharing of information in forms suited to machine processing: &lt;br /&gt;
&lt;br /&gt;
*# 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 [http://www.ruleml.org/ RuleML Initiative] and elsewhere. &lt;br /&gt;
*# Rules provide a powerful business logic representation, as business rules, in many modern information systems. &lt;br /&gt;
*# Rules are often the technology of choice for creating maintainable adapters between information systems. &lt;br /&gt;
*# 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. &lt;br /&gt;
&lt;br /&gt;
The purpose of this RIF-UCR document is to describe the use cases that guided the design of RIF and to document the design requirements that were derived from both the use cases and from the basic goals of RIF. RIF-UCR also delivers a structured context for formulating future technical specifications of further RIF dialects. Each dialect targets at a cluster of similar rule languages and enables platform-independent interoperation between them (via interchange of RIF rules). 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.&lt;br /&gt;
&lt;br /&gt;
The RIF-UCR document is structured as follows: Section 2 formulates the overall goals of RIF. Section 3 summarizes the released RIF dialects and the current structure of RIF. Section 4 discusses several important requirements for RIF dialects. Section 5 presents a set of use cases that are representative of the types of application scenarios that RIF is intended to support. The use cases illustrate the utilization of the current RIF dialects.  More importantly, the functionality specified in the use cases, together with the requirements discussed in the previous section, serves as input for both the technical specification of future RIF dialects and for the implementation of various variants of these scenarios by RIF-compliant applications and systems. &lt;br /&gt;
&lt;br /&gt;
Although in this document the discussion of requirements precedes the discussion of the use cases in this document,  the development of the use cases preceded, and in fact motivated, the development of the requirements. In general, it is intended that for each requirement, there is at least one use case, or straightforward modification of a use case, from which that requirement was derived.  There are some exceptions to this rule: some requirements were already defined as constraints in the working group charter, and were not necessarily derived from any specific use case. The fulfillment of such requirements is discussed with respect to the existing RIF dialects. &lt;br /&gt;
&lt;br /&gt;
Note that in fact not all use cases can be represented in a straightforward manner within all RIF dialects. In particular, several use cases cannot be represented within the RIF dialect BLD. This is due first, to the fact that BLD is strictly less expressive than first-order logic (since negation is not expressible), and second, to the fact that some use cases are most naturally represented in languages more powerful than first-order logic, such as modal logics. Following the presentation of each use case in Section 5 is a note indicating in which of the current RIF dialects a use case can be represented naturally, sometimes accompanied by discussion.&lt;br /&gt;
&lt;br /&gt;
It should be noted that even use cases which cannot be represented in a straightforward manner within some RIF dialect, such as BLD, there may be other approaches which will enable representation. For example, although epistemic operators such as &amp;lt;tt&amp;gt;Know&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;Believe&amp;lt;/tt&amp;gt; are most straightforwardly represented within a modal logic, it is generally possible to represent such operators in a first-order logic using a possible-worlds semantics. For certain use cases which cannot be naturally represented within some dialect, the extent to which this can be done will be discussed.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Goals ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
The primary goal of 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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;goal-exchange-of-rules&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
==== Exchange of Rules ====&lt;br /&gt;
&lt;br /&gt;
The primary goal of RIF is to facilitate the exchange of rules. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;goal-w3c-consistency&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
==== Consistency with W3C specifications ====&lt;br /&gt;
&lt;br /&gt;
RIF 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 RIF. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;goal-widescale-adoption&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
==== Widescale Adoption ====&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;network effect&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
Along with the use cases in the next section, these goals motivate the requirements in Section 5.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Structure of RIF ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
RIF is described by a set of documents, each fulfilling a different purpose, and catering to a different audience. The three RIF dialects which can be used to represent RIF use cases are:&lt;br /&gt;
&lt;br /&gt;
* [http://www.w3.org/TR/rif-core RIF Core Dialect], which provides a standard, base level of functionality for interchange&lt;br /&gt;
* [http://www.w3.org/TR/rif-bld RIF Basic Logic Dialect] and [http://www.w3.org/TR/2010/REC-rif-prd-20100622/ RIF Production Rule Dialect] provide extended functionality matching two common classes of rule engines, namely derivation rules and production rules.&lt;br /&gt;
&lt;br /&gt;
Along with these three dialects, RIF consists of related documents: [http://www.w3.org/TR/rif-fld RIF Framework for Logic Dialects], [http://www.w3.org/TR/rif-dtb RIF Datatypes and Built-Ins 1.0], [http://www.w3.org/TR/rif-test RIF Test Cases], [http://www.w3.org/TR/rif-rdf-owl RIF RDF and OWL Compatibility], [http://www.w3.org/TR/rif-ucr/ RIF Use Cases and Requirements], [http://www.w3.org/TR/rif-owl-rl OWL 2 RL in RIF], [http://www.w3.org/2007/OWL/wiki/PlainLiteral rdf:PlainLiteral], [http://www.w3.org/TR/rif-xml-data RIF Combination with XML data], [http://www.w3.org/TR/rif-primer RIF Primer] and [http://www.w3.org/TR/rif-in-rdf/ RIF In RDF]. For an overview on RIF see the [http://www.w3.org/TR/rif-overview RIF Overview].&lt;br /&gt;
&lt;br /&gt;
RIF is designed as a family of RIF dialects as shown in the following Venn diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image: RIF_DIALECTS_VENN.jpg | Venn Diagram of RIF Dialects]]&lt;br /&gt;
&lt;br /&gt;
Each dialect is a collection of components that works together, forming an interlingua. New dialects are needed when no existing dialect provides the required rule-language features for interchange.&lt;br /&gt;
&lt;br /&gt;
The RIF Framework for Logic-based Dialects ([http://www.w3.org/TR/rif-fld RIF-FLD]) describes mechanisms for specifying the syntax and semantics of logic-based RIF dialects through a number of generic concepts. Every logic-based RIF dialect should specialize these general mechanisms or justify why it does not. This specialization may include leaving out some elements of RIF-FLD, to produce its concrete syntax and model-theoretic semantics. Currently, the first two existing RIF dialects are the RIF Basic Logic Dialect (RIF-BLD) and the RIF Production Rules Dialect (RIF-PRD) which is a partial specialization of FLD.&lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/TR/rif-bld RIF-BLD] (Basic Logic Dialect) is a specialization of RIF-FLD capable of representing definite Horn rules with equality enhanced with a number of syntactic extensions to support expressive features such as objects and frames, internationalized resource identifiers (IRIs) as identifiers for concepts, and XML Schema data types.&lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/TR/rif-prd RIF-PRD] (Production Rules Dialect) specifies a production rules dialect to enable the interchange of production rules. The condition language of RIF PRD is defined in Core as a common subset of RIF BLD and RIF PRD. &lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/TR/rif-core RIF-Core] (Core Dialect) specifies a common subset of RIF-BLD and RIF-PRD which includes RIF-DTB.&lt;br /&gt;
&lt;br /&gt;
The normative syntax for RIF dialects is a concrete XML syntax. A non-normative presentation syntax is additionally specified for each dialect, to allow a more easily readable and compact presentation of language fragments (such as examples).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Requirements ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-semantic-tagging&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
The goals and use cases motivate a number of requirements for a Rule Interchange Format. The Working Group has approved the following requirements.  &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-implementability&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Implementability ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-semantic-precision&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Semantic precision ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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 extend RIF core.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-extensible&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Extensible Format ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''It must be possible to create new RIF dialects which extend existing dialects (thus providing backward compatibility) and are handled gracefully by systems which support existing dialects (thus providing forward compatibility).'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-translators&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Translators ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-standard-components&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Standard components ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-coverage&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Rule language coverage ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''Because of the great diversity of rule languages, no single interchange language is likely to be able to bridge between all. Instead, RIF provides dialects each of which is targeted at a cluster of similar rule languages. RIF must allow intra-dialect interoperation, i.e. interoperability between semantically similar rule languages (via interchange of RIF rules) within one dialect, and should support inter-dialect interoperation, i.e. interoperation between dialects with maximum overlap.''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-compliance-model&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Compliance model ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''The RIF specifications must provide clear conformance criteria that define what is or is not a conformant RIF implementation.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-default-behavior&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Default behavior ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-different-semantics&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Different semantics ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must cover rule languages having different semantics.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-dialects&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Limited number of dialects ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must have a standard core, and a limited number of standard dialects based upon that core.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-comments&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Embedded comments ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must be able to pass comments.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-metadata&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Embedded metadata ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must support metadata such as author and rule name.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-owl-data&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== OWL data ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must cover OWL knowledge bases as data where compatible with RIF semantics.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-rdf-data&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== RDF data ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must cover RDF triples as data where compatible with RIF semantics.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-dialect-identification&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Dialect Identification ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''The semantics of a RIF document must be uniquely determined by the content of the document, without out-of-band data.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-xml-syntax&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== XML syntax ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must have an XML syntax as its primary normative syntax.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-xml-types&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== XML types ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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 [http://www.w3.org/2005/rules/wg/charter#datatype0 Datatype support]. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-merge&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Merge Rule Sets ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must support the ability to merge rule sets.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-rulesets&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Identify Rule Sets ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must support the identification of rule sets.''  &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-xml-data&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== XML data ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF should be able to accept XML elements as data.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-rif-text&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Internationalized text ===&lt;br /&gt;
&lt;br /&gt;
''RIF must support internationalized text — that is, text that additionally conveys information in terms of a language tag.''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Use Cases ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
A use case for RIF consists of a description of a problem together with a solution that either uses an existing RIF dialect or requires the specification of a new RIF dialect.&lt;br /&gt;
&lt;br /&gt;
The set of use cases is intended to do the following:&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;motivate the need for a RIF in a broad range of application domains and industrial sectors;&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;provide scenarios that motivate the design of RIF and explain the benefits of a RIF in such scenarios;&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;guide users to RIF's specified dialects; and&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;motivate the working group's set of requirements for a RIF.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The set of use cases were developed over several years.&lt;br /&gt;
Nearly [http://www.w3.org/2005/rules/wg/wiki/Use_Cases fifty use cases] documenting the need for a RIF were originally submitted by the working group members. These were grouped into  general categories and then synthesized as much as possible. The goal was to come up with a relatively small set of use cases that would cover a broad range of possible requirements. In addition,  it was desired that the use cases refer to popular application domains and industrial sectors. For every use case we will briefly discuss the coverage of the use case by the existing three RIF dialects (Core, BLD, and PRD). &lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- do not skip a line &lt;br /&gt;
&amp;lt;html&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px dotted black; padding:0.5em; margin: 1em; &amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;The button below can be used to show or hide the RIF examples.&amp;lt;/p&amp;gt;&amp;lt;form action=&amp;quot;&amp;quot;&amp;gt;&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;input id=&amp;quot;hide-rif&amp;quot; type=&amp;quot;button&amp;quot; value=&amp;quot;Hide Examples&amp;quot; style=&amp;quot;display:none&amp;quot;&lt;br /&gt;
  onclick=&amp;quot;display('rif', 'none');&lt;br /&gt;
           set_display_by_id('hide-rif', 'none'); &lt;br /&gt;
           set_display_by_id('show-rif', '');&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;input id=&amp;quot;show-rif&amp;quot; type=&amp;quot;button&amp;quot; value=&amp;quot;Show Examples&amp;quot; &lt;br /&gt;
  onclick=&amp;quot;display('rif','');&lt;br /&gt;
     set_display_by_id('hide-rif', ''); &lt;br /&gt;
     set_display_by_id('show-rif', 'none');&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&amp;lt;/form&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;/html&amp;gt;--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Negotiating eBusiness Contracts Across Rule Platforms ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This use case illustrates a fundamental use of RIF: to supply 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, and in particular without concern that a business partner does not have the same vendor technology. It also illustrates the fact that RIF can be used to foster collaborative work. Each developer and stakeholder can make a contribution to the joint effort without being forced to adopt the tools or platforms of the other contributors. &lt;br /&gt;
&lt;br /&gt;
John is negotiating an electronic business contract regarding the supply of various types of items that Jane's company is manufacturing. Jane and John interchange the contract-related data and rules involved in the negotiation 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 goods and services involved - in this case an XML schema and appropriate test XML documents are interchanged with their rules. Since John and Jane run applications based on different vendors' rule engines and rule languages, they interchange the rules using RIF; both vendors used can interpret the XML schema and data, and produce the results as an amended XML document. John's company defines its purchase orders in terms of an XML description of goods, packaging, delivery location and date with delivery and payment rules. A rule proposed by John might be the following: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If an item is perishable and it is delivered to John more than 10 days after the scheduled delivery date then the item will be rejected by him.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
This rule set can be adequately represented in RIF Core either using (ordered) relations as e.g. in standard Logic Programming, unordered relations using named arguments, or in a more object-oriented encoding using frames.&amp;lt;br /&amp;gt;   &lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
''Ordered representation in RIF Core presentation syntax using relations:'' &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&lt;br /&gt;
 &lt;br /&gt;
  Group &lt;br /&gt;
  (&lt;br /&gt;
      Forall ?item ?deliverydate ?scheduledate ?diffdays (&lt;br /&gt;
      ex:reject(&amp;quot;John&amp;quot; ?item) :-&lt;br /&gt;
          ex:perishable(?item)&lt;br /&gt;
          ex:delivered(?item ?deliverydate &amp;quot;John&amp;quot;)&lt;br /&gt;
          ex:scheduled(?item ?scheduledate)&lt;br /&gt;
          ?diffdays = External(func:days-from-duration(&lt;br /&gt;
                                  External(func:subtract-dateTimes(?deliverydate ?scheduledate))  &lt;br /&gt;
                               )) &lt;br /&gt;
          External(pred:numeric-greater-than(?diffdays  10)) &lt;br /&gt;
      ) &lt;br /&gt;
   ) &lt;br /&gt;
) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
Note, the nesting of external built-in functions and operations and the assignment/binding of (intermediate) result (sets) from functions to variables by equality in this example.&amp;lt;br /&amp;gt;    &lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
''Unordered representation in RIF Core presentation syntax using namened arguments:'' &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#) &lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#) &lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#) &lt;br /&gt;
 &lt;br /&gt;
  Group &lt;br /&gt;
  ( &lt;br /&gt;
      Forall ?item ?deliverydate ?scheduledate ?diffdays ( &lt;br /&gt;
      ex:reject(ex:ware -&amp;gt; ?item ex:receiver -&amp;gt; &amp;quot;John&amp;quot;) :- &lt;br /&gt;
         ex:perishable(ex:ware -&amp;gt; ?item) &lt;br /&gt;
         ex:delivered(ex:ware -&amp;gt; ?item  ex:datetime -&amp;gt; ?deliverydate  ex:receiver -&amp;gt; &amp;quot;John&amp;quot;) &lt;br /&gt;
         ex:scheduled(ex:datetime -&amp;gt; ?scheduledate  ex:ware -&amp;gt; ?item) &lt;br /&gt;
         ?diffdays = External(func:days-from-duration( &lt;br /&gt;
                                  External(func:subtract-dateTimes(?deliverydate ?scheduledate))  &lt;br /&gt;
                               )) &lt;br /&gt;
          External(pred:numeric-greater-than(?diffdays  10)) &lt;br /&gt;
      ) &lt;br /&gt;
   ) &lt;br /&gt;
) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
Note, the arbitrarily unordered named argument arguments of the user-defined relations, in contrast to external built-in functions and operations, which must have a predefined order. &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
''Object-Oriented Representation in RIF Core presentation syntax using frames:'' &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt;  Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#) &lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#) &lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#) &lt;br /&gt;
 &lt;br /&gt;
  Group &lt;br /&gt;
  ( &lt;br /&gt;
      Forall ?item ?deliverydate ?scheduledate ?diffdays ( &lt;br /&gt;
      ?item[ex:status -&amp;gt; &amp;quot;rejected&amp;quot;] :- &lt;br /&gt;
         ?item[ex:perishable -&amp;gt; true]  &lt;br /&gt;
         ?item[ex:deliveredOn -&amp;gt; ?deliverydate ex:delivered -&amp;gt; &amp;quot;John&amp;quot;]  &lt;br /&gt;
         ?item[ex:scheduledOn -&amp;gt; ?scheduledate ex:delivered -&amp;gt; &amp;quot;John&amp;quot;]  &lt;br /&gt;
         External(pred:numeric-greater-than(         &lt;br /&gt;
             External(func:days-from-duration( &lt;br /&gt;
                                  External(func:subtract-dateTimes(?deliverydate ?scheduledate))  &lt;br /&gt;
                      )) &lt;br /&gt;
             10 &lt;br /&gt;
         ) &lt;br /&gt;
      ) &lt;br /&gt;
   ) &lt;br /&gt;
) &lt;br /&gt;
&amp;lt;/code&amp;gt;  &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Jane replies with some suggested rule changes: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
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 then a discount of 18.7% will be applied to the delivered item.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
''Representation in RIF Core presentation syntax using positional relations:'' &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#) &lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#) &lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#) &lt;br /&gt;
 &lt;br /&gt;
  Group &lt;br /&gt;
  ( &lt;br /&gt;
     Forall ?item ?deliverydate ?scheduledate ?diffdays ( &lt;br /&gt;
     ex:discount(&amp;quot;John&amp;quot; ?item 18.7 ) :- &lt;br /&gt;
           ex:perishable(?item) &lt;br /&gt;
           ex:delivered(?item ?deliverydate &amp;quot;John&amp;quot;) &lt;br /&gt;
           ex:scheduled(?item ?scheduledate) &lt;br /&gt;
           ?diffdays = External(func:days-from-duration( &lt;br /&gt;
                                  External(func:subtract-dateTimes(?deliverydate ?scheduledate))  &lt;br /&gt;
                               )) &lt;br /&gt;
           External(pred:numeric-greater-than(?diffdays  7)) &lt;br /&gt;
           External(pred:numeric-less-than(?diffdays  14)) &lt;br /&gt;
     ) &lt;br /&gt;
   ) &lt;br /&gt;
) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binding of the intermeditate results to the variable &amp;quot;?diffdays&amp;quot; avoids repetition, as it used twice in the subsequent rule conditions. As demonstrated in the previous examples, similar representations for this rule can be given using slots or frames and as a production rule which asserts the conclusion as a new fact. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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 order and determine contract compliance. &lt;br /&gt;
&lt;br /&gt;
Future requests for the supply of items by John's company are defined on their purchasing web site, as the appropriate XML schema and a RIF ruleset (or rulesets). This allows Jane's company and its competitors to respond electronically with XML cost sheets. Suppliers respond with multiple cost sheets with different variations on the RIF rules proposed by John's company, allowing John's company to review the alternative rules with their associated costs to determine whether they, as a business, would benefit by relaxing or adding new rules as proposed by suppliers. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by: RIF Core, RIF BLD, RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
The rules of this use case can be adequately represented in RIF Core (and BLD and PRD) either using (ordered) relations, as e.g. in standard Logic Programming, unordered relations, using named arguments, or in a more object-oriented encoding using frames. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Negotiating eCommerce Transactions Through Disclosure of Buyer and Seller Policies and Preferences ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This use case concerns the ability of parties involved in formal transactions or procedures, e.g., credit card authorization of a purchase, access of private medical records, etc., to express and protect their interests within a policy-governed framework. The goal is to formally encode the preferences, priorities, responses, etc., of the parties in such a way that the overall policy can work as intended while providing opportunity for automatic negotiation of terms when allowed by the policy. Utilization of RIF in this use case would extend the scope of this technology, affording a higher degree of interoperability, as well as enabling re-use and sharing of preferences, etc., through interchange. The detailed scenario below shows how this would work. &lt;br /&gt;
&lt;br /&gt;
Alice wants to buy a device at an online site called &amp;quot;eShop.&amp;quot; Alice employs software called &amp;quot;Emptor&amp;quot; that functions as automated negotiating agent for buyers. eShop employs software called &amp;quot;Venditor&amp;quot; as automated negotiating agent for sellers. &lt;br /&gt;
&lt;br /&gt;
Alice's and eShop's policies describe who they trust and for what purposes. The negotiation is based on the policies, 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. &lt;br /&gt;
&lt;br /&gt;
Policies are themselves subject to access control. Thus, rule interchange is necessarily done during negotiation and (in general) depends on the current level of trust that the systems have on each other. Since Emptor and Venditor might use different rule languages and/or engines for evaluating (own and imported) rules, a (standard) rule interchange format (RIF) needs to be employed for enabling the rule interchange between the two systems. &lt;br /&gt;
&lt;br /&gt;
When Alice clicks on a &amp;quot;buy it&amp;quot; button at the 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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
In order to grant access a buyer must provide valid credit card information together with delivery information (address, postal code, city, and country).&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF Core presentation syntax using relations and frames in combination: &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&lt;br /&gt;
&lt;br /&gt;
  Group&lt;br /&gt;
  (&lt;br /&gt;
    Forall ?buyer ?creditCard ?address (&lt;br /&gt;
    ex:permit_access(&amp;quot;eShop&amp;quot; ?buyer) :-&lt;br /&gt;
      ex:provide(&amp;quot;eShop&amp;quot; ?buyer)&lt;br /&gt;
      ?buyer[ex:card -&amp;gt; ?creditCard ex:deliveryAddr -&amp;gt; ?address]&lt;br /&gt;
      ex:valid_payment_method(?creditCard)&lt;br /&gt;
      ex:valid_delivery_address(?address)&lt;br /&gt;
    )   &lt;br /&gt;
 &lt;br /&gt;
    Forall ?type ?person ?first ?last ?number ?code ?date ?month ?year (&lt;br /&gt;
    ex:valid_payment_method(?card)   :-&lt;br /&gt;
        ?card[type -&amp;gt; ?type&lt;br /&gt;
              ex:holder -&amp;gt; ?person  &lt;br /&gt;
              ex:number -&amp;gt; ?number &lt;br /&gt;
              ex:code -&amp;gt; ?code&lt;br /&gt;
              ex:expiry -&amp;gt; ?date]&lt;br /&gt;
        ?person[ex:lastname -&amp;gt; ?last ex:firstname -&amp;gt; ?first]&lt;br /&gt;
        ?date[ex:month -&amp;gt; ?month ex:year -&amp;gt; ?year]&lt;br /&gt;
        ex:credential(?type ?person ?number ?code ?date)&lt;br /&gt;
    ) &lt;br /&gt;
 &lt;br /&gt;
    Forall ?address ?last ?first ?street ?strname ?number ?code ?city ?country (&lt;br /&gt;
    ex:valid_delivery_address(?address)   :-&lt;br /&gt;
       ?address[ex:name -&amp;gt; ?person ex:street -&amp;gt; ?street ex:postal_code -&amp;gt; ?code ex:city -&amp;gt; ?city ex:country -&amp;gt; ?country ]&lt;br /&gt;
       ?person[ex:lastname -&amp;gt; ?last ex:firstname -&amp;gt; ?first] &lt;br /&gt;
       ?street[name -&amp;gt; ?strname ex:number -&amp;gt; ?number] &lt;br /&gt;
       ex:declaration(?person ?street ?number ?code ?city ?country)&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
  )&lt;br /&gt;
)&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that in this example relational representation is used in combination with frame representation. Such mixing of representation styles is supported by RIF. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Rules express compactly possible ways in which a resource can be accessed; by exchanging them negotiations are shorter and privacy protection is improved. In the 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 and required information to disclose. &lt;br /&gt;
&lt;br /&gt;
For determining whether Venditor's request for information is consistent with Alice's policy, Emptor takes its rules into account, which state for example: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
Disclose Alice's credit card information only to online shops belonging to the Better Business Bureau.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF Core presentation syntax: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&lt;br /&gt;
&lt;br /&gt;
  Group&lt;br /&gt;
  (&lt;br /&gt;
    Forall ?Shop ?card ?Credential ?Buyer  (&lt;br /&gt;
      ex:provide(?Shop ?Buyer )  :-  &lt;br /&gt;
         ?Buyer[ex:card -&amp;gt; ?creditCard ex:deliveryAddr -&amp;gt; ?address]&lt;br /&gt;
         ex:belongs_to(?Shop  &amp;quot;Better Business Bureau&amp;quot;) &lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
    Forall ?deliveryAddr ?card ?Date ?Person ?Street  (&lt;br /&gt;
      ex:Alice[ex:card -&amp;gt; ?card ex:deliveryAddr -&amp;gt; ?deliveryAddr] :-&lt;br /&gt;
                  ?Date = ex:Date[ex:month -&amp;gt; 12 ex:year -&amp;gt; 2012]&lt;br /&gt;
                  ?Person = ex:Person[ex:lastname -&amp;gt; &amp;quot;Sure&amp;quot; ex:firstname -&amp;gt; &amp;quot;Alice&amp;quot;]&lt;br /&gt;
                  ?Street = ex:Street[name -&amp;gt; &amp;quot;North Street&amp;quot; number -&amp;gt; 111]&lt;br /&gt;
                  ?card= ex:Card[ ex:type -&amp;gt; &amp;quot;Visa&amp;quot;&lt;br /&gt;
                                  ex:holder -&amp;gt;  ?Person &lt;br /&gt;
                                  ex:number -&amp;gt; &amp;quot;123456789&amp;quot; &lt;br /&gt;
                                  ex:code -&amp;gt; &amp;quot;123&amp;quot;&lt;br /&gt;
                                  ex:expiry -&amp;gt; ?Date &lt;br /&gt;
                                 ]&lt;br /&gt;
                  ?deliveryAddr = ex:DeliveryAddress[ ex:name -&amp;gt; ?Person &lt;br /&gt;
                                                      ex:street -&amp;gt; ?Street&lt;br /&gt;
                                                      ex:postal_code -&amp;gt; &amp;quot;NE3456&amp;quot; &lt;br /&gt;
                                                      ex:city -&amp;gt; &amp;quot;New York&amp;quot; &lt;br /&gt;
                                                      ex:country -&amp;gt; &amp;quot;USA&amp;quot; &lt;br /&gt;
                                                    ]&lt;br /&gt;
     )&lt;br /&gt;
&lt;br /&gt;
   )&lt;br /&gt;
)&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
By disclosing (interchanging) the above given rule, Emptor asks Venditor to provide credentials saying that it belongs to the Better Business Bureau, Alice's most trusted source of information on online shops. eShop has such a credential and its policy contains a rule stating to release it to any potential purchaser. Hence, Venditor passes the credential to Emptor. Emptor is now ready to disclose Alice's credit card information to Venditor but it still must check whether disclosing all the information does not break Alice's denial constraints. Alice has stated two constraints stating: &lt;br /&gt;
 &lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
For anonymity reasons, never provide both her birth date and postal code.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
The current RIF dialects do not specify explicit constructs for integrity constraints. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For this purchase, Alice birthdate is no issue. Thus, Alice's constraints are respected. Emptor therefore provides Alice's credit card information to Venditor. &lt;br /&gt;
&lt;br /&gt;
Companies that provide software such as Venditor and Emptor would make use of RIF in a number of ways. The rules 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 work together in real-time. When these two systems need to exchange policy or preference information of their respective clients they would use RIF to enable the interchange in real-time. When Venditor sends its initial policy information to Emptor it uses RIF. Emptor takes that policy and translates it from RIF to its internal representation in order to determine what it needs to do. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Not supported by the current RIF dialects (Core, BLD, PRD) '''&lt;br /&gt;
&lt;br /&gt;
Current RIF dialects  do not specify explicit constructs for integrity constraints; thus, this use case is not adequately supported by any of these dialects. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Collaborative Policy Development for Dynamic Spectrum Access ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This use case demonstrates how RIF leads to increased flexibility in matching the goals of end-users of a service/device, with the goals of providers and regulators of such services/devices. RIF can do that because it enables deployment of third party systems that can generate various suitable interpretations and/or translations of the sanctioned rules governing a service/device. &lt;br /&gt;
&lt;br /&gt;
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 a device to absorb the rules defining the policies of a region, or the operational protocols required to dynamically access available spectrum, is contingent upon those rules being in a form that the device can use, as well as their being tailored to work with devices in the same class having different capabilities. &lt;br /&gt;
&lt;br /&gt;
In this use-case we suppose a region adopts a policy that allows certain wireless devices to opportunistically use frequency bands that are normally reserved for certain high-priority users. ([http://europa.eu.int/eur-lex/lex/LexUriServ/site/en/oj/2005/l_187/l_18720050719en00220024.pdf The decision] by the European Union to allow &amp;quot;Dynamic Frequency Selection&amp;quot; (DFS) use of the 5 GHz frequency band by wireless systems, a band intermittently used by military and weather radar, is a recent example.) &lt;br /&gt;
&lt;br /&gt;
Suppose the policy states: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
A wireless device can transmit on a 5 GHz band if no priority user is currently using that band.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
&amp;lt;!-- Representation in RIF Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt; &lt;br /&gt;
     Forall ?device ?band ?user (&amp;lt;br /&amp;gt;&lt;br /&gt;
     ex:transmit(?device ?band 5) :- &amp;lt;br /&amp;gt;&lt;br /&gt;
         not(ex:used(?user ?band))&amp;lt;br /&amp;gt;&lt;br /&gt;
      )&amp;lt;br /&amp;gt;&lt;br /&gt;
   )&amp;lt;br /&amp;gt;&lt;br /&gt;
)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt; --&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;Note, since default negation (not) such as negation as failure is not supported by RIF BLD there is no adequate way to represent that &amp;quot;no priority user is currently using the band&amp;quot;. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
How does a device know that no priority user is currently using a band it wants to use? The answer will depend on the specific capabilities of the device. One type of device may answer this question by sensing the amount of energy it is receiving on that band. That is, it might employ the rule: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If no energy is detected on a desired band then assume no other device is using the band.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt;&lt;br /&gt;
      Forall ?device ?band ?level  (&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:used(?device ?band) :- &amp;lt;br /&amp;gt;&lt;br /&gt;
                   ex:detect(ex:energy(?level ?band))&amp;lt;br /&amp;gt;&lt;br /&gt;
                   External(pred:numeric-greater-than(?level  0))&amp;lt;br /&amp;gt;&lt;br /&gt;
      )&amp;lt;br /&amp;gt;&lt;br /&gt;
   )&amp;lt;br /&amp;gt;&lt;br /&gt;
)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;Note, the engergy detection function would require an external call for sensing  the level of energy. Such procedural attachments cannot be specified in BLD. Reaction rules provide event detection capabilities. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A second type of device, may get information from a control channel that lets it know whether the desired band is being used by a priority user. That is, it might employ the rule: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If no control signal indicating use of a desired band by a priority user is detected then assume the band is available.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt;&lt;br /&gt;
      Forall ?device ?band ?user  (&amp;lt;br /&amp;gt;&lt;br /&gt;
       ex:used(?device ?band) :- &amp;lt;br /&amp;gt;&lt;br /&gt;
                   ex:detect(ex:signal(?user ?band))&amp;lt;br /&amp;gt;&lt;br /&gt;
                   ex:priority(?user,&amp;quot;high&amp;quot;).&amp;lt;br /&amp;gt;&lt;br /&gt;
      )&amp;lt;br /&amp;gt;&lt;br /&gt;
   )&amp;lt;br /&amp;gt;&lt;br /&gt;
)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
So each type of device will need to employ different &amp;quot;interpretations&amp;quot; or &amp;quot;operational definitions&amp;quot; of the policy in question. &lt;br /&gt;
&lt;br /&gt;
Now assume that there are 10 manufacturers of these 2 different types of wireless devices. Suppose that each of these manufacturers uses a distinct rule-based platform in designing its devices. Each manufacturer needs to write 2 interpretations of the policy (for each of the two types of device). That means that 20 different versions of the policy must be written, tested and maintained. &lt;br /&gt;
&lt;br /&gt;
Enter RIF. The 10 manufacturers form a consortium. This is a third-party group that is responsible for translating regional policies into RIF. When it does so, however, it provides different versions corresponding to the possible interpretations (operational definitions) of the policy. So in this case, 2 RIF versions of the DFS policy are provided for the 2 types of device mentioned above. Each of these RIF specifications can be automatically translated into the appropriate rule-platform provided a RIF-Compiler for the target device architecture exists. Clearly it will be in the interest of each device manufacturer to develop such compilers. That is because the manufacturer only needs to develop such a compiler ''once'' for every architecture it owns. Contrast that investment with having to produce, test, and maintain different versions of various policies over the lifetime of a product. &lt;br /&gt;
&lt;br /&gt;
This arrangement also allows the overall process to be organized in a fashion that maintains the natural division of labor in the corresponding division of artifacts produced by that labor: the policy and its various interpretations are written and maintained in platform-independent artifacts (RIF); knowledge about how to translate from 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. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Partly supported by: RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
The energy detection function specified in this use case would require an external call to a device that would sense  the level of energy. Such procedural attachments cannot be specified in the current RIF dialects. Reaction rules support (complex) event detection capabilities on, e.g., event streams over sensor data. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This use case is not supported at all by RIF BLD, and by extension, by RIF Core. These dialects do not support negation, and&lt;br /&gt;
the use case makes explicit mention of negation, e.g. for representing that &amp;quot;no priority user is currently using the band.&amp;quot;&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Access to Business Rules of Supply Chain Partners ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If inspector believes vehicle is repairable then process as repair otherwise process as total loss.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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). &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
How such a unified 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, RIF permits a unified dynamic view of the business rule logic no matter what the original form of the rules. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Not supported, in a straightforward manner, by the current RIF dialects'''&lt;br /&gt;
&lt;br /&gt;
BLD and PRD do not support modal operators or predicates on quoted sentences; therefore standard representations of knowledge, belief, and/or uncertainty cannot be specified in BLD and PRD. Even without such constructs, it can be possible to represent knowledge or belief using the semantics of possible worlds &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#moore|Moore1980]]]. That is, one can get the effect of saying that an agent A believes proposition P by saying that P holds in all words that are belief-accessible to P. For example, to get the effect of saying &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;Believe(john,overCreditLimit(bill,t))&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
one says instead&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
holds(overCreditLimit(bill),t1) :- beliefAccessible(john,t,t1)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The translation between sentences involve operators such as Know and Believe and sentences that make direct use of possible worlds relies on the possible-worlds semantics, which posits properties on the knowledge-accessibility or belief-accessibility relation. These relations correspond to axioms on the Know and Believe operators.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Such a strategy could work, to a certain extent, in RIF PRD, but would not work in RIF BLD. This is because expressing the standard axioms on belief or knowledge would require the use of negation, which is not supported by BLD.&lt;br /&gt;
&lt;br /&gt;
For both PRD and BLD there is an additional consideration, which is that the notion of reification is in general not supported by the dialects of RIF.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Managing Inter-Organizational Business Policies and Practices ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
* An organization may buy rule sets from expert sources &lt;br /&gt;
* An organization may use rule sets from shared interest groups such as trade associations &lt;br /&gt;
* A component of a distributed organization may acquire 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. &lt;br /&gt;
&lt;br /&gt;
The following scenario examines these different methods of acquisition and the various types of integration and management issues that may arise. &lt;br /&gt;
&lt;br /&gt;
''This scenario uses the (fictitious) car rental company, EU-Rent, used as the case study in the [http://www.omg.org/spec/SBVR/1.0/ Semantics of Business Vocabulary and Business Rules Specification]. The EU legislation discussed is also fictitious, as are the consulting companies CarWise and AutoLaw.''&lt;br /&gt;
&lt;br /&gt;
EU-Rent's corporate HQ deals with CarWise, a consulting company with expertise in managing fleets of vehicles. One service CarWise offers to its clients is negotiating with EU regulators to clarify regulations. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
* A business policy, stating that every car rental must be insured for damages to third parties.&lt;br /&gt;
* 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.&lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
Each tax schedule must have electronic signatures from two EU-Rent employees who are at least at the level of manager.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
* The rule set for car rental insurance (from CarWise), including the basic policy and the supporting rule set.&lt;br /&gt;
* The rule set for electronic compliance documentation (also from CarWise).&lt;br /&gt;
* Its own rule set for building insurance into the basic rental cost.&lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
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.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
Insurance policies that provide separate third-party coverage must not be renewed.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
EU-Rent HQ is also concerned about meeting deadlines for electronic filing. It introduces a new rule that it distributes to operating companies: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
Each electronic compliance document must have its required electronic signatures 48 hours before its filing deadline.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Partially supported by RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
The business rules in this use case express norms which requires the representation of deontic operators for obligations and permissions. Deontic operators are generally represented by modal operators, as in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-Horty-deontic-logic|Horty2001]]]. As was discussed above, for Know and Belief, it is not possible to express modal operators directly within RIF dialects. However, one can use the technique discussed above, of reasoning directly within possible worlds. This is possible within PRD though not within BLD or Core. &lt;br /&gt;
&lt;br /&gt;
Moreover, in a meta programming approach it is possible to express deontic reasoning rules with RIF PRD.  Using this approach, too, one would not be able to use BLD or Core, since some business rules express negated deontic norms.&lt;br /&gt;
&lt;br /&gt;
=== Ruleset Integration for Medical Decision Support ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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 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. &lt;br /&gt;
&lt;br /&gt;
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 [http://www.snomed.org 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. &lt;br /&gt;
&lt;br /&gt;
The following scenario illustrates how rule-interchange would be used in various medical decision support systems to support the following functionalities: &lt;br /&gt;
&lt;br /&gt;
* Improving situation assessment, e.g., determining when a patient needs to be put on medication, or have his medication switched. &lt;br /&gt;
* Prescribing a course of action, e.g., determining which drug is best for a patient in a particular circumstance. &lt;br /&gt;
* Improving event planning, e.g., determining whether a patient can be scheduled for a procedure given the medication that he is currently taking. &lt;br /&gt;
&lt;br /&gt;
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 &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt; system to help him decide when to switch to medications and which drugs to prescribe. The &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt; 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 RIF. Here are two specific examples of such synergistic effects. &lt;br /&gt;
&lt;br /&gt;
''This scenario discusses the fictitious expert systems &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt; 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.'' &lt;br /&gt;
&lt;br /&gt;
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 &amp;lt;tt&amp;gt;HbA1c&amp;lt;/tt&amp;gt; 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 &amp;lt;tt&amp;gt;HbA1c&amp;lt;/tt&amp;gt; level. The following rule from the ''laboratory knowledge base'' suggests that Bob's treatment at that time was not effective: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If a Type II diabetes patient's current level of HbA1c is high, then the patient's current treatment is considered to be ineffective.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD  Presentation Syntax using relations and an event calculus axiomatization:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt;&lt;br /&gt;
    Forall ?Patient ?Treatment ?Level ?T (&amp;lt;br /&amp;gt;&lt;br /&gt;
    ex:holdsAt(ex:ineffective(?Patient ?Treatment) ?T) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:holdsAt(ex:hasDisease(?Patient &amp;quot;diabetesTypeII&amp;quot;) ?T)&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:holdsAt(ex:elevated(levelOf(?Patient &amp;quot;hbA1c&amp;quot; ?Level)) ?T)&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:holdsAt(ex:treatmentPlan(?Treatment ?Patient) ?T)&amp;lt;br /&amp;gt;&lt;br /&gt;
      )&amp;lt;br /&amp;gt;&lt;br /&gt;
   )&amp;lt;br /&amp;gt;&lt;br /&gt;
)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;Note, the example requires the formalization of changeable states which can be represented by an event calculus axiomatization. [[#event-calculus|KS86]]] The EC axioms can then be represented using RIF BLD.   &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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 &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt; 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. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
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.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Based on the recommendation from &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt;, Dr. Rosen switched Bob's prescription to Glucophage and Avandia (rosiglitazone, one of the thiazolidinediones). &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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.). &lt;br /&gt;
&lt;br /&gt;
MEDIC uses a variety of sources in its reasoning, including: &lt;br /&gt;
&lt;br /&gt;
* the pharmaceutical knowledge base, described above &lt;br /&gt;
* the patient databases, which gives the patient record, including the medications a patient is currently taking &lt;br /&gt;
* the hospital medical event protocol knowledge base, which details the protocol used for different medical procedures &lt;br /&gt;
&lt;br /&gt;
In this case, MEDIC uses all three sources, and pulls up the following information: &lt;br /&gt;
&lt;br /&gt;
* Metformin is contraindicated with contrast dye. &lt;br /&gt;
* Metformin is the generic form of Glucophage. &lt;br /&gt;
* Bob is taking Glucophage. &lt;br /&gt;
* The contrast MRI requires as one of its steps injecting the patient with contrast dye. &lt;br /&gt;
&lt;br /&gt;
MEDIC therefore determines that Bob should not be taking the contrast MRI at this time. &lt;br /&gt;
&lt;br /&gt;
For MEDIC to work, the rules from these different sources must be mapped to a unified interchange format. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
The use case requires the formalization of changeable states (fluents) which can be represented by e.g. an event calculus axiomatization &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#event-calculus|KS86]]]. However, to formulate the classical event calculus as a set of Horn clause rules, so that it could be run as a Prolog program, negation as failure is needed, which is not supported by RIF BLD. &lt;br /&gt;
The use case can be represented in RIF PRD which supports changeable states (modifications) and assertions and retractions of knowledge.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Interchanging Rule Extensions to OWL ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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 provide a richer language for describing dependencies between properties (binary predicates), and may also support higher-arity predicates. &lt;br /&gt;
&lt;br /&gt;
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 labeling 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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If MAE X is bounded by Z and MAE Y is also bounded by Z then X is connected to Y.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF Core, RIF BLD and RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
The use case uses RIF SWC to combine RIF Rules with OWL ontologies.&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Vocabulary Mapping for Data Integration ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
* a report on application services and associated servers, databases and networks (from the IT department) &lt;br /&gt;
* a maintenance contracts database (from the finance department) &lt;br /&gt;
* a registry indicating which business processes use which IT services (from the business planning group) &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
First, Vlad creates simple mapping rules to create a uniform, simplified view of the data in terms of a small number of concepts -- Server, Business&amp;lt;tt&amp;gt;&amp;lt;/tt&amp;gt;Process and Dependency. This involves rules such as: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 If x is a ComputeNode in Rack r&lt;br /&gt;
    and Rack r is in Cage c&lt;br /&gt;
    and mc is a MaintenanceContract for Cage c&lt;br /&gt;
       then x is a Server with MaintenanceContract mc&lt;br /&gt;
 &lt;br /&gt;
 If x is a ComputeNode with a NetworkInterface with Port p&lt;br /&gt;
    and app is an Application running on Port p&lt;br /&gt;
       then x is a Server that hosts app&lt;br /&gt;
 &lt;br /&gt;
 If bp is a BusinessProcess that uses Application app&lt;br /&gt;
       then bp has a Dependency on app&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Forall ?X ?MC ?R ?C(&lt;br /&gt;
  ?X[rdf:type-&amp;gt;ex:Server ex:maintenanceContract-&amp;gt;?MC] :- And(&lt;br /&gt;
    ?X[rdf:type-&amp;gt;ex:ComputeNode ex:location-&amp;gt;?R] ?R#ex:Rack &lt;br /&gt;
    ?R[ex:location-&amp;gt;?C] ?C#ex:Cage&lt;br /&gt;
    ?C[ex:maintenanceContract-&amp;gt;?MC] ?MC#ex:MaintenanceContract )) &lt;br /&gt;
&lt;br /&gt;
  Forall ?X ?Ni ?P ?App (&lt;br /&gt;
   ?X[rdf:type-&amp;gt;ex:Server ex:hosts-&amp;gt;?App] :- And( &lt;br /&gt;
     ?X[rdf:type-&amp;gt;ex:ComputeNode ex:networkInterface-&amp;gt;?Ni] &lt;br /&gt;
     ?Ni[ex:port-&amp;gt;?P]  ?P#ex:Port&lt;br /&gt;
     ?App[rdf:type-&amp;gt;ex:Application ex:onPort-&amp;gt;?P])) &lt;br /&gt;
&lt;br /&gt;
  Forall ?App ?BP ( &lt;br /&gt;
   ?BP[ex:dependsOn-&amp;gt;?App] :- &lt;br /&gt;
     ?BP[rdf:type-&amp;gt;ex:BusinessProcess ex:processUses-&amp;gt;?App] )) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt; &lt;br /&gt;
 &lt;br /&gt;
He then creates rules that combine the data across his now simplified data sources, e.g. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 If bp is a BusinessProcess that has a Dependency on Application app&lt;br /&gt;
   and x is a Server with MaintenanceContract mc that hosts Application app&lt;br /&gt;
      then bp has a Dependency on mc&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt;   Forall ?App ?BP ?App ?MC( &lt;br /&gt;
   ?BP[ex:dependsOn-&amp;gt;?MC] :- &amp;lt;&lt;br /&gt;
     ?BP[rdf:type-&amp;gt;ex:BusinessProcess ex:dependsOn-&amp;gt;?App] ?App#ex:Application &lt;br /&gt;
     ?X[rdf:type-&amp;gt;ex:Server ex:hosts-&amp;gt;?App ex:maintenanceContract-&amp;gt;?MC] )) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF BLD and RID PRD'''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== BPEL Orchestration of Rule-Based Web Services ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
The credit evaluation rules are themselves grouped into three rulesets that are executed sequentially. Rules in the first ruleset apply thresholds to several &amp;quot;red flag&amp;quot; quantities in the credit report, such as: &lt;br /&gt;
&lt;br /&gt;
* number of times a payment was 60 days late &lt;br /&gt;
* debt-to-income ratio &lt;br /&gt;
* number of foreclosures or repossessions &lt;br /&gt;
* number of garnishments &lt;br /&gt;
* number of liens &lt;br /&gt;
* bankruptcy &lt;br /&gt;
&lt;br /&gt;
A red flag above the threshold results in denial of credit. &lt;br /&gt;
&lt;br /&gt;
Rules in the second ruleset increment a credit score variable. For example: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 If applicant owns residence then add 40.&lt;br /&gt;
 If applicant rents then add 30.&lt;br /&gt;
 If applicant has lived at current address 2 to 4 years then add 20.&lt;br /&gt;
 If applicant's income is under 20000 then add 10.&lt;br /&gt;
 If applicant's income is between 40000 and 50000 then add 40.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt;Document(&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(prolog_func &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/2007/rif-prolog-builtin-function#)&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt;&lt;br /&gt;
     ex:score(0)&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
     ex:score(?Applicant ?Score) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:increment(?Applicant)&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
      prolog_func:retract(ex:score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
      prolog_func:assert(ex:score(0)).   &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant) :-   &amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:owns(?Applicant)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:retract(ex:score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 40&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(ex:score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant):-   &amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:rents(?Applicant)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:retract(score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 30&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant):-&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:lives(?Applicant ?Date),&amp;lt;br /&amp;gt;&lt;br /&gt;
   $sysTime(?CurrentDateTime)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?CurrentYear = $fn:year-from-dateTime(?CurrentDateTime)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Year = $fn:year-from-dateTime(?Date)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Diff = ?CurrentYear - ?Year&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Diff &amp;gt; 1&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Diff &amp;lt; 5&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:retract(score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 20&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(ex:score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant):-   &amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:income(?Applicant ?Income)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Income &amp;lt; 20000&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:retract(score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 10&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(ex:score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant):-&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:income(?Applicant ?Income)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Income &amp;lt; 50000&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Income &amp;gt; 40000&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:retract(ex:score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 40&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(ex:score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;A goal-driven solution which makes use of assert and retract (not supported by BLD) to update a global score value, which is stored in a fact.&lt;br /&gt;
&amp;lt;/p&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
This use case requires a goal-driven solution which makes use of assert and retract  to update a global score value. Assert and retract are not supported by BLD; indeed, there is no such similar notion within BLD.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Publishing Rules for Interlinked Metadata ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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 &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;imd.example.org. Besides the ground facts, which can be expressed in RDF, the metadata might also have general rules like the following: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 Every science fiction movie is a movie.&lt;br /&gt;
 Every movie produced before 1930 is black and white.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD (Abridged) Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; ?Movie#ex:Movie :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Movie#ex:ScienceFictionMovie.&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ?Movie#ex:BlackWhiteMovie :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Movie#ex:Movie[ex:date -&amp;gt; ?Date]&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Date &amp;lt; &amp;quot;1930&amp;quot;^^xs:dateTime.&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;  &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
Published rules also allow combining data from different sources to exploit this knowledge. Consider an alternative database of movies published at &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;altmd.example.org. In addition to metadata, it again publishes its own rules: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 All movies listed at &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;altmd.example.org but not listed at &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;imd.example.org are independent movies.&lt;br /&gt;
 All movies with budgets below 5 million USD are low-budget movies.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD (Abridged) Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; ?Movie#ex:IndependentMovie :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    listed(?Movie#ex:Movie,&amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//altmd.example.org&amp;gt;)&amp;lt;br /&amp;gt;&lt;br /&gt;
    not(listed(?Movie#ex:Movie,&amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//imd.example.org&amp;gt;)). 	&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ?Movie#ex:LowBudgetMovie :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Movie#ex:Movie [date -&amp;gt; ?Date, budget -&amp;gt; ?Budget]&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Budget &amp;lt; 5000000^^xs:long.&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;  &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 If Charlie is currently attending a public talk according to &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;charlie.example.org/calender.ical&lt;br /&gt;
     then leave him a voicemail message&lt;br /&gt;
 &lt;br /&gt;
 If Charlie is currently in a meeting according to &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;charlie.example.org/calender.ical&lt;br /&gt;
   and the importance is high&lt;br /&gt;
     then call his cell number&lt;br /&gt;
 &lt;br /&gt;
 If Charlie currently has no appointments according to &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;charlie.example.org/calender.ical&lt;br /&gt;
     then call his office number&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD (Abridged) Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; contactInfo(&amp;quot;Charlie&amp;quot; ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    sysTime(?Time)&amp;lt;br /&amp;gt;&lt;br /&gt;
    attending(&amp;quot;Charlie&amp;quot; &amp;quot;talk&amp;quot; ?Time)&amp;lt;br /&amp;gt;&lt;br /&gt;
    contact(&amp;quot;Charlie&amp;quot; &amp;quot;voicemail&amp;quot; ?ContactInfo).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contactInfo(&amp;quot;Charlie&amp;quot; ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    sysTime(?Time)&amp;lt;br /&amp;gt;&lt;br /&gt;
    attending(&amp;quot;Charlie&amp;quot; &amp;quot;meeting&amp;quot; ?Time)&amp;lt;br /&amp;gt;&lt;br /&gt;
    contact(&amp;quot;Charlie&amp;quot; &amp;quot;cell number&amp;quot; ?ContactInfo).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contactInfo(&amp;quot;Charlie&amp;quot;, ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    sysTime(?Time),&amp;lt;br /&amp;gt;&lt;br /&gt;
    not(attending(&amp;quot;Charlie&amp;quot;,?Event, ?Time)),&amp;lt;br /&amp;gt;&lt;br /&gt;
    contact(&amp;quot;Charlie&amp;quot;, &amp;quot;office number&amp;quot;, ?ContactInfo).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 sysTime(?Time) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    % get the actual system time e.g. via a built-in&amp;lt;br /&amp;gt;&lt;br /&gt;
    % or procedural attachment call to Java or C++.&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Time = External(call(java.util.Calendar().getInstance())).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 attending(&amp;quot;Charlie&amp;quot;,&amp;quot;talk&amp;quot;, ?CurrentTime) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    % getEventData would implement the functionality to dynamically access and query&amp;lt;br /&amp;gt;&lt;br /&gt;
    % &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/calender.ical&amp;lt;br /&amp;gt;&lt;br /&gt;
    getEventData(&amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/calender.ical&amp;gt;,?EventTitle,?Type,?StartDate,?EndDate),&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Type = &amp;quot;talk&amp;quot;,&amp;lt;br /&amp;gt;&lt;br /&gt;
    External(op:dateTime-less-than(?CurrentTime,?EndDate),&amp;lt;br /&amp;gt;&lt;br /&gt;
    External(op:dateTime-greater-than(?CurrentTime,?StartDate).&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;        &lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
 attending(&amp;quot;Charlie&amp;quot;,&amp;quot;meeting&amp;quot;, ?CurrentTime) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    getEventData(&amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/calender.ical&amp;gt;,?EventTitle,?Type,?StartDate,?EndDate),&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Type = &amp;quot;meeting&amp;quot;,&amp;lt;br /&amp;gt;&lt;br /&gt;
    External(op:dateTime-less-than(?CurrentTime,?EndDate),&amp;lt;br /&amp;gt;&lt;br /&gt;
    External(op:dateTime-greater-than(?CurrentTime,?StartDate).&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;       &lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contact(&amp;quot;Charlie&amp;quot;, &amp;quot;voicemail&amp;quot;, ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    % retrieve the Voice mail number, e.g. from&amp;lt;br /&amp;gt;&lt;br /&gt;
    % Charlie's vCard, &amp;lt;br /&amp;gt;&lt;br /&gt;
    % e.g. xmlns:vCard = &amp;quot;&amp;lt;nowiki&amp;gt;http://www.w3.org/2001/vcard-rdf/3.0#&amp;quot;&amp;lt;/nowiki&amp;gt;&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard:FN&amp;gt; -&amp;gt; &amp;quot;Charlie&amp;quot;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard_TEL&amp;gt; -&amp;gt; ?Telephone],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf:type&amp;gt; -&amp;gt; &amp;lt;nowiki&amp;gt;&amp;lt;http://www.w3.org/2001/vcard-rdf/3.0#voice&amp;gt;&amp;lt;/nowiki&amp;gt;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf_value&amp;gt; -&amp;gt; ?ContactInfo].&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contact(&amp;quot;Charlie&amp;quot;, &amp;quot;cell number&amp;quot;, ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard:FN&amp;gt; -&amp;gt; &amp;quot;Charlie&amp;quot;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard_TEL&amp;gt; -&amp;gt; ?Telephone],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf:type&amp;gt; -&amp;gt; &amp;lt;nowiki&amp;gt;&amp;lt;http://www.w3.org/2001/vcard-rdf/3.0#cell&amp;gt;&amp;lt;/nowiki&amp;gt;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf_value&amp;gt; -&amp;gt; ?ContactInfo].&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contact(&amp;quot;Charlie&amp;quot;, &amp;quot;office number&amp;quot;, ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard:FN&amp;gt; -&amp;gt; &amp;quot;Charlie&amp;quot;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard_TEL&amp;gt; -&amp;gt; ?Telephone],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf:type&amp;gt; -&amp;gt; &amp;lt;nowiki&amp;gt;&amp;lt;http://www.w3.org/2001/vcard-rdf/3.0#work&amp;gt;&amp;lt;/nowiki&amp;gt;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf_value&amp;gt; -&amp;gt; ?ContactInfo]. &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;intelligent&amp;quot; crawling and search. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
Since negation is not supported by RIF BLD it is not possible to express ''... but not listed at ...''.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Conclusion ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
The goal of the RIF working group is to provide representational interchange formats for processes based on the use of rules and rule-based systems. These formats act as &amp;quot;interlingua&amp;quot; to interchange rules and integrate with other languages, in particular (Semantic) Web mark-up languages. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
In light of this diversity, rather than being a single all-encompassing format, RIF consists 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. &lt;br /&gt;
&lt;br /&gt;
RIF has been designed in such a way that it is possible to create new dialects (extensibility) according to the overall 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. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-Horty-deontic-logic&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
; [Horty2001]&lt;br /&gt;
: ''Agency and Deontic Logic'', John F. Horty, Oxford University Press, 2001.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;event-calculus&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
; [KS86]&lt;br /&gt;
: Kowalski, R.A. and M.J. Sergot, ''A logic-based calculus of events.'' New Generation Computing, 1986. 4: p. 67-95.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;moore&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
; [Moore80]&lt;br /&gt;
: Moore, R.C., ''Reasoning about Knowledge and Action,'' SRI TR-191, 1980.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Appendix: Change Log (Informative) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This appendix summarizes the main changes to this document since its publication as a Working Draft.&lt;br /&gt;
&lt;br /&gt;
Changes since the [http://www.w3.org/TR/rif-ucr/ draft of December 18th, 2008]:&lt;br /&gt;
* [[#Structure_of_RIF|section describing the structure of RIF]] updated with the new RIF documents;&lt;br /&gt;
* all code examples are removed from the document&lt;br /&gt;
* each use cases has a new paragraph at the end which discusses the support of the use case by the current RIF dialects Core, BLD and PRD&lt;br /&gt;
* added an informative change log section&lt;br /&gt;
* flattened the list of requirements removing the distinction between general and basic requirements&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</description>
			<pubDate>Tue, 11 Dec 2012 14:14:44 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Talk:UCR</comments>		</item>
		<item>
			<title>UCR</title>
			<link>http://www.w3.org/2005/rules/wiki/UCR</link>
			<description>&lt;p&gt;Sandro:&amp;#32;fix link to rif primer&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NUMBEREDHEADINGS__&lt;br /&gt;
{{TR|title=RIF Use Cases and Requirements}}&lt;br /&gt;
&amp;lt;div id='editors'&amp;gt;&lt;br /&gt;
; Editors:&lt;br /&gt;
: Adrian Paschke, Freie Universitaet Berlin&lt;br /&gt;
: Leora Morgenstern, SAIC&lt;br /&gt;
: David Hirtle, National Research Council Canada&lt;br /&gt;
: Allen Ginsberg, Mitre&lt;br /&gt;
: Paula-Lavinia Patranjan, REWERSE&lt;br /&gt;
: Frank &amp;lt;nowiki&amp;gt;McCabe&amp;lt;/nowiki&amp;gt;, Fujitsu&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
; Abstract&lt;br /&gt;
: &amp;lt;div id='abstract'&amp;gt;&amp;lt;p&amp;gt;&amp;lt;/p&amp;gt; &amp;lt;p&amp;gt;&amp;lt;/p&amp;gt; &amp;lt;p&amp;gt;&amp;lt;/p&amp;gt; &amp;lt;p&amp;gt;This document, developed by the [http://www.w3.org/2005/rules/wg Rule Interchange Format (RIF) Working Group], specifies use cases and requirements for the W3C Rule Interchange Format, a family of rule interchange dialects that allows rules to be translated between rule languages and thus transferred between rule systems. &amp;lt;/p&amp;gt; &amp;lt;/div&amp;gt;&lt;br /&gt;
; Status of this Document&lt;br /&gt;
: 3rd revised version of the UCR document&lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/Consortium/Legal/ipr-notice#Copyright Copyright] © 2010 [http://www.w3.org/ W3C]&amp;lt;sup&amp;gt;®&amp;lt;/sup&amp;gt; ([http://www.csail.mit.edu/ MIT], [http://www.ercim.org/ ERCIM], [http://www.keio.ac.jp/ Keio]), All Rights Reserved. W3C [http://www.w3.org/Consortium/Legal/ipr-notice#Legal_Disclaimer liability], [http://www.w3.org/Consortium/Legal/ipr-notice#W3C_Trademarks trademark] and [http://www.w3.org/Consortium/Legal/copyright-documents document use] rules apply.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id='docbody'&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;html&amp;gt;&lt;br /&gt;
&amp;lt;script type=&amp;quot;text/javascript&amp;quot;&amp;gt;/*&amp;lt;![CDATA[*/&lt;br /&gt;
/*&lt;br /&gt;
	Written by Jonathan Snook, http://www.snook.ca/jonathan&lt;br /&gt;
	Add-ons by Robert Nyman, http://www.robertnyman.com&lt;br /&gt;
	Author says &amp;quot;The credit comment is all it takes, no license. Go crazy with it!:-)&amp;quot;&lt;br /&gt;
	From http://www.robertnyman.com/2005/11/07/the-ultimate-getelementsbyclassname/&lt;br /&gt;
*/&lt;br /&gt;
&lt;br /&gt;
var displayed = [];&lt;br /&gt;
displayed[&amp;quot;bld&amp;quot;] = 1;&lt;br /&gt;
displayed[&amp;quot;prd&amp;quot;] = 1;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
function display(syntax,status) {&lt;br /&gt;
  var howmany = 0;&lt;br /&gt;
  if (status=='none') {&lt;br /&gt;
    displayed[syntax] = 0; &lt;br /&gt;
  } else { &lt;br /&gt;
    displayed[syntax] = 1;&lt;br /&gt;
  }&lt;br /&gt;
  for ( i in displayed ) {&lt;br /&gt;
       howmany = howmany + displayed[i];&lt;br /&gt;
  }&lt;br /&gt;
  set_display_by_class('p',syntax,status);&lt;br /&gt;
  if ( howmany == 1 ) {&lt;br /&gt;
      set_display_by_class('b','syntax-head','none');&lt;br /&gt;
  } else {&lt;br /&gt;
      set_display_by_class('b','syntax-head','');&lt;br /&gt;
  }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
function getElementsByClassName(oElm, strTagName, oClassNames){&lt;br /&gt;
	var arrElements = (! (! (strTagName == &amp;quot;*&amp;quot;) || ! (oElm.all)))? oElm.all : oElm.getElementsByTagName(strTagName);&lt;br /&gt;
	var arrReturnElements = new Array();&lt;br /&gt;
	var arrRegExpClassNames = new Array();&lt;br /&gt;
	if(typeof oClassNames == &amp;quot;object&amp;quot;){&lt;br /&gt;
		for(var i=0; !(i&amp;gt;=oClassNames.length); i++){ /*&amp;gt;*/&lt;br /&gt;
			arrRegExpClassNames.push(new RegExp(&amp;quot;(^|\\s)&amp;quot; + oClassNames[i].replace(/\-/g, &amp;quot;\\-&amp;quot;) + &amp;quot;(\\s|$)&amp;quot;));&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
	else{&lt;br /&gt;
		arrRegExpClassNames.push(new RegExp(&amp;quot;(^|\\s)&amp;quot; + oClassNames.replace(/\-/g, &amp;quot;\\-&amp;quot;) + &amp;quot;(\\s|$)&amp;quot;));&lt;br /&gt;
	}&lt;br /&gt;
	var oElement;&lt;br /&gt;
	var bMatchesAll;&lt;br /&gt;
	for(var j=0; !(j&amp;gt;=arrElements.length); j++){ /*&amp;gt;*/&lt;br /&gt;
		oElement = arrElements[j];&lt;br /&gt;
		bMatchesAll = true;&lt;br /&gt;
		for(var k=0; !(k&amp;gt;=arrRegExpClassNames.length); k++){ /*&amp;gt;*/&lt;br /&gt;
			if(!arrRegExpClassNames[k].test(oElement.className)){&lt;br /&gt;
				bMatchesAll = false;&lt;br /&gt;
				break;&lt;br /&gt;
			}&lt;br /&gt;
		}&lt;br /&gt;
		if(bMatchesAll){&lt;br /&gt;
			arrReturnElements.push(oElement);&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
	return (arrReturnElements)&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
function set_display_by_class(el, cls, newValue) {&lt;br /&gt;
   var e = getElementsByClassName(document, el, cls);&lt;br /&gt;
   if (e != null) {&lt;br /&gt;
      for (var i=0; !(i&amp;gt;=e.length); i++) {&lt;br /&gt;
        e[i].style.display = newValue;&lt;br /&gt;
      }&lt;br /&gt;
   }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
function set_display_by_id(id, newValue) {&lt;br /&gt;
   var e = document.getElementById(id);&lt;br /&gt;
   if (e != null) {&lt;br /&gt;
     e.style.display = newValue;&lt;br /&gt;
   }&lt;br /&gt;
}&lt;br /&gt;
/*]]&amp;gt;*/&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/html&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;   &amp;lt;!-- because there seems to be a close-div after the intro --&amp;gt;&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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 existing 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. This mission of RIF is part of W3C's larger goal of enabling the sharing of information in forms suited to machine processing: &lt;br /&gt;
&lt;br /&gt;
*# 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 [http://www.ruleml.org/ RuleML Initiative] and elsewhere. &lt;br /&gt;
*# Rules provide a powerful business logic representation, as business rules, in many modern information systems. &lt;br /&gt;
*# Rules are often the technology of choice for creating maintainable adapters between information systems. &lt;br /&gt;
*# 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. &lt;br /&gt;
&lt;br /&gt;
The purpose of this RIF-UCR document is to describe the use cases that guided the design of RIF and to document the design requirements that were derived from both the use cases and from the basic goals of RIF. RIF-UCR also delivers a structured context for formulating future technical specifications of further RIF dialects. Each dialect targets at a cluster of similar rule languages and enables platform-independent interoperation between them (via interchange of RIF rules). 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.&lt;br /&gt;
&lt;br /&gt;
The RIF-UCR document is structured as follows: Section 2 formulates the overall goals of RIF. Section 3 summarizes the released RIF dialects and the current structure of RIF. Section 4 discusses several important requirements for RIF dialects. Section 5 presents a set of use cases that are representative of the types of application scenarios that RIF is intended to support. The use cases illustrate the utilization of the current RIF dialects.  More importantly, the functionality specified in the use cases, together with the requirements discussed in the previous section, serves as input for both the technical specification of future RIF dialects and for the implementation of various variants of these scenarios by RIF-compliant applications and systems. &lt;br /&gt;
&lt;br /&gt;
Although in this document the discussion of requirements precedes the discussion of the use cases in this document,  the development of the use cases preceded, and in fact motivated, the development of the requirements. In general, it is intended that for each requirement, there is at least one use case, or straightforward modification of a use case, from which that requirement was derived.  There are some exceptions to this rule: some requirements were already defined as constraints in the working group charter, and were not necessarily derived from any specific use case. The fulfillment of such requirements is discussed with respect to the existing RIF dialects. &lt;br /&gt;
&lt;br /&gt;
Note that in fact not all use cases can be represented in a straightforward manner within all RIF dialects. In particular, several use cases cannot be represented within the RIF dialect BLD. This is due first, to the fact that BLD is strictly less expressive than first-order logic (since negation is not expressible), and second, to the fact that some use cases are most naturally represented in languages more powerful than first-order logic, such as modal logics. Following the presentation of each use case in Section 5 is a note indicating in which of the current RIF dialects a use case can be represented naturally, sometimes accompanied by discussion.&lt;br /&gt;
&lt;br /&gt;
It should be noted that even use cases which cannot be represented in a straightforward manner within some RIF dialect, such as BLD, there may be other approaches which will enable representation. For example, although epistemic operators such as &amp;lt;tt&amp;gt;Know&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;Believe&amp;lt;/tt&amp;gt; are most straightforwardly represented within a modal logic, it is generally possible to represent such operators in a first-order logic using a possible-worlds semantics. For certain use cases which cannot be naturally represented within some dialect, the extent to which this can be done will be discussed.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Goals ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
The primary goal of 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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;goal-exchange-of-rules&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
==== Exchange of Rules ====&lt;br /&gt;
&lt;br /&gt;
The primary goal of RIF is to facilitate the exchange of rules. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;goal-w3c-consistency&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
==== Consistency with W3C specifications ====&lt;br /&gt;
&lt;br /&gt;
RIF 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 RIF. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;goal-widescale-adoption&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
==== Widescale Adoption ====&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;network effect&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
Along with the use cases in the next section, these goals motivate the requirements in Section 5.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Structure of RIF ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
RIF is described by a set of documents, each fulfilling a different purpose, and catering to a different audience. The three RIF dialects which can be used to represent RIF use cases are:&lt;br /&gt;
&lt;br /&gt;
* [http://www.w3.org/TR/rif-core RIF Core Dialect], which provides a standard, base level of functionality for interchange&lt;br /&gt;
* [http://www.w3.org/TR/rif-bld RIF Basic Logic Dialect] and [http://www.w3.org/TR/2010/REC-rif-prd-20100622/ RIF Production Rule Dialect] provide extended functionality matching two common classes of rule engines, namely derivation rules and production rules.&lt;br /&gt;
&lt;br /&gt;
Along with these three dialects, RIF consists of related documents: [http://www.w3.org/TR/rif-fld RIF Framework for Logic Dialects], [http://www.w3.org/TR/rif-dtb RIF Datatypes and Built-Ins 1.0], [http://www.w3.org/TR/rif-test RIF Test Cases], [http://www.w3.org/TR/rif-rdf-owl RIF RDF and OWL Compatibility], [http://www.w3.org/TR/rif-ucr/ RIF Use Cases and Requirements], [http://www.w3.org/TR/rif-owl-rl OWL 2 RL in RIF], [http://www.w3.org/2007/OWL/wiki/PlainLiteral rdf:PlainLiteral], [http://www.w3.org/TR/rif-xml-data RIF Combination with XML data], [http://www.w3.org/TR/rif-primer RIF Primer] and [http://www.w3.org/TR/rif-in-rdf/ RIF In RDF]. For an overview on RIF see the [http://www.w3.org/TR/rif-overview RIF Overview].&lt;br /&gt;
&lt;br /&gt;
RIF is designed as a family of RIF dialects as shown in the following Venn diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image: RIF_DIALECTS_VENN.jpg | Venn Diagram of RIF Dialects]]&lt;br /&gt;
&lt;br /&gt;
Each dialect is a collection of components that works together, forming an interlingua. New dialects are needed when no existing dialect provides the required rule-language features for interchange.&lt;br /&gt;
&lt;br /&gt;
The RIF Framework for Logic-based Dialects ([http://www.w3.org/TR/rif-fld RIF-FLD]) describes mechanisms for specifying the syntax and semantics of logic-based RIF dialects through a number of generic concepts. Every logic-based RIF dialect should specialize these general mechanisms or justify why it does not. This specialization may include leaving out some elements of RIF-FLD, to produce its concrete syntax and model-theoretic semantics. Currently, the first two existing RIF dialects are the RIF Basic Logic Dialect (RIF-BLD) and the RIF Production Rules Dialect (RIF-PRD) which is a partial specialization of FLD.&lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/TR/rif-bld RIF-BLD] (Basic Logic Dialect) is a specialization of RIF-FLD capable of representing definite Horn rules with equality enhanced with a number of syntactic extensions to support expressive features such as objects and frames, internationalized resource identifiers (IRIs) as identifiers for concepts, and XML Schema data types.&lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/TR/rif-prd RIF-PRD] (Production Rules Dialect) specifies a production rules dialect to enable the interchange of production rules. The condition language of RIF PRD is defined in Core as a common subset of RIF BLD and RIF PRD. &lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/TR/rif-core RIF-Core] (Core Dialect) specifies a common subset of RIF-BLD and RIF-PRD which includes RIF-DTB.&lt;br /&gt;
&lt;br /&gt;
The normative syntax for RIF dialects is a concrete XML syntax. A non-normative presentation syntax is additionally specified for each dialect, to allow a more easily readable and compact presentation of language fragments (such as examples).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Requirements ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-semantic-tagging&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
The goals and use cases motivate a number of requirements for a Rule Interchange Format. The Working Group has approved the following requirements.  &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-implementability&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Implementability ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-semantic-precision&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Semantic precision ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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 extend RIF core.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-extensible&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Extensible Format ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''It must be possible to create new RIF dialects which extend existing dialects (thus providing backward compatibility) and are handled gracefully by systems which support existing dialects (thus providing forward compatibility).'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-translators&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Translators ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-standard-components&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Standard components ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-coverage&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Rule language coverage ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''Because of the great diversity of rule languages, no single interchange language is likely to be able to bridge between all. Instead, RIF provides dialects each of which is targeted at a cluster of similar rule languages. RIF must allow intra-dialect interoperation, i.e. interoperability between semantically similar rule languages (via interchange of RIF rules) within one dialect, and should support inter-dialect interoperation, i.e. interoperation between dialects with maximum overlap.''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-compliance-model&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Compliance model ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''The RIF specifications must provide clear conformance criteria that define what is or is not a conformant RIF implementation.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-default-behavior&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Default behavior ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-different-semantics&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Different semantics ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must cover rule languages having different semantics.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-dialects&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Limited number of dialects ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must have a standard core, and a limited number of standard dialects based upon that core.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-comments&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Embedded comments ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must be able to pass comments.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-metadata&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Embedded metadata ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must support metadata such as author and rule name.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-owl-data&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== OWL data ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must cover OWL knowledge bases as data where compatible with RIF semantics.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-rdf-data&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== RDF data ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must cover RDF triples as data where compatible with RIF semantics.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-dialect-identification&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Dialect Identification ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''The semantics of a RIF document must be uniquely determined by the content of the document, without out-of-band data.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-xml-syntax&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== XML syntax ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must have an XML syntax as its primary normative syntax.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-xml-types&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== XML types ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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 [http://www.w3.org/2005/rules/wg/charter#datatype0 Datatype support]. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-merge&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Merge Rule Sets ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must support the ability to merge rule sets.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-rulesets&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Identify Rule Sets ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must support the identification of rule sets.''  &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-xml-data&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== XML data ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF should be able to accept XML elements as data.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-rif-text&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Internationalized text ===&lt;br /&gt;
&lt;br /&gt;
''RIF must support internationalized text — that is, text that additionally conveys information in terms of a language tag.''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Use Cases ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
A use case for RIF consists of a description of a problem together with a solution that either uses an existing RIF dialect or requires the specification of a new RIF dialect.&lt;br /&gt;
&lt;br /&gt;
The set of use cases is intended to do the following:&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;motivate the need for a RIF in a broad range of application domains and industrial sectors;&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;provide scenarios that motivate the design of RIF and explain the benefits of a RIF in such scenarios;&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;guide users to RIF's specified dialects; and&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;motivate the working group's set of requirements for a RIF.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The set of use cases were developed over several years.&lt;br /&gt;
Nearly [http://www.w3.org/2005/rules/wg/wiki/Use_Cases fifty use cases] documenting the need for a RIF were originally submitted by the working group members. These were grouped into  general categories and then synthesized as much as possible. The goal was to come up with a relatively small set of use cases that would cover a broad range of possible requirements. In addition,  it was desired that the use cases refer to popular application domains and industrial sectors. For every use case we will briefly discuss the coverage of the use case by the existing three RIF dialects (Core, BLD, and PRD). &lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- do not skip a line &lt;br /&gt;
&amp;lt;html&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px dotted black; padding:0.5em; margin: 1em; &amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;The button below can be used to show or hide the RIF examples.&amp;lt;/p&amp;gt;&amp;lt;form action=&amp;quot;&amp;quot;&amp;gt;&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;input id=&amp;quot;hide-rif&amp;quot; type=&amp;quot;button&amp;quot; value=&amp;quot;Hide Examples&amp;quot; style=&amp;quot;display:none&amp;quot;&lt;br /&gt;
  onclick=&amp;quot;display('rif', 'none');&lt;br /&gt;
           set_display_by_id('hide-rif', 'none'); &lt;br /&gt;
           set_display_by_id('show-rif', '');&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;input id=&amp;quot;show-rif&amp;quot; type=&amp;quot;button&amp;quot; value=&amp;quot;Show Examples&amp;quot; &lt;br /&gt;
  onclick=&amp;quot;display('rif','');&lt;br /&gt;
     set_display_by_id('hide-rif', ''); &lt;br /&gt;
     set_display_by_id('show-rif', 'none');&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&amp;lt;/form&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;/html&amp;gt;--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Negotiating eBusiness Contracts Across Rule Platforms ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This use case illustrates a fundamental use of RIF: to supply 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, and in particular without concern that a business partner does not have the same vendor technology. It also illustrates the fact that RIF can be used to foster collaborative work. Each developer and stakeholder can make a contribution to the joint effort without being forced to adopt the tools or platforms of the other contributors. &lt;br /&gt;
&lt;br /&gt;
John is negotiating an electronic business contract regarding the supply of various types of items that Jane's company is manufacturing. Jane and John interchange the contract-related data and rules involved in the negotiation 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 goods and services involved - in this case an XML schema and appropriate test XML documents are interchanged with their rules. Since John and Jane run applications based on different vendors' rule engines and rule languages, they interchange the rules using RIF; both vendors used can interpret the XML schema and data, and produce the results as an amended XML document. John's company defines its purchase orders in terms of an XML description of goods, packaging, delivery location and date with delivery and payment rules. A rule proposed by John might be the following: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If an item is perishable and it is delivered to John more than 10 days after the scheduled delivery date then the item will be rejected by him.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
This rule set can be adequately represented in RIF Core either using (ordered) relations as e.g. in standard Logic Programming, unordered relations using named arguments, or in a more object-oriented encoding using frames.&amp;lt;br /&amp;gt;   &lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
''Ordered representation in RIF Core presentation syntax using relations:'' &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&lt;br /&gt;
 &lt;br /&gt;
  Group &lt;br /&gt;
  (&lt;br /&gt;
      Forall ?item ?deliverydate ?scheduledate ?diffdays (&lt;br /&gt;
      ex:reject(&amp;quot;John&amp;quot; ?item) :-&lt;br /&gt;
          ex:perishable(?item)&lt;br /&gt;
          ex:delivered(?item ?deliverydate &amp;quot;John&amp;quot;)&lt;br /&gt;
          ex:scheduled(?item ?scheduledate)&lt;br /&gt;
          ?diffdays = External(func:days-from-duration(&lt;br /&gt;
                                  External(func:subtract-dateTimes(?deliverydate ?scheduledate))  &lt;br /&gt;
                               )) &lt;br /&gt;
          External(pred:numeric-greater-than(?diffdays  10)) &lt;br /&gt;
      ) &lt;br /&gt;
   ) &lt;br /&gt;
) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
Note, the nesting of external built-in functions and operations and the assignment/binding of (intermediate) result (sets) from functions to variables by equality in this example.&amp;lt;br /&amp;gt;    &lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
''Unordered representation in RIF Core presentation syntax using namened arguments:'' &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#) &lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#) &lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#) &lt;br /&gt;
 &lt;br /&gt;
  Group &lt;br /&gt;
  ( &lt;br /&gt;
      Forall ?item ?deliverydate ?scheduledate ?diffdays ( &lt;br /&gt;
      ex:reject(ex:ware -&amp;gt; ?item ex:receiver -&amp;gt; &amp;quot;John&amp;quot;) :- &lt;br /&gt;
         ex:perishable(ex:ware -&amp;gt; ?item) &lt;br /&gt;
         ex:delivered(ex:ware -&amp;gt; ?item  ex:datetime -&amp;gt; ?deliverydate  ex:receiver -&amp;gt; &amp;quot;John&amp;quot;) &lt;br /&gt;
         ex:scheduled(ex:datetime -&amp;gt; ?scheduledate  ex:ware -&amp;gt; ?item) &lt;br /&gt;
         ?diffdays = External(func:days-from-duration( &lt;br /&gt;
                                  External(func:subtract-dateTimes(?deliverydate ?scheduledate))  &lt;br /&gt;
                               )) &lt;br /&gt;
          External(pred:numeric-greater-than(?diffdays  10)) &lt;br /&gt;
      ) &lt;br /&gt;
   ) &lt;br /&gt;
) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
Note, the arbitrarily unordered named argument arguments of the user-defined relations, in contrast to external built-in functions and operations, which must have a predefined order. &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
''Object-Oriented Representation in RIF Core presentation syntax using frames:'' &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt;  Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#) &lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#) &lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#) &lt;br /&gt;
 &lt;br /&gt;
  Group &lt;br /&gt;
  ( &lt;br /&gt;
      Forall ?item ?deliverydate ?scheduledate ?diffdays ( &lt;br /&gt;
      ?item[ex:status -&amp;gt; &amp;quot;rejected&amp;quot;] :- &lt;br /&gt;
         ?item[ex:perishable -&amp;gt; true]  &lt;br /&gt;
         ?item[ex:deliveredOn -&amp;gt; ?deliverydate ex:delivered -&amp;gt; &amp;quot;John&amp;quot;]  &lt;br /&gt;
         ?item[ex:scheduledOn -&amp;gt; ?scheduledate ex:delivered -&amp;gt; &amp;quot;John&amp;quot;]  &lt;br /&gt;
         External(pred:numeric-greater-than(         &lt;br /&gt;
             External(func:days-from-duration( &lt;br /&gt;
                                  External(func:subtract-dateTimes(?deliverydate ?scheduledate))  &lt;br /&gt;
                      )) &lt;br /&gt;
             10 &lt;br /&gt;
         ) &lt;br /&gt;
      ) &lt;br /&gt;
   ) &lt;br /&gt;
) &lt;br /&gt;
&amp;lt;/code&amp;gt;  &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Jane replies with some suggested rule changes: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
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 then a discount of 18.7% will be applied to the delivered item.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
''Representation in RIF Core presentation syntax using positional relations:'' &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#) &lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#) &lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#) &lt;br /&gt;
 &lt;br /&gt;
  Group &lt;br /&gt;
  ( &lt;br /&gt;
     Forall ?item ?deliverydate ?scheduledate ?diffdays ( &lt;br /&gt;
     ex:discount(&amp;quot;John&amp;quot; ?item 18.7 ) :- &lt;br /&gt;
           ex:perishable(?item) &lt;br /&gt;
           ex:delivered(?item ?deliverydate &amp;quot;John&amp;quot;) &lt;br /&gt;
           ex:scheduled(?item ?scheduledate) &lt;br /&gt;
           ?diffdays = External(func:days-from-duration( &lt;br /&gt;
                                  External(func:subtract-dateTimes(?deliverydate ?scheduledate))  &lt;br /&gt;
                               )) &lt;br /&gt;
           External(pred:numeric-greater-than(?diffdays  7)) &lt;br /&gt;
           External(pred:numeric-less-than(?diffdays  14)) &lt;br /&gt;
     ) &lt;br /&gt;
   ) &lt;br /&gt;
) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binding of the intermeditate results to the variable &amp;quot;?diffdays&amp;quot; avoids repetition, as it used twice in the subsequent rule conditions. As demonstrated in the previous examples, similar representations for this rule can be given using slots or frames and as a production rule which asserts the conclusion as a new fact. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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 order and determine contract compliance. &lt;br /&gt;
&lt;br /&gt;
Future requests for the supply of items by John's company are defined on their purchasing web site, as the appropriate XML schema and a RIF ruleset (or rulesets). This allows Jane's company and its competitors to respond electronically with XML cost sheets. Suppliers respond with multiple cost sheets with different variations on the RIF rules proposed by John's company, allowing John's company to review the alternative rules with their associated costs to determine whether they, as a business, would benefit by relaxing or adding new rules as proposed by suppliers. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by: RIF Core, RIF BLD, RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
The rules of this use case can be adequately represented in RIF Core (and BLD and PRD) either using (ordered) relations, as e.g. in standard Logic Programming, unordered relations, using named arguments, or in a more object-oriented encoding using frames. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Negotiating eCommerce Transactions Through Disclosure of Buyer and Seller Policies and Preferences ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This use case concerns the ability of parties involved in formal transactions or procedures, e.g., credit card authorization of a purchase, access of private medical records, etc., to express and protect their interests within a policy-governed framework. The goal is to formally encode the preferences, priorities, responses, etc., of the parties in such a way that the overall policy can work as intended while providing opportunity for automatic negotiation of terms when allowed by the policy. Utilization of RIF in this use case would extend the scope of this technology, affording a higher degree of interoperability, as well as enabling re-use and sharing of preferences, etc., through interchange. The detailed scenario below shows how this would work. &lt;br /&gt;
&lt;br /&gt;
Alice wants to buy a device at an online site called &amp;quot;eShop.&amp;quot; Alice employs software called &amp;quot;Emptor&amp;quot; that functions as automated negotiating agent for buyers. eShop employs software called &amp;quot;Venditor&amp;quot; as automated negotiating agent for sellers. &lt;br /&gt;
&lt;br /&gt;
Alice's and eShop's policies describe who they trust and for what purposes. The negotiation is based on the policies, 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. &lt;br /&gt;
&lt;br /&gt;
Policies are themselves subject to access control. Thus, rule interchange is necessarily done during negotiation and (in general) depends on the current level of trust that the systems have on each other. Since Emptor and Venditor might use different rule languages and/or engines for evaluating (own and imported) rules, a (standard) rule interchange format (RIF) needs to be employed for enabling the rule interchange between the two systems. &lt;br /&gt;
&lt;br /&gt;
When Alice clicks on a &amp;quot;buy it&amp;quot; button at the 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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
In order to grant access a buyer must provide valid credit card information together with delivery information (address, postal code, city, and country).&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF Core presentation syntax using relations and frames in combination: &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&lt;br /&gt;
&lt;br /&gt;
  Group&lt;br /&gt;
  (&lt;br /&gt;
    Forall ?buyer ?creditCard ?address (&lt;br /&gt;
    ex:permit_access(&amp;quot;eShop&amp;quot; ?buyer) :-&lt;br /&gt;
      ex:provide(&amp;quot;eShop&amp;quot; ?buyer)&lt;br /&gt;
      ?buyer[ex:card -&amp;gt; ?creditCard ex:deliveryAddr -&amp;gt; ?address]&lt;br /&gt;
      ex:valid_payment_method(?creditCard)&lt;br /&gt;
      ex:valid_delivery_address(?address)&lt;br /&gt;
    )   &lt;br /&gt;
 &lt;br /&gt;
    Forall ?type ?person ?first ?last ?number ?code ?date ?month ?year (&lt;br /&gt;
    ex:valid_payment_method(?card)   :-&lt;br /&gt;
        ?card[type -&amp;gt; ?type&lt;br /&gt;
              ex:holder -&amp;gt; ?person  &lt;br /&gt;
              ex:number -&amp;gt; ?number &lt;br /&gt;
              ex:code -&amp;gt; ?code&lt;br /&gt;
              ex:expiry -&amp;gt; ?date]&lt;br /&gt;
        ?person[ex:lastname -&amp;gt; ?last ex:firstname -&amp;gt; ?first]&lt;br /&gt;
        ?date[ex:month -&amp;gt; ?month ex:year -&amp;gt; ?year]&lt;br /&gt;
        ex:credential(?type ?person ?number ?code ?date)&lt;br /&gt;
    ) &lt;br /&gt;
 &lt;br /&gt;
    Forall ?address ?last ?first ?street ?strname ?number ?code ?city ?country (&lt;br /&gt;
    ex:valid_delivery_address(?address)   :-&lt;br /&gt;
       ?address[ex:name -&amp;gt; ?person ex:street -&amp;gt; ?street ex:postal_code -&amp;gt; ?code ex:city -&amp;gt; ?city ex:country -&amp;gt; ?country ]&lt;br /&gt;
       ?person[ex:lastname -&amp;gt; ?last ex:firstname -&amp;gt; ?first] &lt;br /&gt;
       ?street[name -&amp;gt; ?strname ex:number -&amp;gt; ?number] &lt;br /&gt;
       ex:declaration(?person ?street ?number ?code ?city ?country)&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
  )&lt;br /&gt;
)&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that in this example relational representation is used in combination with frame representation. Such mixing of representation styles is supported by RIF. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Rules express compactly possible ways in which a resource can be accessed; by exchanging them negotiations are shorter and privacy protection is improved. In the 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 and required information to disclose. &lt;br /&gt;
&lt;br /&gt;
For determining whether Venditor's request for information is consistent with Alice's policy, Emptor takes its rules into account, which state for example: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
Disclose Alice's credit card information only to online shops belonging to the Better Business Bureau.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF Core presentation syntax: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&lt;br /&gt;
&lt;br /&gt;
  Group&lt;br /&gt;
  (&lt;br /&gt;
    Forall ?Shop ?card ?Credential ?Buyer  (&lt;br /&gt;
      ex:provide(?Shop ?Buyer )  :-  &lt;br /&gt;
         ?Buyer[ex:card -&amp;gt; ?creditCard ex:deliveryAddr -&amp;gt; ?address]&lt;br /&gt;
         ex:belongs_to(?Shop  &amp;quot;Better Business Bureau&amp;quot;) &lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
    Forall ?deliveryAddr ?card ?Date ?Person ?Street  (&lt;br /&gt;
      ex:Alice[ex:card -&amp;gt; ?card ex:deliveryAddr -&amp;gt; ?deliveryAddr] :-&lt;br /&gt;
                  ?Date = ex:Date[ex:month -&amp;gt; 12 ex:year -&amp;gt; 2012]&lt;br /&gt;
                  ?Person = ex:Person[ex:lastname -&amp;gt; &amp;quot;Sure&amp;quot; ex:firstname -&amp;gt; &amp;quot;Alice&amp;quot;]&lt;br /&gt;
                  ?Street = ex:Street[name -&amp;gt; &amp;quot;North Street&amp;quot; number -&amp;gt; 111]&lt;br /&gt;
                  ?card= ex:Card[ ex:type -&amp;gt; &amp;quot;Visa&amp;quot;&lt;br /&gt;
                                  ex:holder -&amp;gt;  ?Person &lt;br /&gt;
                                  ex:number -&amp;gt; &amp;quot;123456789&amp;quot; &lt;br /&gt;
                                  ex:code -&amp;gt; &amp;quot;123&amp;quot;&lt;br /&gt;
                                  ex:expiry -&amp;gt; ?Date &lt;br /&gt;
                                 ]&lt;br /&gt;
                  ?deliveryAddr = ex:DeliveryAddress[ ex:name -&amp;gt; ?Person &lt;br /&gt;
                                                      ex:street -&amp;gt; ?Street&lt;br /&gt;
                                                      ex:postal_code -&amp;gt; &amp;quot;NE3456&amp;quot; &lt;br /&gt;
                                                      ex:city -&amp;gt; &amp;quot;New York&amp;quot; &lt;br /&gt;
                                                      ex:country -&amp;gt; &amp;quot;USA&amp;quot; &lt;br /&gt;
                                                    ]&lt;br /&gt;
     )&lt;br /&gt;
&lt;br /&gt;
   )&lt;br /&gt;
)&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
By disclosing (interchanging) the above given rule, Emptor asks Venditor to provide credentials saying that it belongs to the Better Business Bureau, Alice's most trusted source of information on online shops. eShop has such a credential and its policy contains a rule stating to release it to any potential purchaser. Hence, Venditor passes the credential to Emptor. Emptor is now ready to disclose Alice's credit card information to Venditor but it still must check whether disclosing all the information does not break Alice's denial constraints. Alice has stated two constraints stating: &lt;br /&gt;
 &lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
For anonymity reasons, never provide both her birth date and postal code.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
The current RIF dialects do not specify explicit constructs for integrity constraints. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For this purchase, Alice birthdate is no issue. Thus, Alice's constraints are respected. Emptor therefore provides Alice's credit card information to Venditor. &lt;br /&gt;
&lt;br /&gt;
Companies that provide software such as Venditor and Emptor would make use of RIF in a number of ways. The rules 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 work together in real-time. When these two systems need to exchange policy or preference information of their respective clients they would use RIF to enable the interchange in real-time. When Venditor sends its initial policy information to Emptor it uses RIF. Emptor takes that policy and translates it from RIF to its internal representation in order to determine what it needs to do. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Not supported by the current RIF dialects (Core, BLD, PRD) '''&lt;br /&gt;
&lt;br /&gt;
Current RIF dialects  do not specify explicit constructs for integrity constraints; thus, this use case is not adequately supported by any of these dialects. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Collaborative Policy Development for Dynamic Spectrum Access ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This use case demonstrates how RIF leads to increased flexibility in matching the goals of end-users of a service/device, with the goals of providers and regulators of such services/devices. RIF can do that because it enables deployment of third party systems that can generate various suitable interpretations and/or translations of the sanctioned rules governing a service/device. &lt;br /&gt;
&lt;br /&gt;
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 a device to absorb the rules defining the policies of a region, or the operational protocols required to dynamically access available spectrum, is contingent upon those rules being in a form that the device can use, as well as their being tailored to work with devices in the same class having different capabilities. &lt;br /&gt;
&lt;br /&gt;
In this use-case we suppose a region adopts a policy that allows certain wireless devices to opportunistically use frequency bands that are normally reserved for certain high-priority users. ([http://europa.eu.int/eur-lex/lex/LexUriServ/site/en/oj/2005/l_187/l_18720050719en00220024.pdf The decision] by the European Union to allow &amp;quot;Dynamic Frequency Selection&amp;quot; (DFS) use of the 5 GHz frequency band by wireless systems, a band intermittently used by military and weather radar, is a recent example.) &lt;br /&gt;
&lt;br /&gt;
Suppose the policy states: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
A wireless device can transmit on a 5 GHz band if no priority user is currently using that band.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
&amp;lt;!-- Representation in RIF Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt; &lt;br /&gt;
     Forall ?device ?band ?user (&amp;lt;br /&amp;gt;&lt;br /&gt;
     ex:transmit(?device ?band 5) :- &amp;lt;br /&amp;gt;&lt;br /&gt;
         not(ex:used(?user ?band))&amp;lt;br /&amp;gt;&lt;br /&gt;
      )&amp;lt;br /&amp;gt;&lt;br /&gt;
   )&amp;lt;br /&amp;gt;&lt;br /&gt;
)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt; --&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;Note, since default negation (not) such as negation as failure is not supported by RIF BLD there is no adequate way to represent that &amp;quot;no priority user is currently using the band&amp;quot;. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
How does a device know that no priority user is currently using a band it wants to use? The answer will depend on the specific capabilities of the device. One type of device may answer this question by sensing the amount of energy it is receiving on that band. That is, it might employ the rule: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If no energy is detected on a desired band then assume no other device is using the band.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt;&lt;br /&gt;
      Forall ?device ?band ?level  (&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:used(?device ?band) :- &amp;lt;br /&amp;gt;&lt;br /&gt;
                   ex:detect(ex:energy(?level ?band))&amp;lt;br /&amp;gt;&lt;br /&gt;
                   External(pred:numeric-greater-than(?level  0))&amp;lt;br /&amp;gt;&lt;br /&gt;
      )&amp;lt;br /&amp;gt;&lt;br /&gt;
   )&amp;lt;br /&amp;gt;&lt;br /&gt;
)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;Note, the engergy detection function would require an external call for sensing  the level of energy. Such procedural attachments cannot be specified in BLD. Reaction rules provide event detection capabilities. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A second type of device, may get information from a control channel that lets it know whether the desired band is being used by a priority user. That is, it might employ the rule: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If no control signal indicating use of a desired band by a priority user is detected then assume the band is available.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt;&lt;br /&gt;
      Forall ?device ?band ?user  (&amp;lt;br /&amp;gt;&lt;br /&gt;
       ex:used(?device ?band) :- &amp;lt;br /&amp;gt;&lt;br /&gt;
                   ex:detect(ex:signal(?user ?band))&amp;lt;br /&amp;gt;&lt;br /&gt;
                   ex:priority(?user,&amp;quot;high&amp;quot;).&amp;lt;br /&amp;gt;&lt;br /&gt;
      )&amp;lt;br /&amp;gt;&lt;br /&gt;
   )&amp;lt;br /&amp;gt;&lt;br /&gt;
)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
So each type of device will need to employ different &amp;quot;interpretations&amp;quot; or &amp;quot;operational definitions&amp;quot; of the policy in question. &lt;br /&gt;
&lt;br /&gt;
Now assume that there are 10 manufacturers of these 2 different types of wireless devices. Suppose that each of these manufacturers uses a distinct rule-based platform in designing its devices. Each manufacturer needs to write 2 interpretations of the policy (for each of the two types of device). That means that 20 different versions of the policy must be written, tested and maintained. &lt;br /&gt;
&lt;br /&gt;
Enter RIF. The 10 manufacturers form a consortium. This is a third-party group that is responsible for translating regional policies into RIF. When it does so, however, it provides different versions corresponding to the possible interpretations (operational definitions) of the policy. So in this case, 2 RIF versions of the DFS policy are provided for the 2 types of device mentioned above. Each of these RIF specifications can be automatically translated into the appropriate rule-platform provided a RIF-Compiler for the target device architecture exists. Clearly it will be in the interest of each device manufacturer to develop such compilers. That is because the manufacturer only needs to develop such a compiler ''once'' for every architecture it owns. Contrast that investment with having to produce, test, and maintain different versions of various policies over the lifetime of a product. &lt;br /&gt;
&lt;br /&gt;
This arrangement also allows the overall process to be organized in a fashion that maintains the natural division of labor in the corresponding division of artifacts produced by that labor: the policy and its various interpretations are written and maintained in platform-independent artifacts (RIF); knowledge about how to translate from 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. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Partly supported by: RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
The energy detection function specified in this use case would require an external call to a device that would sense  the level of energy. Such procedural attachments cannot be specified in the current RIF dialects. Reaction rules support (complex) event detection capabilities on, e.g., event streams over sensor data. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This use case is not supported at all by RIF BLD, and by extension, by RIF Core. These dialects do not support negation, and&lt;br /&gt;
the use case makes explicit mention of negation, e.g. for representing that &amp;quot;no priority user is currently using the band.&amp;quot;&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Access to Business Rules of Supply Chain Partners ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If inspector believes vehicle is repairable then process as repair otherwise process as total loss.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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). &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
How such a unified 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, RIF permits a unified dynamic view of the business rule logic no matter what the original form of the rules. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Not supported, in a straightforward manner, by the current RIF dialects'''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
BLD and PRD do not support modal operators or predicates on quoted sentences; therefore standard representations of knowledge, belief, and/or uncertainty cannot be specified in BLD and PRD. Even without such constructs, it can be possible to represent knowledge or belief using the semantics of possible worlds &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#moore|Moore1980]]]. That is, one can get the effect of saying that an agent A believes proposition P by saying that P holds in all words that are belief-accessible to P. For example, to get the effect of saying &lt;br /&gt;
&amp;lt;pre width=130&amp;gt;Believe(john,overCreditLimit(bill,t))&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
 one says instead&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
holds(overCreditLimit(bill),t1) :- beliefAccessible(john,t,t1)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The translation between sentences involve operators such as Know and Believe and sentences that make direct use of possible worlds relies on the possible-worlds semantics, which posits properties on the knowledge-accessibility or belief-accessibility relation. These relations correspond to axioms on the Know and Believe operators.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Such a strategy could work, to a certain extent, in RIF PRD, but would not work in RIF BLD. This is because expressing the standard axioms on belief or knowledge would require the use of negation, which is not supported by BLD.&lt;br /&gt;
&lt;br /&gt;
For both PRD and BLD there is an additional consideration, which is that the notion of reification is in general not supported by the dialects of RIF.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Managing Inter-Organizational Business Policies and Practices ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
* An organization may buy rule sets from expert sources &lt;br /&gt;
* An organization may use rule sets from shared interest groups such as trade associations &lt;br /&gt;
* A component of a distributed organization may acquire 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. &lt;br /&gt;
&lt;br /&gt;
The following scenario examines these different methods of acquisition and the various types of integration and management issues that may arise. &lt;br /&gt;
&lt;br /&gt;
''This scenario uses the (fictitious) car rental company, EU-Rent, used as the case study in the [http://www.omg.org/spec/SBVR/1.0/ Semantics of Business Vocabulary and Business Rules Specification]. The EU legislation discussed is also fictitious, as are the consulting companies CarWise and AutoLaw.''&lt;br /&gt;
&lt;br /&gt;
EU-Rent's corporate HQ deals with CarWise, a consulting company with expertise in managing fleets of vehicles. One service CarWise offers to its clients is negotiating with EU regulators to clarify regulations. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
* A business policy, stating that every car rental must be insured for damages to third parties.&lt;br /&gt;
* 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.&lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
Each tax schedule must have electronic signatures from two EU-Rent employees who are at least at the level of manager.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
* The rule set for car rental insurance (from CarWise), including the basic policy and the supporting rule set.&lt;br /&gt;
* The rule set for electronic compliance documentation (also from CarWise).&lt;br /&gt;
* Its own rule set for building insurance into the basic rental cost.&lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
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.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
Insurance policies that provide separate third-party coverage must not be renewed.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
EU-Rent HQ is also concerned about meeting deadlines for electronic filing. It introduces a new rule that it distributes to operating companies: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
Each electronic compliance document must have its required electronic signatures 48 hours before its filing deadline.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Partially supported by RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
The business rules in this use case express norms which requires the representation of deontic operators for obligations and permissions. Deontic operators are generally represented by modal operators, as in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-Horty-deontic-logic|Horty2001]]]. As was discussed above, for Know and Belief, it is not possible to express modal operators directly within RIF dialects. However, one can use the technique discussed above, of reasoning directly within possible worlds. This is possible within PRD though not within BLD or Core. &lt;br /&gt;
&lt;br /&gt;
Moreover, in a meta programming approach it is possible to express deontic reasoning rules with RIF PRD.  Using this approach, too, one would not be able to use BLD or Core, since some business rules express negated deontic norms.&lt;br /&gt;
&lt;br /&gt;
=== Ruleset Integration for Medical Decision Support ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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 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. &lt;br /&gt;
&lt;br /&gt;
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 [http://www.snomed.org 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. &lt;br /&gt;
&lt;br /&gt;
The following scenario illustrates how rule-interchange would be used in various medical decision support systems to support the following functionalities: &lt;br /&gt;
&lt;br /&gt;
* Improving situation assessment, e.g., determining when a patient needs to be put on medication, or have his medication switched. &lt;br /&gt;
* Prescribing a course of action, e.g., determining which drug is best for a patient in a particular circumstance. &lt;br /&gt;
* Improving event planning, e.g., determining whether a patient can be scheduled for a procedure given the medication that he is currently taking. &lt;br /&gt;
&lt;br /&gt;
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 &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt; system to help him decide when to switch to medications and which drugs to prescribe. The &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt; 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 RIF. Here are two specific examples of such synergistic effects. &lt;br /&gt;
&lt;br /&gt;
''This scenario discusses the fictitious expert systems &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt; 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.'' &lt;br /&gt;
&lt;br /&gt;
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 &amp;lt;tt&amp;gt;HbA1c&amp;lt;/tt&amp;gt; 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 &amp;lt;tt&amp;gt;HbA1c&amp;lt;/tt&amp;gt; level. The following rule from the ''laboratory knowledge base'' suggests that Bob's treatment at that time was not effective: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If a Type II diabetes patient's current level of HbA1c is high, then the patient's current treatment is considered to be ineffective.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD  Presentation Syntax using relations and an event calculus axiomatization:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt;&lt;br /&gt;
    Forall ?Patient ?Treatment ?Level ?T (&amp;lt;br /&amp;gt;&lt;br /&gt;
    ex:holdsAt(ex:ineffective(?Patient ?Treatment) ?T) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:holdsAt(ex:hasDisease(?Patient &amp;quot;diabetesTypeII&amp;quot;) ?T)&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:holdsAt(ex:elevated(levelOf(?Patient &amp;quot;hbA1c&amp;quot; ?Level)) ?T)&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:holdsAt(ex:treatmentPlan(?Treatment ?Patient) ?T)&amp;lt;br /&amp;gt;&lt;br /&gt;
      )&amp;lt;br /&amp;gt;&lt;br /&gt;
   )&amp;lt;br /&amp;gt;&lt;br /&gt;
)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;Note, the example requires the formalization of changeable states which can be represented by an event calculus axiomatization. [[#event-calculus|KS86]]] The EC axioms can then be represented using RIF BLD.   &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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 &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt; 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. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
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.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Based on the recommendation from &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt;, Dr. Rosen switched Bob's prescription to Glucophage and Avandia (rosiglitazone, one of the thiazolidinediones). &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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.). &lt;br /&gt;
&lt;br /&gt;
MEDIC uses a variety of sources in its reasoning, including: &lt;br /&gt;
&lt;br /&gt;
* the pharmaceutical knowledge base, described above &lt;br /&gt;
* the patient databases, which gives the patient record, including the medications a patient is currently taking &lt;br /&gt;
* the hospital medical event protocol knowledge base, which details the protocol used for different medical procedures &lt;br /&gt;
&lt;br /&gt;
In this case, MEDIC uses all three sources, and pulls up the following information: &lt;br /&gt;
&lt;br /&gt;
* Metformin is contraindicated with contrast dye. &lt;br /&gt;
* Metformin is the generic form of Glucophage. &lt;br /&gt;
* Bob is taking Glucophage. &lt;br /&gt;
* The contrast MRI requires as one of its steps injecting the patient with contrast dye. &lt;br /&gt;
&lt;br /&gt;
MEDIC therefore determines that Bob should not be taking the contrast MRI at this time. &lt;br /&gt;
&lt;br /&gt;
For MEDIC to work, the rules from these different sources must be mapped to a unified interchange format. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
The use case requires the formalization of changeable states (fluents) which can be represented by e.g. an event calculus axiomatization &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#event-calculus|KS86]]]. However, to formulate the classical event calculus as a set of Horn clause rules, so that it could be run as a Prolog program, negation as failure is needed, which is not supported by RIF BLD. &lt;br /&gt;
The use case can be represented in RIF PRD which supports changeable states (modifications) and assertions and retractions of knowledge.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Interchanging Rule Extensions to OWL ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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 provide a richer language for describing dependencies between properties (binary predicates), and may also support higher-arity predicates. &lt;br /&gt;
&lt;br /&gt;
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 labeling 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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If MAE X is bounded by Z and MAE Y is also bounded by Z then X is connected to Y.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF Core, RIF BLD and RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
The use case uses RIF SWC to combine RIF Rules with OWL ontologies.&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Vocabulary Mapping for Data Integration ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
* a report on application services and associated servers, databases and networks (from the IT department) &lt;br /&gt;
* a maintenance contracts database (from the finance department) &lt;br /&gt;
* a registry indicating which business processes use which IT services (from the business planning group) &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
First, Vlad creates simple mapping rules to create a uniform, simplified view of the data in terms of a small number of concepts -- Server, Business&amp;lt;tt&amp;gt;&amp;lt;/tt&amp;gt;Process and Dependency. This involves rules such as: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 If x is a ComputeNode in Rack r&lt;br /&gt;
    and Rack r is in Cage c&lt;br /&gt;
    and mc is a MaintenanceContract for Cage c&lt;br /&gt;
       then x is a Server with MaintenanceContract mc&lt;br /&gt;
 &lt;br /&gt;
 If x is a ComputeNode with a NetworkInterface with Port p&lt;br /&gt;
    and app is an Application running on Port p&lt;br /&gt;
       then x is a Server that hosts app&lt;br /&gt;
 &lt;br /&gt;
 If bp is a BusinessProcess that uses Application app&lt;br /&gt;
       then bp has a Dependency on app&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Forall ?X ?MC ?R ?C(&lt;br /&gt;
  ?X[rdf:type-&amp;gt;ex:Server ex:maintenanceContract-&amp;gt;?MC] :- And(&lt;br /&gt;
    ?X[rdf:type-&amp;gt;ex:ComputeNode ex:location-&amp;gt;?R] ?R#ex:Rack &lt;br /&gt;
    ?R[ex:location-&amp;gt;?C] ?C#ex:Cage&lt;br /&gt;
    ?C[ex:maintenanceContract-&amp;gt;?MC] ?MC#ex:MaintenanceContract )) &lt;br /&gt;
&lt;br /&gt;
  Forall ?X ?Ni ?P ?App (&lt;br /&gt;
   ?X[rdf:type-&amp;gt;ex:Server ex:hosts-&amp;gt;?App] :- And( &lt;br /&gt;
     ?X[rdf:type-&amp;gt;ex:ComputeNode ex:networkInterface-&amp;gt;?Ni] &lt;br /&gt;
     ?Ni[ex:port-&amp;gt;?P]  ?P#ex:Port&lt;br /&gt;
     ?App[rdf:type-&amp;gt;ex:Application ex:onPort-&amp;gt;?P])) &lt;br /&gt;
&lt;br /&gt;
  Forall ?App ?BP ( &lt;br /&gt;
   ?BP[ex:dependsOn-&amp;gt;?App] :- &lt;br /&gt;
     ?BP[rdf:type-&amp;gt;ex:BusinessProcess ex:processUses-&amp;gt;?App] )) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt; &lt;br /&gt;
 &lt;br /&gt;
He then creates rules that combine the data across his now simplified data sources, e.g. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 If bp is a BusinessProcess that has a Dependency on Application app&lt;br /&gt;
   and x is a Server with MaintenanceContract mc that hosts Application app&lt;br /&gt;
      then bp has a Dependency on mc&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt;   Forall ?App ?BP ?App ?MC( &lt;br /&gt;
   ?BP[ex:dependsOn-&amp;gt;?MC] :- &amp;lt;&lt;br /&gt;
     ?BP[rdf:type-&amp;gt;ex:BusinessProcess ex:dependsOn-&amp;gt;?App] ?App#ex:Application &lt;br /&gt;
     ?X[rdf:type-&amp;gt;ex:Server ex:hosts-&amp;gt;?App ex:maintenanceContract-&amp;gt;?MC] )) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF BLD and RID PRD'''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== BPEL Orchestration of Rule-Based Web Services ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
The credit evaluation rules are themselves grouped into three rulesets that are executed sequentially. Rules in the first ruleset apply thresholds to several &amp;quot;red flag&amp;quot; quantities in the credit report, such as: &lt;br /&gt;
&lt;br /&gt;
* number of times a payment was 60 days late &lt;br /&gt;
* debt-to-income ratio &lt;br /&gt;
* number of foreclosures or repossessions &lt;br /&gt;
* number of garnishments &lt;br /&gt;
* number of liens &lt;br /&gt;
* bankruptcy &lt;br /&gt;
&lt;br /&gt;
A red flag above the threshold results in denial of credit. &lt;br /&gt;
&lt;br /&gt;
Rules in the second ruleset increment a credit score variable. For example: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 If applicant owns residence then add 40.&lt;br /&gt;
 If applicant rents then add 30.&lt;br /&gt;
 If applicant has lived at current address 2 to 4 years then add 20.&lt;br /&gt;
 If applicant's income is under 20000 then add 10.&lt;br /&gt;
 If applicant's income is between 40000 and 50000 then add 40.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt;Document(&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(prolog_func &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/2007/rif-prolog-builtin-function#)&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt;&lt;br /&gt;
     ex:score(0)&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
     ex:score(?Applicant ?Score) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:increment(?Applicant)&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
      prolog_func:retract(ex:score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
      prolog_func:assert(ex:score(0)).   &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant) :-   &amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:owns(?Applicant)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:retract(ex:score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 40&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(ex:score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant):-   &amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:rents(?Applicant)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:retract(score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 30&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant):-&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:lives(?Applicant ?Date),&amp;lt;br /&amp;gt;&lt;br /&gt;
   $sysTime(?CurrentDateTime)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?CurrentYear = $fn:year-from-dateTime(?CurrentDateTime)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Year = $fn:year-from-dateTime(?Date)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Diff = ?CurrentYear - ?Year&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Diff &amp;gt; 1&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Diff &amp;lt; 5&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:retract(score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 20&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(ex:score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant):-   &amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:income(?Applicant ?Income)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Income &amp;lt; 20000&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:retract(score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 10&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(ex:score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant):-&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:income(?Applicant ?Income)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Income &amp;lt; 50000&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Income &amp;gt; 40000&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:retract(ex:score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 40&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(ex:score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;A goal-driven solution which makes use of assert and retract (not supported by BLD) to update a global score value, which is stored in a fact.&lt;br /&gt;
&amp;lt;/p&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
This use case requires a goal-driven solution which makes use of assert and retract  to update a global score value. Assert and retract are not supported by BLD; indeed, there is no such similar notion within BLD.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Publishing Rules for Interlinked Metadata ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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 &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;imd.example.org. Besides the ground facts, which can be expressed in RDF, the metadata might also have general rules like the following: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 Every science fiction movie is a movie.&lt;br /&gt;
 Every movie produced before 1930 is black and white.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD (Abridged) Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; ?Movie#ex:Movie :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Movie#ex:ScienceFictionMovie.&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ?Movie#ex:BlackWhiteMovie :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Movie#ex:Movie[ex:date -&amp;gt; ?Date]&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Date &amp;lt; &amp;quot;1930&amp;quot;^^xs:dateTime.&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;  &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
Published rules also allow combining data from different sources to exploit this knowledge. Consider an alternative database of movies published at &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;altmd.example.org. In addition to metadata, it again publishes its own rules: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 All movies listed at &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;altmd.example.org but not listed at &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;imd.example.org are independent movies.&lt;br /&gt;
 All movies with budgets below 5 million USD are low-budget movies.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD (Abridged) Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; ?Movie#ex:IndependentMovie :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    listed(?Movie#ex:Movie,&amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//altmd.example.org&amp;gt;)&amp;lt;br /&amp;gt;&lt;br /&gt;
    not(listed(?Movie#ex:Movie,&amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//imd.example.org&amp;gt;)). 	&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ?Movie#ex:LowBudgetMovie :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Movie#ex:Movie [date -&amp;gt; ?Date, budget -&amp;gt; ?Budget]&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Budget &amp;lt; 5000000^^xs:long.&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;  &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 If Charlie is currently attending a public talk according to &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;charlie.example.org/calender.ical&lt;br /&gt;
     then leave him a voicemail message&lt;br /&gt;
 &lt;br /&gt;
 If Charlie is currently in a meeting according to &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;charlie.example.org/calender.ical&lt;br /&gt;
   and the importance is high&lt;br /&gt;
     then call his cell number&lt;br /&gt;
 &lt;br /&gt;
 If Charlie currently has no appointments according to &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;charlie.example.org/calender.ical&lt;br /&gt;
     then call his office number&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD (Abridged) Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; contactInfo(&amp;quot;Charlie&amp;quot; ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    sysTime(?Time)&amp;lt;br /&amp;gt;&lt;br /&gt;
    attending(&amp;quot;Charlie&amp;quot; &amp;quot;talk&amp;quot; ?Time)&amp;lt;br /&amp;gt;&lt;br /&gt;
    contact(&amp;quot;Charlie&amp;quot; &amp;quot;voicemail&amp;quot; ?ContactInfo).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contactInfo(&amp;quot;Charlie&amp;quot; ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    sysTime(?Time)&amp;lt;br /&amp;gt;&lt;br /&gt;
    attending(&amp;quot;Charlie&amp;quot; &amp;quot;meeting&amp;quot; ?Time)&amp;lt;br /&amp;gt;&lt;br /&gt;
    contact(&amp;quot;Charlie&amp;quot; &amp;quot;cell number&amp;quot; ?ContactInfo).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contactInfo(&amp;quot;Charlie&amp;quot;, ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    sysTime(?Time),&amp;lt;br /&amp;gt;&lt;br /&gt;
    not(attending(&amp;quot;Charlie&amp;quot;,?Event, ?Time)),&amp;lt;br /&amp;gt;&lt;br /&gt;
    contact(&amp;quot;Charlie&amp;quot;, &amp;quot;office number&amp;quot;, ?ContactInfo).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 sysTime(?Time) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    % get the actual system time e.g. via a built-in&amp;lt;br /&amp;gt;&lt;br /&gt;
    % or procedural attachment call to Java or C++.&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Time = External(call(java.util.Calendar().getInstance())).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 attending(&amp;quot;Charlie&amp;quot;,&amp;quot;talk&amp;quot;, ?CurrentTime) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    % getEventData would implement the functionality to dynamically access and query&amp;lt;br /&amp;gt;&lt;br /&gt;
    % &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/calender.ical&amp;lt;br /&amp;gt;&lt;br /&gt;
    getEventData(&amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/calender.ical&amp;gt;,?EventTitle,?Type,?StartDate,?EndDate),&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Type = &amp;quot;talk&amp;quot;,&amp;lt;br /&amp;gt;&lt;br /&gt;
    External(op:dateTime-less-than(?CurrentTime,?EndDate),&amp;lt;br /&amp;gt;&lt;br /&gt;
    External(op:dateTime-greater-than(?CurrentTime,?StartDate).&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;        &lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
 attending(&amp;quot;Charlie&amp;quot;,&amp;quot;meeting&amp;quot;, ?CurrentTime) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    getEventData(&amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/calender.ical&amp;gt;,?EventTitle,?Type,?StartDate,?EndDate),&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Type = &amp;quot;meeting&amp;quot;,&amp;lt;br /&amp;gt;&lt;br /&gt;
    External(op:dateTime-less-than(?CurrentTime,?EndDate),&amp;lt;br /&amp;gt;&lt;br /&gt;
    External(op:dateTime-greater-than(?CurrentTime,?StartDate).&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;       &lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contact(&amp;quot;Charlie&amp;quot;, &amp;quot;voicemail&amp;quot;, ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    % retrieve the Voice mail number, e.g. from&amp;lt;br /&amp;gt;&lt;br /&gt;
    % Charlie's vCard, &amp;lt;br /&amp;gt;&lt;br /&gt;
    % e.g. xmlns:vCard = &amp;quot;&amp;lt;nowiki&amp;gt;http://www.w3.org/2001/vcard-rdf/3.0#&amp;quot;&amp;lt;/nowiki&amp;gt;&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard:FN&amp;gt; -&amp;gt; &amp;quot;Charlie&amp;quot;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard_TEL&amp;gt; -&amp;gt; ?Telephone],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf:type&amp;gt; -&amp;gt; &amp;lt;nowiki&amp;gt;&amp;lt;http://www.w3.org/2001/vcard-rdf/3.0#voice&amp;gt;&amp;lt;/nowiki&amp;gt;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf_value&amp;gt; -&amp;gt; ?ContactInfo].&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contact(&amp;quot;Charlie&amp;quot;, &amp;quot;cell number&amp;quot;, ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard:FN&amp;gt; -&amp;gt; &amp;quot;Charlie&amp;quot;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard_TEL&amp;gt; -&amp;gt; ?Telephone],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf:type&amp;gt; -&amp;gt; &amp;lt;nowiki&amp;gt;&amp;lt;http://www.w3.org/2001/vcard-rdf/3.0#cell&amp;gt;&amp;lt;/nowiki&amp;gt;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf_value&amp;gt; -&amp;gt; ?ContactInfo].&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contact(&amp;quot;Charlie&amp;quot;, &amp;quot;office number&amp;quot;, ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard:FN&amp;gt; -&amp;gt; &amp;quot;Charlie&amp;quot;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard_TEL&amp;gt; -&amp;gt; ?Telephone],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf:type&amp;gt; -&amp;gt; &amp;lt;nowiki&amp;gt;&amp;lt;http://www.w3.org/2001/vcard-rdf/3.0#work&amp;gt;&amp;lt;/nowiki&amp;gt;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf_value&amp;gt; -&amp;gt; ?ContactInfo]. &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;intelligent&amp;quot; crawling and search. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
Since negation is not supported by RIF BLD it is not possible to express ''... but not listed at ...''.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Conclusion ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
The goal of the RIF working group is to provide representational interchange formats for processes based on the use of rules and rule-based systems. These formats act as &amp;quot;interlingua&amp;quot; to interchange rules and integrate with other languages, in particular (Semantic) Web mark-up languages. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
In light of this diversity, rather than being a single all-encompassing format, RIF consists 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. &lt;br /&gt;
&lt;br /&gt;
RIF has been designed in such a way that it is possible to create new dialects (extensibility) according to the overall 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. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-Horty-deontic-logic&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
; [Horty2001]&lt;br /&gt;
: ''Agency and Deontic Logic'', John F. Horty, Oxford University Press, 2001.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;event-calculus&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
; [KS86]&lt;br /&gt;
: Kowalski, R.A. and M.J. Sergot, ''A logic-based calculus of events.'' New Generation Computing, 1986. 4: p. 67-95.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;moore&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
; [Moore80]&lt;br /&gt;
: Moore, R.C., ''Reasoning about Knowledge and Action,'' SRI TR-191, 1980.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Appendix: Change Log (Informative) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This appendix summarizes the main changes to this document since its publication as a Working Draft.&lt;br /&gt;
&lt;br /&gt;
Changes since the [http://www.w3.org/TR/rif-ucr/ draft of December 18th, 2008]:&lt;br /&gt;
* [[#Structure_of_RIF|section describing the structure of RIF]] updated with the new RIF documents;&lt;br /&gt;
* all code examples are removed from the document&lt;br /&gt;
* each use cases has a new paragraph at the end which discusses the support of the use case by the current RIF dialects Core, BLD and PRD&lt;br /&gt;
* added an informative change log section&lt;br /&gt;
* flattened the list of requirements removing the distinction between general and basic requirements&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</description>
			<pubDate>Tue, 11 Dec 2012 14:11:34 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Talk:UCR</comments>		</item>
		<item>
			<title>UCR</title>
			<link>http://www.w3.org/2005/rules/wiki/UCR</link>
			<description>&lt;p&gt;Sandro:&amp;#32;making example.org URLs not be links, fix SBVR link&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NUMBEREDHEADINGS__&lt;br /&gt;
{{TR|title=RIF Use Cases and Requirements}}&lt;br /&gt;
&amp;lt;div id='editors'&amp;gt;&lt;br /&gt;
; Editors:&lt;br /&gt;
: Adrian Paschke, Freie Universitaet Berlin&lt;br /&gt;
: Leora Morgenstern, SAIC&lt;br /&gt;
: David Hirtle, National Research Council Canada&lt;br /&gt;
: Allen Ginsberg, Mitre&lt;br /&gt;
: Paula-Lavinia Patranjan, REWERSE&lt;br /&gt;
: Frank &amp;lt;nowiki&amp;gt;McCabe&amp;lt;/nowiki&amp;gt;, Fujitsu&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
; Abstract&lt;br /&gt;
: &amp;lt;div id='abstract'&amp;gt;&amp;lt;p&amp;gt;&amp;lt;/p&amp;gt; &amp;lt;p&amp;gt;&amp;lt;/p&amp;gt; &amp;lt;p&amp;gt;&amp;lt;/p&amp;gt; &amp;lt;p&amp;gt;This document, developed by the [http://www.w3.org/2005/rules/wg Rule Interchange Format (RIF) Working Group], specifies use cases and requirements for the W3C Rule Interchange Format, a family of rule interchange dialects that allows rules to be translated between rule languages and thus transferred between rule systems. &amp;lt;/p&amp;gt; &amp;lt;/div&amp;gt;&lt;br /&gt;
; Status of this Document&lt;br /&gt;
: 3rd revised version of the UCR document&lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/Consortium/Legal/ipr-notice#Copyright Copyright] © 2010 [http://www.w3.org/ W3C]&amp;lt;sup&amp;gt;®&amp;lt;/sup&amp;gt; ([http://www.csail.mit.edu/ MIT], [http://www.ercim.org/ ERCIM], [http://www.keio.ac.jp/ Keio]), All Rights Reserved. W3C [http://www.w3.org/Consortium/Legal/ipr-notice#Legal_Disclaimer liability], [http://www.w3.org/Consortium/Legal/ipr-notice#W3C_Trademarks trademark] and [http://www.w3.org/Consortium/Legal/copyright-documents document use] rules apply.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id='docbody'&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;html&amp;gt;&lt;br /&gt;
&amp;lt;script type=&amp;quot;text/javascript&amp;quot;&amp;gt;/*&amp;lt;![CDATA[*/&lt;br /&gt;
/*&lt;br /&gt;
	Written by Jonathan Snook, http://www.snook.ca/jonathan&lt;br /&gt;
	Add-ons by Robert Nyman, http://www.robertnyman.com&lt;br /&gt;
	Author says &amp;quot;The credit comment is all it takes, no license. Go crazy with it!:-)&amp;quot;&lt;br /&gt;
	From http://www.robertnyman.com/2005/11/07/the-ultimate-getelementsbyclassname/&lt;br /&gt;
*/&lt;br /&gt;
&lt;br /&gt;
var displayed = [];&lt;br /&gt;
displayed[&amp;quot;bld&amp;quot;] = 1;&lt;br /&gt;
displayed[&amp;quot;prd&amp;quot;] = 1;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
function display(syntax,status) {&lt;br /&gt;
  var howmany = 0;&lt;br /&gt;
  if (status=='none') {&lt;br /&gt;
    displayed[syntax] = 0; &lt;br /&gt;
  } else { &lt;br /&gt;
    displayed[syntax] = 1;&lt;br /&gt;
  }&lt;br /&gt;
  for ( i in displayed ) {&lt;br /&gt;
       howmany = howmany + displayed[i];&lt;br /&gt;
  }&lt;br /&gt;
  set_display_by_class('p',syntax,status);&lt;br /&gt;
  if ( howmany == 1 ) {&lt;br /&gt;
      set_display_by_class('b','syntax-head','none');&lt;br /&gt;
  } else {&lt;br /&gt;
      set_display_by_class('b','syntax-head','');&lt;br /&gt;
  }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
function getElementsByClassName(oElm, strTagName, oClassNames){&lt;br /&gt;
	var arrElements = (! (! (strTagName == &amp;quot;*&amp;quot;) || ! (oElm.all)))? oElm.all : oElm.getElementsByTagName(strTagName);&lt;br /&gt;
	var arrReturnElements = new Array();&lt;br /&gt;
	var arrRegExpClassNames = new Array();&lt;br /&gt;
	if(typeof oClassNames == &amp;quot;object&amp;quot;){&lt;br /&gt;
		for(var i=0; !(i&amp;gt;=oClassNames.length); i++){ /*&amp;gt;*/&lt;br /&gt;
			arrRegExpClassNames.push(new RegExp(&amp;quot;(^|\\s)&amp;quot; + oClassNames[i].replace(/\-/g, &amp;quot;\\-&amp;quot;) + &amp;quot;(\\s|$)&amp;quot;));&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
	else{&lt;br /&gt;
		arrRegExpClassNames.push(new RegExp(&amp;quot;(^|\\s)&amp;quot; + oClassNames.replace(/\-/g, &amp;quot;\\-&amp;quot;) + &amp;quot;(\\s|$)&amp;quot;));&lt;br /&gt;
	}&lt;br /&gt;
	var oElement;&lt;br /&gt;
	var bMatchesAll;&lt;br /&gt;
	for(var j=0; !(j&amp;gt;=arrElements.length); j++){ /*&amp;gt;*/&lt;br /&gt;
		oElement = arrElements[j];&lt;br /&gt;
		bMatchesAll = true;&lt;br /&gt;
		for(var k=0; !(k&amp;gt;=arrRegExpClassNames.length); k++){ /*&amp;gt;*/&lt;br /&gt;
			if(!arrRegExpClassNames[k].test(oElement.className)){&lt;br /&gt;
				bMatchesAll = false;&lt;br /&gt;
				break;&lt;br /&gt;
			}&lt;br /&gt;
		}&lt;br /&gt;
		if(bMatchesAll){&lt;br /&gt;
			arrReturnElements.push(oElement);&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
	return (arrReturnElements)&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
function set_display_by_class(el, cls, newValue) {&lt;br /&gt;
   var e = getElementsByClassName(document, el, cls);&lt;br /&gt;
   if (e != null) {&lt;br /&gt;
      for (var i=0; !(i&amp;gt;=e.length); i++) {&lt;br /&gt;
        e[i].style.display = newValue;&lt;br /&gt;
      }&lt;br /&gt;
   }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
function set_display_by_id(id, newValue) {&lt;br /&gt;
   var e = document.getElementById(id);&lt;br /&gt;
   if (e != null) {&lt;br /&gt;
     e.style.display = newValue;&lt;br /&gt;
   }&lt;br /&gt;
}&lt;br /&gt;
/*]]&amp;gt;*/&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/html&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;   &amp;lt;!-- because there seems to be a close-div after the intro --&amp;gt;&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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 existing 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. This mission of RIF is part of W3C's larger goal of enabling the sharing of information in forms suited to machine processing: &lt;br /&gt;
&lt;br /&gt;
*# 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 [http://www.ruleml.org/ RuleML Initiative] and elsewhere. &lt;br /&gt;
*# Rules provide a powerful business logic representation, as business rules, in many modern information systems. &lt;br /&gt;
*# Rules are often the technology of choice for creating maintainable adapters between information systems. &lt;br /&gt;
*# 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. &lt;br /&gt;
&lt;br /&gt;
The purpose of this RIF-UCR document is to describe the use cases that guided the design of RIF and to document the design requirements that were derived from both the use cases and from the basic goals of RIF. RIF-UCR also delivers a structured context for formulating future technical specifications of further RIF dialects. Each dialect targets at a cluster of similar rule languages and enables platform-independent interoperation between them (via interchange of RIF rules). 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.&lt;br /&gt;
&lt;br /&gt;
The RIF-UCR document is structured as follows: Section 2 formulates the overall goals of RIF. Section 3 summarizes the released RIF dialects and the current structure of RIF. Section 4 discusses several important requirements for RIF dialects. Section 5 presents a set of use cases that are representative of the types of application scenarios that RIF is intended to support. The use cases illustrate the utilization of the current RIF dialects.  More importantly, the functionality specified in the use cases, together with the requirements discussed in the previous section, serves as input for both the technical specification of future RIF dialects and for the implementation of various variants of these scenarios by RIF-compliant applications and systems. &lt;br /&gt;
&lt;br /&gt;
Although in this document the discussion of requirements precedes the discussion of the use cases in this document,  the development of the use cases preceded, and in fact motivated, the development of the requirements. In general, it is intended that for each requirement, there is at least one use case, or straightforward modification of a use case, from which that requirement was derived.  There are some exceptions to this rule: some requirements were already defined as constraints in the working group charter, and were not necessarily derived from any specific use case. The fulfillment of such requirements is discussed with respect to the existing RIF dialects. &lt;br /&gt;
&lt;br /&gt;
Note that in fact not all use cases can be represented in a straightforward manner within all RIF dialects. In particular, several use cases cannot be represented within the RIF dialect BLD. This is due first, to the fact that BLD is strictly less expressive than first-order logic (since negation is not expressible), and second, to the fact that some use cases are most naturally represented in languages more powerful than first-order logic, such as modal logics. Following the presentation of each use case in Section 5 is a note indicating in which of the current RIF dialects a use case can be represented naturally, sometimes accompanied by discussion.&lt;br /&gt;
&lt;br /&gt;
It should be noted that even use cases which cannot be represented in a straightforward manner within some RIF dialect, such as BLD, there may be other approaches which will enable representation. For example, although epistemic operators such as &amp;lt;tt&amp;gt;Know&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;Believe&amp;lt;/tt&amp;gt; are most straightforwardly represented within a modal logic, it is generally possible to represent such operators in a first-order logic using a possible-worlds semantics. For certain use cases which cannot be naturally represented within some dialect, the extent to which this can be done will be discussed.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Goals ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
The primary goal of 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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;goal-exchange-of-rules&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
==== Exchange of Rules ====&lt;br /&gt;
&lt;br /&gt;
The primary goal of RIF is to facilitate the exchange of rules. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;goal-w3c-consistency&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
==== Consistency with W3C specifications ====&lt;br /&gt;
&lt;br /&gt;
RIF 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 RIF. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;goal-widescale-adoption&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
==== Widescale Adoption ====&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;network effect&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
Along with the use cases in the next section, these goals motivate the requirements in Section 5.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Structure of RIF ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
RIF is described by a set of documents, each fulfilling a different purpose, and catering to a different audience. The three RIF dialects which can be used to represent RIF use cases are:&lt;br /&gt;
&lt;br /&gt;
* [http://www.w3.org/TR/rif-core RIF Core Dialect], which provides a standard, base level of functionality for interchange&lt;br /&gt;
* [http://www.w3.org/TR/rif-bld RIF Basic Logic Dialect] and [http://www.w3.org/TR/2010/REC-rif-prd-20100622/ RIF Production Rule Dialect] provide extended functionality matching two common classes of rule engines, namely derivation rules and production rules.&lt;br /&gt;
&lt;br /&gt;
Along with these three dialects, RIF consists of related documents: [http://www.w3.org/TR/rif-fld RIF Framework for Logic Dialects], [http://www.w3.org/TR/rif-dtb RIF Datatypes and Built-Ins 1.0], [http://www.w3.org/TR/rif-test RIF Test Cases], [http://www.w3.org/TR/rif-rdf-owl RIF RDF and OWL Compatibility], [http://www.w3.org/TR/rif-ucr/ RIF Use Cases and Requirements], [http://www.w3.org/TR/rif-owl-rl OWL 2 RL in RIF], [http://www.w3.org/2007/OWL/wiki/PlainLiteral rdf:PlainLiteral], [http://www.w3.org/TR/rif-xml-data RIF Combination with XML data], [http://www.w3.org/TR/primer RIF Primer] and [http://www.w3.org/TR/rif-in-rdf/ RIF In RDF]. For an overview on RIF see the [http://www.w3.org/TR/rif-overview RIF Overview].&lt;br /&gt;
&lt;br /&gt;
RIF is designed as a family of RIF dialects as shown in the following Venn diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image: RIF_DIALECTS_VENN.jpg | Venn Diagram of RIF Dialects]]&lt;br /&gt;
&lt;br /&gt;
Each dialect is a collection of components that works together, forming an interlingua. New dialects are needed when no existing dialect provides the required rule-language features for interchange.&lt;br /&gt;
&lt;br /&gt;
The RIF Framework for Logic-based Dialects ([http://www.w3.org/TR/rif-fld RIF-FLD]) describes mechanisms for specifying the syntax and semantics of logic-based RIF dialects through a number of generic concepts. Every logic-based RIF dialect should specialize these general mechanisms or justify why it does not. This specialization may include leaving out some elements of RIF-FLD, to produce its concrete syntax and model-theoretic semantics. Currently, the first two existing RIF dialects are the RIF Basic Logic Dialect (RIF-BLD) and the RIF Production Rules Dialect (RIF-PRD) which is a partial specialization of FLD.&lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/TR/rif-bld RIF-BLD] (Basic Logic Dialect) is a specialization of RIF-FLD capable of representing definite Horn rules with equality enhanced with a number of syntactic extensions to support expressive features such as objects and frames, internationalized resource identifiers (IRIs) as identifiers for concepts, and XML Schema data types.&lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/TR/rif-prd RIF-PRD] (Production Rules Dialect) specifies a production rules dialect to enable the interchange of production rules. The condition language of RIF PRD is defined in Core as a common subset of RIF BLD and RIF PRD. &lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/TR/rif-core RIF-Core] (Core Dialect) specifies a common subset of RIF-BLD and RIF-PRD which includes RIF-DTB.&lt;br /&gt;
&lt;br /&gt;
The normative syntax for RIF dialects is a concrete XML syntax. A non-normative presentation syntax is additionally specified for each dialect, to allow a more easily readable and compact presentation of language fragments (such as examples).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Requirements ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-semantic-tagging&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
The goals and use cases motivate a number of requirements for a Rule Interchange Format. The Working Group has approved the following requirements.  &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-implementability&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Implementability ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-semantic-precision&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Semantic precision ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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 extend RIF core.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-extensible&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Extensible Format ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''It must be possible to create new RIF dialects which extend existing dialects (thus providing backward compatibility) and are handled gracefully by systems which support existing dialects (thus providing forward compatibility).'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-translators&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Translators ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-standard-components&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Standard components ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-coverage&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Rule language coverage ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''Because of the great diversity of rule languages, no single interchange language is likely to be able to bridge between all. Instead, RIF provides dialects each of which is targeted at a cluster of similar rule languages. RIF must allow intra-dialect interoperation, i.e. interoperability between semantically similar rule languages (via interchange of RIF rules) within one dialect, and should support inter-dialect interoperation, i.e. interoperation between dialects with maximum overlap.''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-compliance-model&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Compliance model ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''The RIF specifications must provide clear conformance criteria that define what is or is not a conformant RIF implementation.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-default-behavior&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Default behavior ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-different-semantics&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Different semantics ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must cover rule languages having different semantics.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-dialects&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Limited number of dialects ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must have a standard core, and a limited number of standard dialects based upon that core.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-comments&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Embedded comments ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must be able to pass comments.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-metadata&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Embedded metadata ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must support metadata such as author and rule name.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-owl-data&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== OWL data ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must cover OWL knowledge bases as data where compatible with RIF semantics.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-rdf-data&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== RDF data ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must cover RDF triples as data where compatible with RIF semantics.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-dialect-identification&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Dialect Identification ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''The semantics of a RIF document must be uniquely determined by the content of the document, without out-of-band data.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-xml-syntax&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== XML syntax ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must have an XML syntax as its primary normative syntax.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-xml-types&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== XML types ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''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 [http://www.w3.org/2005/rules/wg/charter#datatype0 Datatype support]. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-merge&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Merge Rule Sets ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must support the ability to merge rule sets.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-rulesets&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Identify Rule Sets ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF must support the identification of rule sets.''  &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-xml-data&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== XML data ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''RIF should be able to accept XML elements as data.'' &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;req-rif-text&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=== Internationalized text ===&lt;br /&gt;
&lt;br /&gt;
''RIF must support internationalized text — that is, text that additionally conveys information in terms of a language tag.''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Use Cases ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
A use case for RIF consists of a description of a problem together with a solution that either uses an existing RIF dialect or requires the specification of a new RIF dialect.&lt;br /&gt;
&lt;br /&gt;
The set of use cases is intended to do the following:&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;motivate the need for a RIF in a broad range of application domains and industrial sectors;&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;provide scenarios that motivate the design of RIF and explain the benefits of a RIF in such scenarios;&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;guide users to RIF's specified dialects; and&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;motivate the working group's set of requirements for a RIF.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The set of use cases were developed over several years.&lt;br /&gt;
Nearly [http://www.w3.org/2005/rules/wg/wiki/Use_Cases fifty use cases] documenting the need for a RIF were originally submitted by the working group members. These were grouped into  general categories and then synthesized as much as possible. The goal was to come up with a relatively small set of use cases that would cover a broad range of possible requirements. In addition,  it was desired that the use cases refer to popular application domains and industrial sectors. For every use case we will briefly discuss the coverage of the use case by the existing three RIF dialects (Core, BLD, and PRD). &lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- do not skip a line &lt;br /&gt;
&amp;lt;html&amp;gt;&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;border: 1px dotted black; padding:0.5em; margin: 1em; &amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;The button below can be used to show or hide the RIF examples.&amp;lt;/p&amp;gt;&amp;lt;form action=&amp;quot;&amp;quot;&amp;gt;&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;input id=&amp;quot;hide-rif&amp;quot; type=&amp;quot;button&amp;quot; value=&amp;quot;Hide Examples&amp;quot; style=&amp;quot;display:none&amp;quot;&lt;br /&gt;
  onclick=&amp;quot;display('rif', 'none');&lt;br /&gt;
           set_display_by_id('hide-rif', 'none'); &lt;br /&gt;
           set_display_by_id('show-rif', '');&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;input id=&amp;quot;show-rif&amp;quot; type=&amp;quot;button&amp;quot; value=&amp;quot;Show Examples&amp;quot; &lt;br /&gt;
  onclick=&amp;quot;display('rif','');&lt;br /&gt;
     set_display_by_id('hide-rif', ''); &lt;br /&gt;
     set_display_by_id('show-rif', 'none');&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&amp;lt;/form&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;p&amp;gt;&lt;br /&gt;
&amp;lt;/html&amp;gt;--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Negotiating eBusiness Contracts Across Rule Platforms ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This use case illustrates a fundamental use of RIF: to supply 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, and in particular without concern that a business partner does not have the same vendor technology. It also illustrates the fact that RIF can be used to foster collaborative work. Each developer and stakeholder can make a contribution to the joint effort without being forced to adopt the tools or platforms of the other contributors. &lt;br /&gt;
&lt;br /&gt;
John is negotiating an electronic business contract regarding the supply of various types of items that Jane's company is manufacturing. Jane and John interchange the contract-related data and rules involved in the negotiation 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 goods and services involved - in this case an XML schema and appropriate test XML documents are interchanged with their rules. Since John and Jane run applications based on different vendors' rule engines and rule languages, they interchange the rules using RIF; both vendors used can interpret the XML schema and data, and produce the results as an amended XML document. John's company defines its purchase orders in terms of an XML description of goods, packaging, delivery location and date with delivery and payment rules. A rule proposed by John might be the following: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If an item is perishable and it is delivered to John more than 10 days after the scheduled delivery date then the item will be rejected by him.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
This rule set can be adequately represented in RIF Core either using (ordered) relations as e.g. in standard Logic Programming, unordered relations using named arguments, or in a more object-oriented encoding using frames.&amp;lt;br /&amp;gt;   &lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
''Ordered representation in RIF Core presentation syntax using relations:'' &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&lt;br /&gt;
 &lt;br /&gt;
  Group &lt;br /&gt;
  (&lt;br /&gt;
      Forall ?item ?deliverydate ?scheduledate ?diffdays (&lt;br /&gt;
      ex:reject(&amp;quot;John&amp;quot; ?item) :-&lt;br /&gt;
          ex:perishable(?item)&lt;br /&gt;
          ex:delivered(?item ?deliverydate &amp;quot;John&amp;quot;)&lt;br /&gt;
          ex:scheduled(?item ?scheduledate)&lt;br /&gt;
          ?diffdays = External(func:days-from-duration(&lt;br /&gt;
                                  External(func:subtract-dateTimes(?deliverydate ?scheduledate))  &lt;br /&gt;
                               )) &lt;br /&gt;
          External(pred:numeric-greater-than(?diffdays  10)) &lt;br /&gt;
      ) &lt;br /&gt;
   ) &lt;br /&gt;
) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
Note, the nesting of external built-in functions and operations and the assignment/binding of (intermediate) result (sets) from functions to variables by equality in this example.&amp;lt;br /&amp;gt;    &lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
''Unordered representation in RIF Core presentation syntax using namened arguments:'' &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#) &lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#) &lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#) &lt;br /&gt;
 &lt;br /&gt;
  Group &lt;br /&gt;
  ( &lt;br /&gt;
      Forall ?item ?deliverydate ?scheduledate ?diffdays ( &lt;br /&gt;
      ex:reject(ex:ware -&amp;gt; ?item ex:receiver -&amp;gt; &amp;quot;John&amp;quot;) :- &lt;br /&gt;
         ex:perishable(ex:ware -&amp;gt; ?item) &lt;br /&gt;
         ex:delivered(ex:ware -&amp;gt; ?item  ex:datetime -&amp;gt; ?deliverydate  ex:receiver -&amp;gt; &amp;quot;John&amp;quot;) &lt;br /&gt;
         ex:scheduled(ex:datetime -&amp;gt; ?scheduledate  ex:ware -&amp;gt; ?item) &lt;br /&gt;
         ?diffdays = External(func:days-from-duration( &lt;br /&gt;
                                  External(func:subtract-dateTimes(?deliverydate ?scheduledate))  &lt;br /&gt;
                               )) &lt;br /&gt;
          External(pred:numeric-greater-than(?diffdays  10)) &lt;br /&gt;
      ) &lt;br /&gt;
   ) &lt;br /&gt;
) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
Note, the arbitrarily unordered named argument arguments of the user-defined relations, in contrast to external built-in functions and operations, which must have a predefined order. &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
''Object-Oriented Representation in RIF Core presentation syntax using frames:'' &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt;  Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#) &lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#) &lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#) &lt;br /&gt;
 &lt;br /&gt;
  Group &lt;br /&gt;
  ( &lt;br /&gt;
      Forall ?item ?deliverydate ?scheduledate ?diffdays ( &lt;br /&gt;
      ?item[ex:status -&amp;gt; &amp;quot;rejected&amp;quot;] :- &lt;br /&gt;
         ?item[ex:perishable -&amp;gt; true]  &lt;br /&gt;
         ?item[ex:deliveredOn -&amp;gt; ?deliverydate ex:delivered -&amp;gt; &amp;quot;John&amp;quot;]  &lt;br /&gt;
         ?item[ex:scheduledOn -&amp;gt; ?scheduledate ex:delivered -&amp;gt; &amp;quot;John&amp;quot;]  &lt;br /&gt;
         External(pred:numeric-greater-than(         &lt;br /&gt;
             External(func:days-from-duration( &lt;br /&gt;
                                  External(func:subtract-dateTimes(?deliverydate ?scheduledate))  &lt;br /&gt;
                      )) &lt;br /&gt;
             10 &lt;br /&gt;
         ) &lt;br /&gt;
      ) &lt;br /&gt;
   ) &lt;br /&gt;
) &lt;br /&gt;
&amp;lt;/code&amp;gt;  &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Jane replies with some suggested rule changes: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
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 then a discount of 18.7% will be applied to the delivered item.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
''Representation in RIF Core presentation syntax using positional relations:'' &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#) &lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#) &lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#) &lt;br /&gt;
 &lt;br /&gt;
  Group &lt;br /&gt;
  ( &lt;br /&gt;
     Forall ?item ?deliverydate ?scheduledate ?diffdays ( &lt;br /&gt;
     ex:discount(&amp;quot;John&amp;quot; ?item 18.7 ) :- &lt;br /&gt;
           ex:perishable(?item) &lt;br /&gt;
           ex:delivered(?item ?deliverydate &amp;quot;John&amp;quot;) &lt;br /&gt;
           ex:scheduled(?item ?scheduledate) &lt;br /&gt;
           ?diffdays = External(func:days-from-duration( &lt;br /&gt;
                                  External(func:subtract-dateTimes(?deliverydate ?scheduledate))  &lt;br /&gt;
                               )) &lt;br /&gt;
           External(pred:numeric-greater-than(?diffdays  7)) &lt;br /&gt;
           External(pred:numeric-less-than(?diffdays  14)) &lt;br /&gt;
     ) &lt;br /&gt;
   ) &lt;br /&gt;
) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binding of the intermeditate results to the variable &amp;quot;?diffdays&amp;quot; avoids repetition, as it used twice in the subsequent rule conditions. As demonstrated in the previous examples, similar representations for this rule can be given using slots or frames and as a production rule which asserts the conclusion as a new fact. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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 order and determine contract compliance. &lt;br /&gt;
&lt;br /&gt;
Future requests for the supply of items by John's company are defined on their purchasing web site, as the appropriate XML schema and a RIF ruleset (or rulesets). This allows Jane's company and its competitors to respond electronically with XML cost sheets. Suppliers respond with multiple cost sheets with different variations on the RIF rules proposed by John's company, allowing John's company to review the alternative rules with their associated costs to determine whether they, as a business, would benefit by relaxing or adding new rules as proposed by suppliers. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by: RIF Core, RIF BLD, RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
The rules of this use case can be adequately represented in RIF Core (and BLD and PRD) either using (ordered) relations, as e.g. in standard Logic Programming, unordered relations, using named arguments, or in a more object-oriented encoding using frames. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Negotiating eCommerce Transactions Through Disclosure of Buyer and Seller Policies and Preferences ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This use case concerns the ability of parties involved in formal transactions or procedures, e.g., credit card authorization of a purchase, access of private medical records, etc., to express and protect their interests within a policy-governed framework. The goal is to formally encode the preferences, priorities, responses, etc., of the parties in such a way that the overall policy can work as intended while providing opportunity for automatic negotiation of terms when allowed by the policy. Utilization of RIF in this use case would extend the scope of this technology, affording a higher degree of interoperability, as well as enabling re-use and sharing of preferences, etc., through interchange. The detailed scenario below shows how this would work. &lt;br /&gt;
&lt;br /&gt;
Alice wants to buy a device at an online site called &amp;quot;eShop.&amp;quot; Alice employs software called &amp;quot;Emptor&amp;quot; that functions as automated negotiating agent for buyers. eShop employs software called &amp;quot;Venditor&amp;quot; as automated negotiating agent for sellers. &lt;br /&gt;
&lt;br /&gt;
Alice's and eShop's policies describe who they trust and for what purposes. The negotiation is based on the policies, 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. &lt;br /&gt;
&lt;br /&gt;
Policies are themselves subject to access control. Thus, rule interchange is necessarily done during negotiation and (in general) depends on the current level of trust that the systems have on each other. Since Emptor and Venditor might use different rule languages and/or engines for evaluating (own and imported) rules, a (standard) rule interchange format (RIF) needs to be employed for enabling the rule interchange between the two systems. &lt;br /&gt;
&lt;br /&gt;
When Alice clicks on a &amp;quot;buy it&amp;quot; button at the 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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
In order to grant access a buyer must provide valid credit card information together with delivery information (address, postal code, city, and country).&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF Core presentation syntax using relations and frames in combination: &amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&lt;br /&gt;
&lt;br /&gt;
  Group&lt;br /&gt;
  (&lt;br /&gt;
    Forall ?buyer ?creditCard ?address (&lt;br /&gt;
    ex:permit_access(&amp;quot;eShop&amp;quot; ?buyer) :-&lt;br /&gt;
      ex:provide(&amp;quot;eShop&amp;quot; ?buyer)&lt;br /&gt;
      ?buyer[ex:card -&amp;gt; ?creditCard ex:deliveryAddr -&amp;gt; ?address]&lt;br /&gt;
      ex:valid_payment_method(?creditCard)&lt;br /&gt;
      ex:valid_delivery_address(?address)&lt;br /&gt;
    )   &lt;br /&gt;
 &lt;br /&gt;
    Forall ?type ?person ?first ?last ?number ?code ?date ?month ?year (&lt;br /&gt;
    ex:valid_payment_method(?card)   :-&lt;br /&gt;
        ?card[type -&amp;gt; ?type&lt;br /&gt;
              ex:holder -&amp;gt; ?person  &lt;br /&gt;
              ex:number -&amp;gt; ?number &lt;br /&gt;
              ex:code -&amp;gt; ?code&lt;br /&gt;
              ex:expiry -&amp;gt; ?date]&lt;br /&gt;
        ?person[ex:lastname -&amp;gt; ?last ex:firstname -&amp;gt; ?first]&lt;br /&gt;
        ?date[ex:month -&amp;gt; ?month ex:year -&amp;gt; ?year]&lt;br /&gt;
        ex:credential(?type ?person ?number ?code ?date)&lt;br /&gt;
    ) &lt;br /&gt;
 &lt;br /&gt;
    Forall ?address ?last ?first ?street ?strname ?number ?code ?city ?country (&lt;br /&gt;
    ex:valid_delivery_address(?address)   :-&lt;br /&gt;
       ?address[ex:name -&amp;gt; ?person ex:street -&amp;gt; ?street ex:postal_code -&amp;gt; ?code ex:city -&amp;gt; ?city ex:country -&amp;gt; ?country ]&lt;br /&gt;
       ?person[ex:lastname -&amp;gt; ?last ex:firstname -&amp;gt; ?first] &lt;br /&gt;
       ?street[name -&amp;gt; ?strname ex:number -&amp;gt; ?number] &lt;br /&gt;
       ex:declaration(?person ?street ?number ?code ?city ?country)&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
  )&lt;br /&gt;
)&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that in this example relational representation is used in combination with frame representation. Such mixing of representation styles is supported by RIF. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Rules express compactly possible ways in which a resource can be accessed; by exchanging them negotiations are shorter and privacy protection is improved. In the 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 and required information to disclose. &lt;br /&gt;
&lt;br /&gt;
For determining whether Venditor's request for information is consistent with Alice's policy, Emptor takes its rules into account, which state for example: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
Disclose Alice's credit card information only to online shops belonging to the Better Business Bureau.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF Core presentation syntax: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&lt;br /&gt;
&lt;br /&gt;
  Group&lt;br /&gt;
  (&lt;br /&gt;
    Forall ?Shop ?card ?Credential ?Buyer  (&lt;br /&gt;
      ex:provide(?Shop ?Buyer )  :-  &lt;br /&gt;
         ?Buyer[ex:card -&amp;gt; ?creditCard ex:deliveryAddr -&amp;gt; ?address]&lt;br /&gt;
         ex:belongs_to(?Shop  &amp;quot;Better Business Bureau&amp;quot;) &lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
    Forall ?deliveryAddr ?card ?Date ?Person ?Street  (&lt;br /&gt;
      ex:Alice[ex:card -&amp;gt; ?card ex:deliveryAddr -&amp;gt; ?deliveryAddr] :-&lt;br /&gt;
                  ?Date = ex:Date[ex:month -&amp;gt; 12 ex:year -&amp;gt; 2012]&lt;br /&gt;
                  ?Person = ex:Person[ex:lastname -&amp;gt; &amp;quot;Sure&amp;quot; ex:firstname -&amp;gt; &amp;quot;Alice&amp;quot;]&lt;br /&gt;
                  ?Street = ex:Street[name -&amp;gt; &amp;quot;North Street&amp;quot; number -&amp;gt; 111]&lt;br /&gt;
                  ?card= ex:Card[ ex:type -&amp;gt; &amp;quot;Visa&amp;quot;&lt;br /&gt;
                                  ex:holder -&amp;gt;  ?Person &lt;br /&gt;
                                  ex:number -&amp;gt; &amp;quot;123456789&amp;quot; &lt;br /&gt;
                                  ex:code -&amp;gt; &amp;quot;123&amp;quot;&lt;br /&gt;
                                  ex:expiry -&amp;gt; ?Date &lt;br /&gt;
                                 ]&lt;br /&gt;
                  ?deliveryAddr = ex:DeliveryAddress[ ex:name -&amp;gt; ?Person &lt;br /&gt;
                                                      ex:street -&amp;gt; ?Street&lt;br /&gt;
                                                      ex:postal_code -&amp;gt; &amp;quot;NE3456&amp;quot; &lt;br /&gt;
                                                      ex:city -&amp;gt; &amp;quot;New York&amp;quot; &lt;br /&gt;
                                                      ex:country -&amp;gt; &amp;quot;USA&amp;quot; &lt;br /&gt;
                                                    ]&lt;br /&gt;
     )&lt;br /&gt;
&lt;br /&gt;
   )&lt;br /&gt;
)&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
By disclosing (interchanging) the above given rule, Emptor asks Venditor to provide credentials saying that it belongs to the Better Business Bureau, Alice's most trusted source of information on online shops. eShop has such a credential and its policy contains a rule stating to release it to any potential purchaser. Hence, Venditor passes the credential to Emptor. Emptor is now ready to disclose Alice's credit card information to Venditor but it still must check whether disclosing all the information does not break Alice's denial constraints. Alice has stated two constraints stating: &lt;br /&gt;
 &lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
For anonymity reasons, never provide both her birth date and postal code.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
The current RIF dialects do not specify explicit constructs for integrity constraints. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For this purchase, Alice birthdate is no issue. Thus, Alice's constraints are respected. Emptor therefore provides Alice's credit card information to Venditor. &lt;br /&gt;
&lt;br /&gt;
Companies that provide software such as Venditor and Emptor would make use of RIF in a number of ways. The rules 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 work together in real-time. When these two systems need to exchange policy or preference information of their respective clients they would use RIF to enable the interchange in real-time. When Venditor sends its initial policy information to Emptor it uses RIF. Emptor takes that policy and translates it from RIF to its internal representation in order to determine what it needs to do. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Not supported by the current RIF dialects (Core, BLD, PRD) '''&lt;br /&gt;
&lt;br /&gt;
Current RIF dialects  do not specify explicit constructs for integrity constraints; thus, this use case is not adequately supported by any of these dialects. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Collaborative Policy Development for Dynamic Spectrum Access ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This use case demonstrates how RIF leads to increased flexibility in matching the goals of end-users of a service/device, with the goals of providers and regulators of such services/devices. RIF can do that because it enables deployment of third party systems that can generate various suitable interpretations and/or translations of the sanctioned rules governing a service/device. &lt;br /&gt;
&lt;br /&gt;
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 a device to absorb the rules defining the policies of a region, or the operational protocols required to dynamically access available spectrum, is contingent upon those rules being in a form that the device can use, as well as their being tailored to work with devices in the same class having different capabilities. &lt;br /&gt;
&lt;br /&gt;
In this use-case we suppose a region adopts a policy that allows certain wireless devices to opportunistically use frequency bands that are normally reserved for certain high-priority users. ([http://europa.eu.int/eur-lex/lex/LexUriServ/site/en/oj/2005/l_187/l_18720050719en00220024.pdf The decision] by the European Union to allow &amp;quot;Dynamic Frequency Selection&amp;quot; (DFS) use of the 5 GHz frequency band by wireless systems, a band intermittently used by military and weather radar, is a recent example.) &lt;br /&gt;
&lt;br /&gt;
Suppose the policy states: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
A wireless device can transmit on a 5 GHz band if no priority user is currently using that band.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
&amp;lt;!-- Representation in RIF Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt; &lt;br /&gt;
     Forall ?device ?band ?user (&amp;lt;br /&amp;gt;&lt;br /&gt;
     ex:transmit(?device ?band 5) :- &amp;lt;br /&amp;gt;&lt;br /&gt;
         not(ex:used(?user ?band))&amp;lt;br /&amp;gt;&lt;br /&gt;
      )&amp;lt;br /&amp;gt;&lt;br /&gt;
   )&amp;lt;br /&amp;gt;&lt;br /&gt;
)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt; --&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;Note, since default negation (not) such as negation as failure is not supported by RIF BLD there is no adequate way to represent that &amp;quot;no priority user is currently using the band&amp;quot;. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
How does a device know that no priority user is currently using a band it wants to use? The answer will depend on the specific capabilities of the device. One type of device may answer this question by sensing the amount of energy it is receiving on that band. That is, it might employ the rule: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If no energy is detected on a desired band then assume no other device is using the band.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt;&lt;br /&gt;
      Forall ?device ?band ?level  (&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:used(?device ?band) :- &amp;lt;br /&amp;gt;&lt;br /&gt;
                   ex:detect(ex:energy(?level ?band))&amp;lt;br /&amp;gt;&lt;br /&gt;
                   External(pred:numeric-greater-than(?level  0))&amp;lt;br /&amp;gt;&lt;br /&gt;
      )&amp;lt;br /&amp;gt;&lt;br /&gt;
   )&amp;lt;br /&amp;gt;&lt;br /&gt;
)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;Note, the engergy detection function would require an external call for sensing  the level of energy. Such procedural attachments cannot be specified in BLD. Reaction rules provide event detection capabilities. &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A second type of device, may get information from a control channel that lets it know whether the desired band is being used by a priority user. That is, it might employ the rule: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If no control signal indicating use of a desired band by a priority user is detected then assume the band is available.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt;&lt;br /&gt;
      Forall ?device ?band ?user  (&amp;lt;br /&amp;gt;&lt;br /&gt;
       ex:used(?device ?band) :- &amp;lt;br /&amp;gt;&lt;br /&gt;
                   ex:detect(ex:signal(?user ?band))&amp;lt;br /&amp;gt;&lt;br /&gt;
                   ex:priority(?user,&amp;quot;high&amp;quot;).&amp;lt;br /&amp;gt;&lt;br /&gt;
      )&amp;lt;br /&amp;gt;&lt;br /&gt;
   )&amp;lt;br /&amp;gt;&lt;br /&gt;
)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
So each type of device will need to employ different &amp;quot;interpretations&amp;quot; or &amp;quot;operational definitions&amp;quot; of the policy in question. &lt;br /&gt;
&lt;br /&gt;
Now assume that there are 10 manufacturers of these 2 different types of wireless devices. Suppose that each of these manufacturers uses a distinct rule-based platform in designing its devices. Each manufacturer needs to write 2 interpretations of the policy (for each of the two types of device). That means that 20 different versions of the policy must be written, tested and maintained. &lt;br /&gt;
&lt;br /&gt;
Enter RIF. The 10 manufacturers form a consortium. This is a third-party group that is responsible for translating regional policies into RIF. When it does so, however, it provides different versions corresponding to the possible interpretations (operational definitions) of the policy. So in this case, 2 RIF versions of the DFS policy are provided for the 2 types of device mentioned above. Each of these RIF specifications can be automatically translated into the appropriate rule-platform provided a RIF-Compiler for the target device architecture exists. Clearly it will be in the interest of each device manufacturer to develop such compilers. That is because the manufacturer only needs to develop such a compiler ''once'' for every architecture it owns. Contrast that investment with having to produce, test, and maintain different versions of various policies over the lifetime of a product. &lt;br /&gt;
&lt;br /&gt;
This arrangement also allows the overall process to be organized in a fashion that maintains the natural division of labor in the corresponding division of artifacts produced by that labor: the policy and its various interpretations are written and maintained in platform-independent artifacts (RIF); knowledge about how to translate from 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. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Partly supported by: RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
The energy detection function specified in this use case would require an external call to a device that would sense  the level of energy. Such procedural attachments cannot be specified in the current RIF dialects. Reaction rules support (complex) event detection capabilities on, e.g., event streams over sensor data. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This use case is not supported at all by RIF BLD, and by extension, by RIF Core. These dialects do not support negation, and&lt;br /&gt;
the use case makes explicit mention of negation, e.g. for representing that &amp;quot;no priority user is currently using the band.&amp;quot;&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Access to Business Rules of Supply Chain Partners ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If inspector believes vehicle is repairable then process as repair otherwise process as total loss.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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). &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
How such a unified 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, RIF permits a unified dynamic view of the business rule logic no matter what the original form of the rules. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Not supported, in a straightforward manner, by the current RIF dialects'''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
BLD and PRD do not support modal operators or predicates on quoted sentences; therefore standard representations of knowledge, belief, and/or uncertainty cannot be specified in BLD and PRD. Even without such constructs, it can be possible to represent knowledge or belief using the semantics of possible worlds &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#moore|Moore1980]]]. That is, one can get the effect of saying that an agent A believes proposition P by saying that P holds in all words that are belief-accessible to P. For example, to get the effect of saying &lt;br /&gt;
&amp;lt;pre width=130&amp;gt;Believe(john,overCreditLimit(bill,t))&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
 one says instead&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
holds(overCreditLimit(bill),t1) :- beliefAccessible(john,t,t1)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The translation between sentences involve operators such as Know and Believe and sentences that make direct use of possible worlds relies on the possible-worlds semantics, which posits properties on the knowledge-accessibility or belief-accessibility relation. These relations correspond to axioms on the Know and Believe operators.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
Such a strategy could work, to a certain extent, in RIF PRD, but would not work in RIF BLD. This is because expressing the standard axioms on belief or knowledge would require the use of negation, which is not supported by BLD.&lt;br /&gt;
&lt;br /&gt;
For both PRD and BLD there is an additional consideration, which is that the notion of reification is in general not supported by the dialects of RIF.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Managing Inter-Organizational Business Policies and Practices ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
* An organization may buy rule sets from expert sources &lt;br /&gt;
* An organization may use rule sets from shared interest groups such as trade associations &lt;br /&gt;
* A component of a distributed organization may acquire 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. &lt;br /&gt;
&lt;br /&gt;
The following scenario examines these different methods of acquisition and the various types of integration and management issues that may arise. &lt;br /&gt;
&lt;br /&gt;
''This scenario uses the (fictitious) car rental company, EU-Rent, used as the case study in the [http://www.omg.org/spec/SBVR/1.0/ Semantics of Business Vocabulary and Business Rules Specification]. The EU legislation discussed is also fictitious, as are the consulting companies CarWise and AutoLaw.''&lt;br /&gt;
&lt;br /&gt;
EU-Rent's corporate HQ deals with CarWise, a consulting company with expertise in managing fleets of vehicles. One service CarWise offers to its clients is negotiating with EU regulators to clarify regulations. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
* A business policy, stating that every car rental must be insured for damages to third parties.&lt;br /&gt;
* 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.&lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
Each tax schedule must have electronic signatures from two EU-Rent employees who are at least at the level of manager.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
* The rule set for car rental insurance (from CarWise), including the basic policy and the supporting rule set.&lt;br /&gt;
* The rule set for electronic compliance documentation (also from CarWise).&lt;br /&gt;
* Its own rule set for building insurance into the basic rental cost.&lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
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.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
Insurance policies that provide separate third-party coverage must not be renewed.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
EU-Rent HQ is also concerned about meeting deadlines for electronic filing. It introduces a new rule that it distributes to operating companies: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
Each electronic compliance document must have its required electronic signatures 48 hours before its filing deadline.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Partially supported by RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
The business rules in this use case express norms which requires the representation of deontic operators for obligations and permissions. Deontic operators are generally represented by modal operators, as in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-Horty-deontic-logic|Horty2001]]]. As was discussed above, for Know and Belief, it is not possible to express modal operators directly within RIF dialects. However, one can use the technique discussed above, of reasoning directly within possible worlds. This is possible within PRD though not within BLD or Core. &lt;br /&gt;
&lt;br /&gt;
Moreover, in a meta programming approach it is possible to express deontic reasoning rules with RIF PRD.  Using this approach, too, one would not be able to use BLD or Core, since some business rules express negated deontic norms.&lt;br /&gt;
&lt;br /&gt;
=== Ruleset Integration for Medical Decision Support ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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 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. &lt;br /&gt;
&lt;br /&gt;
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 [http://www.snomed.org 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. &lt;br /&gt;
&lt;br /&gt;
The following scenario illustrates how rule-interchange would be used in various medical decision support systems to support the following functionalities: &lt;br /&gt;
&lt;br /&gt;
* Improving situation assessment, e.g., determining when a patient needs to be put on medication, or have his medication switched. &lt;br /&gt;
* Prescribing a course of action, e.g., determining which drug is best for a patient in a particular circumstance. &lt;br /&gt;
* Improving event planning, e.g., determining whether a patient can be scheduled for a procedure given the medication that he is currently taking. &lt;br /&gt;
&lt;br /&gt;
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 &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt; system to help him decide when to switch to medications and which drugs to prescribe. The &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt; 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 RIF. Here are two specific examples of such synergistic effects. &lt;br /&gt;
&lt;br /&gt;
''This scenario discusses the fictitious expert systems &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt; 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.'' &lt;br /&gt;
&lt;br /&gt;
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 &amp;lt;tt&amp;gt;HbA1c&amp;lt;/tt&amp;gt; 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 &amp;lt;tt&amp;gt;HbA1c&amp;lt;/tt&amp;gt; level. The following rule from the ''laboratory knowledge base'' suggests that Bob's treatment at that time was not effective: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If a Type II diabetes patient's current level of HbA1c is high, then the patient's current treatment is considered to be ineffective.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD  Presentation Syntax using relations and an event calculus axiomatization:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Document(&lt;br /&gt;
&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt;&lt;br /&gt;
    Forall ?Patient ?Treatment ?Level ?T (&amp;lt;br /&amp;gt;&lt;br /&gt;
    ex:holdsAt(ex:ineffective(?Patient ?Treatment) ?T) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:holdsAt(ex:hasDisease(?Patient &amp;quot;diabetesTypeII&amp;quot;) ?T)&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:holdsAt(ex:elevated(levelOf(?Patient &amp;quot;hbA1c&amp;quot; ?Level)) ?T)&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:holdsAt(ex:treatmentPlan(?Treatment ?Patient) ?T)&amp;lt;br /&amp;gt;&lt;br /&gt;
      )&amp;lt;br /&amp;gt;&lt;br /&gt;
   )&amp;lt;br /&amp;gt;&lt;br /&gt;
)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;Note, the example requires the formalization of changeable states which can be represented by an event calculus axiomatization. [[#event-calculus|KS86]]] The EC axioms can then be represented using RIF BLD.   &lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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 &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt; 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. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
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.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Based on the recommendation from &amp;lt;tt&amp;gt;AutoDoc&amp;lt;/tt&amp;gt;, Dr. Rosen switched Bob's prescription to Glucophage and Avandia (rosiglitazone, one of the thiazolidinediones). &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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.). &lt;br /&gt;
&lt;br /&gt;
MEDIC uses a variety of sources in its reasoning, including: &lt;br /&gt;
&lt;br /&gt;
* the pharmaceutical knowledge base, described above &lt;br /&gt;
* the patient databases, which gives the patient record, including the medications a patient is currently taking &lt;br /&gt;
* the hospital medical event protocol knowledge base, which details the protocol used for different medical procedures &lt;br /&gt;
&lt;br /&gt;
In this case, MEDIC uses all three sources, and pulls up the following information: &lt;br /&gt;
&lt;br /&gt;
* Metformin is contraindicated with contrast dye. &lt;br /&gt;
* Metformin is the generic form of Glucophage. &lt;br /&gt;
* Bob is taking Glucophage. &lt;br /&gt;
* The contrast MRI requires as one of its steps injecting the patient with contrast dye. &lt;br /&gt;
&lt;br /&gt;
MEDIC therefore determines that Bob should not be taking the contrast MRI at this time. &lt;br /&gt;
&lt;br /&gt;
For MEDIC to work, the rules from these different sources must be mapped to a unified interchange format. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
The use case requires the formalization of changeable states (fluents) which can be represented by e.g. an event calculus axiomatization &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#event-calculus|KS86]]]. However, to formulate the classical event calculus as a set of Horn clause rules, so that it could be run as a Prolog program, negation as failure is needed, which is not supported by RIF BLD. &lt;br /&gt;
The use case can be represented in RIF PRD which supports changeable states (modifications) and assertions and retractions of knowledge.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Interchanging Rule Extensions to OWL ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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 provide a richer language for describing dependencies between properties (binary predicates), and may also support higher-arity predicates. &lt;br /&gt;
&lt;br /&gt;
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 labeling 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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
If MAE X is bounded by Z and MAE Y is also bounded by Z then X is connected to Y.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF Core, RIF BLD and RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
The use case uses RIF SWC to combine RIF Rules with OWL ontologies.&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Vocabulary Mapping for Data Integration ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
* a report on application services and associated servers, databases and networks (from the IT department) &lt;br /&gt;
* a maintenance contracts database (from the finance department) &lt;br /&gt;
* a registry indicating which business processes use which IT services (from the business planning group) &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
First, Vlad creates simple mapping rules to create a uniform, simplified view of the data in terms of a small number of concepts -- Server, Business&amp;lt;tt&amp;gt;&amp;lt;/tt&amp;gt;Process and Dependency. This involves rules such as: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 If x is a ComputeNode in Rack r&lt;br /&gt;
    and Rack r is in Cage c&lt;br /&gt;
    and mc is a MaintenanceContract for Cage c&lt;br /&gt;
       then x is a Server with MaintenanceContract mc&lt;br /&gt;
 &lt;br /&gt;
 If x is a ComputeNode with a NetworkInterface with Port p&lt;br /&gt;
    and app is an Application running on Port p&lt;br /&gt;
       then x is a Server that hosts app&lt;br /&gt;
 &lt;br /&gt;
 If bp is a BusinessProcess that uses Application app&lt;br /&gt;
       then bp has a Dependency on app&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; Forall ?X ?MC ?R ?C(&lt;br /&gt;
  ?X[rdf:type-&amp;gt;ex:Server ex:maintenanceContract-&amp;gt;?MC] :- And(&lt;br /&gt;
    ?X[rdf:type-&amp;gt;ex:ComputeNode ex:location-&amp;gt;?R] ?R#ex:Rack &lt;br /&gt;
    ?R[ex:location-&amp;gt;?C] ?C#ex:Cage&lt;br /&gt;
    ?C[ex:maintenanceContract-&amp;gt;?MC] ?MC#ex:MaintenanceContract )) &lt;br /&gt;
&lt;br /&gt;
  Forall ?X ?Ni ?P ?App (&lt;br /&gt;
   ?X[rdf:type-&amp;gt;ex:Server ex:hosts-&amp;gt;?App] :- And( &lt;br /&gt;
     ?X[rdf:type-&amp;gt;ex:ComputeNode ex:networkInterface-&amp;gt;?Ni] &lt;br /&gt;
     ?Ni[ex:port-&amp;gt;?P]  ?P#ex:Port&lt;br /&gt;
     ?App[rdf:type-&amp;gt;ex:Application ex:onPort-&amp;gt;?P])) &lt;br /&gt;
&lt;br /&gt;
  Forall ?App ?BP ( &lt;br /&gt;
   ?BP[ex:dependsOn-&amp;gt;?App] :- &lt;br /&gt;
     ?BP[rdf:type-&amp;gt;ex:BusinessProcess ex:processUses-&amp;gt;?App] )) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt; &lt;br /&gt;
 &lt;br /&gt;
He then creates rules that combine the data across his now simplified data sources, e.g. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 If bp is a BusinessProcess that has a Dependency on Application app&lt;br /&gt;
   and x is a Server with MaintenanceContract mc that hosts Application app&lt;br /&gt;
      then bp has a Dependency on mc&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt;   Forall ?App ?BP ?App ?MC( &lt;br /&gt;
   ?BP[ex:dependsOn-&amp;gt;?MC] :- &amp;lt;&lt;br /&gt;
     ?BP[rdf:type-&amp;gt;ex:BusinessProcess ex:dependsOn-&amp;gt;?App] ?App#ex:Application &lt;br /&gt;
     ?X[rdf:type-&amp;gt;ex:Server ex:hosts-&amp;gt;?App ex:maintenanceContract-&amp;gt;?MC] )) &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF BLD and RID PRD'''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== BPEL Orchestration of Rule-Based Web Services ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
The credit evaluation rules are themselves grouped into three rulesets that are executed sequentially. Rules in the first ruleset apply thresholds to several &amp;quot;red flag&amp;quot; quantities in the credit report, such as: &lt;br /&gt;
&lt;br /&gt;
* number of times a payment was 60 days late &lt;br /&gt;
* debt-to-income ratio &lt;br /&gt;
* number of foreclosures or repossessions &lt;br /&gt;
* number of garnishments &lt;br /&gt;
* number of liens &lt;br /&gt;
* bankruptcy &lt;br /&gt;
&lt;br /&gt;
A red flag above the threshold results in denial of credit. &lt;br /&gt;
&lt;br /&gt;
Rules in the second ruleset increment a credit score variable. For example: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 If applicant owns residence then add 40.&lt;br /&gt;
 If applicant rents then add 30.&lt;br /&gt;
 If applicant has lived at current address 2 to 4 years then add 20.&lt;br /&gt;
 If applicant's income is under 20000 then add 10.&lt;br /&gt;
 If applicant's income is between 40000 and 50000 then add 40.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt;Document(&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(pred http://www.w3.org/2007/rif-builtin-predicate#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(func http://www.w3.org/2007/rif-builtin-function#)&amp;lt;br /&amp;gt;&lt;br /&gt;
  Prefix(prolog_func &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/2007/rif-prolog-builtin-function#)&lt;br /&gt;
  Prefix(ex   &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//example.org/example#)&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
  Group&amp;lt;br /&amp;gt;&lt;br /&gt;
  (&amp;lt;br /&amp;gt;&lt;br /&gt;
     ex:score(0)&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
     ex:score(?Applicant ?Score) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:increment(?Applicant)&amp;lt;br /&amp;gt;&lt;br /&gt;
      ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
      prolog_func:retract(ex:score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
      prolog_func:assert(ex:score(0)).   &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant) :-   &amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:owns(?Applicant)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:retract(ex:score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 40&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(ex:score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant):-   &amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:rents(?Applicant)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:retract(score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 30&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant):-&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:lives(?Applicant ?Date),&amp;lt;br /&amp;gt;&lt;br /&gt;
   $sysTime(?CurrentDateTime)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?CurrentYear = $fn:year-from-dateTime(?CurrentDateTime)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Year = $fn:year-from-dateTime(?Date)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Diff = ?CurrentYear - ?Year&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Diff &amp;gt; 1&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Diff &amp;lt; 5&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:retract(score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 20&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(ex:score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant):-   &amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:income(?Applicant ?Income)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Income &amp;lt; 20000&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:retract(score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 10&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(ex:score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ex:increment(?Applicant):-&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:income(?Applicant ?Income)&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Income &amp;lt; 50000&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?Income &amp;gt; 40000&amp;lt;br /&amp;gt;&lt;br /&gt;
   ex:score(?Score)&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:retract(ex:score(?Score))&amp;lt;br /&amp;gt;&lt;br /&gt;
   ?NewScore = ?Score + 40&amp;lt;br /&amp;gt;&lt;br /&gt;
   prolog_func:assert(ex:score(?NewScore)).&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;A goal-driven solution which makes use of assert and retract (not supported by BLD) to update a global score value, which is stored in a fact.&lt;br /&gt;
&amp;lt;/p&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
This use case requires a goal-driven solution which makes use of assert and retract  to update a global score value. Assert and retract are not supported by BLD; indeed, there is no such similar notion within BLD.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Publishing Rules for Interlinked Metadata ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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 &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;imd.example.org. Besides the ground facts, which can be expressed in RDF, the metadata might also have general rules like the following: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 Every science fiction movie is a movie.&lt;br /&gt;
 Every movie produced before 1930 is black and white.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD (Abridged) Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; ?Movie#ex:Movie :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Movie#ex:ScienceFictionMovie.&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ?Movie#ex:BlackWhiteMovie :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Movie#ex:Movie[ex:date -&amp;gt; ?Date]&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Date &amp;lt; &amp;quot;1930&amp;quot;^^xs:dateTime.&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;  &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
Published rules also allow combining data from different sources to exploit this knowledge. Consider an alternative database of movies published at &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;altmd.example.org. In addition to metadata, it again publishes its own rules: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 All movies listed at &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;altmd.example.org but not listed at &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;imd.example.org are independent movies.&lt;br /&gt;
 All movies with budgets below 5 million USD are low-budget movies.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD (Abridged) Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; ?Movie#ex:IndependentMovie :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    listed(?Movie#ex:Movie,&amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//altmd.example.org&amp;gt;)&amp;lt;br /&amp;gt;&lt;br /&gt;
    not(listed(?Movie#ex:Movie,&amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//imd.example.org&amp;gt;)). 	&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 ?Movie#ex:LowBudgetMovie :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Movie#ex:Movie [date -&amp;gt; ?Date, budget -&amp;gt; ?Budget]&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Budget &amp;lt; 5000000^^xs:long.&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;  &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
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: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre width=130&amp;gt;&lt;br /&gt;
 If Charlie is currently attending a public talk according to &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;charlie.example.org/calender.ical&lt;br /&gt;
     then leave him a voicemail message&lt;br /&gt;
 &lt;br /&gt;
 If Charlie is currently in a meeting according to &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;charlie.example.org/calender.ical&lt;br /&gt;
   and the importance is high&lt;br /&gt;
     then call his cell number&lt;br /&gt;
 &lt;br /&gt;
 If Charlie currently has no appointments according to &amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;charlie.example.org/calender.ical&lt;br /&gt;
     then call his office number&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p class=&amp;quot;rif&amp;quot; style=&amp;quot;display:none&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;b class=&amp;quot;syntax-head&amp;quot;&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
Representation in RIF BLD (Abridged) Presentation Syntax using relations:&amp;lt;br /&amp;gt; &lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;code style=&amp;quot;white-space: pre;&amp;quot;&amp;gt; contactInfo(&amp;quot;Charlie&amp;quot; ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    sysTime(?Time)&amp;lt;br /&amp;gt;&lt;br /&gt;
    attending(&amp;quot;Charlie&amp;quot; &amp;quot;talk&amp;quot; ?Time)&amp;lt;br /&amp;gt;&lt;br /&gt;
    contact(&amp;quot;Charlie&amp;quot; &amp;quot;voicemail&amp;quot; ?ContactInfo).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contactInfo(&amp;quot;Charlie&amp;quot; ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    sysTime(?Time)&amp;lt;br /&amp;gt;&lt;br /&gt;
    attending(&amp;quot;Charlie&amp;quot; &amp;quot;meeting&amp;quot; ?Time)&amp;lt;br /&amp;gt;&lt;br /&gt;
    contact(&amp;quot;Charlie&amp;quot; &amp;quot;cell number&amp;quot; ?ContactInfo).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contactInfo(&amp;quot;Charlie&amp;quot;, ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    sysTime(?Time),&amp;lt;br /&amp;gt;&lt;br /&gt;
    not(attending(&amp;quot;Charlie&amp;quot;,?Event, ?Time)),&amp;lt;br /&amp;gt;&lt;br /&gt;
    contact(&amp;quot;Charlie&amp;quot;, &amp;quot;office number&amp;quot;, ?ContactInfo).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 sysTime(?Time) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    % get the actual system time e.g. via a built-in&amp;lt;br /&amp;gt;&lt;br /&gt;
    % or procedural attachment call to Java or C++.&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Time = External(call(java.util.Calendar().getInstance())).&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 attending(&amp;quot;Charlie&amp;quot;,&amp;quot;talk&amp;quot;, ?CurrentTime) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    % getEventData would implement the functionality to dynamically access and query&amp;lt;br /&amp;gt;&lt;br /&gt;
    % &amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/calender.ical&amp;lt;br /&amp;gt;&lt;br /&gt;
    getEventData(&amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/calender.ical&amp;gt;,?EventTitle,?Type,?StartDate,?EndDate),&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Type = &amp;quot;talk&amp;quot;,&amp;lt;br /&amp;gt;&lt;br /&gt;
    External(op:dateTime-less-than(?CurrentTime,?EndDate),&amp;lt;br /&amp;gt;&lt;br /&gt;
    External(op:dateTime-greater-than(?CurrentTime,?StartDate).&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;        &lt;br /&gt;
&amp;lt;br /&amp;gt; &lt;br /&gt;
 attending(&amp;quot;Charlie&amp;quot;,&amp;quot;meeting&amp;quot;, ?CurrentTime) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    getEventData(&amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/calender.ical&amp;gt;,?EventTitle,?Type,?StartDate,?EndDate),&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Type = &amp;quot;meeting&amp;quot;,&amp;lt;br /&amp;gt;&lt;br /&gt;
    External(op:dateTime-less-than(?CurrentTime,?EndDate),&amp;lt;br /&amp;gt;&lt;br /&gt;
    External(op:dateTime-greater-than(?CurrentTime,?StartDate).&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;       &lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contact(&amp;quot;Charlie&amp;quot;, &amp;quot;voicemail&amp;quot;, ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    % retrieve the Voice mail number, e.g. from&amp;lt;br /&amp;gt;&lt;br /&gt;
    % Charlie's vCard, &amp;lt;br /&amp;gt;&lt;br /&gt;
    % e.g. xmlns:vCard = &amp;quot;&amp;lt;nowiki&amp;gt;http://www.w3.org/2001/vcard-rdf/3.0#&amp;quot;&amp;lt;/nowiki&amp;gt;&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard:FN&amp;gt; -&amp;gt; &amp;quot;Charlie&amp;quot;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard_TEL&amp;gt; -&amp;gt; ?Telephone],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf:type&amp;gt; -&amp;gt; &amp;lt;nowiki&amp;gt;&amp;lt;http://www.w3.org/2001/vcard-rdf/3.0#voice&amp;gt;&amp;lt;/nowiki&amp;gt;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf_value&amp;gt; -&amp;gt; ?ContactInfo].&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contact(&amp;quot;Charlie&amp;quot;, &amp;quot;cell number&amp;quot;, ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard:FN&amp;gt; -&amp;gt; &amp;quot;Charlie&amp;quot;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard_TEL&amp;gt; -&amp;gt; ?Telephone],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf:type&amp;gt; -&amp;gt; &amp;lt;nowiki&amp;gt;&amp;lt;http://www.w3.org/2001/vcard-rdf/3.0#cell&amp;gt;&amp;lt;/nowiki&amp;gt;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf_value&amp;gt; -&amp;gt; ?ContactInfo].&amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;br /&amp;gt;&lt;br /&gt;
 contact(&amp;quot;Charlie&amp;quot;, &amp;quot;office number&amp;quot;, ?ContactInfo) :-&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard:FN&amp;gt; -&amp;gt; &amp;quot;Charlie&amp;quot;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    &amp;lt;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//charlie.example.org/vCard&amp;gt;[&amp;lt;vCard_TEL&amp;gt; -&amp;gt; ?Telephone],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf:type&amp;gt; -&amp;gt; &amp;lt;nowiki&amp;gt;&amp;lt;http://www.w3.org/2001/vcard-rdf/3.0#work&amp;gt;&amp;lt;/nowiki&amp;gt;],&amp;lt;br /&amp;gt;&lt;br /&gt;
    ?Telephone[&amp;lt;rdf_value&amp;gt; -&amp;gt; ?ContactInfo]. &amp;lt;br /&amp;gt;&lt;br /&gt;
 &amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;/p&amp;gt;  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;intelligent&amp;quot; crawling and search. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Supported by RIF PRD'''&lt;br /&gt;
&lt;br /&gt;
Since negation is not supported by RIF BLD it is not possible to express ''... but not listed at ...''.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Conclusion ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
The goal of the RIF working group is to provide representational interchange formats for processes based on the use of rules and rule-based systems. These formats act as &amp;quot;interlingua&amp;quot; to interchange rules and integrate with other languages, in particular (Semantic) Web mark-up languages. &lt;br /&gt;
&lt;br /&gt;
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. &lt;br /&gt;
&lt;br /&gt;
In light of this diversity, rather than being a single all-encompassing format, RIF consists 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. &lt;br /&gt;
&lt;br /&gt;
RIF has been designed in such a way that it is possible to create new dialects (extensibility) according to the overall 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. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ref-Horty-deontic-logic&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
; [Horty2001]&lt;br /&gt;
: ''Agency and Deontic Logic'', John F. Horty, Oxford University Press, 2001.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;event-calculus&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
; [KS86]&lt;br /&gt;
: Kowalski, R.A. and M.J. Sergot, ''A logic-based calculus of events.'' New Generation Computing, 1986. 4: p. 67-95.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;moore&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
; [Moore80]&lt;br /&gt;
: Moore, R.C., ''Reasoning about Knowledge and Action,'' SRI TR-191, 1980.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Appendix: Change Log (Informative) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div&amp;gt;&amp;lt;div lang=&amp;quot;en&amp;quot; dir=&amp;quot;ltr&amp;quot;&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This appendix summarizes the main changes to this document since its publication as a Working Draft.&lt;br /&gt;
&lt;br /&gt;
Changes since the [http://www.w3.org/TR/rif-ucr/ draft of December 18th, 2008]:&lt;br /&gt;
* [[#Structure_of_RIF|section describing the structure of RIF]] updated with the new RIF documents;&lt;br /&gt;
* all code examples are removed from the document&lt;br /&gt;
* each use cases has a new paragraph at the end which discusses the support of the use case by the current RIF dialects Core, BLD and PRD&lt;br /&gt;
* added an informative change log section&lt;br /&gt;
* flattened the list of requirements removing the distinction between general and basic requirements&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</description>
			<pubDate>Tue, 11 Dec 2012 14:03:13 GMT</pubDate>			<dc:creator>Sandro</dc:creator>			<comments>http://www.w3.org/2005/rules/wiki/Talk:UCR</comments>		</item>
		<item>
			<title>BLD</title>
			<link>http://www.w3.org/2005/rules/wiki/BLD</link>
			<description>&lt;p&gt;Sandro:&amp;#32;update curie reference&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NUMBEREDHEADINGS__&lt;br /&gt;
{{TR|title=RIF Basic Logic Dialect}}&lt;br /&gt;
&amp;lt;div id='editors'&amp;gt;&lt;br /&gt;
; Editors:&lt;br /&gt;
: Harold Boley, National Research Council Canada&lt;br /&gt;
: Michael Kifer, State University of New York at Stony Brook, USA&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
; Abstract&lt;br /&gt;
: &amp;lt;div id='abstract'&amp;gt;&amp;lt;p&amp;gt;This document, developed by the [[RIF_Working_Group|Rule Interchange Format (RIF) Working Group]], specifies the Basic Logic Dialect, RIF-BLD, a format that allows logic rules to be exchanged between rule systems. The RIF-BLD presentation syntax and semantics are specified both directly and as specializations of the ''RIF Framework for Logic Dialects'', or RIF-FLD. The XML serialization syntax of RIF-BLD is specified via a mapping from the presentation syntax. A normative XML schema is also provided.&amp;lt;/p&amp;gt; &amp;lt;/div&amp;gt;&lt;br /&gt;
; Status of this Document&lt;br /&gt;
: {{status|bld}}&lt;br /&gt;
&lt;br /&gt;
[http://www.w3.org/Consortium/Legal/ipr-notice#Copyright Copyright] &amp;amp;copy; 2010 [http://www.w3.org/ W3C]&amp;lt;sup&amp;gt;&amp;amp;reg;&amp;lt;/sup&amp;gt; ([http://www.csail.mit.edu/ MIT], [http://www.ercim.org/ ERCIM], [http://www.keio.ac.jp/ Keio]), All Rights Reserved. W3C [http://www.w3.org/Consortium/Legal/ipr-notice#Legal_Disclaimer liability], [http://www.w3.org/Consortium/Legal/ipr-notice#W3C_Trademarks trademark] and [http://www.w3.org/Consortium/Legal/copyright-documents document use] rules apply.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div id='docbody'&amp;gt;&lt;br /&gt;
== Overview ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;overview&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; This specification develops '''''RIF-BLD''''' (the '''B'''asic '''L'''ogic '''D'''ialect of the '''R'''ule '''I'''nterchange '''F'''ormat). From a theoretical perspective, RIF-BLD corresponds to the language of definite Horn rules with equality and a standard first-order semantics &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-chang-lee|CL73]]]. Syntactically, RIF-BLD has a number of extensions to support features such as objects and frames as in F-logic &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-flogic-95|KLW95]]], internationalized resource identifiers (or IRIs, defined by &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rfc-3987|RFC-3987]]]) as identifiers for concepts, and XML Schema datatypes &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xml-schema2|XML-SCHEMA2]]]. In addition, RIF RDF and OWL Compatibility &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-swc|RIF-RDF+OWL]]] defines semantics for the integrated RIF-BLD/RDF and RIF-BLD/OWL languages. These features make RIF-BLD a Web-aware language. However, it should be kept in mind that RIF is designed to enable interoperability among rule languages in general, and its uses are not limited to the Web. &lt;br /&gt;
&lt;br /&gt;
While rule interchange (and not, e.g., execution) is the principle design goal for RIF-BLD, the design clearly indicates a decision to avoid solving the (probably impossible) problem of rule interchange in general.  Instead, the design of RIF reflects the rationale of identifying specific kinds of rules within existing rule systems, called ''RIF dialects'', that can be translated into other rule systems without changing their meaning. RIF-BLD is just the first in a series of such dialects. In particular, RIF-BLD has the RIF-Core dialect &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-core|RIF-Core]]] as a subset. It is ''not expected'' that most rule systems will be able to translate all their rules into RIF-BLD, rather it is expected that only certain kinds of rules will be translatable.  Since there are many existing rule languages with useful features that are not supported in RIF-BLD, it is expected that RIF-BLD translators will not translate rules that use such features.  This could drive the design of &amp;quot;BLD-specific&amp;quot; rule sets in which rules are specifically written by the implementor to be within the BLD dialect and thus be portable between many rule system implementations.  &lt;br /&gt;
&lt;br /&gt;
Among its many influences, RIF shares certain characteristics with ISO Common Logic (CL) &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-common-logic|ISO-CL]]], itself an evolution of KIF &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-kif|KIF]]] and Conceptual Graphs &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-cg|CG]]]. Like CL, RIF employs XML as its primary normative syntax, uses IRIs as identifiers, specifies integrated RIF-BLD/RDF and RIF-BLD/OWL languages for Semantic Web Compatibility &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-swc|RIF-RDF+OWL]]], and provides a rich set of datatypes and built-ins that are designed to be well aligned with Web-aware rule system implementations &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]]. Unlike CL, RIF-BLD was designed to be a ''simple'' dialect with limited expressiveness that lies within the intersection of first-order and logic-programming systems. This is why RIF-BLD does not support negation. More generally, RIF-BLD is part of a coherent array of RIF rule dialects, which encompasses both logic rules -- through the RIF framework for logic dialects &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-fld|RIF-FLD]]] also including a variety of rule languages based on non-monotonic theories -- and production rules, as defined in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-prd|RIF-PRD]]]. CL, on the other hand, is strictly first-order; it does not account for non-monotonic semantics (e.g. negation as failure, defaults, priorities, etc.). For rule interchange between CL and RIF dialects, it is expected that partial RIF-CL mappings will be defined.&lt;br /&gt;
&lt;br /&gt;
RIF-BLD also bears some similarity to SPARQL, in particular with respect to RDF Compatibility &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-swc|RIF-RDF+OWL]]].  As with the well-known correspondence between a fragment of SQL and Datalog, SPARQL can be partially mapped to Datalog (and thus to the RIF-Core subset of RIF-BLD), see &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-sparql-rules|AP07]]] and &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-sparql-expr|AG08]]] for details. A full mapping of SPARQL would need constructs beyond RIF-BLD, such as non-monotonic negation. Likewise, not all of SPARQL's FILTER functions are expressible in RIF-DTB built-in predicates. Not all of RIF-BLD is expressible in SPARQL either, for instance recursive rules over RDF Data are not expressible as SPARQL CONSTRUCT statements.&lt;br /&gt;
&lt;br /&gt;
RIF-BLD is defined in two different ways -- ''both normative'':&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    As a direct specification, independently of the RIF framework for logic dialects &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-fld|RIF-FLD]]], for the benefit of those who desire a direct path to RIF-BLD, e.g., as prospective implementers, and are not interested in extensibility issues. This version of the RIF-BLD specification is given first.&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    As a specialization of the RIF framework for logic dialects &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-fld|RIF-FLD]]], which is part of the RIF extensibility framework.&lt;br /&gt;
&lt;br /&gt;
    Building on RIF-FLD, this version of the RIF-BLD specification is comparatively short and is presented in Section [[#sec-bld-fld-spec|RIF-BLD as a Specialization of the RIF Framework]] at the end of this document. This is intended for the reader who is already familiar with RIF-FLD and does not need to go through the much longer direct specification of RIF-BLD. This section is also useful for dialect designers, as it is a concrete example of how a non-trivial RIF dialect can be derived from the RIF framework for logic dialects.&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Logic-based RIF dialects that specialize or extend RIF-BLD in accordance with the RIF framework for logic dialects &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-fld|RIF-FLD]]] include RIF-Core as a specialization of RIF-BLD. It is expected that other specifications will develop further logic dialects based on RIF-BLD such as a RIF-BLD extension capturing uncertainty &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-urd|URD08]]].&lt;br /&gt;
&lt;br /&gt;
As a preview, here is a simple complete RIF-BLD example deriving a ternary relation from its inverse.&lt;br /&gt;
&lt;br /&gt;
'''Example 1''' (An introductory RIF-BLD example).&lt;br /&gt;
&lt;br /&gt;
A rule can be written in English to derive the &amp;lt;tt&amp;gt;buy&amp;lt;/tt&amp;gt; relationships&lt;br /&gt;
(rather than store them) from the &amp;lt;tt&amp;gt;sell&amp;lt;/tt&amp;gt; relationships that are&lt;br /&gt;
stored as facts (e.g., as exemplified by the English statement below):&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
   &amp;lt;em&amp;gt;&lt;br /&gt;
     A buyer buys an item from a seller&lt;br /&gt;
     if the seller sells the item to the buyer.&lt;br /&gt;
   &amp;lt;/em&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
   &amp;lt;em&amp;gt;&lt;br /&gt;
     John sells LeRif to Mary.&lt;br /&gt;
   &amp;lt;/em&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Intuitively, the fact ''Mary buys LeRif from John'' should be logically derivable from the above premises.&lt;br /&gt;
Assuming Web IRIs for the predicates &amp;lt;tt&amp;gt;buy&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;sell&amp;lt;/tt&amp;gt;, as well as for the individuals&lt;br /&gt;
&amp;lt;tt&amp;gt;John&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;Mary&amp;lt;/tt&amp;gt;, and &amp;lt;tt&amp;gt;LeRif&amp;lt;/tt&amp;gt;, the above English text can be represented in the [[#sec-bld-direct-syntax|RIF-BLD Presentation Syntax]] as follows.&lt;br /&gt;
 &lt;br /&gt;
 Document(&lt;br /&gt;
   Base(&amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/people#&amp;amp;gt;)&lt;br /&gt;
   Prefix(cpt &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/concepts#&amp;amp;gt;)&lt;br /&gt;
   Prefix(bks &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/books#&amp;amp;gt;)&lt;br /&gt;
 &lt;br /&gt;
   Group&lt;br /&gt;
   (&lt;br /&gt;
     Forall ?Buyer ?Item ?Seller (&lt;br /&gt;
         cpt:buy(?Buyer ?Item ?Seller) :- cpt:sell(?Seller ?Item ?Buyer)&lt;br /&gt;
     )&lt;br /&gt;
  &lt;br /&gt;
     cpt:sell(&amp;lt;John&amp;gt; bks:LeRif &amp;quot;Mary&amp;quot;^^rif:iri)&lt;br /&gt;
   )&lt;br /&gt;
 )&lt;br /&gt;
&lt;br /&gt;
Note that IRIs are represented in several different ways in this example. First,&lt;br /&gt;
the &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-curie|CURIE]]] notation &amp;lt;tt&amp;gt;prefix:suffix&amp;lt;/tt&amp;gt; is used to shorten IRI representation. For instance, &amp;lt;tt&amp;gt;cpt:buy&amp;lt;/tt&amp;gt; via a &amp;lt;tt&amp;gt;Prefix&amp;lt;/tt&amp;gt; directive represents the &amp;lt;tt&amp;gt;rif:iri&amp;lt;/tt&amp;gt; constant &amp;lt;tt&amp;gt;&amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/concepts#buy&amp;quot;^^rif:iri&amp;lt;/tt&amp;gt;.&lt;br /&gt;
Another way to shorten this IRI constant is to use the angle-bracketed notation &amp;lt;tt&amp;gt;&amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/concepts#buy&amp;amp;gt;&amp;lt;/tt&amp;gt;. The &amp;lt;tt&amp;gt;Base&amp;lt;/tt&amp;gt; directive provides yet another shortcut: it applies to all relative IRIs, such as&lt;br /&gt;
&amp;lt;tt&amp;gt;&amp;quot;Mary&amp;quot;^^rif:iri&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;&amp;amp;lt;John&amp;amp;gt;&amp;lt;/tt&amp;gt;. The &amp;lt;tt&amp;gt;Base&amp;lt;/tt&amp;gt; directive expands these relative IRIs to &amp;lt;tt&amp;gt;&amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/people#Mary&amp;quot;^^rif:iri&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;&amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/people#John&amp;quot;^^rif:iri&amp;lt;/tt&amp;gt;, respectively.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Whenever a RIF-BLD document falls into the Core subset or can be translated to it, the document should be produced in RIF-Core to allow its interchange with a maximum number of RIF consumers.&lt;br /&gt;
For instance, the Datalog-like RIF document in Example 1 is also a RIF-Core example.&lt;br /&gt;
&lt;br /&gt;
For the interchange of documents containing RIF-BLD rules (and facts), a concrete [[#sec-xml-bld|RIF-BLD XML Syntax]] is given in this specification. To formalize their meaning, a model-theoretic [[#sec-bld-direct-semantics|RIF-BLD Semantics]] is specified.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-bld-direct-syntax&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Direct Specification of RIF-BLD Presentation Syntax ==&lt;br /&gt;
&lt;br /&gt;
This section specifies the '''''presentation syntax''''' of RIF-BLD directly, without relying on &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-fld|RIF-FLD]]]. In the first five (normative) subsections, the presentation syntax is&lt;br /&gt;
defined using &amp;quot;mathematical English,&amp;quot; a special form of English for communicating mathematical definitions, examples, etc.&lt;br /&gt;
In the non-normative subsection [[#sec-concrete-syntax|EBNF Grammar for the Presentation Syntax of RIF-BLD]], a grammar for a superset of the presentation syntax is given using Extended Backus–Naur Form (EBNF).&lt;br /&gt;
Neither the mathematical English nor the EBNF is intended to be a concrete syntax for RIF-BLD.  The mathematical English deliberately leaves out details such as the delimiters of the various syntactic components, escape symbols, parenthesizing, precedence of operators, and the like. The EBNF does not specify context-sensitive syntactic constraints.&lt;br /&gt;
Since RIF is an interchange format, it uses '''''XML as the only concrete syntax''''',&lt;br /&gt;
which will be defined in [[#sec-xml-bld|XML Serialization Syntax for RIF-BLD]]. Hence [[#sec-conformance|RIF-BLD conformance]] is described in terms of [[#def-conformance|semantics-preserving transformations]].&lt;br /&gt;
&lt;br /&gt;
Note to the reader: this section depends on Section [[DTB#sec-constants|Constants, Symbol Spaces, and Datatypes]] of &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-alphabet&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
==== Alphabet of RIF-BLD ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-bld-alphabet&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
'''Definition (Alphabet)'''.&lt;br /&gt;
The '''''alphabet''''' of the presentation language of RIF-BLD consists of &lt;br /&gt;
* a countably infinite set of '''''constant symbols''''' &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt;&lt;br /&gt;
* a countably infinite set of '''''variable symbols''''' &amp;lt;tt&amp;gt;Var&amp;lt;/tt&amp;gt; (disjoint from &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt;)&lt;br /&gt;
* a countably infinite set of argument names, &amp;lt;tt&amp;gt;ArgNames&amp;lt;/tt&amp;gt; (disjoint from &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;Var&amp;lt;/tt&amp;gt;)&lt;br /&gt;
* connective symbols &amp;lt;tt&amp;gt;And&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;Or&amp;lt;/tt&amp;gt;, and &amp;lt;tt&amp;gt;:-&amp;lt;/tt&amp;gt;&lt;br /&gt;
* quantifiers &amp;lt;tt&amp;gt;Exists&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;Forall&amp;lt;/tt&amp;gt;&lt;br /&gt;
* the symbols &amp;lt;tt&amp;gt;=&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;#&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;##&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;-&amp;gt;&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;External&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;Prefix&amp;lt;/tt&amp;gt;, and &amp;lt;tt&amp;gt;Base&amp;lt;/tt&amp;gt; &lt;br /&gt;
* the symbols &amp;lt;tt&amp;gt;Group&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;Document&amp;lt;/tt&amp;gt;&lt;br /&gt;
* the symbols for representing lists: &amp;lt;tt&amp;gt;List&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;OpenList&amp;lt;/tt&amp;gt;.  &lt;br /&gt;
* the auxiliary symbols &amp;lt;tt&amp;gt;(&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;)&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;[&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;]&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;&amp;amp;lt;&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;&amp;amp;gt;&amp;lt;/tt&amp;gt;, and &amp;lt;tt&amp;gt;^^&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The set of connective symbols, quantifiers, &amp;lt;tt&amp;gt;=&amp;lt;/tt&amp;gt;, etc., is disjoint from &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;Var&amp;lt;/tt&amp;gt;. The argument names in &amp;lt;tt&amp;gt;ArgNames&amp;lt;/tt&amp;gt; are written as Unicode strings that must not start with a question mark, &amp;quot;&amp;lt;tt&amp;gt;?&amp;lt;/tt&amp;gt;&amp;quot;. Variables are written as Unicode strings preceded with the symbol &amp;quot;&amp;lt;tt&amp;gt;?&amp;lt;/tt&amp;gt;&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
Constants are written as &amp;lt;tt&amp;gt;&amp;quot;literal&amp;quot;^^symspace&amp;lt;/tt&amp;gt;, where &amp;lt;tt&amp;gt;literal&amp;lt;/tt&amp;gt; is a sequence of Unicode characters and&lt;br /&gt;
&amp;lt;tt&amp;gt;symspace&amp;lt;/tt&amp;gt; is an identifier for a symbol space. Symbol spaces are defined in Section [[DTB#sec-constants|Constants, Symbol Spaces, and Datatypes]] of &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]].&lt;br /&gt;
&lt;br /&gt;
The symbols &amp;lt;tt&amp;gt;=&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;#&amp;lt;/tt&amp;gt;, and &amp;lt;tt&amp;gt;##&amp;lt;/tt&amp;gt; are used in formulas that define equality, class membership, and subclass relationships. The symbol &amp;lt;tt&amp;gt;-&amp;gt;&amp;lt;/tt&amp;gt; is used in terms that have named arguments and in frame formulas. The symbol &amp;lt;tt&amp;gt;External&amp;lt;/tt&amp;gt; indicates that an atomic formula or a function term is defined externally (e.g., a built-in)  and the symbols &amp;lt;tt&amp;gt;Prefix&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;Base&amp;lt;/tt&amp;gt; enable compact representations of IRIs &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rfc-3987|RFC-3987]]].&lt;br /&gt;
&lt;br /&gt;
The symbol &amp;lt;tt&amp;gt;Document&amp;lt;/tt&amp;gt; is used to specify RIF-BLD documents, the symbol &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; is an import directive, and the symbol &amp;lt;tt&amp;gt;Group&amp;lt;/tt&amp;gt; is used to organize RIF-BLD formulas into collections. &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
&lt;br /&gt;
The language of RIF-BLD is the set of formulas constructed using the above alphabet according to the rules given below. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-terms&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== Terms ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
RIF-BLD defines several kinds of terms: ''constants'' and ''variables'',&lt;br /&gt;
''positional'' terms, terms with ''named arguments'', plus ''equality'',&lt;br /&gt;
''membership'', ''subclass'', ''frame'', and ''external'' terms. The word &amp;quot;''term''&amp;quot; will be used to refer to any of these constructs.&lt;br /&gt;
&lt;br /&gt;
To simplify the next definition, we will use the phrase ''base term'' to refer to simple, positional, or named-argument terms, or to terms of the form &amp;lt;tt&amp;gt;External(t)&amp;lt;/tt&amp;gt;, where &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; is a positional or a named-argument term.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-bld-term&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
'''Definition (Term)'''.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;''Constants and variables''. If &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; &amp;amp;isin; &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; &amp;amp;isin; &amp;lt;tt&amp;gt;Var&amp;lt;/tt&amp;gt; then &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; is a '''''simple term'''''. &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;''Positional terms''. If &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; &amp;amp;isin; &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;t&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, ..., &amp;lt;tt&amp;gt;t&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;n&amp;amp;ge;0&amp;lt;/tt&amp;gt;, are base terms then &amp;lt;tt&amp;gt;t(t&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... t&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;)&amp;lt;/tt&amp;gt; is a '''''positional term'''''. &lt;br /&gt;
  &amp;lt;p&amp;gt;&lt;br /&gt;
  Positional terms correspond to the usual terms and atomic formulas of&lt;br /&gt;
classical first-order logic &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-enderton01|Enderton01]], [[#ref-mendelson97|Mendelson97]]].&lt;br /&gt;
  &amp;lt;/p&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;''Terms with named arguments''. A '''''term with named arguments''''' is of the form &amp;lt;tt&amp;gt;t(s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... s&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;)&amp;lt;/tt&amp;gt;, where &amp;lt;tt&amp;gt;n&amp;amp;ge;0&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; &amp;amp;isin; &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, ..., &amp;lt;tt&amp;gt;v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; are  base terms and &amp;lt;tt&amp;gt;s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, ..., &amp;lt;tt&amp;gt;s&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; are pairwise distinct symbols from the set &amp;lt;tt&amp;gt;ArgNames&amp;lt;/tt&amp;gt;.&lt;br /&gt;
    &amp;lt;p&amp;gt;The constant &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; here represents a predicate or a function; &amp;lt;tt&amp;gt;s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, ..., &amp;lt;tt&amp;gt;s&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; represent argument names; and &amp;lt;tt&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, ..., &amp;lt;tt&amp;gt;v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; represent argument values. The argument names, &amp;lt;tt&amp;gt;s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, ..., &amp;lt;tt&amp;gt;s&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, are required to be pairwise distinct. Terms with named arguments are like positional terms except that the arguments are named and their order is immaterial. Note that a term of the form &amp;lt;tt&amp;gt;f()&amp;lt;/tt&amp;gt; is, trivially, both a positional term and a term with named arguments. &amp;lt;/p&amp;gt;&lt;br /&gt;
    &amp;lt;p&amp;gt;&lt;br /&gt;
Terms with named arguments are introduced to support exchange of languages&lt;br /&gt;
that permit argument positions of predicates and functions to be named&lt;br /&gt;
(in which case the order of the arguments does not matter).&lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;  &lt;br /&gt;
     ''List terms''. There are two kinds of list terms: &amp;lt;em&amp;gt;open&amp;lt;/em&amp;gt; and &amp;lt;em&amp;gt;closed&amp;lt;/em&amp;gt;.  &lt;br /&gt;
     &amp;lt;ul&amp;gt;     &lt;br /&gt;
       &amp;lt;li&amp;gt;&lt;br /&gt;
	 A '''''closed list''''' has the form &amp;lt;tt&amp;gt;List(t&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;m&amp;lt;/sub&amp;gt;&amp;lt;tt&amp;gt;)&amp;lt;/tt&amp;gt;, where &amp;lt;tt&amp;gt;m&amp;amp;ge;0&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;, ..., &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;m&amp;lt;/sub&amp;gt; are terms.  &lt;br /&gt;
       &amp;lt;/li&amp;gt;&lt;br /&gt;
       &amp;lt;li&amp;gt;       &lt;br /&gt;
	  An '''''open list''''' (or a list with a tail) has the form&lt;br /&gt;
	  &amp;lt;tt&amp;gt;OpenList(t&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;m&amp;lt;/sub&amp;gt; &amp;lt;tt&amp;gt;t)&amp;lt;/tt&amp;gt;, where &amp;lt;tt&amp;gt;m&amp;amp;gt;0&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;, ..., &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;m&amp;lt;/sub&amp;gt;, &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; are terms. Open lists are usually written using the following: &amp;lt;tt&amp;gt;List(t&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;m&amp;lt;/sub&amp;gt; &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;|&amp;lt;/nowiki&amp;gt;&amp;lt;/tt&amp;gt; &amp;lt;tt&amp;gt;t)&amp;lt;/tt&amp;gt;.&lt;br /&gt;
	  &amp;lt;p&amp;gt;&lt;br /&gt;
	     The last argument, &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt;, represents the tail of the list and so it is normally a list as well. However, the syntax does not restrict &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; in any way: it could be an integer, a variable, another list, or, in fact, any term. An example is &amp;lt;tt&amp;gt;List(1 2 &amp;lt;nowiki&amp;gt;|&amp;lt;/nowiki&amp;gt; 3)&amp;lt;/tt&amp;gt;. This is not an ordinary list, where the last argument, &amp;lt;tt&amp;gt;3&amp;lt;/tt&amp;gt;, would represent the tail of a list (and thus would also be a list, which &amp;lt;tt&amp;gt;3&amp;lt;/tt&amp;gt; is not). Such general open lists correspond to Lisp's dotted lists &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-steele90|Steele90]]]. Note that they can be the result of instantiating an open list with a variable in the tail, hence are hard to avoid. For instance, &amp;lt;tt&amp;gt;List(1 2 &amp;lt;nowiki&amp;gt;|&amp;lt;/nowiki&amp;gt; 3)&amp;lt;/tt&amp;gt; is &amp;lt;tt&amp;gt;List(1 2 &amp;lt;nowiki&amp;gt;|&amp;lt;/nowiki&amp;gt; ?X)&amp;lt;/tt&amp;gt;, where the variable &amp;lt;tt&amp;gt;?X&amp;lt;/tt&amp;gt; is replaced with &amp;lt;tt&amp;gt;3&amp;lt;/tt&amp;gt;.&lt;br /&gt;
	  &amp;lt;/p&amp;gt;&lt;br /&gt;
       &amp;lt;/li&amp;gt;&lt;br /&gt;
     &amp;lt;/ul&amp;gt;&lt;br /&gt;
     &amp;lt;p&amp;gt;&lt;br /&gt;
        A closed list of the form &amp;lt;tt&amp;gt;List()&amp;lt;/tt&amp;gt; (i.e., a list in which &amp;lt;tt&amp;gt;m=0&amp;lt;/tt&amp;gt;, corresponding to Lisp's &amp;lt;tt&amp;gt;nil&amp;lt;/tt&amp;gt;) is called the '''''empty list'''''. &lt;br /&gt;
     &amp;lt;/p&amp;gt;&lt;br /&gt;
     &amp;lt;p&amp;gt;&lt;br /&gt;
     &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;''Equality terms''.  &amp;lt;tt&amp;gt;t&amp;amp;nbsp;=&amp;amp;nbsp;s&amp;lt;/tt&amp;gt; is an '''''equality term''''', if &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;s&amp;lt;/tt&amp;gt; are base terms. &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;''Class membership terms'' (or just ''membership terms''). &amp;lt;tt&amp;gt;t#s&amp;lt;/tt&amp;gt; is a '''''membership term''''' if &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;s&amp;lt;/tt&amp;gt; are base terms. &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;''Subclass terms''. &amp;lt;tt&amp;gt;t##s&amp;lt;/tt&amp;gt; is a '''''subclass term''''' if &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;s&amp;lt;/tt&amp;gt; are base terms.&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;''Frame terms''. &amp;lt;tt&amp;gt;t[p&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... p&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;]&amp;lt;/tt&amp;gt; is a '''''frame term''''' (or simply a '''''frame''''') if &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;p&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, ..., &amp;lt;tt&amp;gt;p&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, ..., &amp;lt;tt&amp;gt;v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;n &amp;amp;ge; 0&amp;lt;/tt&amp;gt;, are base terms.&lt;br /&gt;
    &amp;lt;p&amp;gt;&lt;br /&gt;
    Membership, subclass, and frame terms are used to describe objects and class hierarchies.&lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;  &lt;br /&gt;
    ''Externally defined terms.'' If &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; is a positional or a named-argument term then &amp;lt;tt&amp;gt;External(t)&amp;lt;/tt&amp;gt; is an '''''externally defined term'''''.&lt;br /&gt;
  &amp;lt;p&amp;gt;&lt;br /&gt;
     External terms are used for representing built-in functions and predicates as well as &amp;quot;procedurally attached&amp;quot; terms or predicates, which might exist in various rule-based systems, but are not specified by RIF. &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
  &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Observe that the argument names of frame terms, &amp;lt;tt&amp;gt;p&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, ..., &amp;lt;tt&amp;gt;p&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, are base terms and so, as a special case, can be variables. In contrast, terms with named arguments can use only the symbols from &amp;lt;tt&amp;gt;ArgNames&amp;lt;/tt&amp;gt; to represent their argument names. They cannot be constants from &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt; or variables from &amp;lt;tt&amp;gt;Var&amp;lt;/tt&amp;gt;. The reason for not allowing variables for those is to control the complexity of unification, which is used by several inference mechanisms of first-order logic.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Example 2''' (Terms)&lt;br /&gt;
 &lt;br /&gt;
a. Positional term:   &amp;lt;tt&amp;gt;&amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/ex1&amp;quot;^^rif:iri(1 &amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/ex2&amp;quot;^^rif:iri(?X 5) &amp;quot;abc&amp;quot;)&amp;lt;/tt&amp;gt;  &lt;br /&gt;
 &lt;br /&gt;
b. Term with named arguments: &amp;lt;tt&amp;gt;&amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/Person&amp;quot;^^rif:iri(id-&amp;gt;&amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/John&amp;quot;^^rif:iri &amp;quot;age&amp;quot;^^rif:local-&amp;gt;?X &amp;quot;spouse&amp;quot;^^rif:local-&amp;gt;?Y)&amp;lt;/tt&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
c. Frame term: &amp;lt;tt&amp;gt;&amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/John&amp;quot;^^rif:iri[&amp;quot;age&amp;quot;^^rif:local-&amp;gt;?X &amp;quot;spouse&amp;quot;^^rif:local-&amp;gt;?Y]&amp;lt;/tt&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
d. Lists&lt;br /&gt;
 &lt;br /&gt;
- Empty list:  &amp;lt;tt&amp;gt;List()&amp;lt;/tt&amp;gt; &lt;br /&gt;
 &lt;br /&gt;
- Closed list with variable inside:  &amp;lt;tt&amp;gt;List(&amp;quot;a&amp;quot;^^xs:string ?Y &amp;quot;c&amp;quot;^^xs:string)&amp;lt;/tt&amp;gt;  &lt;br /&gt;
 &lt;br /&gt;
- Open list with variables:  &amp;lt;tt&amp;gt;List(&amp;quot;a&amp;quot;^^xs:string ?Y &amp;quot;c&amp;quot;^^xs:string | ?Z)&amp;lt;/tt&amp;gt;  &lt;br /&gt;
 &lt;br /&gt;
- Equality term with lists inside:  &amp;lt;tt&amp;gt;List(Head | Tail) = List(&amp;quot;a&amp;quot;^^xs:string ?Y &amp;quot;c&amp;quot;^^xs:string)&amp;lt;/tt&amp;gt;  &lt;br /&gt;
 &lt;br /&gt;
- Nested list:  &amp;lt;tt&amp;gt;List(&amp;quot;a&amp;quot;^^xs:string List(?X &amp;quot;b&amp;quot;^^xs:string) &amp;quot;c&amp;quot;^^xs:string)&amp;lt;/tt&amp;gt;  &lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
e. Classification terms&lt;br /&gt;
 &lt;br /&gt;
- Membership: &amp;lt;tt&amp;gt;?X # ?Y&amp;lt;/tt&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
- Subclass:   &amp;lt;tt&amp;gt;?X ## &amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/ex1&amp;quot;^^rif:iri(?Y)&amp;lt;/tt&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
- Membership: &amp;lt;tt&amp;gt;&amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/John&amp;quot;^^rif:iri # &amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/Person&amp;quot;^^rif:iri&amp;lt;/tt&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
- Subclass:   &amp;lt;tt&amp;gt;&amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/Student&amp;quot;^^rif:iri ## &amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/Person&amp;quot;^^rif:iri&amp;lt;/tt&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
f. External term:  &amp;lt;tt&amp;gt;External(pred:numeric-greater-than(?diffdays 10)))&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-formulas&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== Formulas ====&lt;br /&gt;
&lt;br /&gt;
RIF-BLD distinguishes certain subsets of the set &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt; of symbols, including subsets of ''predicate symbols'' and ''function symbols''. Section [[#sec-well-formed|Well-formed Formulas]] gives more details, but we do not need those details yet.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-bld-atomic-formula&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
'''Definition (Atomic Formula)'''.&lt;br /&gt;
Any term (positional or with named arguments) of the form &amp;lt;tt&amp;gt;p(...)&amp;lt;/tt&amp;gt;, where &amp;lt;tt&amp;gt;p&amp;lt;/tt&amp;gt; is a predicate symbol, is also an '''''atomic formula'''''. Equality, membership, subclass, and frame terms are also atomic formulas. An externally defined term of the form &amp;lt;tt&amp;gt;External(&amp;amp;phi;)&amp;lt;/tt&amp;gt;, where &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; is an atomic formula, is also an atomic formula, called an '''''externally defined''''' atomic formula.&lt;br /&gt;
&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
&lt;br /&gt;
Note that simple terms (constants and variables) are ''not'' formulas.&lt;br /&gt;
&lt;br /&gt;
More general formulas are constructed from atomic formulas with the help of logical connectives.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-bld-formula&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
'''Definition (Formula)'''.&lt;br /&gt;
A '''''formula''''' can have several different forms and is defined as follows:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    ''Atomic'': If &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;  is an atomic formula then it is also a formula.&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    ''&amp;lt;span id=&amp;quot;def-bld-condition&amp;quot;&amp;gt;Condition formula&amp;lt;/span&amp;gt;'': A '''''condition formula''''' is either an atomic formula or a formula that has one of the following forms:&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;&lt;br /&gt;
        ''Conjunction'': If &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, ..., &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;,  &amp;lt;tt&amp;gt;n &amp;amp;ge; 0&amp;lt;/tt&amp;gt;, are condition formulas then so is &amp;lt;tt&amp;gt;And(&amp;amp;phi;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... &amp;amp;phi;&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;)&amp;lt;/tt&amp;gt;, called a ''conjunctive'' formula. As a special case, &amp;lt;tt&amp;gt;And()&amp;lt;/tt&amp;gt; is allowed and is treated as a tautology, i.e., a formula that is always true. &lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;&lt;br /&gt;
        ''Disjunction'': If &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, ..., &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;n &amp;amp;ge; 0&amp;lt;/tt&amp;gt;, are condition formulas then so is &amp;lt;tt&amp;gt;Or(&amp;amp;phi;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... &amp;amp;phi;&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;)&amp;lt;/tt&amp;gt;, called a ''disjunctive'' formula. As a special case, &amp;lt;tt&amp;gt;Or()&amp;lt;/tt&amp;gt; is permitted and is treated as a contradiction, i.e., a formula that is always false. &lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;&lt;br /&gt;
        ''Existentials'': If &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;  is a condition formula and &amp;lt;tt&amp;gt;?V&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, ..., &amp;lt;tt&amp;gt;?V&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;n&amp;amp;gt;0&amp;lt;/tt&amp;gt;, are distinct variables then &amp;lt;tt&amp;gt;Exists ?V&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... ?V&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;(&amp;amp;phi;)&amp;lt;/tt&amp;gt; is an ''existential'' formula. &lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt; &lt;br /&gt;
    &amp;lt;p&amp;gt;&lt;br /&gt;
      Condition formulas are intended to be used inside the premises of rules. Next we define the notions of rule implications, universal rules, universal facts, groups (i.e., sets of rules and facts), and documents.&lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    ''Rule implication'': &amp;lt;tt&amp;gt;&amp;amp;phi; :- &amp;amp;psi;&amp;lt;/tt&amp;gt; is a formula, called ''rule implication'', if:&lt;br /&gt;
    &amp;lt;ul&amp;gt;    &lt;br /&gt;
      &amp;lt;li&amp;gt;&lt;br /&gt;
        &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;  is an atomic formula or a ''conjunction'' of atomic formulas,&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;&lt;br /&gt;
	&amp;lt;tt&amp;gt;&amp;amp;psi;&amp;lt;/tt&amp;gt;  is a condition formula, and&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;      &lt;br /&gt;
	none of the atomic formulas in &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;  is an externally defined term (i.e., a term of the form &amp;lt;tt&amp;gt;External(...)&amp;lt;/tt&amp;gt;). Note: external terms ''can'' occur in the ''arguments'' of atomic formulas in the rule conclusion. For instance, &amp;lt;tt&amp;gt;p(func:numeric-add(?X &amp;quot;2&amp;quot;^^xs:integer)) :- q(?X)&amp;lt;/tt&amp;gt;.&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    ''Universal rule'': If &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;  is a rule implication and &amp;lt;tt&amp;gt;?V&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, ..., &amp;lt;tt&amp;gt;?V&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;n&amp;amp;gt;0&amp;lt;/tt&amp;gt;, are distinct variables then &amp;lt;tt&amp;gt;Forall ?V&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... ?V&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;(&amp;amp;phi;)&amp;lt;/tt&amp;gt; is a formula, called a ''universal rule''. It is required that all the ''free'' variables in &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;  occur among the variables &amp;lt;tt&amp;gt;?V&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... ?V&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; in the quantification part. An occurrence of a variable &amp;lt;tt&amp;gt;?v&amp;lt;/tt&amp;gt; is ''free'' in &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; if it is not inside a subformula of &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; of the form &amp;lt;tt&amp;gt;Exists ?v (&amp;amp;psi;)&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;&amp;amp;psi;&amp;lt;/tt&amp;gt; is a formula.  Universal rules will also be referred to as '''''&amp;lt;span id=&amp;quot;def-rif-bld-rule&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;RIF-BLD rules&amp;lt;/span&amp;gt;'''''.&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    ''Universal fact'': If &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;  is an atomic formula and &amp;lt;tt&amp;gt;?V&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, ..., &amp;lt;tt&amp;gt;?V&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;n&amp;amp;gt;0&amp;lt;/tt&amp;gt;, are distinct variables then&lt;br /&gt;
     &amp;lt;tt&amp;gt;Forall ?V&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... ?V&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;(&amp;amp;phi;)&amp;lt;/tt&amp;gt; is a formula, called a ''universal fact'', provided that all the free variables in  &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;  occur among the variables &amp;lt;tt&amp;gt;?V&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... ?V&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;.&lt;br /&gt;
    &amp;lt;p&amp;gt;&lt;br /&gt;
      Universal facts are often considered to be rules without premises.&lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    ''Group'': If &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, ..., &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; are RIF-BLD rules, universal facts, variable-free rule implications, variable-free atomic formulas, ''or'' group formulas then &amp;lt;tt&amp;gt;Group(&amp;amp;phi;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... &amp;amp;phi;&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;)&amp;lt;/tt&amp;gt; is a ''group formula''. As a special case, the empty group formula, &amp;lt;tt&amp;gt;Group()&amp;lt;/tt&amp;gt;, is allowed and is treated as a tautology, i.e., a formula that is always true.&lt;br /&gt;
    &amp;lt;p&amp;gt;&lt;br /&gt;
       Non-empty group formulas are used to represent sets of rules and facts. Note that some of the &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;'s can be group formulas themselves, which means that groups can be nested. &lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;  &lt;br /&gt;
    ''Document'': An expression of the form &amp;lt;tt&amp;gt;Document(&amp;lt;em&amp;gt;directive&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/em&amp;gt; ... &amp;lt;em&amp;gt;directive&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/em&amp;gt; &amp;amp;Gamma;)&amp;lt;/tt&amp;gt; is a ''RIF-BLD document formula'' (or simply a ''document formula''), if&lt;br /&gt;
    &amp;lt;ul&amp;gt;    &lt;br /&gt;
      &amp;lt;li&amp;gt;      &lt;br /&gt;
	&amp;lt;tt&amp;gt;&amp;amp;Gamma;&amp;lt;/tt&amp;gt; is an optional group formula; it is called the group formula &amp;lt;span id=&amp;quot;def-associated-group&amp;quot;&amp;gt;''associated''&amp;lt;/span&amp;gt; with the document.&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;&lt;br /&gt;
	&amp;lt;tt&amp;gt;&amp;lt;em&amp;gt;directive&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/em&amp;gt;&amp;lt;/tt&amp;gt;, ..., &amp;lt;tt&amp;gt;&amp;lt;em&amp;gt;directive&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/em&amp;gt;&amp;lt;/tt&amp;gt; is an optional sequence of &amp;lt;span id=&amp;quot;def-directives&amp;quot;&amp;gt;&amp;lt;em&amp;gt;directives&amp;lt;/em&amp;gt;&amp;lt;/span&amp;gt;. A directive can be a ''base directive'', a ''prefix directive'' or an ''import directive''. &lt;br /&gt;
      &amp;lt;ul&amp;gt;&lt;br /&gt;
	&amp;lt;li&amp;gt;	&lt;br /&gt;
	  A '''''base directive''''' has the form &amp;lt;tt&amp;gt;Base(&amp;amp;lt;iri&amp;amp;gt;)&amp;lt;/tt&amp;gt;, where &amp;lt;tt&amp;gt;iri&amp;lt;/tt&amp;gt; is a Unicode string in the form of an absolute IRI &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rfc-3987|RFC-3987]]].&lt;br /&gt;
	  &amp;lt;p&amp;gt;&lt;br /&gt;
	    The &amp;lt;tt&amp;gt;Base&amp;lt;/tt&amp;gt; directive defines a syntactic shortcut for expanding relative IRIs into full IRIs, as described in Section [[DTB#sec-constants|Constants, Symbol Spaces, and Datatypes]] of &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]].   This applies to relative IRIs that appear anywhere, including as constants, symbol spaces, locators, and profiles.&lt;br /&gt;
	  &amp;lt;/p&amp;gt;&lt;br /&gt;
	&amp;lt;/li&amp;gt;&lt;br /&gt;
	&amp;lt;li&amp;gt;	&lt;br /&gt;
	   A '''''prefix directive''''' has the form &amp;lt;tt&amp;gt;Prefix(p &amp;amp;lt;v&amp;amp;gt;)&amp;lt;/tt&amp;gt;, where &amp;lt;tt&amp;gt;p&amp;lt;/tt&amp;gt; is an alphanumeric string that serves as the prefix name and &amp;lt;tt&amp;gt;v&amp;lt;/tt&amp;gt; is an expansion for &amp;lt;tt&amp;gt;p&amp;lt;/tt&amp;gt; -- a Unicode sequence of characters that forms an IRI.&lt;br /&gt;
	   (An alphanumeric string is a sequence of ASCII characters, where each character is a letter, a digit, or an underscore &amp;quot;_&amp;quot;, and the first character is a letter.)&lt;br /&gt;
	   &amp;lt;p&amp;gt;&lt;br /&gt;
	      Like the &amp;lt;tt&amp;gt;Base&amp;lt;/tt&amp;gt; directive, the &amp;lt;tt&amp;gt;Prefix&amp;lt;/tt&amp;gt; directives can be used to define shorthands to allow more concise representation of constants that come from the symbol space &amp;lt;tt&amp;gt;rif:iri&amp;lt;/tt&amp;gt; (we will call such constants &amp;lt;tt&amp;gt;rif:iri&amp;lt;/tt&amp;gt; '''''constants'''''). This mechanism is explained in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]], Section [[DTB#sec-constants|Constants, Symbol Spaces, and Datatypes]].&lt;br /&gt;
	   &amp;lt;/p&amp;gt;&lt;br /&gt;
	&amp;lt;/li&amp;gt;&lt;br /&gt;
	&amp;lt;li&amp;gt;      &lt;br /&gt;
	  An '''''import directive''''' can have one of these two forms: &amp;lt;tt&amp;gt;Import(&amp;amp;lt;loc&amp;amp;gt;)&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;Import(&amp;amp;lt;loc&amp;amp;gt; &amp;amp;lt;p&amp;amp;gt;)&amp;lt;/tt&amp;gt;. Here &amp;lt;tt&amp;gt;loc&amp;lt;/tt&amp;gt; is a Unicode sequence of characters that forms an IRI and &amp;lt;tt&amp;gt;p&amp;lt;/tt&amp;gt; is another Unicode sequence of characters. The constant &amp;lt;tt&amp;gt;loc&amp;lt;/tt&amp;gt; represents the location of another document to be imported; it is called the &amp;lt;span id=&amp;quot;ref-locator&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;'''''locator'''''&amp;lt;/span&amp;gt; of the imported document. The argument &amp;lt;tt&amp;gt;p&amp;lt;/tt&amp;gt; is called the ''profile of import''; it has the form of a Unicode character sequence in the form of an IRI -- see &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-swc|RIF-RDF+OWL]]].&lt;br /&gt;
	  &amp;lt;p&amp;gt;&lt;br /&gt;
	    Section [[#sec-bld-direct-semantics|Direct Specification of RIF-BLD Semantics]] of this document defines the semantics for the directive &amp;lt;tt&amp;gt;Import(&amp;amp;lt;loc&amp;amp;gt;)&amp;lt;/tt&amp;gt; only. The two-argument directive, &amp;lt;tt&amp;gt;Import(&amp;amp;lt;loc&amp;amp;gt; &amp;amp;lt;p&amp;amp;gt;)&amp;lt;/tt&amp;gt;, is intended for importing non-RIF-BLD documents, such as rules from other RIF dialects, RDF data, or OWL ontologies. The profile, &amp;lt;tt&amp;gt;p&amp;lt;/tt&amp;gt;, indicates what kind of entity is being imported and under what semantics (for instance, the various RDF entailment regimes have different profiles). The semantics of &amp;lt;tt&amp;gt;Import(&amp;amp;lt;loc&amp;amp;gt; &amp;amp;lt;p&amp;amp;gt;)&amp;lt;/tt&amp;gt; (for various &amp;lt;tt&amp;gt;p&amp;lt;/tt&amp;gt;) are expected to be given by other specifications on a case-by-case basis. For instance, &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-swc|RIF-RDF+OWL]]] defines the semantics for the profiles that are recommended for importing RDF and OWL.&lt;br /&gt;
	  &amp;lt;/p&amp;gt;&lt;br /&gt;
	&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;/ul&amp;gt;&lt;br /&gt;
      &amp;lt;p&amp;gt;&lt;br /&gt;
        Note that although &amp;lt;tt&amp;gt;Base&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;Prefix&amp;lt;/tt&amp;gt;, and &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; all use symbols of the form &amp;amp;lt;iri&amp;amp;gt; to indicate the connection of these symbols to IRIs, these symbols are &amp;lt;em&amp;gt;not&amp;lt;/em&amp;gt; &amp;lt;tt&amp;gt;rif:iri&amp;lt;/tt&amp;gt; constants, as semantically they are interpreted in a way that is quite different from constants.&lt;br /&gt;
      &amp;lt;/p&amp;gt;&lt;br /&gt;
      &amp;lt;p&amp;gt;&lt;br /&gt;
        A document formula can contain at most one &amp;lt;tt&amp;gt;Base&amp;lt;/tt&amp;gt; directive. The &amp;lt;tt&amp;gt;Base&amp;lt;/tt&amp;gt; directive, if present, must be first, followed by any number of &amp;lt;tt&amp;gt;Prefix&amp;lt;/tt&amp;gt; directives, followed by any number of &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directives.&lt;br /&gt;
      &amp;lt;/p&amp;gt;&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
  In the definition of a formula, the component formulas &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;&amp;amp;psi;&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, and &amp;lt;tt&amp;gt;&amp;amp;Gamma;&amp;lt;/tt&amp;gt;  are said to be &amp;lt;span id=&amp;quot;def-subformula&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;'''''subformulas'''''&amp;lt;/span&amp;gt; of the respective formulas (condition, rule, group, etc.) that are built using these components. &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-formal-syntax-metadata&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== RIF-BLD Annotations in the Presentation Syntax ====&lt;br /&gt;
&lt;br /&gt;
RIF-BLD allows every term and formula (including terms and formulas that occur inside other terms and formulas) to be optionally preceded by ''one'' '''''annotation''''' of the form &amp;lt;tt&amp;gt;(* id &amp;amp;phi; *)&amp;lt;/tt&amp;gt;, where &amp;lt;tt&amp;gt;id&amp;lt;/tt&amp;gt; is a &amp;lt;tt&amp;gt;[[DTB#rif-iri-space|rif:iri]]&amp;lt;/tt&amp;gt; constant and &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; is a frame formula or a conjunction of frame formulas. Both items inside the annotation are optional. The &amp;lt;tt&amp;gt;id&amp;lt;/tt&amp;gt; part represents the identifier of the term or formula to which the annotation is attached and &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; is the metadata part of the annotation. RIF-BLD does not impose any restrictions on &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; apart from what is stated above. This means that it may include variables, function symbols, constants from the symbol space &amp;lt;tt&amp;gt;[[DTB#rif-local-space|rif:local]]&amp;lt;/tt&amp;gt; (often referred to as '''''local''''' or &amp;lt;tt&amp;gt;rif:local&amp;lt;/tt&amp;gt; '''''constants'''''), and so on.   &lt;br /&gt;
&lt;br /&gt;
Document formulas with and without annotations will be referred to as '''''&amp;lt;span id=&amp;quot;def-rif-bld-document&amp;quot;&amp;gt;RIF-BLD documents&amp;lt;/span&amp;gt;'''''.&lt;br /&gt;
&lt;br /&gt;
The following convention is used to avoid a syntactic ambiguity with respect to annotations. The annotation scoping convention associates each annotation to the largest term or formula it precedes. For instance, in &amp;lt;tt&amp;gt;(* id &amp;amp;phi; *) t[w -&amp;gt; v]&amp;lt;/tt&amp;gt; the metadata annotation could be attributed to the term &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; or to the entire frame &amp;lt;tt&amp;gt;t[w -&amp;gt; v]&amp;lt;/tt&amp;gt;. The convention specifies that the above annotation is considered to be syntactically attached to the entire frame. Yet, since &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; can be a conjunction, some conjuncts can be used to provide metadata targeted to the object part, &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt;, of the frame. For instance, &amp;lt;tt&amp;gt;(* And(_foo[meta_for_frame-&amp;gt;&amp;quot;this is an annotation for the entire frame&amp;quot;] _bar[meta_for_object-&amp;gt;&amp;quot;this is an annotation for t&amp;quot; meta_for_property-&amp;gt;&amp;quot;this is an annotation for w&amp;quot;]) *) t[w -&amp;gt; v]&amp;lt;/tt&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We suggest to use Dublin Core, RDFS, and OWL properties for metadata, along the lines of [http://www.w3.org/TR/owl-ref/#Annotations Section 7.1] of &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-owl-reference|OWL-Reference]]]-- specifically &amp;lt;tt&amp;gt;owl:versionInfo&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;rdfs:label&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;rdfs:comment&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;rdfs:seeAlso&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;rdfs:isDefinedBy&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;dc:creator&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;dc:description&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;dc:date&amp;lt;/tt&amp;gt;, and &amp;lt;tt&amp;gt;foaf:maker&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-well-formed&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== Well-formed Formulas ====&lt;br /&gt;
&lt;br /&gt;
Not all formulas and thus not all documents are well-formed in RIF-BLD:&lt;br /&gt;
it is required that no constant appear in more than one context. What this means precisely is explained below. Informally, this means that each constant symbol in RIF-BLD can be either an individual, a plain function, a plain predicate, an externally defined function, or an externally defined predicate. However, symbols can be ''polyadic'': the same function or predicate symbol (normal or external) can occur with different numbers of arguments in different places. Note that polyadic symbols could be replaced by non-polyadic symbols with the arity information encoded in the function or predicate names. For instance, the polyadic terms &amp;lt;tt&amp;gt;p(?X)&amp;lt;/tt&amp;gt;  and &amp;lt;tt&amp;gt;p(?X,?Y)&amp;lt;/tt&amp;gt;  could be represented as &amp;lt;tt&amp;gt;p_1(?X)&amp;lt;/tt&amp;gt;  and &amp;lt;tt&amp;gt;p_2(?X,?Y)&amp;lt;/tt&amp;gt;,  respectively.&lt;br /&gt;
&lt;br /&gt;
The set of all constant symbols, &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt;, is partitioned into the following subsets:&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;A subset of individuals.&lt;br /&gt;
    &amp;lt;p&amp;gt;The symbols in &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt; that belong to the symbol spaces of [[DTB#sec-data-types|Datatypes]] are required to be individuals.&amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;A subset of plain (i.e., non-external) function symbols.&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;A subset for external function symbols.&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;A subset of plain predicate symbols.&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;A subset for external predicate symbols.&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The above subsets do not differentiate between positional and named argument symbols. Also, as seen from the following definitions, these subsets are not specified explicitly but, rather, are inferred from the occurrences of the symbols.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-bld-context&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
'''Definition (Context of a symbol)'''.&lt;br /&gt;
The '''''context of an occurrence''''' of a symbol, &amp;lt;tt&amp;gt;s&amp;amp;isin;Const&amp;lt;/tt&amp;gt;, in a formula, &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;,  is determined as follows:&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
     If &amp;lt;tt&amp;gt;s&amp;lt;/tt&amp;gt; occurs as a predicate of the form &amp;lt;tt&amp;gt;s(...)&amp;lt;/tt&amp;gt; (positional or named-argument) in an atomic [[#def-subformula|subformula]] of &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; then &amp;lt;tt&amp;gt;s&amp;lt;/tt&amp;gt; occurs in the ''context of a (plain) predicate symbol''.     &lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
     If &amp;lt;tt&amp;gt;s&amp;lt;/tt&amp;gt; occurs as a function symbol in a non-subformula term of the form &amp;lt;tt&amp;gt;s(...)&amp;lt;/tt&amp;gt; then &amp;lt;tt&amp;gt;s&amp;lt;/tt&amp;gt; occurs in the ''context of a (plain) function symbol''.&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;  &lt;br /&gt;
    If &amp;lt;tt&amp;gt;s&amp;lt;/tt&amp;gt; occurs as a predicate in an atomic subformula &amp;lt;tt&amp;gt;External(s(...))&amp;lt;/tt&amp;gt; then &amp;lt;tt&amp;gt;s&amp;lt;/tt&amp;gt; occurs in the ''context of an external predicate symbol''.&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;  &lt;br /&gt;
    If &amp;lt;tt&amp;gt;s&amp;lt;/tt&amp;gt; occurs as a function in a non-subformula term &amp;lt;tt&amp;gt;External(s(...))&amp;lt;/tt&amp;gt; then &amp;lt;tt&amp;gt;s&amp;lt;/tt&amp;gt; occurs in the ''context of an external function symbol''.&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;  &lt;br /&gt;
     If &amp;lt;tt&amp;gt;s&amp;lt;/tt&amp;gt; occurs in any other context (in a frame: &amp;lt;tt&amp;gt;s[...]&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;...[s-&amp;gt;...]&amp;lt;/tt&amp;gt;, or &amp;lt;tt&amp;gt;...[...-&amp;gt;s]&amp;lt;/tt&amp;gt;; or in a positional/named-argument term: &amp;lt;tt&amp;gt;p(...s...)&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;q(...-&amp;gt;s...)&amp;lt;/tt&amp;gt;), it is said to occur as an ''individual''. &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-bld-imported-doc&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
'''Definition (Imported document).'''&lt;br /&gt;
Let &amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt; be a document formula and &amp;lt;tt&amp;gt;Import(''loc'')&amp;lt;/tt&amp;gt; be one of its import directives, where ''loc'' is a [[#ref-locator|locator]] of another document formula, &amp;lt;tt&amp;gt;&amp;amp;Delta;'&amp;lt;/tt&amp;gt;.  We say that &amp;lt;tt&amp;gt;&amp;amp;Delta;'&amp;lt;/tt&amp;gt; is '''''directly imported''''' into &amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
A document formula &amp;lt;tt&amp;gt;&amp;amp;Delta;'&amp;lt;/tt&amp;gt; is said to be '''''imported''''' into&lt;br /&gt;
&amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt; if it is either directly imported into &amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt; or it is imported (directly or not) into some other formula that is directly imported into &amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt;. &amp;amp;nbsp; &amp;amp;nbsp; &amp;amp;#9744;  &lt;br /&gt;
&lt;br /&gt;
The above definition deals only with one-argument import directives, since &lt;br /&gt;
only such directives can be used to import other RIF-BLD documents.&lt;br /&gt;
Two-argument import directives are provided to enable import of other types of documents, and their semantics are supposed to be covered by other specifications, such as &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-swc|RIF-RDF+OWL]]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-bld-wff&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
'''Definition (Well-formed formula)'''.&lt;br /&gt;
A formula &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;  is '''''well-formed''''' iff:&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    every constant symbol (whether coming from the symbol space &amp;lt;tt&amp;gt;[[DTB#rif-local-space|rif:local]]&amp;lt;/tt&amp;gt; or not) mentioned in &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; occurs in exactly one [[#def-bld-context|context]].&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;  &lt;br /&gt;
    if &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; is a document formula and &amp;lt;tt&amp;gt;&amp;amp;Delta;'&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, ..., &amp;lt;tt&amp;gt;&amp;amp;Delta;'&amp;lt;sub&amp;gt;k&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; are all of its imported documents, then every non-&amp;lt;tt&amp;gt;rif:local&amp;lt;/tt&amp;gt; constant symbol mentioned in &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; or any of the imported &amp;lt;tt&amp;gt;&amp;amp;Delta;'&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;s must occur in exactly one context (in all of the &amp;lt;tt&amp;gt;&amp;amp;Delta;'&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;s).&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    whenever a formula contains a term or a subformula of the form &amp;lt;tt&amp;gt;External(t)&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; must be an instantiation of a schema in the coherent set of external schemas (Section [[DTB#app-external-schema|Schemas for Externally Defined Terms]] of &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]]) associated with the [[#def-bld-lang|language of RIF-BLD]].&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    if &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; is an instantiation of a schema in the coherent set of external schemas associated with the language then &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; can occur only as &amp;lt;tt&amp;gt;External(t)&amp;lt;/tt&amp;gt;, i.e., as an external term or atomic formula. &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-bld-lang&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
'''Definition (Language of RIF-BLD)'''.&lt;br /&gt;
The '''''language of RIF-BLD''''' consists of the set of all well-formed formulas and is determined by:&lt;br /&gt;
* the alphabet of the language and&lt;br /&gt;
* a  set of [[DTB#def-external-schema-set|coherent external schemas]], which determine the available built-ins and other externally defined predicates and functions. &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-concrete-syntax&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== EBNF Grammar for the Presentation Syntax of RIF-BLD (Informative) ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Until now, we have been using mathematical English to specify the syntax of RIF-BLD. Tool developers, however, may prefer EBNF notation, which provides a more succinct view of the syntax. Several points should be kept in mind regarding this notation. &lt;br /&gt;
&lt;br /&gt;
* The syntax of first-order logic is not context-free, so EBNF cannot capture the syntax of RIF-BLD precisely. For instance, it cannot capture some [[#sec-well-formed|well-formedness conditions]], such as the requirement that external terms must be instances of external schemas. As a result, the EBNF grammar defines a strict ''superset'' of RIF-BLD: not all formulas that are derivable using the EBNF grammar are well-formed formulas in RIF-BLD. &lt;br /&gt;
* The EBNF grammar does not address all details of how constants (defined in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]]) and variables are represented, and it is not sufficiently precise about the delimiters and escape symbols. White space is informally used as a delimiter, and is implied in productions that use Kleene star. For instance, &amp;lt;tt&amp;gt;TERM*&amp;lt;/tt&amp;gt; is to be understood as &amp;lt;tt&amp;gt;TERM&amp;amp;nbsp;TERM&amp;amp;nbsp;...&amp;amp;nbsp;TERM&amp;lt;/tt&amp;gt;, where each space abstracts from one or more blanks, tabs, newlines, etc. This is so because RIF's presentation syntax is a tool for specifying the semantics and for illustration of the main RIF concepts through examples. It is ''not'' intended as a concrete syntax for a rule language. RIF defines a concrete syntax only for ''exchanging'' rules, and that syntax is XML-based, obtained as a refinement and serialization of the presentation syntax.&lt;br /&gt;
* For all the above reasons, the EBNF grammar is ''not normative''. Recall from the [[#sec-bld-direct-syntax|opening paragraph]], however, that the RIF-BLD presentation syntax as specified in mathematical English is normative.&lt;br /&gt;
&lt;br /&gt;
The EBNF for the RIF-BLD presentation syntax is given as follows, showing the entire (top-down) context of its three parts for rules, conditions, and annotations.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;part-rule-language&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
'''Rule Language:'''&lt;br /&gt;
   Document       ::= IRIMETA? 'Document' '(' Base? Prefix* Import* Group? ')'&lt;br /&gt;
   Base           ::= 'Base' '(' [[DTB#sec-shortcuts-constants|ANGLEBRACKIRI]] ')'&lt;br /&gt;
   Prefix         ::= 'Prefix' '(' [http://www.w3.org/TR/2006/REC-xml-names11-20060816/#NT-NCName NCName] [[DTB#sec-shortcuts-constants|ANGLEBRACKIRI]] ')'&lt;br /&gt;
   Import         ::= IRIMETA? 'Import' '(' LOCATOR PROFILE? ')'&lt;br /&gt;
   Group          ::= IRIMETA? 'Group' '(' (RULE | Group)* ')'&lt;br /&gt;
   RULE           ::= (IRIMETA? 'Forall' Var+ '(' CLAUSE ')') | CLAUSE&lt;br /&gt;
   CLAUSE         ::= Implies | ATOMIC&lt;br /&gt;
   Implies        ::= IRIMETA? (ATOMIC | 'And' '(' ATOMIC* ')') ':-' FORMULA&lt;br /&gt;
   LOCATOR        ::= [[DTB#sec-shortcuts-constants|ANGLEBRACKIRI]]&lt;br /&gt;
   PROFILE        ::= [[DTB#sec-shortcuts-constants|ANGLEBRACKIRI]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;part-condition-language&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
'''Condition Language:'''&lt;br /&gt;
   FORMULA        ::= IRIMETA? 'And' '(' FORMULA* ')' |&lt;br /&gt;
                      IRIMETA? 'Or' '(' FORMULA* ')' |&lt;br /&gt;
                      IRIMETA? 'Exists' Var+ '(' FORMULA ')' |&lt;br /&gt;
                      ATOMIC |&lt;br /&gt;
                      IRIMETA? 'External' '(' Atom ')'&lt;br /&gt;
   ATOMIC         ::= IRIMETA? (Atom | Equal | Member | Subclass | Frame)&lt;br /&gt;
   Atom           ::= UNITERM&lt;br /&gt;
   UNITERM        ::= Const '(' (TERM* | (Name '-&amp;gt;' TERM)*) ')'&lt;br /&gt;
   Equal          ::= TERM '=' TERM&lt;br /&gt;
   Member         ::= TERM '#' TERM&lt;br /&gt;
   Subclass       ::= TERM '##' TERM&lt;br /&gt;
   Frame          ::= TERM '[' (TERM '-&amp;gt;' TERM)* ']'&lt;br /&gt;
   TERM           ::= IRIMETA? (Const | Var | Expr | List | 'External' '(' Expr ')')&lt;br /&gt;
   Expr           ::= UNITERM&lt;br /&gt;
   List           ::= 'List' '(' TERM* ')' | 'List' '(' TERM+ '|' TERM ')'&lt;br /&gt;
   Const          ::= '&amp;quot;' [[DTB#sec-shortcuts-constants|UNICODESTRING]] '&amp;quot;^^' SYMSPACE | [[DTB#sec-shortcuts-constants|CONSTSHORT]]&lt;br /&gt;
   Var            ::= '?' Name&lt;br /&gt;
   Name           ::= [http://www.w3.org/TR/2006/REC-xml-names11-20060816/#NT-NCName NCName] | '&amp;quot;' [[DTB#sec-shortcuts-constants|UNICODESTRING]] '&amp;quot;'&lt;br /&gt;
   SYMSPACE       ::= [[DTB#sec-shortcuts-constants|ANGLEBRACKIRI]] | [[DTB#sec-shortcuts-constants|CURIE]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;part-annotations&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
'''Annotations:'''&lt;br /&gt;
   IRIMETA        ::= '(*' IRICONST? (Frame | 'And' '(' Frame* ')')? '*)'&lt;br /&gt;
&lt;br /&gt;
The following subsections explain and exemplify these parts, starting with the basic language of positive conditions.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-ebnf-condition-language&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
===== EBNF for the Condition Language =====&lt;br /&gt;
&lt;br /&gt;
The Condition Language represents formulas that can be used in the premises of RIF-BLD rules (also called rule bodies). The EBNF grammar for a superset of the RIF-BLD condition language is shown in the above [[#part-condition-language|conditions part]].&lt;br /&gt;
&lt;br /&gt;
The production rule for the non-terminal &amp;lt;tt&amp;gt;FORMULA&amp;lt;/tt&amp;gt; represents ''RIF condition formulas'' (defined earlier). The connectives &amp;lt;tt&amp;gt;And&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;Or&amp;lt;/tt&amp;gt; define conjunctions and disjunctions of conditions, respectively. &amp;lt;tt&amp;gt;Exists&amp;lt;/tt&amp;gt; introduces existentially quantified variables. Here &amp;lt;tt&amp;gt;Var+&amp;lt;/tt&amp;gt; stands for the list of variables that are free in &amp;lt;tt&amp;gt;FORMULA&amp;lt;/tt&amp;gt;.  A RIF-BLD &amp;lt;tt&amp;gt;FORMULA&amp;lt;/tt&amp;gt; can also be an &amp;lt;tt&amp;gt;ATOMIC&amp;lt;/tt&amp;gt; term, i.e. an &amp;lt;tt&amp;gt;Atom&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;External&amp;lt;/tt&amp;gt; &amp;lt;tt&amp;gt;Atom&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;Equal&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;Member&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;Subclass&amp;lt;/tt&amp;gt;, or &amp;lt;tt&amp;gt;Frame&amp;lt;/tt&amp;gt;. A &amp;lt;tt&amp;gt;TERM&amp;lt;/tt&amp;gt; can be a constant, variable, &amp;lt;tt&amp;gt;Expr&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;List&amp;lt;/tt&amp;gt;, or &amp;lt;tt&amp;gt;External&amp;lt;/tt&amp;gt; &amp;lt;tt&amp;gt;Expr&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The RIF-BLD presentation syntax does not commit to any particular vocabulary and permits arbitrary Unicode strings in constant symbols, argument names, and variables. Constant symbols can have this form: &amp;lt;tt&amp;gt;&amp;quot;UNICODESTRING&amp;quot;^^SYMSPACE&amp;lt;/tt&amp;gt;, where &amp;lt;tt&amp;gt;SYMSPACE&amp;lt;/tt&amp;gt; is an &amp;lt;tt&amp;gt;ANGLEBRACKIRI&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;CURIE&amp;lt;/tt&amp;gt; that represents the identifier of the symbol space of the constant. &amp;lt;tt&amp;gt;UNICODESTRING&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;ANGLEBRACKIRI&amp;lt;/tt&amp;gt;, and &amp;lt;tt&amp;gt;CURIE&amp;lt;/tt&amp;gt; are defined in Section [[DTB#sec-shortcuts-constants|Shortcuts for Constants in RIF's Presentation Syntax]] of &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]]. Constant symbols can also have several shortcut forms, which are represented by the non-terminal &amp;lt;tt&amp;gt;CONSTSHORT&amp;lt;/tt&amp;gt;. These shortcuts are also defined in the same section of &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]]. One of them is the &amp;lt;tt&amp;gt;CURIE&amp;lt;/tt&amp;gt; shortcut, which is extensively used in the examples in this document.&lt;br /&gt;
Names are Unicode character sequences. Variables are composed of &amp;lt;tt&amp;gt;UNICODESTRING&amp;lt;/tt&amp;gt; symbols prefixed with a &amp;lt;tt&amp;gt;?&amp;lt;/tt&amp;gt;-sign.&lt;br /&gt;
&lt;br /&gt;
Equality, membership, and subclass terms are self-explanatory. An &amp;lt;tt&amp;gt;Atom&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;Expr&amp;lt;/tt&amp;gt; (expression) can either be positional or have named arguments. A frame term is a term composed of an object identifier and a collection of attribute-value pairs. The term &amp;lt;tt&amp;gt;External&amp;lt;/tt&amp;gt;(&amp;lt;tt&amp;gt;Atom&amp;lt;/tt&amp;gt;) is a call to an externally defined predicate. Likewise, &amp;lt;tt&amp;gt;External&amp;lt;/tt&amp;gt;(&amp;lt;tt&amp;gt;Expr&amp;lt;/tt&amp;gt;) is a call to an externally defined function.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ex-rif-bld-cond-pres-syntax&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&lt;br /&gt;
'''Example 3''' (RIF-BLD conditions).&lt;br /&gt;
&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This example shows conditions that are composed of atoms, expressions, equalities with lists, frames, and existentials. In frame formulas, variables are shown in the positions of object identifiers, object properties, and property values. For brevity, we use the shortcut CURIE notation &amp;lt;tt&amp;gt;prefix:suffix&amp;lt;/tt&amp;gt; for constant symbols defined in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]]. This is understood as a shorthand for an IRI obtained by concatenation of the &amp;lt;tt&amp;gt;prefix&amp;lt;/tt&amp;gt;  definition and &amp;lt;tt&amp;gt;suffix&amp;lt;/tt&amp;gt;. Thus, if &amp;lt;tt&amp;gt;bks&amp;lt;/tt&amp;gt; is a prefix that expands into &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/books#&amp;lt;/tt&amp;gt; then &amp;lt;tt&amp;gt;bks:LeRif&amp;lt;/tt&amp;gt; is an abbreviation for &amp;lt;tt&amp;gt;&amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/books#LeRif&amp;quot;^^rif:iri&amp;lt;/tt&amp;gt;. &lt;br /&gt;
 &lt;br /&gt;
 Prefix(bks  &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/books#&amp;amp;gt;)&lt;br /&gt;
 Prefix(auth &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/authors#&amp;amp;gt;)&lt;br /&gt;
 Prefix(cpt  &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/concepts#&amp;amp;gt;)&lt;br /&gt;
 &lt;br /&gt;
Positional terms:&lt;br /&gt;
   &lt;br /&gt;
   cpt:book(auth:rifwg bks:LeRif)&lt;br /&gt;
   Exists ?X (cpt:book(?X bks:LeRif))&lt;br /&gt;
 &lt;br /&gt;
Terms with named arguments:&lt;br /&gt;
 &lt;br /&gt;
   cpt:book(cpt:author-&amp;gt;auth:rifwg  cpt:title-&amp;gt;bks:LeRif)&lt;br /&gt;
   Exists ?X (cpt:book(cpt:author-&amp;gt;?X cpt:title-&amp;gt;bks:LeRif))&lt;br /&gt;
 &lt;br /&gt;
Equalities with list terms:&lt;br /&gt;
&lt;br /&gt;
   ?L = List(?X ?Y ?X)&lt;br /&gt;
   List(?Head | ?Tail) = List(&amp;quot;a&amp;quot;^^rif:local ?Y &amp;quot;c&amp;quot;^^rif:local)&lt;br /&gt;
 &lt;br /&gt;
Frames:&lt;br /&gt;
 &lt;br /&gt;
   bks:wd1[cpt:author-&amp;gt;auth:rifwg cpt:title-&amp;gt;bks:LeRif]&lt;br /&gt;
   Exists ?X (bks:wd2[cpt:author-&amp;gt;?X  cpt:title-&amp;gt;bks:LeRif])&lt;br /&gt;
   Exists ?X (And (bks:wd2#cpt:book  bks:wd2[cpt:author-&amp;gt;?X  cpt:title-&amp;gt;bks:LeRif]))&lt;br /&gt;
   Exists ?I ?X (?I[cpt:author-&amp;gt;?X  cpt:title-&amp;gt;bks:LeRif])&lt;br /&gt;
   Exists ?I ?X (And (?I#cpt:book ?I[cpt:author-&amp;gt;?X  cpt:title-&amp;gt;bks:LeRif]))&lt;br /&gt;
   Exists ?S (bks:wd2[cpt:author-&amp;gt;auth:rifwg ?S-&amp;gt;bks:LeRif])&lt;br /&gt;
   Exists ?X ?S (bks:wd2[cpt:author-&amp;gt;?X ?S-&amp;gt;bks:LeRif])&lt;br /&gt;
   Exists ?I ?X ?S (And (?I#cpt:book  ?I[author-&amp;gt;?X ?S-&amp;gt;bks:LeRif]))&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-ebnf-rule-language&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== EBNF for the Rule Language =====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The presentation syntax for RIF-BLD rules is based on the syntax in Section [[#sec-ebnf-condition-language|EBNF for RIF-BLD Condition Language]] with the productions shown in the above [[#part-rule-language|rules part]].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;document-preamble&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
A RIF-BLD &amp;lt;tt&amp;gt;Document&amp;lt;/tt&amp;gt; consists of an optional &amp;lt;tt&amp;gt;Base&amp;lt;/tt&amp;gt;, followed by any number of &amp;lt;tt&amp;gt;Prefix&amp;lt;/tt&amp;gt;es, followed by any number of &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt;s, followed by an optional &amp;lt;tt&amp;gt;Group&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&amp;lt;tt&amp;gt;Base&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;Prefix&amp;lt;/tt&amp;gt; serve as shortcut mechanisms for IRIs.&lt;br /&gt;
&amp;lt;tt&amp;gt;IRI&amp;lt;/tt&amp;gt; has the form of an internationalized resource identifier as defined by &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rfc-3987|RFC-3987]]].&lt;br /&gt;
An &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; indicates the location of a document to be imported and an optional profile.&lt;br /&gt;
A RIF-BLD &amp;lt;tt&amp;gt;Group&amp;lt;/tt&amp;gt; is a collection of&lt;br /&gt;
any number of &amp;lt;tt&amp;gt;RULE&amp;lt;/tt&amp;gt; elements along with any number of nested &amp;lt;tt&amp;gt;Group&amp;lt;/tt&amp;gt;s.&lt;br /&gt;
&lt;br /&gt;
Rules are generated using &amp;lt;tt&amp;gt;CLAUSE&amp;lt;/tt&amp;gt; elements. The &amp;lt;tt&amp;gt;RULE&amp;lt;/tt&amp;gt;  production has two alternatives:&lt;br /&gt;
&lt;br /&gt;
* In the first, a &amp;lt;tt&amp;gt;CLAUSE&amp;lt;/tt&amp;gt;  is in the scope of the &amp;lt;tt&amp;gt;Forall&amp;lt;/tt&amp;gt; quantifier. In that case, all variables mentioned in  &amp;lt;tt&amp;gt;CLAUSE&amp;lt;/tt&amp;gt; are required to also appear among the variables in the &amp;lt;tt&amp;gt;Var+&amp;lt;/tt&amp;gt; sequence.&lt;br /&gt;
* In the second alternative, &amp;lt;tt&amp;gt;CLAUSE&amp;lt;/tt&amp;gt; appears on its own. In that case, &amp;lt;tt&amp;gt;CLAUSE&amp;lt;/tt&amp;gt; cannot have variables. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;Var&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;ATOMIC&amp;lt;/tt&amp;gt;, and &amp;lt;tt&amp;gt;FORMULA&amp;lt;/tt&amp;gt; were defined as part of the syntax for positive conditions in Section [[#sec-ebnf-condition-language|EBNF for RIF-BLD Condition Language]]. In the &amp;lt;tt&amp;gt;CLAUSE&amp;lt;/tt&amp;gt; production, an &amp;lt;tt&amp;gt;ATOMIC&amp;lt;/tt&amp;gt; is what is usually called a ''fact''. An &amp;lt;tt&amp;gt;Implies&amp;lt;/tt&amp;gt; ''rule'' can have an &amp;lt;tt&amp;gt;ATOMIC&amp;lt;/tt&amp;gt; or a conjunction of &amp;lt;tt&amp;gt;ATOMIC&amp;lt;/tt&amp;gt; elements as its conclusion; it has a &amp;lt;tt&amp;gt;FORMULA&amp;lt;/tt&amp;gt; as its premise. Note that, by the [[#def-bld-formula|definition of formulas]], externally defined atoms (i.e., formulas of the form &amp;lt;tt&amp;gt;External(Atom)&amp;lt;/tt&amp;gt;) are not allowed in the conclusion part of a rule (&amp;lt;tt&amp;gt;ATOMIC&amp;lt;/tt&amp;gt; does not expand to &amp;lt;tt&amp;gt;External&amp;lt;/tt&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ex-rif-bld-rule-pres-syntax&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&lt;br /&gt;
'''Example 4''' (RIF-BLD rules).&lt;br /&gt;
&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This example shows a business rule borrowed from the document [[UCR|RIF Use Cases and Requirements]]:&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    &amp;lt;em&amp;gt;&lt;br /&gt;
      If an item is perishable and it is delivered to John more than 10 days&lt;br /&gt;
      after the scheduled delivery date then the item will be rejected by him.&lt;br /&gt;
    &amp;lt;/em&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
As before, for better readability we use the compact URI notation, the angle-bracket notation, and the &amp;lt;tt&amp;gt;Base&amp;lt;/tt&amp;gt; directive defined in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]], Section [[DTB#sec-constants|Constants, Symbol Spaces, and Datatypes]]. Again, directives are assumed in the preamble to the document.&lt;br /&gt;
Then, two versions of the main part of the document are given.&lt;br /&gt;
 &lt;br /&gt;
 Base(&amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/people#&amp;amp;gt;)&lt;br /&gt;
 Prefix(cpt  &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/concepts#&amp;amp;gt;)&lt;br /&gt;
 Prefix(func &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2007/rif-builtin-function#&amp;amp;gt;)&lt;br /&gt;
 Prefix(pred &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2007/rif-builtin-predicate#&amp;amp;gt;)&lt;br /&gt;
 &lt;br /&gt;
a. Universal form:&lt;br /&gt;
 &lt;br /&gt;
    Forall ?item ?deliverydate ?scheduledate ?diffduration ?diffdays (&lt;br /&gt;
         cpt:reject(&amp;amp;lt;John&amp;amp;gt; ?item) :-&lt;br /&gt;
             And(cpt:perishable(?item)&lt;br /&gt;
                 cpt:delivered(?item ?deliverydate &amp;amp;lt;John&amp;amp;gt;)&lt;br /&gt;
                 cpt:scheduled(?item ?scheduledate)&lt;br /&gt;
                 ?diffduration = External(func:subtract-dateTimes(?deliverydate ?scheduledate))&lt;br /&gt;
                 ?diffdays = External(func:days-from-duration(?diffduration))&lt;br /&gt;
                 External(pred:numeric-greater-than(?diffdays 10)))&lt;br /&gt;
    )&lt;br /&gt;
 &lt;br /&gt;
b. Universal-existential form:&lt;br /&gt;
 &lt;br /&gt;
    Forall ?item (&lt;br /&gt;
         cpt:reject(&amp;amp;lt;John&amp;amp;gt; ?item ) :-&lt;br /&gt;
             Exists ?deliverydate ?scheduledate ?diffduration ?diffdays (&lt;br /&gt;
                  And(cpt:perishable(?item)&lt;br /&gt;
                      cpt:delivered(?item ?deliverydate &amp;amp;lt;John&amp;amp;gt;)&lt;br /&gt;
                      cpt:scheduled(?item ?scheduledate)&lt;br /&gt;
                      ?diffduration = External(func:subtract-dateTimes(?deliverydate ?scheduledate))&lt;br /&gt;
                      ?diffdays = External(func:days-from-duration(?diffduration))&lt;br /&gt;
                      External(pred:numeric-greater-than(?diffdays 10)))&lt;br /&gt;
             )&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-ebnf-annotations&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== EBNF for Annotations =====&lt;br /&gt;
&lt;br /&gt;
The EBNF grammar production for RIF-BLD annotations is shown in the above [[#part-annotations|annotations part]].&lt;br /&gt;
&lt;br /&gt;
As explained in Section [[#sec-formal-syntax-metadata|RIF-BLD Annotations in the Presentation Syntax]], each RIF-BLD formula and term can be preceded by one optional annotation, &amp;lt;tt&amp;gt;IRIMETA&amp;lt;/tt&amp;gt;, for identification and metadata.&lt;br /&gt;
&amp;lt;tt&amp;gt;IRIMETA&amp;lt;/tt&amp;gt; is represented using &amp;lt;tt&amp;gt;(*...*)&amp;lt;/tt&amp;gt;-brackets&lt;br /&gt;
that contain an optional &amp;lt;tt&amp;gt;rif:iri&amp;lt;/tt&amp;gt; constant, &amp;lt;tt&amp;gt;IRICONST&amp;lt;/tt&amp;gt;, as identifier followed by&lt;br /&gt;
an optional &amp;lt;tt&amp;gt;Frame&amp;lt;/tt&amp;gt; or conjunction of &amp;lt;tt&amp;gt;Frame&amp;lt;/tt&amp;gt;s as metadata.&lt;br /&gt;
&lt;br /&gt;
An &amp;lt;tt&amp;gt;IRICONST&amp;lt;/tt&amp;gt; is &amp;lt;tt&amp;gt;rif:iri&amp;lt;/tt&amp;gt; constant,&lt;br /&gt;
again permitting the shortcut forms defined in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]].&lt;br /&gt;
One such specialization is &amp;lt;tt&amp;gt;'&amp;quot;' IRI '&amp;quot;^^' 'rif:iri'&amp;lt;/tt&amp;gt; from the &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt; production, where &amp;lt;tt&amp;gt;IRI&amp;lt;/tt&amp;gt; is a sequence of Unicode characters that forms an internationalized resource identifier as defined by &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rfc-3987|RFC-3987]]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ex-rif-bld-annotatedgroup-pres-syntax&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&lt;br /&gt;
'''Example 5''' (A RIF-BLD document containing an annotated group).&lt;br /&gt;
&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This example shows a complete document containing a group formula that consists of two RIF-BLD rules. The first of these rules is copied from Example 4a. The group is annotated with an IRI identifier and metadata represented using Dublin Core vocabulary.&lt;br /&gt;
&lt;br /&gt;
 Document(&lt;br /&gt;
   Base(&amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/people#&amp;amp;gt;)&lt;br /&gt;
   Prefix(cpt  &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/concepts#&amp;amp;gt;)&lt;br /&gt;
   Prefix(dc   &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;purl.org/dc/terms/&amp;amp;gt;)&lt;br /&gt;
   Prefix(func &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2007/rif-builtin-function#&amp;amp;gt;)&lt;br /&gt;
   Prefix(pred &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2007/rif-builtin-predicate#&amp;amp;gt;)&lt;br /&gt;
   Prefix(xs   &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2001/XMLSchema#&amp;amp;gt;)&lt;br /&gt;
   &lt;br /&gt;
   (* &amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;sample.org&amp;quot;^^rif:iri _pd[dc:publisher -&amp;gt; &amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/&amp;quot;^^rif:iri&lt;br /&gt;
                                       dc:date -&amp;gt; &amp;quot;2008-04-04&amp;quot;^^xs:date] *)&lt;br /&gt;
   Group&lt;br /&gt;
   (&lt;br /&gt;
     Forall ?item ?deliverydate ?scheduledate ?diffduration ?diffdays (&lt;br /&gt;
         cpt:reject(&amp;amp;lt;John&amp;amp;gt; ?item) :-&lt;br /&gt;
             And(cpt:perishable(?item)&lt;br /&gt;
                 cpt:delivered(?item ?deliverydate &amp;amp;lt;John&amp;amp;gt;)&lt;br /&gt;
                 cpt:scheduled(?item ?scheduledate)&lt;br /&gt;
                 ?diffduration = External(func:subtract-dateTimes(?deliverydate ?scheduledate))&lt;br /&gt;
                 ?diffdays = External(func:days-from-duration(?diffduration))&lt;br /&gt;
                 External(pred:numeric-greater-than(?diffdays 10)))&lt;br /&gt;
     )&lt;br /&gt;
  &lt;br /&gt;
     Forall ?item (&lt;br /&gt;
         cpt:reject(&amp;amp;lt;Fred&amp;amp;gt; ?item) :- cpt:unsolicited(?item)&lt;br /&gt;
     )&lt;br /&gt;
   )&lt;br /&gt;
 )&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-bld-direct-semantics&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Direct Specification of RIF-BLD Semantics ==&lt;br /&gt;
&lt;br /&gt;
This normative section specifies the semantics of RIF-BLD directly, without&lt;br /&gt;
relying on &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-fld|RIF-FLD]]].&lt;br /&gt;
&lt;br /&gt;
Recall that the presentation syntax of RIF-BLD allows shorthand notation,&lt;br /&gt;
which is specified via the &amp;lt;tt&amp;gt;Prefix&amp;lt;/tt&amp;gt;  and &amp;lt;tt&amp;gt;Base&amp;lt;/tt&amp;gt; directives, and various shortcuts for integers, strings, and &amp;lt;tt&amp;gt;rif:local&amp;lt;/tt&amp;gt; symbols.&lt;br /&gt;
The semantics, below, is described using the full syntax, i.e., we&lt;br /&gt;
assume that all shortcuts have already been expanded as defined in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]], Section [[DTB#sec-constants|Constants, Symbol Spaces, and Datatypes]].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-truth-values&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
==== Truth Values ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The set '''''TV''''' of truth values in RIF-BLD consists of two values, '''t''' and '''f'''.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-model-theory&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== Semantic Structures ====&lt;br /&gt;
&lt;br /&gt;
The key concept in a model-theoretic semantics for a logic language is the notion of a ''semantic structure'' &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-enderton01|Enderton01]], [[#ref-mendelson97|Mendelson97]]]. The definition is slightly more general than what is strictly necessary for RIF-BLD alone. This lays the groundwork for extensions to RIF-BLD and makes the connection with the [[FLD#sec-fld-semantic-framework|semantics of the RIF framework for logic-based dialects]] &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-fld|RIF-FLD]]] more obvious.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-bld-sem-struct&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
'''Definition (Semantic structure)'''.&lt;br /&gt;
A '''''semantic structure''''', '''''I''''', is a tuple of the form&lt;br /&gt;
&amp;amp;lt;'''''TV''''', '''''DTS''''', '''''D''''', '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;,&lt;br /&gt;
'''''D'''''&amp;lt;sub&amp;gt;func&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;C&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;V&amp;lt;/sub&amp;gt;,&lt;br /&gt;
'''''I'''''&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;NF&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;tail&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;frame&amp;lt;/sub&amp;gt;,&lt;br /&gt;
'''''I'''''&amp;lt;sub&amp;gt;sub&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;isa&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;=&amp;lt;/sub&amp;gt;,&lt;br /&gt;
'''''I'''''&amp;lt;sub&amp;gt;external&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;truth&amp;lt;/sub&amp;gt;&amp;gt;. Here '''''D''''' is a non-empty set of elements called the '''''domain''''' of '''''I''''', and '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;, '''''D'''''&amp;lt;sub&amp;gt;func&amp;lt;/sub&amp;gt; are nonempty subsets of '''''D'''''. '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt; is used to interpret the elements of &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt; that [[#def-bld-context|occur as]] individuals and '''''D'''''&amp;lt;sub&amp;gt;func&amp;lt;/sub&amp;gt; is used to interpret the elements of &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt; that [[#def-bld-context|occur in the context of]] function symbols. As before, &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt; denotes the set of all constant symbols and &amp;lt;tt&amp;gt;Var&amp;lt;/tt&amp;gt; the set of all variable symbols. '''''DTS''''' denotes a set of identifiers for datatypes (please refer to Section [[DTB#sec-data-types|Datatypes]] of &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]] for the semantics of datatypes). &lt;br /&gt;
&lt;br /&gt;
The other components of '''''I''''' are ''total'' mappings defined as follows: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    '''''I'''''&amp;lt;sub&amp;gt;C&amp;lt;/sub&amp;gt; maps &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt; to '''''D'''''.&lt;br /&gt;
    &amp;lt;p&amp;gt;&lt;br /&gt;
      This mapping interprets constant symbols. In addition:&lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;&lt;br /&gt;
	If a constant, &amp;lt;tt&amp;gt;c&amp;lt;/tt&amp;gt;&amp;amp;nbsp;&amp;amp;isin;&amp;amp;nbsp;&amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt;,&lt;br /&gt;
	is an ''individual'' then it is required that&lt;br /&gt;
	'''''I'''''&amp;lt;sub&amp;gt;C&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;c&amp;lt;/tt&amp;gt;)&amp;amp;nbsp;&amp;amp;isin;&amp;amp;nbsp;'''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;.&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;&lt;br /&gt;
	If &amp;lt;tt&amp;gt;c&amp;lt;/tt&amp;gt;&amp;amp;nbsp;&amp;amp;isin;&amp;amp;nbsp;&amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt;, is a ''function symbol'' (positional or with named arguments) then it is required that '''''I'''''&amp;lt;sub&amp;gt;C&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;c&amp;lt;/tt&amp;gt;)&amp;amp;nbsp;&amp;amp;isin;&amp;amp;nbsp;'''''D'''''&amp;lt;sub&amp;gt;func&amp;lt;/sub&amp;gt;.&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    '''''I'''''&amp;lt;sub&amp;gt;V&amp;lt;/sub&amp;gt; maps &amp;lt;tt&amp;gt;Var&amp;lt;/tt&amp;gt; to '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;.&lt;br /&gt;
    &amp;lt;p&amp;gt;This mapping interprets variable symbols.&amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    '''''I'''''&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt; maps '''''D''''' to total functions '''''D*'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt; &amp;amp;rarr; '''''D''''' (here '''''D*'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt; is a set of all finite sequences over the domain '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;).&lt;br /&gt;
    &amp;lt;p&amp;gt;This mapping interprets positional terms. In addition: &amp;lt;/p&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;If &amp;lt;tt&amp;gt;d&amp;lt;/tt&amp;gt; &amp;amp;isin; '''''D'''''&amp;lt;sub&amp;gt;func&amp;lt;/sub&amp;gt; then '''''I'''''&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;d&amp;lt;/tt&amp;gt;) must be a function '''''D*'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt; &amp;amp;rarr; '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;.&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;This means that when a function symbol is applied to arguments that are individual objects then the result is also an individual object.&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;'''''I'''''&amp;lt;sub&amp;gt;NF&amp;lt;/sub&amp;gt; maps '''''D''''' to the set of total functions of the form &amp;lt;tt&amp;gt;SetOfFiniteSets&amp;lt;/tt&amp;gt;(&amp;lt;tt&amp;gt;ArgNames&amp;lt;/tt&amp;gt; &amp;amp;times; '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;) &amp;amp;rarr; '''''D'''''.&lt;br /&gt;
    &amp;lt;p&amp;gt;This mapping interprets function symbols with named arguments. In addition:&amp;lt;/p&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;If &amp;lt;tt&amp;gt;d&amp;lt;/tt&amp;gt; &amp;amp;isin; '''''D'''''&amp;lt;sub&amp;gt;func&amp;lt;/sub&amp;gt; then '''''I'''''&amp;lt;sub&amp;gt;NF&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;d&amp;lt;/tt&amp;gt;) must be a function &amp;lt;tt&amp;gt;SetOfFiniteSets&amp;lt;/tt&amp;gt;(&amp;lt;tt&amp;gt;ArgNames&amp;lt;/tt&amp;gt; &amp;amp;times; '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;) &amp;amp;rarr; '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;.&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;This is analogous to the interpretation of positional terms with two differences:&lt;br /&gt;
        &amp;lt;ul&amp;gt;&lt;br /&gt;
          &amp;lt;li&amp;gt;Each pair &amp;amp;lt;&amp;lt;tt&amp;gt;s,v&amp;lt;/tt&amp;gt;&amp;gt; &amp;amp;isin; &amp;lt;tt&amp;gt;ArgNames&amp;lt;/tt&amp;gt; &amp;amp;times; '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt; represents an argument/value pair instead of just a value in the case of a positional term. &amp;lt;/li&amp;gt;&lt;br /&gt;
          &amp;lt;li&amp;gt;The arguments of a term with named arguments constitute a finite set of argument/value pairs rather than a finite ordered sequence of simple elements.  So, the order of the arguments does not matter.&amp;lt;/li&amp;gt;&lt;br /&gt;
        &amp;lt;/ul&amp;gt;&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;  &lt;br /&gt;
     '''''I'''''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt; and '''''I'''''&amp;lt;sub&amp;gt;tail&amp;lt;/sub&amp;gt; are used to interpret lists. They are mappings of the following form:&lt;br /&gt;
     &amp;lt;ul&amp;gt;     &lt;br /&gt;
       &amp;lt;li&amp;gt;&lt;br /&gt;
	 '''''I'''''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt; : '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;&amp;lt;sup&amp;gt;&amp;lt;nowiki&amp;gt;*&amp;lt;/nowiki&amp;gt;&amp;lt;/sup&amp;gt; &amp;amp;rarr; '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt; &lt;br /&gt;
       &amp;lt;/li&amp;gt;&lt;br /&gt;
       &amp;lt;li&amp;gt;&lt;br /&gt;
	 '''''I'''''&amp;lt;sub&amp;gt;tail&amp;lt;/sub&amp;gt; : '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;&amp;lt;sup&amp;gt;+&amp;lt;/sup&amp;gt;&amp;amp;times; '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt; &amp;amp;rarr; '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt; &lt;br /&gt;
       &amp;lt;/li&amp;gt;&lt;br /&gt;
     &amp;lt;/ul&amp;gt;&lt;br /&gt;
     &amp;lt;p&amp;gt;&lt;br /&gt;
        In addition, these mappings are required to satisfy the following conditions:&lt;br /&gt;
     &amp;lt;/p&amp;gt;&lt;br /&gt;
     &amp;lt;ul&amp;gt;     &lt;br /&gt;
       &amp;lt;li&amp;gt;&lt;br /&gt;
	The function '''''I'''''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt; is injective (one-to-one).&lt;br /&gt;
       &amp;lt;/li&amp;gt;&lt;br /&gt;
       &amp;lt;li&amp;gt;&lt;br /&gt;
	 The set '''''I'''''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt;('''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;&amp;lt;sup&amp;gt;*&amp;lt;/sup&amp;gt;), henceforth denoted &amp;lt;span id=&amp;quot;def-Dlist&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;'''''D'''''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt;&amp;lt;/span&amp;gt;, is disjoint from the value spaces of all data types in '''''DTS'''''.&lt;br /&gt;
       &amp;lt;/li&amp;gt;&lt;br /&gt;
       &amp;lt;li&amp;gt;&lt;br /&gt;
	 '''''I'''''&amp;lt;sub&amp;gt;tail&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;a&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;, ..., &amp;lt;tt&amp;gt;a&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;k&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;a&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;k+1&amp;lt;/sub&amp;gt;, ..., &amp;lt;tt&amp;gt;a&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;k+m&amp;lt;/sub&amp;gt;)) = '''''I'''''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;a&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;, ..., &amp;lt;tt&amp;gt;a&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;k&amp;lt;/sub&amp;gt;, &amp;lt;tt&amp;gt;a&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;k+1&amp;lt;/sub&amp;gt;, ..., &amp;lt;tt&amp;gt;a&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;k+m&amp;lt;/sub&amp;gt;). &lt;br /&gt;
       &amp;lt;/li&amp;gt;&lt;br /&gt;
     &amp;lt;/ul&amp;gt;&lt;br /&gt;
     &amp;lt;p&amp;gt;&lt;br /&gt;
       Note that the last condition above restricts '''''I'''''&amp;lt;sub&amp;gt;tail&amp;lt;/sub&amp;gt; only when its last argument is in '''''D'''''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt;. If the last argument of '''''I'''''&amp;lt;sub&amp;gt;tail&amp;lt;/sub&amp;gt; is not in '''''D'''''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt;, then the list is a general open one and there are no restrictions on the value of '''''I'''''&amp;lt;sub&amp;gt;tail&amp;lt;/sub&amp;gt; except that it must be in '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;.&lt;br /&gt;
     &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;'''''I'''''&amp;lt;sub&amp;gt;frame&amp;lt;/sub&amp;gt; maps '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt; to total functions of the form &amp;lt;tt&amp;gt;SetOfFiniteBags&amp;lt;/tt&amp;gt;('''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt; &amp;amp;times; '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;) &amp;amp;rarr; '''''D'''''.&lt;br /&gt;
    &amp;lt;p&amp;gt;This mapping interprets frame terms. An argument, &amp;lt;tt&amp;gt;d&amp;lt;/tt&amp;gt; &amp;amp;isin; '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;, to '''''I'''''&amp;lt;sub&amp;gt;frame&amp;lt;/sub&amp;gt; represents an object and the finite bag {&amp;amp;lt;&amp;lt;tt&amp;gt;a1,v1&amp;lt;/tt&amp;gt;&amp;gt;, ..., &amp;amp;lt;&amp;lt;tt&amp;gt;ak,vk&amp;lt;/tt&amp;gt;&amp;gt;} represents a bag of attribute-value pairs for &amp;lt;tt&amp;gt;d&amp;lt;/tt&amp;gt;. We will see shortly how '''''I'''''&amp;lt;sub&amp;gt;frame&amp;lt;/sub&amp;gt; is used to determine the truth valuation of frame terms. &amp;lt;/p&amp;gt;&lt;br /&gt;
    &amp;lt;p&amp;gt;Bags (multi-sets) are used here because the order of the attribute/value pairs in a frame is immaterial and pairs may repeat. Such repetitions arise naturally when variables are instantiated with constants. For instance, &amp;lt;tt&amp;gt;o[?A-&amp;gt;?B&amp;amp;nbsp;?C-&amp;gt;?D]&amp;lt;/tt&amp;gt; becomes &amp;lt;tt&amp;gt;o[a-&amp;gt;b&amp;amp;nbsp;a-&amp;gt;b]&amp;lt;/tt&amp;gt; if variables &amp;lt;tt&amp;gt;?A&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;?C&amp;lt;/tt&amp;gt; are instantiated with the symbol &amp;lt;tt&amp;gt;a&amp;lt;/tt&amp;gt; while &amp;lt;tt&amp;gt;?B&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;?D&amp;lt;/tt&amp;gt; are instantiated with &amp;lt;tt&amp;gt;b&amp;lt;/tt&amp;gt;. (We shall see later that &amp;lt;tt&amp;gt;o[a-&amp;gt;b&amp;amp;nbsp;a-&amp;gt;b]&amp;lt;/tt&amp;gt; is equivalent to &amp;lt;tt&amp;gt;o[a-&amp;gt;b]&amp;lt;/tt&amp;gt;.)&lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;'''''I'''''&amp;lt;sub&amp;gt;sub&amp;lt;/sub&amp;gt; gives meaning to the subclass relationship. It is a mapping of the form '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt; &amp;amp;times; '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt; &amp;amp;rarr; '''''D'''''.&lt;br /&gt;
    &amp;lt;p&amp;gt;&lt;br /&gt;
    '''''I'''''&amp;lt;sub&amp;gt;sub&amp;lt;/sub&amp;gt; will be further restricted in Section [[#sec-interpretation-of-formulas|Interpretation of Formulas]] to ensure that&lt;br /&gt;
    the operator &amp;lt;tt&amp;gt;##&amp;lt;/tt&amp;gt; is transitive, i.e., that &amp;lt;tt&amp;gt;c1&amp;amp;nbsp;##&amp;amp;nbsp;c2&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;c2&amp;amp;nbsp;##&amp;amp;nbsp;c3&amp;lt;/tt&amp;gt; imply &amp;lt;tt&amp;gt;c1&amp;amp;nbsp;##&amp;amp;nbsp;c3&amp;lt;/tt&amp;gt;.&lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;'''''I'''''&amp;lt;sub&amp;gt;isa&amp;lt;/sub&amp;gt; gives meaning to class membership. It is a mapping of the form '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt; &amp;amp;times; '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt; &amp;amp;rarr; '''''D'''''.&lt;br /&gt;
    &amp;lt;p&amp;gt;&lt;br /&gt;
    '''''I'''''&amp;lt;sub&amp;gt;isa&amp;lt;/sub&amp;gt; will be further restricted in Section [[#sec-interpretation-of-formulas|Interpretation of Formulas]] to ensure that&lt;br /&gt;
    the relationships &amp;lt;tt&amp;gt;#&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;##&amp;lt;/tt&amp;gt; have the usual property that all members of a subclass are also members of the superclass, i.e., that &amp;lt;tt&amp;gt;o&amp;amp;nbsp;#&amp;amp;nbsp;cl&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;cl&amp;amp;nbsp;##&amp;amp;nbsp;scl&amp;lt;/tt&amp;gt; imply &amp;lt;tt&amp;gt;o&amp;amp;nbsp;#&amp;amp;nbsp;scl&amp;lt;/tt&amp;gt;.&lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;'''''I'''''&amp;lt;sub&amp;gt;=&amp;lt;/sub&amp;gt; is a mapping of the form '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt; &amp;amp;times; '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt; &amp;amp;rarr; '''''D'''''.&lt;br /&gt;
    &amp;lt;p&amp;gt;It gives meaning to the equality operator.&amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    '''''I'''''&amp;lt;sub&amp;gt;truth&amp;lt;/sub&amp;gt; is a mapping of the form '''''D''''' &amp;amp;rarr; '''''TV'''''.&lt;br /&gt;
     &amp;lt;p&amp;gt;It is used to define truth valuation for formulas.&amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    '''''I'''''&amp;lt;sub&amp;gt;external&amp;lt;/sub&amp;gt; is a mapping from the coherent set of schemas for externally defined functions to total functions '''''D'''''* &amp;amp;rarr; '''''D'''''. For each external schema &amp;lt;tt&amp;gt;&amp;amp;sigma; = (?X&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... ?X&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;;&amp;amp;nbsp;&amp;amp;tau;)&amp;lt;/tt&amp;gt; in the [[DTB#def-external-schema-set|coherent set of external schemas]] associated with the [[#def-bld-lang|language]], '''''I'''''&amp;lt;sub&amp;gt;external&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;sigma;&amp;lt;/tt&amp;gt;) is a function of the form '''''D'''''&amp;lt;sup&amp;gt;n&amp;lt;/sup&amp;gt; &amp;amp;rarr; '''''D'''''.&lt;br /&gt;
    &amp;lt;p&amp;gt;&lt;br /&gt;
      For every external schema, &amp;lt;tt&amp;gt;&amp;amp;sigma;&amp;lt;/tt&amp;gt;,  associated with the language, '''''I'''''&amp;lt;sub&amp;gt;external&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;sigma;&amp;lt;/tt&amp;gt;) is assumed to be specified externally in some document (hence the name ''external schema''). In particular, if &amp;lt;tt&amp;gt;&amp;amp;sigma;&amp;lt;/tt&amp;gt; is a schema of a RIF built-in predicate or function, '''''I'''''&amp;lt;sub&amp;gt;external&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;sigma;&amp;lt;/tt&amp;gt;) is specified in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]] so that:&lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
      &amp;lt;ul&amp;gt;&lt;br /&gt;
        &amp;lt;li&amp;gt;&lt;br /&gt;
          If &amp;lt;tt&amp;gt;&amp;amp;sigma;&amp;lt;/tt&amp;gt; is a schema of a built-in function then '''''I'''''&amp;lt;sub&amp;gt;external&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;sigma;&amp;lt;/tt&amp;gt;) must be the function defined in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]].&lt;br /&gt;
        &amp;lt;/li&amp;gt;&lt;br /&gt;
        &amp;lt;li&amp;gt;&lt;br /&gt;
          If &amp;lt;tt&amp;gt;&amp;amp;sigma;&amp;lt;/tt&amp;gt; is a schema of a built-in predicate then &lt;br /&gt;
          '''''I'''''&amp;lt;sub&amp;gt;truth&amp;lt;/sub&amp;gt;&amp;lt;tt&amp;gt; &amp;amp;omicron; &amp;lt;/tt&amp;gt;('''''I'''''&amp;lt;sub&amp;gt;external&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;sigma;&amp;lt;/tt&amp;gt;)) (the composition of '''''I'''''&amp;lt;sub&amp;gt;truth&amp;lt;/sub&amp;gt; and '''''I'''''&amp;lt;sub&amp;gt;external&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;sigma;&amp;lt;/tt&amp;gt;), a truth-valued function) must be as specified in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]].&lt;br /&gt;
        &amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;/ul&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
  We also define the following mapping from terms to '''''D''''', which we denote using the same symbol '''''I''''' as the one used for semantic structures. This overloading is convenient and creates no ambiguity.&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    '''''I'''''(&amp;lt;tt&amp;gt;k&amp;lt;/tt&amp;gt;) = '''''I'''''&amp;lt;sub&amp;gt;C&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;k&amp;lt;/tt&amp;gt;), if &amp;lt;tt&amp;gt;k&amp;lt;/tt&amp;gt; is a symbol in &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    '''''I'''''(&amp;lt;tt&amp;gt;?v&amp;lt;/tt&amp;gt;) = '''''I'''''&amp;lt;sub&amp;gt;V&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;?v&amp;lt;/tt&amp;gt;), if &amp;lt;tt&amp;gt;?v&amp;lt;/tt&amp;gt; is a variable in &amp;lt;tt&amp;gt;Var&amp;lt;/tt&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    '''''I'''''(&amp;lt;tt&amp;gt;f(t&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... t&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;)&amp;lt;/tt&amp;gt;) = '''''I'''''&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;('''''I'''''(&amp;lt;tt&amp;gt;f&amp;lt;/tt&amp;gt;))('''''I'''''(&amp;lt;tt&amp;gt;t&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;),...,'''''I'''''(&amp;lt;tt&amp;gt;t&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;))&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    '''''I'''''(&amp;lt;tt&amp;gt;f(s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... s&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;)&amp;lt;/tt&amp;gt;) = '''''I'''''&amp;lt;sub&amp;gt;NF&amp;lt;/sub&amp;gt;('''''I'''''(&amp;lt;tt&amp;gt;f&amp;lt;/tt&amp;gt;))({&amp;amp;lt;&amp;lt;tt&amp;gt;s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;,'''''I'''''(&amp;lt;tt&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;)&amp;gt;,...,&amp;amp;lt;&amp;lt;tt&amp;gt;s&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;,'''''I'''''(&amp;lt;tt&amp;gt;v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;)&amp;gt;})&lt;br /&gt;
  &amp;lt;p&amp;gt;&lt;br /&gt;
    Here we use {...} to denote a set of argument/value pairs. &lt;br /&gt;
  &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;  &lt;br /&gt;
     For list terms, the mapping is defined as follows:&lt;br /&gt;
     &amp;lt;ul&amp;gt;     &lt;br /&gt;
       &amp;lt;li&amp;gt;&lt;br /&gt;
	 '''''I'''''(&amp;lt;tt&amp;gt;List()&amp;lt;/tt&amp;gt;) = '''''I'''''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;lt;&amp;amp;gt;&amp;lt;/tt&amp;gt;). &lt;br /&gt;
	 &amp;lt;p&amp;gt;&lt;br /&gt;
	   Here &amp;lt;tt&amp;gt;&amp;amp;lt;&amp;amp;gt;&amp;lt;/tt&amp;gt; denotes an empty list of elements of '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;. (Note that the domain of '''''I'''''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt; is '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;&amp;lt;sup&amp;gt;&amp;lt;nowiki&amp;gt;*&amp;lt;/nowiki&amp;gt;&amp;lt;/sup&amp;gt;, so '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;&amp;lt;sup&amp;gt;0&amp;lt;/sup&amp;gt; is an empty list of elements of '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;.)&lt;br /&gt;
	 &amp;lt;/p&amp;gt;&lt;br /&gt;
       &amp;lt;/li&amp;gt;&lt;br /&gt;
       &amp;lt;li&amp;gt;&lt;br /&gt;
	 '''''I'''''(&amp;lt;tt&amp;gt;List(t&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;)) = '''''I'''''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt;('''''I'''''(&amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;), ..., '''''I'''''(&amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;)), if &amp;lt;tt&amp;gt;n&amp;amp;gt;0&amp;lt;/tt&amp;gt;. &lt;br /&gt;
       &amp;lt;/li&amp;gt;&lt;br /&gt;
       &amp;lt;li&amp;gt;&lt;br /&gt;
	 '''''I'''''(&amp;lt;tt&amp;gt;List(t&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt; | &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt;)) = '''''I'''''&amp;lt;sub&amp;gt;tail&amp;lt;/sub&amp;gt;('''''I'''''(&amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;), ..., '''''I'''''(&amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;), '''''I'''''(&amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt;)), if &amp;lt;tt&amp;gt;n&amp;amp;gt;0&amp;lt;/tt&amp;gt;. &lt;br /&gt;
       &amp;lt;/li&amp;gt;&lt;br /&gt;
     &amp;lt;/ul&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    '''''I'''''(&amp;lt;tt&amp;gt;o[a&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... a&amp;lt;sub&amp;gt;k&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;k&amp;lt;/sub&amp;gt;]&amp;lt;/tt&amp;gt;) = '''''I'''''&amp;lt;sub&amp;gt;frame&amp;lt;/sub&amp;gt;('''''I'''''(&amp;lt;tt&amp;gt;o&amp;lt;/tt&amp;gt;))({&amp;amp;lt;'''''I'''''(&amp;lt;tt&amp;gt;a&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;),'''''I'''''(&amp;lt;tt&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;)&amp;gt;, ..., &amp;amp;lt;'''''I'''''(&amp;lt;tt&amp;gt;a&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;),'''''I'''''(&amp;lt;tt&amp;gt;v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;)&amp;gt;})&lt;br /&gt;
  &amp;lt;p&amp;gt;&lt;br /&gt;
    Here {...} denotes a bag of attribute/value pairs. Jumping ahead, we note that duplicate elements in such a bag do not affect the truth value of a frame formula. Thus, for instance, &amp;lt;tt&amp;gt;o[a-&amp;gt;b a-&amp;gt;b]&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;o[a-&amp;gt;b]&amp;lt;/tt&amp;gt; always have the same truth value.&lt;br /&gt;
  &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    '''''I'''''(&amp;lt;tt&amp;gt;c1##c2&amp;lt;/tt&amp;gt;) = '''''I'''''&amp;lt;sub&amp;gt;sub&amp;lt;/sub&amp;gt;('''''I'''''(&amp;lt;tt&amp;gt;c1&amp;lt;/tt&amp;gt;), '''''I'''''(&amp;lt;tt&amp;gt;c2&amp;lt;/tt&amp;gt;))&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    '''''I'''''(&amp;lt;tt&amp;gt;o#c&amp;lt;/tt&amp;gt;) = '''''I'''''&amp;lt;sub&amp;gt;isa&amp;lt;/sub&amp;gt;('''''I'''''(&amp;lt;tt&amp;gt;o&amp;lt;/tt&amp;gt;), '''''I'''''(&amp;lt;tt&amp;gt;c&amp;lt;/tt&amp;gt;))&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    '''''I'''''(&amp;lt;tt&amp;gt;x=y&amp;lt;/tt&amp;gt;) = '''''I'''''&amp;lt;sub&amp;gt;=&amp;lt;/sub&amp;gt;('''''I'''''(x), '''''I'''''(y))&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    '''''I'''''(&amp;lt;tt&amp;gt;External(t)&amp;lt;/tt&amp;gt;) = '''''I'''''&amp;lt;sub&amp;gt;external&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;sigma;&amp;lt;/tt&amp;gt;)('''''I'''''(&amp;lt;tt&amp;gt;s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;), ..., '''''I'''''(&amp;lt;tt&amp;gt;s&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;)), if &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; is an instantiation of the external schema &amp;lt;tt&amp;gt;&amp;amp;sigma; = (?X&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... ?X&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;;&amp;amp;nbsp;&amp;amp;tau;)&amp;lt;/tt&amp;gt; by substitution &amp;lt;tt&amp;gt;?X&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;/s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... ?X&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;/s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;.&lt;br /&gt;
    &amp;lt;p&amp;gt;&lt;br /&gt;
      Note that, by definition, &amp;lt;tt&amp;gt;External(t)&amp;lt;/tt&amp;gt; is well-formed only if &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; is an instantiation of an external schema. Furthermore, by the [[DTB#def-external-schema-set|definition of coherent sets of external schemas]], &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; can be an instantiation of at most one such schema, so '''''I'''''(&amp;lt;tt&amp;gt;External(t)&amp;lt;/tt&amp;gt;) is well-defined.&lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that the definitions of '''''I'''''&amp;lt;sub&amp;gt;NF&amp;lt;/sub&amp;gt; and '''''I'''''(&amp;lt;tt&amp;gt;x=y&amp;lt;/tt&amp;gt;) imply that the terms with named arguments that differ only in the order of their arguments are mapped by '''''I''''' to the same element in the domain. This implies that the equalities like &amp;lt;tt&amp;gt;t(a-&amp;gt;1 b-&amp;gt;2 c-&amp;gt;3) = t(c-&amp;gt;3 a-&amp;gt;1 b-&amp;gt;2)&amp;lt;/tt&amp;gt; are tautologies in RIF-BLD.&lt;br /&gt;
&lt;br /&gt;
'''''The effect of datatypes.''''' The set '''''DTS''''' must include the datatypes described in Section [[DTB#sec-data-types|Datatypes]] of &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The datatype identifiers in '''''DTS''''' impose the following restrictions. Given &amp;lt;tt&amp;gt;dt&amp;lt;/tt&amp;gt; &amp;amp;isin; '''''DTS''''', let '''''LS'''''&amp;lt;sub&amp;gt;dt&amp;lt;/sub&amp;gt; denote the lexical space of &amp;lt;tt&amp;gt;dt&amp;lt;/tt&amp;gt;, '''''VS'''''&amp;lt;sub&amp;gt;dt&amp;lt;/sub&amp;gt; denote its value space, and '''''L'''''&amp;lt;sub&amp;gt;dt&amp;lt;/sub&amp;gt;: '''''LS'''''&amp;lt;sub&amp;gt;dt&amp;lt;/sub&amp;gt; &amp;amp;rarr; '''''VS'''''&amp;lt;sub&amp;gt;dt&amp;lt;/sub&amp;gt; the lexical-to-value-space mapping (for the definitions of these concepts, see Section [[DTB#sec-data-types|Datatypes]] of &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]]). Then the following must hold: &lt;br /&gt;
&lt;br /&gt;
* '''''VS'''''&amp;lt;sub&amp;gt;dt&amp;lt;/sub&amp;gt; &amp;amp;sube; '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;; and&lt;br /&gt;
* For each constant &amp;lt;tt&amp;gt;&amp;quot;lit&amp;quot;^^dt&amp;lt;/tt&amp;gt; such that &amp;lt;tt&amp;gt;lit&amp;lt;/tt&amp;gt; &amp;amp;isin; '''''LS'''''&amp;lt;sub&amp;gt;dt&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;C&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;quot;lit&amp;quot;^^dt&amp;lt;/tt&amp;gt;) = '''''L'''''&amp;lt;sub&amp;gt;dt&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;lit&amp;lt;/tt&amp;gt;). &lt;br /&gt;
That is, '''''I'''''&amp;lt;sub&amp;gt;C&amp;lt;/sub&amp;gt; must map the constants of a datatype &amp;lt;tt&amp;gt;dt&amp;lt;/tt&amp;gt; in accordance with '''''L'''''&amp;lt;sub&amp;gt;dt&amp;lt;/sub&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
RIF-BLD does not impose restrictions on '''''I'''''&amp;lt;sub&amp;gt;C&amp;lt;/sub&amp;gt; for constants in symbol spaces that are not datatypes included in '''''DTS'''''.  &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-semantics-metadata&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== RIF-BLD Annotations in the Semantics ====&lt;br /&gt;
&lt;br /&gt;
RIF-BLD annotations are stripped before the mappings that constitute RIF-BLD semantic structures are applied. Likewise, they are stripped before applying the truth valuation, ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;, defined in the next section. Thus, identifiers and metadata have no effect on the formal semantics.&lt;br /&gt;
&lt;br /&gt;
Note that although identifiers and metadata associated with RIF-BLD formulas are ignored by the semantics, they can be extracted by XML tools. The frame terms used to represent RIF-BLD metadata can then be fed to other RIF-BLD rules, thus enabling reasoning about metadata. RIF-BLD does not define any particular semantics for metadata, however.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-interpretation-of-formulas&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== Interpretation of Non-document Formulas ====&lt;br /&gt;
&lt;br /&gt;
This section defines how a semantic structure, '''''I''''', determines&lt;br /&gt;
the truth value ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;)  of a RIF-BLD formula, &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;, where &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; is any formula other than a document formula. Truth valuation of document formulas is defined in the next section.&lt;br /&gt;
&lt;br /&gt;
We define a mapping, ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;, from the set of all non-document formulas to '''''TV'''''. Note that the definition implies that ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;) is defined &amp;lt;em&amp;gt;only if&amp;lt;/em&amp;gt; the set '''''DTS''''' of the datatypes of '''''I''''' includes all the datatypes mentioned in &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; and '''''I'''''&amp;lt;sub&amp;gt;external&amp;lt;/sub&amp;gt; is defined on all externally defined functions and predicates in &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-bld-truth&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
'''Definition (Truth valuation)'''.&lt;br /&gt;
'''''Truth valuation''''' for well-formed formulas in RIF-BLD is determined using the following function, denoted ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;''Positional atomic formulas'': ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;r(t&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... t&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;)&amp;lt;/tt&amp;gt;) = '''''I'''''&amp;lt;sub&amp;gt;truth&amp;lt;/sub&amp;gt;('''''I'''''(&amp;lt;tt&amp;gt;r(t&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... t&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;)&amp;lt;/tt&amp;gt;)) &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;''Atomic formulas with named arguments'': ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;p(s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... s&amp;lt;sub&amp;gt;k&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;k&amp;lt;/sub&amp;gt;)&amp;lt;/tt&amp;gt;) = '''''I'''''&amp;lt;sub&amp;gt;truth&amp;lt;/sub&amp;gt;('''''I'''''(&amp;lt;tt&amp;gt;p(s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... s&amp;lt;sub&amp;gt;k&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;k&amp;lt;/sub&amp;gt;)&amp;lt;/tt&amp;gt;)). &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;''Equality'': ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;x&amp;amp;nbsp;=&amp;amp;nbsp;y&amp;lt;/tt&amp;gt;) = '''''I'''''&amp;lt;sub&amp;gt;truth&amp;lt;/sub&amp;gt;('''''I'''''(&amp;lt;tt&amp;gt;x&amp;amp;nbsp;=&amp;amp;nbsp;y&amp;lt;/tt&amp;gt;)).&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;To ensure that equality has precisely the expected properties, it is required that:&lt;br /&gt;
        &amp;lt;ul&amp;gt;&lt;br /&gt;
	  &amp;lt;li&amp;gt;&lt;br /&gt;
	    '''''I'''''&amp;lt;sub&amp;gt;truth&amp;lt;/sub&amp;gt;('''''I'''''(&amp;lt;tt&amp;gt;x&amp;amp;nbsp;=&amp;amp;nbsp;y&amp;lt;/tt&amp;gt;)) = '''t''' if '''''I'''''(&amp;lt;tt&amp;gt;x&amp;lt;/tt&amp;gt;) = '''''I'''''(&amp;lt;tt&amp;gt;y&amp;lt;/tt&amp;gt;) and  '''''I'''''&amp;lt;sub&amp;gt;truth&amp;lt;/sub&amp;gt;('''''I'''''(&amp;lt;tt&amp;gt;x&amp;amp;nbsp;=&amp;amp;nbsp;y&amp;lt;/tt&amp;gt;)) = '''f''' otherwise.&lt;br /&gt;
	  &amp;lt;/li&amp;gt;&lt;br /&gt;
        &amp;lt;/ul&amp;gt;&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;This is tantamount to saying that ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;x&amp;amp;nbsp;=&amp;amp;nbsp;y&amp;lt;/tt&amp;gt;) = '''t''' if and only if  '''''I'''''(x) = '''''I'''''(y).&amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;''Subclass'': ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;sc&amp;amp;nbsp;##&amp;amp;nbsp;cl&amp;lt;/tt&amp;gt;) = '''''I'''''&amp;lt;sub&amp;gt;truth&amp;lt;/sub&amp;gt;('''''I'''''(&amp;lt;tt&amp;gt;sc&amp;amp;nbsp;##&amp;amp;nbsp;cl&amp;lt;/tt&amp;gt;)).&lt;br /&gt;
    &amp;lt;p&amp;gt;To ensure that the operator &amp;lt;tt&amp;gt;##&amp;lt;/tt&amp;gt; is transitive, i.e., &amp;lt;tt&amp;gt;c1&amp;amp;nbsp;##&amp;amp;nbsp;c2&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;c2&amp;amp;nbsp;##&amp;amp;nbsp;c3&amp;lt;/tt&amp;gt; imply &amp;lt;tt&amp;gt;c1&amp;amp;nbsp;##&amp;amp;nbsp;c3&amp;lt;/tt&amp;gt;, the following is required:&lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
      &amp;lt;ul&amp;gt;&lt;br /&gt;
	&amp;lt;li&amp;gt;&lt;br /&gt;
          For all well-formed terms &amp;lt;tt&amp;gt;c1&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;c2&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;c3&amp;lt;/tt&amp;gt;:  &amp;amp;nbsp; if ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;c1&amp;amp;nbsp;##&amp;amp;nbsp;c2&amp;lt;/tt&amp;gt;) = ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;c2&amp;amp;nbsp;##&amp;amp;nbsp;c3&amp;lt;/tt&amp;gt;) = '''t''' &amp;amp;nbsp; then ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;c1&amp;amp;nbsp;##&amp;amp;nbsp;c3&amp;lt;/tt&amp;gt;) = '''t'''.&lt;br /&gt;
	&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;/ul&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;''Membership'': ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;o&amp;amp;nbsp;#&amp;amp;nbsp;cl&amp;lt;/tt&amp;gt;) = '''''I'''''&amp;lt;sub&amp;gt;truth&amp;lt;/sub&amp;gt;('''''I'''''(&amp;lt;tt&amp;gt;o&amp;amp;nbsp;#&amp;amp;nbsp;cl&amp;lt;/tt&amp;gt;)).&lt;br /&gt;
    &amp;lt;p&amp;gt;To ensure that all members of a subclass are also members of the superclass, i.e., &amp;lt;tt&amp;gt;o&amp;amp;nbsp;#&amp;amp;nbsp;cl&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;cl&amp;amp;nbsp;##&amp;amp;nbsp;scl&amp;lt;/tt&amp;gt; imply &amp;lt;tt&amp;gt;o&amp;amp;nbsp;#&amp;amp;nbsp;scl&amp;lt;/tt&amp;gt;, the following is required:&lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
      &amp;lt;ul&amp;gt;&lt;br /&gt;
	&amp;lt;li&amp;gt;&lt;br /&gt;
        For all well-formed terms &amp;lt;tt&amp;gt;o&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;cl&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;scl&amp;lt;/tt&amp;gt;: &amp;amp;nbsp; if ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;o&amp;amp;nbsp;#&amp;amp;nbsp;cl&amp;lt;/tt&amp;gt;) = ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;cl&amp;amp;nbsp;##&amp;amp;nbsp;scl&amp;lt;/tt&amp;gt;) = '''t''' &amp;amp;nbsp; then &amp;amp;nbsp; ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;o&amp;amp;nbsp;#&amp;amp;nbsp;scl&amp;lt;/tt&amp;gt;) = '''t'''. &lt;br /&gt;
	&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;/ul&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;''Frame'': ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;o[a&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... a&amp;lt;sub&amp;gt;k&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;k&amp;lt;/sub&amp;gt;]&amp;lt;/tt&amp;gt;) = '''''I'''''&amp;lt;sub&amp;gt;truth&amp;lt;/sub&amp;gt;('''''I'''''(&amp;lt;tt&amp;gt;o[a&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... a&amp;lt;sub&amp;gt;k&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;k&amp;lt;/sub&amp;gt;]&amp;lt;/tt&amp;gt;)).&lt;br /&gt;
    &amp;lt;p&amp;gt;&lt;br /&gt;
      Since the bag of attribute/value pairs associated with an object &amp;lt;tt&amp;gt;o&amp;lt;/tt&amp;gt; represents the conjunction of assertions represented by these pairs, the following is required, if &amp;lt;tt&amp;gt;k &amp;amp;gt; 0&amp;lt;/tt&amp;gt;: &lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
      &amp;lt;ul&amp;gt;&lt;br /&gt;
	&amp;lt;li&amp;gt;&lt;br /&gt;
        ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;o[a&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... a&amp;lt;sub&amp;gt;k&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;k&amp;lt;/sub&amp;gt;]&amp;lt;/tt&amp;gt;) = '''t''' if and only if  ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;o[a&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;]&amp;lt;/tt&amp;gt;) = ... = ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;o[a&amp;lt;sub&amp;gt;k&amp;lt;/sub&amp;gt;-&amp;gt;v&amp;lt;sub&amp;gt;k&amp;lt;/sub&amp;gt;]&amp;lt;/tt&amp;gt;) = '''t'''. &lt;br /&gt;
	&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;/ul&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    ''Externally defined atomic formula'': ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;External(t)&amp;lt;/tt&amp;gt;) = '''''I'''''&amp;lt;sub&amp;gt;truth&amp;lt;/sub&amp;gt;('''''I'''''&amp;lt;sub&amp;gt;external&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;sigma;&amp;lt;/tt&amp;gt;)('''''I'''''(&amp;lt;tt&amp;gt;s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;), ..., '''''I'''''(&amp;lt;tt&amp;gt;s&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;))), if &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; is an atomic formula that is an instantiation of the external schema &amp;lt;tt&amp;gt;&amp;amp;sigma; = (?X&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... ?X&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;; &amp;amp;tau;)&amp;lt;/tt&amp;gt; by substitution &amp;lt;tt&amp;gt;?X&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;/s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... ?X&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;/s&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;.&lt;br /&gt;
    &amp;lt;p&amp;gt;&lt;br /&gt;
      Note that, by definition, &amp;lt;tt&amp;gt;External(t)&amp;lt;/tt&amp;gt; is well-formed only if &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; is an instantiation of an external schema. Furthermore, by the [[DTB#def-external-schema-set|definition of coherent sets of external schemas]], &amp;lt;tt&amp;gt;t&amp;lt;/tt&amp;gt; can be an instantiation of at most one such schema, so '''''I'''''(&amp;lt;tt&amp;gt;External(t)&amp;lt;/tt&amp;gt;) is well-defined.&lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;''Conjunction'': ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;And(&amp;lt;/tt&amp;gt;c&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... c&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;tt&amp;gt;)&amp;lt;/tt&amp;gt;) = '''t''' if and only if ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(c&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;) = ... = ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(c&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;) = '''t'''. Otherwise, ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;And(&amp;lt;/tt&amp;gt;c&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... c&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;tt&amp;gt;)&amp;lt;/tt&amp;gt;) = '''f'''.&lt;br /&gt;
  &amp;lt;p&amp;gt;&lt;br /&gt;
  The empty conjunction is treated as a tautology, so ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;And()&amp;lt;/tt&amp;gt;) = '''t'''.&lt;br /&gt;
  &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;''Disjunction'': ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;Or(&amp;lt;/tt&amp;gt;c&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... c&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;tt&amp;gt;)&amp;lt;/tt&amp;gt;) = '''f''' if and only if  ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(c&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;) = ... = ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(c&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;) = '''f'''. Otherwise, ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;Or(&amp;lt;/tt&amp;gt;c&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... c&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;tt&amp;gt;)&amp;lt;/tt&amp;gt;) = '''t'''.&lt;br /&gt;
  &amp;lt;p&amp;gt;&lt;br /&gt;
  The empty disjunction is treated as a contradiction, so ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;Or()&amp;lt;/tt&amp;gt;) = '''f'''.&lt;br /&gt;
  &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;''Quantification'':&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;Exists ?v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... ?v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt; (&amp;amp;phi;)&amp;lt;/tt&amp;gt;) = '''t''' if and only if for some '''''I'''''*, described below,  ''TVal''&amp;lt;sub&amp;gt;I*&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;) = '''t'''.&amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;Forall ?v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... ?v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt; (&amp;amp;phi;))&amp;lt;/tt&amp;gt; = '''t''' if and only if for every '''''I'''''*, described below,  ''TVal''&amp;lt;sub&amp;gt;I*&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;) = '''t'''.&amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
    &amp;lt;p&amp;gt;&lt;br /&gt;
      Here '''''I'''''* is a semantic structure of the form &amp;amp;lt;'''''TV''''', '''''DTS''''', '''''D''''', '''''D'''''&amp;lt;sub&amp;gt;ind&amp;lt;/sub&amp;gt;, '''''D'''''&amp;lt;sub&amp;gt;func&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;C&amp;lt;/sub&amp;gt;, '''''I'''''*&amp;lt;sub&amp;gt;V&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;NF&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;list&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;tail&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;frame&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;sub&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;isa&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;=&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;external&amp;lt;/sub&amp;gt;, '''''I'''''&amp;lt;sub&amp;gt;truth&amp;lt;/sub&amp;gt;&amp;gt;, which is exactly like '''''I''''', except that the mapping '''''I'''''*&amp;lt;sub&amp;gt;V&amp;lt;/sub&amp;gt;, is used instead of '''''I'''''&amp;lt;sub&amp;gt;V&amp;lt;/sub&amp;gt;. &amp;amp;nbsp; '''''I'''''*&amp;lt;sub&amp;gt;V&amp;lt;/sub&amp;gt; is defined to coincide with '''''I'''''&amp;lt;sub&amp;gt;V&amp;lt;/sub&amp;gt; on all variables except, possibly, on &amp;lt;tt&amp;gt;?v&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;,...,&amp;lt;tt&amp;gt;?v&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;.&lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;''Rule implication'':&lt;br /&gt;
    &amp;lt;ul&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;&lt;br /&gt;
        ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(''conclusion'' :- ''condition'') = '''t''', if either ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(''conclusion'')='''t''' or  ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(''condition'')='''f'''.&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;&lt;br /&gt;
        ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(''conclusion'' :- ''condition'') = '''f''' &amp;amp;nbsp; otherwise.&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;''Groups of rules'':&lt;br /&gt;
    &amp;lt;p&amp;gt;&lt;br /&gt;
       If &amp;lt;tt&amp;gt;&amp;amp;Gamma;&amp;lt;/tt&amp;gt; is a group formula of the form  &amp;lt;tt&amp;gt;Group(&amp;amp;phi;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt; ... &amp;amp;phi;&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;)&amp;lt;/tt&amp;gt; then&lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
    &amp;lt;ul&amp;gt;       &lt;br /&gt;
      &amp;lt;li&amp;gt;&lt;br /&gt;
       ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;Gamma;&amp;lt;/tt&amp;gt;) = '''t''' if and only if ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;) = '''t''', ..., ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;) = '''t'''.&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;&lt;br /&gt;
          ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;Gamma;&amp;lt;/tt&amp;gt;) = '''f''' &amp;amp;nbsp; otherwise.&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
    &amp;lt;/ul&amp;gt;&lt;br /&gt;
    &amp;lt;p&amp;gt;&lt;br /&gt;
       This means that a group of rules is treated as a conjunction. In particular, the empty group is treated as a tautology, so ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;Group()&amp;lt;/tt&amp;gt;) = '''t'''.&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-interpretation-of-documents&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== Interpretation of Documents ====&lt;br /&gt;
&lt;br /&gt;
Document formulas are interpreted using the usual semantic structures with two caveats: &amp;lt;tt&amp;gt;rif:local&amp;lt;/tt&amp;gt; must be renamed apart and imported documents must be taken into account. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-bld-renaming-apart&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
'''Definition (Renaming of local constants).'''&lt;br /&gt;
A '''''renaming mapping''''', &amp;amp;rho;, is a function that maps document formulas to document formulas subject to the following restriction:&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    If &amp;amp;rho;(&amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt;) = &amp;lt;tt&amp;gt;&amp;amp;Delta;'&amp;lt;/tt&amp;gt; then &amp;lt;tt&amp;gt;&amp;amp;Delta;'&amp;lt;/tt&amp;gt; is exactly like &amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt; except that all occurrences of some &amp;lt;tt&amp;gt;rif:local&amp;lt;/tt&amp;gt; constants in &amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt; may be consistently renamed into other &amp;lt;tt&amp;gt;rif:local&amp;lt;/tt&amp;gt; constants.&lt;br /&gt;
   &amp;lt;br/&amp;gt;&lt;br /&gt;
   By consistent renaming here we mean that different occurrences of the same  &amp;lt;tt&amp;gt;rif:local&amp;lt;/tt&amp;gt; constant in &amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt; are renamed identically. &lt;br /&gt;
&amp;amp;nbsp; &amp;amp;nbsp; &amp;amp;nbsp; &amp;amp;nbsp; &amp;amp;#9744; &lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-bld-semantic-multistruct&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
'''Definition (Semantic multi-structure).'''&lt;br /&gt;
A '''''semantic multi-structure''''' '''&amp;amp;Icirc;''' is a pair ('''&amp;amp;Icirc;'''&amp;lt;sub&amp;gt;ren&amp;lt;/sub&amp;gt;,'''''I'''''), where&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;  &lt;br /&gt;
     '''&amp;amp;Icirc;'''&amp;lt;sub&amp;gt;ren&amp;lt;/sub&amp;gt; is a renaming mapping; and&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;  &lt;br /&gt;
     '''''I''''' is a semantic structure.&lt;br /&gt;
&amp;amp;nbsp; &amp;amp;nbsp; &amp;amp;nbsp; &amp;amp;nbsp; &amp;amp;#9744; &lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The semantics of RIF documents is now defined as follows.&lt;br /&gt;
&lt;br /&gt;
'''Definition (Truth valuation of document formulas).'''&lt;br /&gt;
Let &amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt; be a document formula and let &lt;br /&gt;
&amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;, ..., &amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt;&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt; be all the RIF-BLD document formulas that are ''imported'' into &amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt; (directly or indirectly, according to Definition [[#def-bld-imported-doc|Imported document]]).&lt;br /&gt;
Let &amp;lt;tt&amp;gt;&amp;amp;Gamma;&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;&amp;amp;Gamma;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, ..., &amp;lt;tt&amp;gt;&amp;amp;Gamma;&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; denote the respective group formulas [[#def-associated-group|associated]] with these documents. If '''&amp;amp;Icirc;''' = ('''&amp;amp;Icirc;'''&amp;lt;sub&amp;gt;ren&amp;lt;/sub&amp;gt;,'''''I''''')  is a semantic multi-structure, then we define:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;       &lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
   ''TVal''&amp;lt;sub&amp;gt;'''&amp;amp;Icirc;'''&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt;) =  '''t'''  if and only if ''TVal''&amp;lt;sub&amp;gt;'''''I'''''&amp;lt;/sub&amp;gt;('''&amp;amp;Icirc;'''&amp;lt;sub&amp;gt;ren&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;Gamma;&amp;lt;/tt&amp;gt;)) =  ''TVal''&amp;lt;sub&amp;gt;'''''I'''''&amp;lt;/sub&amp;gt;('''&amp;amp;Icirc;'''&amp;lt;sub&amp;gt;ren&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;Gamma;&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;)) =  ... = ''TVal''&amp;lt;sub&amp;gt;'''''I'''''&amp;lt;/sub&amp;gt;('''&amp;amp;Icirc;'''&amp;lt;sub&amp;gt;ren&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;Gamma;&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;)) = '''t'''.&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
That is, &amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt; evaluates to '''t''' iff, after possible renaming of &amp;lt;tt&amp;gt;rif:local&amp;lt;/tt&amp;gt; constants, its associated group formula as well as the group formulas of all the imported documents evaluate to '''t'''. &lt;br /&gt;
&lt;br /&gt;
For non-document formulas, we define ''TVal''&amp;lt;sub&amp;gt;'''&amp;amp;Icirc;'''&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;) = ''TVal''&amp;lt;sub&amp;gt;'''''I'''''&amp;lt;/sub&amp;gt;('''&amp;amp;Icirc;'''&amp;lt;sub&amp;gt;ren&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;)).&lt;br /&gt;
&amp;amp;nbsp; &amp;amp;nbsp; &amp;amp;nbsp; &amp;amp;nbsp; &amp;amp;#9744;  &lt;br /&gt;
&lt;br /&gt;
Note that this definition takes into account only those imported document formulas that are reachable via the one-argument import directives. Two argument import directives are not covered here. Their semantics is defined by the document RIF RDF and OWL Compatibility &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-swc|RIF-RDF+OWL]]].&lt;br /&gt;
&lt;br /&gt;
Also note that some of the &amp;lt;tt&amp;gt;&amp;amp;Gamma;&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; above may be missing since all parts in a document formula are optional. In this case, we assume that &amp;lt;tt&amp;gt;&amp;amp;Gamma;&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; is a tautology, such as &amp;lt;tt&amp;gt;And()&amp;lt;/tt&amp;gt;, and every  ''TVal'' function maps such a &amp;lt;tt&amp;gt;&amp;amp;Gamma;&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; to the truth value '''t'''.&lt;br /&gt;
&lt;br /&gt;
The above definitions make the intent behind the &amp;lt;tt&amp;gt;[[DTB#rif-local-space|rif:local]]&amp;lt;/tt&amp;gt; constants clear: due to renaming, occurrences of such constants in different documents can be interpreted differently even if they have the same name. Therefore, each document can choose the names for the &amp;lt;tt&amp;gt;rif:local&amp;lt;/tt&amp;gt; constants freely and without regard to the names of such constants used in the imported documents.&lt;br /&gt;
&lt;br /&gt;
For the relationship between &amp;lt;tt&amp;gt;rif:local&amp;lt;/tt&amp;gt; and RDF blank nodes readers are referred to Section [[SWC#sec-swc-symbols-rdf-owl|Symbols in RIF Versus RDF/OWL (Informative)]] of &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-swc|RIF-RDF+OWL]]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-logical-entailment&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== Logical Entailment ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We now define what it means for a set of RIF-BLD rules (embedded in a group or a document formula) to entail another RIF-BLD formula.  In RIF-BLD we are mostly interested in entailment of RIF condition formulas, which can be viewed as queries to RIF-BLD groups or documents. Entailment of condition formulas provides formal underpinning to RIF-BLD queries.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
We say that a RIF-BLD condition formula &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;  is &amp;lt;span id=&amp;quot;def-bld-existential-closure&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;''existentially closed'', if and only if every variable, &amp;lt;tt&amp;gt;?V&amp;lt;/tt&amp;gt;, in &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;  occurs in a formula of the form &amp;lt;tt&amp;gt;Exists ...?V...(&amp;amp;psi;)&amp;lt;/tt&amp;gt; that occurs as part of &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
In the remainder of this specification, every formula will be assumed to be part of some document. If it is not physically part of any document, it will be said to belong to a special ''query document''. If '''''I''''' is a semantic multi-structure, &amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt; is the document of formula &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;, and '''''I'''''&amp;lt;sup&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt;&amp;lt;/sup&amp;gt; is the component structure in '''''I''''' that corresponds to &amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt;, then ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;) is defined as ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;sup&amp;gt;&amp;amp;Delta;&amp;lt;/sup&amp;gt;&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;). Otherwise, ''TVal''&amp;lt;sub&amp;gt;I&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;) is undefined.&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-bld-model-formula&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
'''Definition (Models).'''&lt;br /&gt;
A multi-structure '''&amp;amp;Icirc;''' is a '''''model''''' of a formula, &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;, written as '''&amp;amp;Icirc;'''&amp;lt;tt&amp;gt;&amp;amp;nbsp;|=&amp;amp;nbsp;&amp;amp;phi;&amp;lt;/tt&amp;gt;, iff ''TVal''&amp;lt;sub&amp;gt;&amp;amp;Icirc;&amp;lt;/sub&amp;gt;(&amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt;) = '''t'''. Here &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; can be a document or a non-document formula. &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-bld-entail&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
'''Definition (Logical entailment).'''&lt;br /&gt;
Let &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;&amp;amp;psi;&amp;lt;/tt&amp;gt; be (document or non-document) formulas. We say that &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;lt;/tt&amp;gt; '''''entails''''' &amp;lt;tt&amp;gt;&amp;amp;psi;&amp;lt;/tt&amp;gt;,  written as &amp;lt;tt&amp;gt;&amp;amp;phi;&amp;amp;nbsp;|=&amp;amp;nbsp;&amp;amp;psi;&amp;lt;/tt&amp;gt;, if and only if for every multi-structure, '''&amp;amp;Icirc;''', '''&amp;amp;Icirc;'''&amp;lt;tt&amp;gt;&amp;amp;nbsp;|=&amp;amp;nbsp;&amp;amp;phi;&amp;lt;/tt&amp;gt; implies '''&amp;amp;Icirc;'''&amp;lt;tt&amp;gt;&amp;amp;nbsp;|=&amp;amp;nbsp;&amp;amp;psi;&amp;lt;/tt&amp;gt;. &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Note that one consequence of the multi-document semantics of RIF-BLD is that local constants specified in one document cannot be queried from another document. For instance, if one document, &amp;lt;tt&amp;gt;&amp;amp;Delta;'&amp;lt;/tt&amp;gt;, has the fact &amp;lt;tt&amp;gt;&amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/ppp&amp;quot;^^rif:iri(&amp;quot;abc&amp;quot;^^rif:local)&amp;lt;/tt&amp;gt; while another document formula, &amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt;, imports &amp;lt;tt&amp;gt;&amp;amp;Delta;'&amp;lt;/tt&amp;gt; and has the rule &amp;lt;tt&amp;gt;&amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/qqq&amp;quot;^^rif:iri(?X) :- &amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/ppp&amp;quot;^^rif:iri(?X)&amp;lt;/tt&amp;gt;, then &amp;lt;tt&amp;gt;&amp;amp;Delta; |= &amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/qqq&amp;quot;^^rif:iri(&amp;quot;abc&amp;quot;^^rif:local)&amp;lt;/tt&amp;gt; does &amp;lt;em&amp;gt;not&amp;lt;/em&amp;gt; hold. This is because the symbol &amp;lt;tt&amp;gt;&amp;quot;abc&amp;quot;^^rif:local&amp;lt;/tt&amp;gt; in &amp;lt;tt&amp;gt;&amp;amp;Delta;'&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;&amp;amp;Delta;&amp;lt;/tt&amp;gt; is treated as different constants by semantic multi-structures. &lt;br /&gt;
&lt;br /&gt;
This behavior of local symbols should be contrasted with the behavior of &amp;lt;tt&amp;gt;rif:iri&amp;lt;/tt&amp;gt; symbols. Suppose, in the above scenario, &amp;lt;tt&amp;gt;&amp;amp;Delta;'&amp;lt;/tt&amp;gt; also has the fact  &amp;lt;tt&amp;gt;&amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/ppp&amp;quot;^^rif:iri(&amp;quot;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//cde.example.org&amp;quot;^^rif:iri)&amp;lt;/tt&amp;gt;. Then &amp;lt;tt&amp;gt;&amp;amp;Delta; |= &amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/qqq&amp;quot;^^rif:iri(&amp;quot;&amp;lt;nowiki&amp;gt;http:&amp;lt;/nowiki&amp;gt;//cde.example.org&amp;quot;^^rif:iri)&amp;lt;/tt&amp;gt; &amp;lt;em&amp;gt;does&amp;lt;/em&amp;gt; hold.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-xml-bld&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== XML Serialization Syntax for RIF-BLD ==&lt;br /&gt;
&lt;br /&gt;
The RIF-BLD XML serialization defines&lt;br /&gt;
* a ''normative'' mapping from the RIF-BLD presentation syntax to XML (Section [[#sec-translation|Mapping from the Presentation Syntax to the XML Syntax]]), and&lt;br /&gt;
* a ''normative'' XML schema for the XML syntax (Appendix [[#sec-xsd-bld|XML Schema for BLD]]).&lt;br /&gt;
&lt;br /&gt;
Recall that the syntax of RIF-BLD is not context-free and thus cannot be fully captured by EBNF or XML Schema. Still, validity with respect to XML Schema can be a useful test. To reflect this state of affairs, we define two notions of syntactic correctness. The weaker notion checks correctness only with respect to XML Schema, while the stricter notion represents &amp;quot;true&amp;quot; syntactic correctness.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-bld-valid-xml&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
'''Definition (Valid BLD document in XML syntax).'''&lt;br /&gt;
A '''''valid''''' BLD document in the XML syntax is an XML document that is valid with respect to the XML schema in Appendix [[#sec-xsd-bld|XML Schema for BLD]]. &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-bld-admissible-xml&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
'''Definition (Admissible BLD document in XML syntax).'''&lt;br /&gt;
An '''''admissible''''' BLD document in the XML syntax is a valid BLD document in XML syntax that is the image of a well-formed RIF-BLD document in the presentation syntax (see Definition [[#def-bld-wff|Well-formed formula]] in Section [[#sec-formulas|Formulas]]) under the presentation-to-XML syntax mapping &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; defined in Section [[#sec-translation|Mapping from the Presentation Syntax to the XML Syntax]]. &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;#9744;&lt;br /&gt;
&lt;br /&gt;
The XML serialization for RIF-BLD is based on an ''alternating'' or ''striped'' syntax &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-alternating-normal-form|ANF01]]]. A striped serialization views XML documents as objects and divides all XML tags into class descriptors, called ''type tags'', and property descriptors, called ''role tags'' &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-type-and-role-tags|TRT03]]]. We follow the tradition of using capitalized names for type tags and lowercase names for role tags.&lt;br /&gt;
&lt;br /&gt;
The all-uppercase classes in the presentation syntax, such as &amp;lt;tt&amp;gt;FORMULA&amp;lt;/tt&amp;gt;, become XML Schema groups in Appendix [[#sec-xsd-bld|XML Schema for BLD]]. They are not visible in instance markup. The other classes as well as non-terminals and symbols (such as &amp;lt;tt&amp;gt;Exists&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;=&amp;lt;/tt&amp;gt;) become XML elements with optional attributes, as shown below.&lt;br /&gt;
&lt;br /&gt;
RIF-BLD uses &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xml-1-point-0|XML1.0]]] for its XML syntax.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-xml-condition-language&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
=== XML for the Condition Language ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
XML serialization of RIF-BLD in Section [[#sec-ebnf-condition-language|EBNF for RIF-BLD Condition Language]] uses the following elements.&lt;br /&gt;
&lt;br /&gt;
 - And       (conjunction)&lt;br /&gt;
 - Or        (disjunction)&lt;br /&gt;
 - Exists    (quantified formula for 'Exists', containing declare and formula roles)&lt;br /&gt;
 - declare   (declare role, containing a Var)&lt;br /&gt;
 - formula   (formula role, containing a FORMULA)&lt;br /&gt;
 - Atom      (atom formula, positional or with named arguments)&lt;br /&gt;
 - External  (external call, containing a content role)&lt;br /&gt;
 - content   (content role, containing an Atom, for predicates, or Expr, for functions)&lt;br /&gt;
 - Member    (member formula)&lt;br /&gt;
 - Subclass  (subclass formula)&lt;br /&gt;
 - Frame     (Frame formula)&lt;br /&gt;
 - object    (Member/Frame role, containing a TERM or an object description)&lt;br /&gt;
 - op        (Atom/Expr role for predicates/functions as operations)&lt;br /&gt;
 - args      (Atom/Expr positional arguments role, with ordered=&amp;quot;yes&amp;quot; attribute, containing n TERMs)&lt;br /&gt;
 - instance  (Member instance role)&lt;br /&gt;
 - class     (Member class role)&lt;br /&gt;
 - sub       (Subclass sub-class role)&lt;br /&gt;
 - super     (Subclass super-class role)&lt;br /&gt;
 - slot      (Atom/Expr or Frame slot role, with ordered=&amp;quot;yes&amp;quot; attribute, containing a Name or TERM followed by a TERM)&lt;br /&gt;
 - Equal     (prefix version of term equation '=')&lt;br /&gt;
 - left      (Equal left-hand side role)&lt;br /&gt;
 - right     (Equal right-hand side role)&lt;br /&gt;
 - Expr      (expression formula, positional or with named arguments)&lt;br /&gt;
 - List      (list term, closed or open)&lt;br /&gt;
 - items     (list items role, with ordered=&amp;quot;yes&amp;quot; attribute, containing n TERMs)&lt;br /&gt;
 - rest      (list rest role, corresponding to '|')&lt;br /&gt;
 - Const     (individual, function, or predicate symbol, with 'type' attribute)&lt;br /&gt;
 - Name      (name of named argument)&lt;br /&gt;
 - Var       (logic variable)&lt;br /&gt;
    &lt;br /&gt;
 - id        (identifier role, containing IRICONST)&lt;br /&gt;
 - meta      (meta role, containing metadata as a Frame or Frame conjunction)&lt;br /&gt;
&lt;br /&gt;
The name of a base or prefix is not associated with a RIF/XML element, since it is handled via preprocessing as discussed in Section [[#sec-translation-rule-language|Mapping of the Rule Language]].&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;tt&amp;gt;id&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;meta&amp;lt;/tt&amp;gt; elements, which are expansions of the &amp;lt;tt&amp;gt;IRIMETA&amp;lt;/tt&amp;gt; element, can occur optionally as the initial children of any Class element.&lt;br /&gt;
&lt;br /&gt;
For the XML Schema definition of the RIF-BLD condition language see Appendix [[#sec-xsd-bld|XML Schema for BLD]]. &lt;br /&gt;
&lt;br /&gt;
The XML syntax for symbol spaces uses the &amp;lt;tt&amp;gt;type&amp;lt;/tt&amp;gt; attribute associated with the XML element &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt;. For instance, a literal in the &amp;lt;tt&amp;gt;xs:dateTime&amp;lt;/tt&amp;gt; datatype is represented as follows:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;&amp;amp;lt;Const&amp;amp;nbsp;type=&amp;quot;&amp;amp;xs;dateTime&amp;quot;&amp;gt;2007-11-23T03:55:44-02:30&amp;amp;lt;/Const&amp;gt;&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;tt&amp;gt;xml:lang&amp;lt;/tt&amp;gt; attribute, as defined by [http://www.w3.org/TR/REC-xml/#sec-lang-tag 2.12 Language Identification] of [http://www.w3.org/TR/2000/REC-xml-20001006 XML 1.0] or its successor specifications in the W3C recommendation track, is optionally used to identify the language for the presentation of the &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt; to the user. It is allowed only in association with constants of the type &amp;lt;tt&amp;gt;rdf:plainLiteral&amp;lt;/tt&amp;gt;. A compliant implementation MUST ignore the &amp;lt;tt&amp;gt;xml:lang&amp;lt;/tt&amp;gt; attribute if the type of the &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt; is not &amp;lt;tt&amp;gt;rdf:plainLiteral&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
RIF-BLD also uses the &amp;lt;tt&amp;gt;ordered=&amp;quot;yes&amp;quot;&amp;lt;/tt&amp;gt; attribute to indicate that the children of &lt;br /&gt;
&amp;lt;tt&amp;gt;args&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;slot&amp;lt;/tt&amp;gt; elements are ordered.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ex-RIF-condition-serialization&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&lt;br /&gt;
'''Example 6''' (A RIF condition and its XML serialization).&lt;br /&gt;
&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This example illustrates XML serialization for RIF conditions. As before, the compact URI notation is used for better readability. Assume that the following prefix directives are found in the preamble to the document, whose XML form will be illustrated in Example 8:&lt;br /&gt;
&lt;br /&gt;
 Prefix(bks    &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/books#&amp;amp;gt;)&lt;br /&gt;
 Prefix(cpt    &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/concepts#&amp;amp;gt;)&lt;br /&gt;
 Prefix(curr   &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/currencies#&amp;amp;gt;)&lt;br /&gt;
 Prefix(rif    &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2007/rif#&amp;amp;gt;)&lt;br /&gt;
 Prefix(xs     &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2001/XMLSchema#&amp;amp;gt;)&lt;br /&gt;
&lt;br /&gt;
RIF condition:&lt;br /&gt;
 &lt;br /&gt;
    And (Exists ?Buyer (cpt:purchase(?Buyer ?Seller&lt;br /&gt;
                                     cpt:book(?Author bks:LeRif)&lt;br /&gt;
                                     curr:USD(49)))&lt;br /&gt;
         ?Seller=?Author )&lt;br /&gt;
 &lt;br /&gt;
XML serialization:&lt;br /&gt;
 &lt;br /&gt;
    &amp;amp;lt;And&amp;gt;&lt;br /&gt;
      &amp;amp;lt;formula&amp;gt;&lt;br /&gt;
        &amp;amp;lt;Exists&amp;gt;&lt;br /&gt;
          &amp;amp;lt;declare&amp;gt;&amp;amp;lt;Var&amp;gt;Buyer&amp;amp;lt;/Var&amp;gt;&amp;amp;lt;/declare&amp;gt;&lt;br /&gt;
          &amp;amp;lt;formula&amp;gt;&lt;br /&gt;
            &amp;amp;lt;Atom&amp;gt;&lt;br /&gt;
              &amp;amp;lt;op&amp;gt;&amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;cpt;purchase&amp;amp;lt;/Const&amp;gt;&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
              &amp;amp;lt;args ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
                &amp;amp;lt;Var&amp;gt;Buyer&amp;amp;lt;/Var&amp;gt;&lt;br /&gt;
                &amp;amp;lt;Var&amp;gt;Seller&amp;amp;lt;/Var&amp;gt;&lt;br /&gt;
                &amp;amp;lt;Expr&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;op&amp;gt;&amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;cpt;book&amp;amp;lt;/Const&amp;gt;&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;args ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;Var&amp;gt;Author&amp;amp;lt;/Var&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;bks;LeRif&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;/args&amp;gt;&lt;br /&gt;
                &amp;amp;lt;/Expr&amp;gt;&lt;br /&gt;
                &amp;amp;lt;Expr&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;op&amp;gt;&amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;curr;USD&amp;amp;lt;/Const&amp;gt;&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;args ordered=&amp;quot;yes&amp;quot;&amp;gt;&amp;amp;lt;Const type=&amp;quot;&amp;amp;xs;integer&amp;quot;&amp;gt;49&amp;amp;lt;/Const&amp;gt;&amp;amp;lt;/args&amp;gt;&lt;br /&gt;
                &amp;amp;lt;/Expr&amp;gt;&lt;br /&gt;
              &amp;amp;lt;/args&amp;gt;&lt;br /&gt;
            &amp;amp;lt;/Atom&amp;gt;&lt;br /&gt;
          &amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
        &amp;amp;lt;/Exists&amp;gt;&lt;br /&gt;
      &amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
      &amp;amp;lt;formula&amp;gt;&lt;br /&gt;
        &amp;amp;lt;Equal&amp;gt;&lt;br /&gt;
          &amp;amp;lt;left&amp;gt;&amp;amp;lt;Var&amp;gt;Seller&amp;amp;lt;/Var&amp;gt;&amp;amp;lt;/left&amp;gt;&lt;br /&gt;
          &amp;amp;lt;right&amp;gt;&amp;amp;lt;Var&amp;gt;Author&amp;amp;lt;/Var&amp;gt;&amp;amp;lt;/right&amp;gt;&lt;br /&gt;
        &amp;amp;lt;/Equal&amp;gt;&lt;br /&gt;
      &amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
    &amp;amp;lt;/And&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ex-rif-bld-namedargs-pres-syntax&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&lt;br /&gt;
'''Example 7''' (An XML serialization of a RIF condition with a frame and a named-argument term).&lt;br /&gt;
&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This example illustrates XML serialization of RIF conditions that involve terms with named arguments. As in Example 6, we assume the following prefix directives, whose XML form will be illustrated in Example 8:&lt;br /&gt;
&lt;br /&gt;
 Prefix(bks    &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/books#&amp;amp;gt;)&lt;br /&gt;
 Prefix(cpt    &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/concepts#&amp;amp;gt;)&lt;br /&gt;
 Prefix(curr   &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/currencies#&amp;amp;gt;)&lt;br /&gt;
 Prefix(rif    &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2007/rif#&amp;amp;gt;)&lt;br /&gt;
 Prefix(xs     &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2001/XMLSchema#&amp;amp;gt;)&lt;br /&gt;
&lt;br /&gt;
RIF condition:&lt;br /&gt;
 &lt;br /&gt;
    And (Exists ?Buyer ?P (&lt;br /&gt;
                  And (?P#cpt:purchase&lt;br /&gt;
                       ?P[cpt:buyer-&amp;gt;?Buyer&lt;br /&gt;
                          cpt:seller-&amp;gt;?Seller&lt;br /&gt;
                          cpt:item-&amp;gt;cpt:book(cpt:author-&amp;gt;?Author cpt:title-&amp;gt;bks:LeRif)&lt;br /&gt;
                          cpt:price-&amp;gt;49&lt;br /&gt;
                          cpt:currency-&amp;gt;curr:USD]))&lt;br /&gt;
         ?Seller=?Author)&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
XML serialization:&lt;br /&gt;
 &lt;br /&gt;
    &amp;amp;lt;And&amp;gt;&lt;br /&gt;
      &amp;amp;lt;formula&amp;gt;&lt;br /&gt;
        &amp;amp;lt;Exists&amp;gt;&lt;br /&gt;
          &amp;amp;lt;declare&amp;gt;&amp;amp;lt;Var&amp;gt;Buyer&amp;amp;lt;/Var&amp;gt;&amp;amp;lt;/declare&amp;gt;&lt;br /&gt;
          &amp;amp;lt;declare&amp;gt;&amp;amp;lt;Var&amp;gt;P&amp;amp;lt;/Var&amp;gt;&amp;amp;lt;/declare&amp;gt;&lt;br /&gt;
          &amp;amp;lt;formula&amp;gt;&lt;br /&gt;
            &amp;amp;lt;And&amp;gt;&lt;br /&gt;
              &amp;amp;lt;formula&amp;gt;&lt;br /&gt;
                &amp;amp;lt;Member&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;instance&amp;gt;&amp;amp;lt;Var&amp;gt;P&amp;amp;lt;/Var&amp;gt;&amp;amp;lt;/instance&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;class&amp;gt;&amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;cpt;purchase&amp;amp;lt;/Const&amp;gt;&amp;amp;lt;/class&amp;gt;&lt;br /&gt;
                &amp;amp;lt;/Member&amp;gt;&lt;br /&gt;
              &amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
              &amp;amp;lt;formula&amp;gt;&lt;br /&gt;
                &amp;amp;lt;Frame&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;object&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;Var&amp;gt;P&amp;amp;lt;/Var&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;/object&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;cpt;buyer&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;Var&amp;gt;Buyer&amp;amp;lt;/Var&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;cpt;seller&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;Var&amp;gt;Seller&amp;amp;lt;/Var&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;cpt;item&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;Expr&amp;gt;&lt;br /&gt;
                      &amp;amp;lt;op&amp;gt;&amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;cpt;book&amp;amp;lt;/Const&amp;gt;&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
                      &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
                        &amp;amp;lt;Name&amp;gt;&amp;amp;cpt;author&amp;amp;lt;/Name&amp;gt;&lt;br /&gt;
                        &amp;amp;lt;Var&amp;gt;Author&amp;amp;lt;/Var&amp;gt;&lt;br /&gt;
                      &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
                      &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
                        &amp;amp;lt;Name&amp;gt;&amp;amp;cpt;title&amp;amp;lt;/Name&amp;gt;&lt;br /&gt;
                        &amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;bks;LeRif&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
                      &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;/Expr&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;cpt;price&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;Const type=&amp;quot;&amp;amp;xs;integer&amp;quot;&amp;gt;49&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;cpt;currency&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;curr;USD&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
                &amp;amp;lt;/Frame&amp;gt;&lt;br /&gt;
              &amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
            &amp;amp;lt;/And&amp;gt;&lt;br /&gt;
          &amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
        &amp;amp;lt;/Exists&amp;gt;&lt;br /&gt;
      &amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
      &amp;amp;lt;formula&amp;gt;&lt;br /&gt;
        &amp;amp;lt;Equal&amp;gt;&lt;br /&gt;
          &amp;amp;lt;left&amp;gt;&amp;amp;lt;Var&amp;gt;Seller&amp;amp;lt;/Var&amp;gt;&amp;amp;lt;/left&amp;gt;&lt;br /&gt;
          &amp;amp;lt;right&amp;gt;&amp;amp;lt;Var&amp;gt;Author&amp;amp;lt;/Var&amp;gt;&amp;amp;lt;/right&amp;gt;&lt;br /&gt;
        &amp;amp;lt;/Equal&amp;gt;&lt;br /&gt;
      &amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
    &amp;amp;lt;/And&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-xml-rule-language&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== XML for the Rule Language ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We now extend the set of RIF-BLD serialization elements from Section [[#sec-xml-condition-language|XML for RIF-BLD Condition Language]] by including rules, along with their enclosing groups and documents, as described in Section [[#sec-ebnf-rule-language|EBNF for RIF-BLD Rule Language]]. The extended set includes the tags listed below.&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
The &amp;lt;tt&amp;gt;Forall&amp;lt;/tt&amp;gt; element contains the role elements &amp;lt;tt&amp;gt;declare&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;formula&amp;lt;/tt&amp;gt;, which were earlier used within the &amp;lt;tt&amp;gt;Exists&amp;lt;/tt&amp;gt; element in Section [[#sec-xml-condition-language|XML for RIF-BLD Condition Language]]. The &amp;lt;tt&amp;gt;Implies&amp;lt;/tt&amp;gt; element contains the role elements &amp;lt;tt&amp;gt;if&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;then&amp;lt;/tt&amp;gt; to designate these two parts of a rule. &lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 - Document  (document, containing optional directive and payload roles)&lt;br /&gt;
 - directive (directive role, containing Import)&lt;br /&gt;
 - payload   (payload role, containing Group)&lt;br /&gt;
 - Import    (importation, containing location and optional profile)&lt;br /&gt;
 - location  (location role, containing ANYURICONST)&lt;br /&gt;
 - profile   (profile role, containing PROFILE)&lt;br /&gt;
 - Group     (nested collection of sentences)&lt;br /&gt;
 - sentence  (sentence role, containing RULE or Group)&lt;br /&gt;
 - Forall    (quantified formula for 'Forall', containing declare and formula roles)&lt;br /&gt;
 - Implies   (implication, containing if and then roles)&lt;br /&gt;
 - if        (antecedent role, containing FORMULA)&lt;br /&gt;
 - then      (consequent role, containing ATOMIC or conjunction of ATOMICs)&lt;br /&gt;
&lt;br /&gt;
The XML Schema Definition of RIF-BLD is given in Appendix [[#sec-xsd-bld|XML Schema for BLD]].&lt;br /&gt;
&lt;br /&gt;
While there is a RIF-BLD element tag for the &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directive, the &amp;lt;tt&amp;gt;Base&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;Prefix&amp;lt;/tt&amp;gt; directives are not represented by RIF/XML tags: they are handled as follows (see also Section [[#sec-translation-rule-language|Mapping of the Rule Language]]).&lt;br /&gt;
A &amp;lt;tt&amp;gt;Base&amp;lt;/tt&amp;gt; directive in the presentation syntax becomes an &amp;lt;tt&amp;gt;xml:base&amp;lt;/tt&amp;gt; attribute &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xml-base|XML-Base]]] in the XML &amp;lt;tt&amp;gt;Document&amp;lt;/tt&amp;gt; tag.&lt;br /&gt;
The base IRI specified as the value of that attribute applies to content of the RIF/XML element that deals with &amp;lt;tt&amp;gt;rif:iri&amp;lt;/tt&amp;gt; constants, namely to relative-IRI content of the &amp;lt;tt&amp;gt;&amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;lt;/tt&amp;gt; element as well as symbol spaces, loation, and profile.&lt;br /&gt;
A collection of &amp;lt;tt&amp;gt;Prefix&amp;lt;/tt&amp;gt; directives in the presentation syntax becomes a &amp;lt;tt&amp;gt;DOCTYPE&amp;lt;/tt&amp;gt; DTD &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xml-1-point-0|XML1.0]]] preceding the RIF-BLD &amp;lt;tt&amp;gt;Document&amp;lt;/tt&amp;gt; and containing a declaration of an &amp;lt;tt&amp;gt;ENTITY&amp;lt;/tt&amp;gt; for each &amp;lt;tt&amp;gt;Prefix&amp;lt;/tt&amp;gt; directive.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;ex-RIF-doc-with-annotation-serialization&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&lt;br /&gt;
'''Example 8''' (Serializing a RIF-BLD document containing an annotated group).&lt;br /&gt;
&amp;lt;/span&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This example shows a serialization for the document from Example 5. For convenience, the presentation syntax is reproduced at the top, and is followed by its serialization.&lt;br /&gt;
The base IRI &amp;lt;tt&amp;gt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/people#&amp;lt;/tt&amp;gt; applies to the relative &amp;lt;tt&amp;gt;rif:iri&amp;lt;/tt&amp;gt; constants with content &amp;lt;tt&amp;gt;John&amp;lt;/tt&amp;gt; (twice) and &amp;lt;tt&amp;gt;Fred&amp;lt;/tt&amp;gt; (once).&lt;br /&gt;
&lt;br /&gt;
Presentation syntax:&lt;br /&gt;
 &lt;br /&gt;
 Document(&lt;br /&gt;
   Base(&amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/people#&amp;amp;gt;)&lt;br /&gt;
   Prefix(cpt  &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/concepts#&amp;amp;gt;)&lt;br /&gt;
   Prefix(dc   &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;purl.org/dc/terms/&amp;amp;gt;)&lt;br /&gt;
   Prefix(rif  &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2007/rif#&amp;amp;gt;)&lt;br /&gt;
   Prefix(func &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2007/rif-builtin-function#&amp;amp;gt;)&lt;br /&gt;
   Prefix(pred &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2007/rif-builtin-predicate#&amp;amp;gt;)&lt;br /&gt;
   Prefix(xs   &amp;amp;lt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2001/XMLSchema#&amp;amp;gt;)&lt;br /&gt;
   &lt;br /&gt;
   (* &amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;sample.org&amp;quot;^^rif:iri _pd[dc:publisher -&amp;gt; &amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/&amp;quot;^^rif:iri&lt;br /&gt;
                                       dc:date -&amp;gt; &amp;quot;2008-04-04&amp;quot;^^xs:date] *)&lt;br /&gt;
   Group&lt;br /&gt;
   (&lt;br /&gt;
     Forall ?item ?deliverydate ?scheduledate ?diffduration ?diffdays (&lt;br /&gt;
         cpt:reject(&amp;amp;lt;John&amp;amp;gt; ?item) :-&lt;br /&gt;
             And(cpt:perishable(?item)&lt;br /&gt;
                 cpt:delivered(?item ?deliverydate &amp;amp;lt;John&amp;amp;gt;)&lt;br /&gt;
                 cpt:scheduled(?item ?scheduledate)&lt;br /&gt;
                 ?diffduration = External(func:subtract-dateTimes(?deliverydate ?scheduledate))&lt;br /&gt;
                 ?diffdays = External(func:days-from-duration(?diffduration))&lt;br /&gt;
                 External(pred:numeric-greater-than(?diffdays 10)))&lt;br /&gt;
     )&lt;br /&gt;
  &lt;br /&gt;
     Forall ?item (&lt;br /&gt;
         cpt:reject(&amp;amp;lt;Fred&amp;amp;gt; ?item) :- cpt:unsolicited(?item)&lt;br /&gt;
     )&lt;br /&gt;
   )&lt;br /&gt;
 )&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
XML syntax:&lt;br /&gt;
 &lt;br /&gt;
 &amp;amp;lt;!DOCTYPE Document [&lt;br /&gt;
   &amp;amp;lt;!ENTITY cpt  &amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/concepts#&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;amp;lt;!ENTITY dc   &amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;purl.org/dc/terms/&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;amp;lt;!ENTITY rif  &amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2007/rif#&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;amp;lt;!ENTITY func &amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2007/rif-builtin-function#&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;amp;lt;!ENTITY pred &amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2007/rif-builtin-predicate#&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;amp;lt;!ENTITY xs   &amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2001/XMLSchema#&amp;quot;&amp;gt;&lt;br /&gt;
 ]&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
 &amp;amp;lt;Document&lt;br /&gt;
     xml:base=&amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;example.com/people#&amp;quot;&lt;br /&gt;
     xmlns=&amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2007/rif#&amp;quot;&lt;br /&gt;
     xmlns:xsi=&amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2001/XMLSchema-instance&amp;quot;&lt;br /&gt;
     xmlns:xs=&amp;quot;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/2001/XMLSchema#&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;amp;lt;payload&amp;gt;&lt;br /&gt;
    &amp;amp;lt;Group&amp;gt;&lt;br /&gt;
     &amp;amp;lt;id&amp;gt;&lt;br /&gt;
       &amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;sample.org&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
     &amp;amp;lt;/id&amp;gt;&lt;br /&gt;
     &amp;amp;lt;meta&amp;gt;&lt;br /&gt;
       &amp;amp;lt;Frame&amp;gt;&lt;br /&gt;
         &amp;amp;lt;object&amp;gt;&lt;br /&gt;
           &amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;local&amp;quot;&amp;gt;pd&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
         &amp;amp;lt;/object&amp;gt;&lt;br /&gt;
         &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
           &amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;dc;publisher&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
           &amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;http://&amp;lt;/nowiki&amp;gt;www.w3.org/&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
         &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
         &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
           &amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;dc;date&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
           &amp;amp;lt;Const type=&amp;quot;&amp;amp;xs;date&amp;quot;&amp;gt;2008-04-04&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
         &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
       &amp;amp;lt;/Frame&amp;gt;&lt;br /&gt;
     &amp;amp;lt;/meta&amp;gt;&lt;br /&gt;
     &amp;amp;lt;sentence&amp;gt;&lt;br /&gt;
      &amp;amp;lt;Forall&amp;gt;&lt;br /&gt;
        &amp;amp;lt;declare&amp;gt;&amp;amp;lt;Var&amp;gt;item&amp;amp;lt;/Var&amp;gt;&amp;amp;lt;/declare&amp;gt;&lt;br /&gt;
        &amp;amp;lt;declare&amp;gt;&amp;amp;lt;Var&amp;gt;deliverydate&amp;amp;lt;/Var&amp;gt;&amp;amp;lt;/declare&amp;gt;&lt;br /&gt;
        &amp;amp;lt;declare&amp;gt;&amp;amp;lt;Var&amp;gt;scheduledate&amp;amp;lt;/Var&amp;gt;&amp;amp;lt;/declare&amp;gt;&lt;br /&gt;
        &amp;amp;lt;declare&amp;gt;&amp;amp;lt;Var&amp;gt;diffduration&amp;amp;lt;/Var&amp;gt;&amp;amp;lt;/declare&amp;gt;&lt;br /&gt;
        &amp;amp;lt;declare&amp;gt;&amp;amp;lt;Var&amp;gt;diffdays&amp;amp;lt;/Var&amp;gt;&amp;amp;lt;/declare&amp;gt;&lt;br /&gt;
        &amp;amp;lt;formula&amp;gt;&lt;br /&gt;
          &amp;amp;lt;Implies&amp;gt;&lt;br /&gt;
            &amp;amp;lt;if&amp;gt;&lt;br /&gt;
              &amp;amp;lt;And&amp;gt;&lt;br /&gt;
                &amp;amp;lt;formula&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;Atom&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;op&amp;gt;&amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;cpt;perishable&amp;amp;lt;/Const&amp;gt;&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;args ordered=&amp;quot;yes&amp;quot;&amp;gt;&amp;amp;lt;Var&amp;gt;item&amp;amp;lt;/Var&amp;gt;&amp;amp;lt;/args&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;/Atom&amp;gt;&lt;br /&gt;
                &amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
                &amp;amp;lt;formula&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;Atom&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;op&amp;gt;&amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;cpt;delivered&amp;amp;lt;/Const&amp;gt;&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;args ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
                      &amp;amp;lt;Var&amp;gt;item&amp;amp;lt;/Var&amp;gt;&lt;br /&gt;
                      &amp;amp;lt;Var&amp;gt;deliverydate&amp;amp;lt;/Var&amp;gt;&lt;br /&gt;
                      &amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;John&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;/args&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;/Atom&amp;gt;&lt;br /&gt;
                &amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
                &amp;amp;lt;formula&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;Atom&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;op&amp;gt;&amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;cpt;scheduled&amp;amp;lt;/Const&amp;gt;&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;args ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
                      &amp;amp;lt;Var&amp;gt;item&amp;amp;lt;/Var&amp;gt;&lt;br /&gt;
                      &amp;amp;lt;Var&amp;gt;scheduledate&amp;amp;lt;/Var&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;/args&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;/Atom&amp;gt;&lt;br /&gt;
                &amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
                &amp;amp;lt;formula&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;Equal&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;left&amp;gt;&amp;amp;lt;Var&amp;gt;diffduration&amp;amp;lt;/Var&amp;gt;&amp;amp;lt;/left&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;right&amp;gt;&lt;br /&gt;
                      &amp;amp;lt;External&amp;gt;&lt;br /&gt;
                        &amp;amp;lt;content&amp;gt;&lt;br /&gt;
                          &amp;amp;lt;Expr&amp;gt;&lt;br /&gt;
                            &amp;amp;lt;op&amp;gt;&amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;func;subtract-dateTimes&amp;amp;lt;/Const&amp;gt;&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
                            &amp;amp;lt;args ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
                              &amp;amp;lt;Var&amp;gt;deliverydate&amp;amp;lt;/Var&amp;gt;&lt;br /&gt;
                              &amp;amp;lt;Var&amp;gt;scheduledate&amp;amp;lt;/Var&amp;gt;&lt;br /&gt;
                            &amp;amp;lt;/args&amp;gt;&lt;br /&gt;
                          &amp;amp;lt;/Expr&amp;gt;&lt;br /&gt;
                        &amp;amp;lt;/content&amp;gt;&lt;br /&gt;
                      &amp;amp;lt;/External&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;/right&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;/Equal&amp;gt;&lt;br /&gt;
                &amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
                &amp;amp;lt;formula&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;Equal&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;left&amp;gt;&amp;amp;lt;Var&amp;gt;diffdays&amp;amp;lt;/Var&amp;gt;&amp;amp;lt;/left&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;right&amp;gt;&lt;br /&gt;
                      &amp;amp;lt;External&amp;gt;&lt;br /&gt;
                        &amp;amp;lt;content&amp;gt;&lt;br /&gt;
                          &amp;amp;lt;Expr&amp;gt;&lt;br /&gt;
                            &amp;amp;lt;op&amp;gt;&amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;func;days-from-duration&amp;amp;lt;/Const&amp;gt;&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
                            &amp;amp;lt;args ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
                              &amp;amp;lt;Var&amp;gt;diffduration&amp;amp;lt;/Var&amp;gt;&lt;br /&gt;
                            &amp;amp;lt;/args&amp;gt;&lt;br /&gt;
                          &amp;amp;lt;/Expr&amp;gt;&lt;br /&gt;
                        &amp;amp;lt;/content&amp;gt;&lt;br /&gt;
                      &amp;amp;lt;/External&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;/right&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;/Equal&amp;gt;&lt;br /&gt;
                &amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
                &amp;amp;lt;formula&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;External&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;content&amp;gt;&lt;br /&gt;
                      &amp;amp;lt;Atom&amp;gt;&lt;br /&gt;
                        &amp;amp;lt;op&amp;gt;&amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;pred;numeric-greater-than&amp;amp;lt;/Const&amp;gt;&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
                        &amp;amp;lt;args ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
                          &amp;amp;lt;Var&amp;gt;diffdays&amp;amp;lt;/Var&amp;gt;&lt;br /&gt;
                          &amp;amp;lt;Const type=&amp;quot;&amp;amp;xs;integer&amp;quot;&amp;gt;10&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
                        &amp;amp;lt;/args&amp;gt;&lt;br /&gt;
                      &amp;amp;lt;/Atom&amp;gt;&lt;br /&gt;
                    &amp;amp;lt;/content&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;/External&amp;gt;&lt;br /&gt;
                &amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
              &amp;amp;lt;/And&amp;gt;&lt;br /&gt;
            &amp;amp;lt;/if&amp;gt;&lt;br /&gt;
            &amp;amp;lt;then&amp;gt;&lt;br /&gt;
              &amp;amp;lt;Atom&amp;gt;&lt;br /&gt;
                &amp;amp;lt;op&amp;gt;&amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;cpt;reject&amp;amp;lt;/Const&amp;gt;&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
                &amp;amp;lt;args ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;John&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;Var&amp;gt;item&amp;amp;lt;/Var&amp;gt;&lt;br /&gt;
                &amp;amp;lt;/args&amp;gt;&lt;br /&gt;
              &amp;amp;lt;/Atom&amp;gt;&lt;br /&gt;
            &amp;amp;lt;/then&amp;gt;&lt;br /&gt;
          &amp;amp;lt;/Implies&amp;gt;&lt;br /&gt;
        &amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
      &amp;amp;lt;/Forall&amp;gt;&lt;br /&gt;
     &amp;amp;lt;/sentence&amp;gt;&lt;br /&gt;
     &amp;amp;lt;sentence&amp;gt;&lt;br /&gt;
      &amp;amp;lt;Forall&amp;gt;&lt;br /&gt;
        &amp;amp;lt;declare&amp;gt;&amp;amp;lt;Var&amp;gt;item&amp;amp;lt;/Var&amp;gt;&amp;amp;lt;/declare&amp;gt;&lt;br /&gt;
        &amp;amp;lt;formula&amp;gt;&lt;br /&gt;
          &amp;amp;lt;Implies&amp;gt;&lt;br /&gt;
            &amp;amp;lt;if&amp;gt;&lt;br /&gt;
              &amp;amp;lt;Atom&amp;gt;&lt;br /&gt;
                &amp;amp;lt;op&amp;gt;&amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;cpt;unsolicited&amp;amp;lt;/Const&amp;gt;&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
                &amp;amp;lt;args ordered=&amp;quot;yes&amp;quot;&amp;gt;&amp;amp;lt;Var&amp;gt;item&amp;amp;lt;/Var&amp;gt;&amp;amp;lt;/args&amp;gt;&lt;br /&gt;
              &amp;amp;lt;/Atom&amp;gt;&lt;br /&gt;
            &amp;amp;lt;/if&amp;gt;&lt;br /&gt;
            &amp;amp;lt;then&amp;gt;&lt;br /&gt;
              &amp;amp;lt;Atom&amp;gt;&lt;br /&gt;
                &amp;amp;lt;op&amp;gt;&amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;&amp;amp;cpt;reject&amp;amp;lt;/Const&amp;gt;&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
                &amp;amp;lt;args ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;Const type=&amp;quot;&amp;amp;rif;iri&amp;quot;&amp;gt;Fred&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
                  &amp;amp;lt;Var&amp;gt;item&amp;amp;lt;/Var&amp;gt;&lt;br /&gt;
                &amp;amp;lt;/args&amp;gt;&lt;br /&gt;
              &amp;amp;lt;/Atom&amp;gt;&lt;br /&gt;
            &amp;amp;lt;/then&amp;gt;&lt;br /&gt;
          &amp;amp;lt;/Implies&amp;gt;&lt;br /&gt;
        &amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
      &amp;amp;lt;/Forall&amp;gt;&lt;br /&gt;
     &amp;amp;lt;/sentence&amp;gt;&lt;br /&gt;
    &amp;amp;lt;/Group&amp;gt;&lt;br /&gt;
   &amp;amp;lt;/payload&amp;gt;&lt;br /&gt;
  &amp;amp;lt;/Document&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-translation&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Mapping from the Presentation Syntax to the XML Syntax ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This section defines a normative mapping, &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;, from the presentation syntax to the XML syntax of RIF-BLD.&lt;br /&gt;
The mapping is given via tables where each row specifies the mapping of a particular syntactic pattern in the presentation syntax. These patterns appear in the first column of the tables and the '''''bold-italic''''' symbols represent metavariables. The second column represents the corresponding XML patterns, which may contain applications of the mapping &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; to these metavariables. When an expression &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;&amp;lt;tt&amp;gt;(&amp;lt;b&amp;gt;&amp;lt;i&amp;gt;metavar&amp;lt;/i&amp;gt;&amp;lt;/b&amp;gt;)&amp;lt;/tt&amp;gt; occurs in an XML pattern in the right column of a translation table, it should be understood as a recursive application of &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; to the presentation syntax represented by the metavariable. The XML syntax result of such an application is substituted for the expression &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;&amp;lt;tt&amp;gt;(&amp;lt;b&amp;gt;&amp;lt;i&amp;gt;metavar&amp;lt;/i&amp;gt;&amp;lt;/b&amp;gt;)&amp;lt;/tt&amp;gt;. &lt;br /&gt;
A sequence of terms containing metavariables with subscripts is indicated by an ellipsis.&lt;br /&gt;
For the subscript &amp;lt;tt&amp;gt;m&amp;lt;/tt&amp;gt; it is understood that&lt;br /&gt;
&amp;lt;tt&amp;gt;m&amp;amp;ge;1&amp;lt;/tt&amp;gt;, i.e. the ellipsis indicates at least one term.&lt;br /&gt;
For the subscript &amp;lt;tt&amp;gt;n&amp;lt;/tt&amp;gt; it is understood that&lt;br /&gt;
&amp;lt;tt&amp;gt;n&amp;amp;ge;0&amp;lt;/tt&amp;gt;, i.e. the ellipsis indicates zero or more terms.&lt;br /&gt;
A metavariable or a well-formed XML subelement is marked as optional by appending a bold-italic question mark, '''''?''''', on its right.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-translation-condition-language&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &lt;br /&gt;
==== Mapping of the Condition Language ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; mapping from the presentation syntax to the XML syntax of the RIF-BLD Condition Language is specified by the table below. &lt;br /&gt;
Each row indicates a translation&lt;br /&gt;
&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;(&amp;lt;tt&amp;gt;Presentation&amp;lt;/tt&amp;gt;) = &amp;lt;tt&amp;gt;XML&amp;lt;/tt&amp;gt;. The function &amp;lt;tt&amp;gt;&amp;lt;i&amp;gt;remove-outer-quotes&amp;lt;/i&amp;gt;&amp;lt;/tt&amp;gt; used in the translation removes enclosing double quotes from a string and leaves unquoted strings untouched. &lt;br /&gt;
Since the presentation syntax of RIF-BLD is context sensitive, the mapping must differentiate between the terms that occur in the position of individuals and the terms that occur as atomic formulas. To this end, in the translation table, the positional and named-argument terms that occur in the context of atomic formulas are denoted by expressions of the form '''''pred'''''(...) and the terms that occur as individuals are denoted by expressions of the form '''''func'''''(...).&lt;br /&gt;
In the table, each metavariable for an (unnamed) positional '''''argument&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;''''' is assumed to be instantiated to values unequal to the instantiations of named arguments '''''name&amp;lt;sub&amp;gt;j&amp;lt;/sub&amp;gt;''''' &amp;lt;tt&amp;gt;-&amp;gt;&amp;lt;/tt&amp;gt; '''''filler&amp;lt;sub&amp;gt;j&amp;lt;/sub&amp;gt;'''''. Regarding the last but first row, we assume that shortcuts for constants &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]] have already been expanded to their full form (&amp;lt;tt&amp;gt;&amp;quot;...&amp;quot;^^&amp;lt;/tt&amp;gt;'''''symspace''''').&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;syntax-translation-table&amp;quot;&lt;br /&gt;
! rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; | Presentation Syntax&lt;br /&gt;
! rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; | XML Syntax&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 And (&lt;br /&gt;
   '''''conjunct&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   . . .&lt;br /&gt;
   '''''conjunct&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
     )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;And&amp;gt;&lt;br /&gt;
   &amp;amp;lt;formula&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''conjunct&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
    . . .&lt;br /&gt;
   &amp;amp;lt;formula&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''conjunct&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/And&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 Or (&lt;br /&gt;
   '''''disjunct&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   . . .&lt;br /&gt;
   '''''disjunct&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
    )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Or&amp;gt;&lt;br /&gt;
   &amp;amp;lt;formula&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''disjunct&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
    . . .&lt;br /&gt;
   &amp;amp;lt;formula&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''disjunct&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Or&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 Exists&lt;br /&gt;
   '''''variable&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   . . .&lt;br /&gt;
   '''''variable&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''' (&lt;br /&gt;
              '''''premise'''''&lt;br /&gt;
             )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Exists&amp;gt;&lt;br /&gt;
   &amp;amp;lt;declare&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''variable&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/declare&amp;gt;&lt;br /&gt;
    . . .&lt;br /&gt;
   &amp;amp;lt;declare&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''variable&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/declare&amp;gt;&lt;br /&gt;
   &amp;amp;lt;formula&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''premise''''')&amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Exists&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 External (&lt;br /&gt;
   '''''atomexpr'''''&lt;br /&gt;
          )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;External&amp;gt;&lt;br /&gt;
   &amp;amp;lt;content&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''atomexpr''''')&amp;amp;lt;/content&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/External&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 '''''pred''''' (&lt;br /&gt;
      )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Atom&amp;gt;&lt;br /&gt;
   &amp;amp;lt;op&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''pred''''')&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Atom&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 '''''pred''''' (&lt;br /&gt;
   '''''argument&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   . . .&lt;br /&gt;
   '''''argument&amp;lt;sub&amp;gt;m&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
      )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Atom&amp;gt;&lt;br /&gt;
   &amp;amp;lt;op&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''pred''''')&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
   &amp;amp;lt;args ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''argument&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
     . . .&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''argument&amp;lt;sub&amp;gt;m&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/args&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Atom&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 '''''func''''' (&lt;br /&gt;
      )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Expr&amp;gt;&lt;br /&gt;
   &amp;amp;lt;op&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''func''''')&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Expr&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 '''''func''''' (&lt;br /&gt;
   '''''argument&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   . . .&lt;br /&gt;
   '''''argument&amp;lt;sub&amp;gt;m&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
      )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Expr&amp;gt;&lt;br /&gt;
   &amp;amp;lt;op&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''func''''')&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
   &amp;amp;lt;args ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''argument&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
     . . .&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''argument&amp;lt;sub&amp;gt;m&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/args&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Expr&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 List (&lt;br /&gt;
   '''''element&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   . . .&lt;br /&gt;
   '''''element&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
     )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;List&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;items ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''element&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
     . . .&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''element&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/items&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/List&amp;amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 List (&lt;br /&gt;
   '''''element&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   . . .&lt;br /&gt;
   '''''element&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   &amp;lt;nowiki&amp;gt;|&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
   '''''remainder'''''&lt;br /&gt;
     )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;List&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;items ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''element&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
     . . .&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''element&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/items&amp;gt;&lt;br /&gt;
   &amp;amp;lt;rest&amp;amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''remainder''''')&amp;amp;lt;/rest&amp;amp;gt;&lt;br /&gt;
 &amp;amp;lt;/List&amp;amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 '''''pred''''' (&lt;br /&gt;
   '''''name&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''' -&amp;gt; '''''filler&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   . . .&lt;br /&gt;
   '''''name&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''' -&amp;gt; '''''filler&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
      )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Atom&amp;gt;&lt;br /&gt;
   &amp;amp;lt;op&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''pred''''')&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
   &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;amp;lt;Name&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''name&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/Name&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''filler&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
    . . .&lt;br /&gt;
   &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;amp;lt;Name&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''name&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/Name&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''filler&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Atom&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 '''''func''''' (&lt;br /&gt;
   '''''name&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''' -&amp;gt; '''''filler&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   . . .&lt;br /&gt;
   '''''name&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''' -&amp;gt; '''''filler&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
      )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Expr&amp;gt;&lt;br /&gt;
   &amp;amp;lt;op&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''func''''')&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
   &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;amp;lt;Name&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''name&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/Name&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''filler&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
    . . .&lt;br /&gt;
   &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;amp;lt;Name&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''name&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/Name&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''filler&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Expr&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 '''''inst''''' [&lt;br /&gt;
   '''''key&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''' -&amp;gt; '''''filler&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   . . .&lt;br /&gt;
   '''''key&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''' -&amp;gt; '''''filler&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
      ]&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Frame&amp;gt;&lt;br /&gt;
   &amp;amp;lt;object&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''inst''''')&amp;amp;lt;/object&amp;gt;&lt;br /&gt;
   &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''key&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''filler&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
    . . .&lt;br /&gt;
   &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''key&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''filler&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Frame&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 '''''inst''''' # '''''class''''' [&lt;br /&gt;
   '''''key&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''' -&amp;gt; '''''filler&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   . . .&lt;br /&gt;
   '''''key&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''' -&amp;gt; '''''filler&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
              ]&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Frame&amp;gt;&lt;br /&gt;
   &amp;amp;lt;object&amp;gt;&lt;br /&gt;
     &amp;amp;lt;Member&amp;gt;&lt;br /&gt;
       &amp;amp;lt;instance&amp;gt;'''''inst''''''&amp;amp;lt;/instance&amp;gt;&lt;br /&gt;
       &amp;amp;lt;class&amp;gt;'''''class''''''&amp;amp;lt;/class&amp;gt;&lt;br /&gt;
     &amp;amp;lt;/Member&amp;gt;&lt;br /&gt;
   &amp;amp;lt;/object&amp;gt;&lt;br /&gt;
   &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     '''''key&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''''&lt;br /&gt;
     '''''filler&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''''&lt;br /&gt;
   &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
    . . .&lt;br /&gt;
   &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     '''''key&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''''&lt;br /&gt;
     '''''filler&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''''&lt;br /&gt;
   &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Frame&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 '''''sub''''' ## '''''super''''' [&lt;br /&gt;
   '''''key&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''' -&amp;gt; '''''filler&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   . . .&lt;br /&gt;
   '''''key&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''' -&amp;gt; '''''filler&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
              ]&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Frame&amp;gt;&lt;br /&gt;
   &amp;amp;lt;object&amp;gt;&lt;br /&gt;
     &amp;amp;lt;Subclass&amp;gt;&lt;br /&gt;
       &amp;amp;lt;sub&amp;gt;'''''sub''''''&amp;amp;lt;/sub&amp;gt;&lt;br /&gt;
       &amp;amp;lt;super&amp;gt;'''''super''''''&amp;amp;lt;/super&amp;gt;&lt;br /&gt;
     &amp;amp;lt;/Subclass&amp;gt;&lt;br /&gt;
   &amp;amp;lt;/object&amp;gt;&lt;br /&gt;
   &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     '''''key&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''''&lt;br /&gt;
     '''''filler&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''''&lt;br /&gt;
   &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
    . . .&lt;br /&gt;
   &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     '''''key&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''''&lt;br /&gt;
     '''''filler&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''''&lt;br /&gt;
   &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Frame&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 '''''inst''''' # '''''class'''''&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Member&amp;gt;&lt;br /&gt;
   &amp;amp;lt;instance&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''inst''''')&amp;amp;lt;/instance&amp;gt;&lt;br /&gt;
   &amp;amp;lt;class&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''class''''')&amp;amp;lt;/class&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Member&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 '''''sub''''' ## '''''super'''''&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Subclass&amp;gt;&lt;br /&gt;
   &amp;amp;lt;sub&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''sub''''')&amp;amp;lt;/sub&amp;gt;&lt;br /&gt;
   &amp;amp;lt;super&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''super''''')&amp;amp;lt;/super&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Subclass&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 '''''left''''' = '''''right'''''&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Equal&amp;gt;&lt;br /&gt;
   &amp;amp;lt;left&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''left''''')&amp;amp;lt;/left&amp;gt;&lt;br /&gt;
   &amp;amp;lt;right&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''right''''')&amp;amp;lt;/right&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Equal&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;quot;'''''unicodestring'''''&amp;quot;^^'''''symspace'''''&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Const type=&amp;quot;'''''symspace'''''&amp;quot;&amp;gt;'''''unicodestring'''''&amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 ?'''''name&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Var&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''name&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/Var&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 '''''name&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
  &amp;lt;i&amp;gt;remove-outer-quotes&amp;lt;/i&amp;gt;('''''name&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-translation-rule-language&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== Mapping of the Rule Language ====&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; mapping from the presentation syntax to the XML syntax of the RIF-BLD Rule Language is specified by the table below. It extends the translation table of Section [[#sec-translation-condition-language|Mapping of the Condition Language]]. While the &amp;lt;tt&amp;gt;Import&amp;lt;/tt&amp;gt; directive is handled by the presentation-to-XML syntax mapping, the &amp;lt;tt&amp;gt;Prefix&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;Base&amp;lt;/tt&amp;gt; directives are not. Instead, these directives should be handled by expanding the associated shortcuts (compact URIs).&lt;br /&gt;
Namely, a prefix name declared in a &amp;lt;tt&amp;gt;Prefix&amp;lt;/tt&amp;gt; directive is expanded into the associated IRI, while relative IRIs are completed using the IRI declared in the &amp;lt;tt&amp;gt;Base&amp;lt;/tt&amp;gt; directive. The mapping &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; applies only to such expanded documents.&lt;br /&gt;
RIF-BLD also allows other treatments of &amp;lt;tt&amp;gt;Prefix&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;Base&amp;lt;/tt&amp;gt; provided that they produce equivalent XML documents. One such treatment is employed in the examples in this document, especially Example 8. It replaces prefix names with definitions of XML entities as follows.&lt;br /&gt;
Each &amp;lt;tt&amp;gt;Prefix&amp;lt;/tt&amp;gt; declaration becomes an &amp;lt;tt&amp;gt;ENTITY&amp;lt;/tt&amp;gt; declaration &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xml-1-point-0|XML1.0]]] within a &amp;lt;tt&amp;gt;DOCTYPE&amp;lt;/tt&amp;gt; DTD attached to the RIF-BLD &amp;lt;tt&amp;gt;Document&amp;lt;/tt&amp;gt;. The &amp;lt;tt&amp;gt;Base&amp;lt;/tt&amp;gt; directive is mapped to the &amp;lt;tt&amp;gt;xml:base&amp;lt;/tt&amp;gt; attribute &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-xml-base|XML-Base]]] in the XML &amp;lt;tt&amp;gt;Document&amp;lt;/tt&amp;gt; tag.&lt;br /&gt;
Compact URIs of the form &amp;lt;tt&amp;gt;prefix:suffix&amp;lt;/tt&amp;gt; are then mapped to &amp;lt;tt&amp;gt;&amp;amp;prefix;suffix&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;syntax-translation-table&amp;quot;&lt;br /&gt;
! rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; | Presentation Syntax&lt;br /&gt;
! rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; | XML Syntax&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 Document(&lt;br /&gt;
   Import('''''loc&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''' '''''prfl&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;?''''')&lt;br /&gt;
    . . .&lt;br /&gt;
   Import('''''loc&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''' '''''prfl&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;?''''')&lt;br /&gt;
   '''''group?'''''&lt;br /&gt;
         )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Document&amp;gt;&lt;br /&gt;
   &amp;amp;lt;directive&amp;gt;&lt;br /&gt;
     &amp;amp;lt;Import&amp;gt;&lt;br /&gt;
       &amp;amp;lt;location&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''loc&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/location&amp;gt;&lt;br /&gt;
       &amp;amp;lt;profile&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''prfl&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/profile&amp;gt;'''''?'''''&lt;br /&gt;
     &amp;amp;lt;/Import&amp;gt;&lt;br /&gt;
   &amp;amp;lt;/directive&amp;gt;&lt;br /&gt;
    . . .&lt;br /&gt;
   &amp;amp;lt;directive&amp;gt;&lt;br /&gt;
     &amp;amp;lt;Import&amp;gt;&lt;br /&gt;
       &amp;amp;lt;location&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''loc&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/location&amp;gt;&lt;br /&gt;
       &amp;amp;lt;profile&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''prfl&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/profile&amp;gt;'''''?'''''&lt;br /&gt;
     &amp;amp;lt;/Import&amp;gt;&lt;br /&gt;
   &amp;amp;lt;/directive&amp;gt;&lt;br /&gt;
   &amp;amp;lt;payload&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''group''''')&amp;amp;lt;/payload&amp;gt;'''''?'''''&lt;br /&gt;
 &amp;amp;lt;/Document&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 Group(&lt;br /&gt;
   '''''clause&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
    . . .&lt;br /&gt;
   '''''clause&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
      )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Group&amp;gt;&lt;br /&gt;
   &amp;amp;lt;sentence&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''clause&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/sentence&amp;gt;&lt;br /&gt;
    . . .&lt;br /&gt;
   &amp;amp;lt;sentence&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''clause&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/sentence&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Group&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 Forall&lt;br /&gt;
   '''''variable&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
    . . .&lt;br /&gt;
   '''''variable&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''' (&lt;br /&gt;
              '''''rule'''''&lt;br /&gt;
             )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Forall&amp;gt;&lt;br /&gt;
   &amp;amp;lt;declare&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''variable&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/declare&amp;gt;&lt;br /&gt;
    . . .&lt;br /&gt;
   &amp;amp;lt;declare&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''variable&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/declare&amp;gt;&lt;br /&gt;
   &amp;amp;lt;formula&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''rule''''')&amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Forall&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 '''''conclusion''''' :- '''''condition'''''&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Implies&amp;gt;&lt;br /&gt;
   &amp;amp;lt;if&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''condition''''')&amp;amp;lt;/if&amp;gt;&lt;br /&gt;
   &amp;amp;lt;then&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''conclusion''''')&amp;amp;lt;/then&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Implies&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Mapping of Annotations ====&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt; mapping from RIF-BLD annotations in the presentation syntax to the XML syntax is specified by the table below.&lt;br /&gt;
It extends the translation tables of Sections [[#sec-translation-condition-language|Mapping of the Condition Language]] and [[#sec-translation-rule-language|Mapping of the Rule Language]].&lt;br /&gt;
The metavariable '''''Typetag''''' in the presentation and XML syntaxes stands for any of the class names &amp;lt;tt&amp;gt;And&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;Or&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;External&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;Document&amp;lt;/tt&amp;gt;, or &amp;lt;tt&amp;gt;Group&amp;lt;/tt&amp;gt;, and '''''Quantifier''''' for &amp;lt;tt&amp;gt;Exists&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;Forall&amp;lt;/tt&amp;gt;. The dollar sign, '''$''', stands for any of the binary infix operator names &amp;lt;tt&amp;gt;#&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;##&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;=&amp;lt;/tt&amp;gt;, or &amp;lt;tt&amp;gt;:-&amp;lt;/tt&amp;gt;, while '''''Binop''''' stands for their respective class names &amp;lt;tt&amp;gt;Member&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;Subclass&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;Equal&amp;lt;/tt&amp;gt;, or &amp;lt;tt&amp;gt;Implies&amp;lt;/tt&amp;gt;.&lt;br /&gt;
Again, each metavariable for an (unnamed) positional '''''argument&amp;lt;sub&amp;gt;i&amp;lt;/sub&amp;gt;''''' is assumed to be instantiated to values unequal to the instantiations of named arguments '''''name&amp;lt;sub&amp;gt;j&amp;lt;/sub&amp;gt;''''' &amp;lt;tt&amp;gt;-&amp;gt;&amp;lt;/tt&amp;gt; '''''filler&amp;lt;sub&amp;gt;j&amp;lt;/sub&amp;gt;'''''.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;syntax-translation-table&amp;quot;&lt;br /&gt;
! rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; | Presentation Syntax&lt;br /&gt;
! rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; | XML Syntax&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 (* '''''iriconst?''''' '''''frameconj?''''' *)&lt;br /&gt;
 '''''Typetag''''' ( '''''e&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''' . . . '''''e&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''' )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;'''''Typetag'''''&amp;gt;&lt;br /&gt;
   &amp;amp;lt;id&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''iriconst''''')&amp;amp;lt;/id&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;meta&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''frameconj''''')&amp;amp;lt;/meta&amp;gt;'''''?'''''&lt;br /&gt;
   '''''e&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''' . . . '''''e&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''''&lt;br /&gt;
 &amp;amp;lt;/'''''Typetag'''''&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
 &amp;lt;tt&amp;gt;where '''''e&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''', . . ., '''''e&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;'''''' are defined by the equation&amp;lt;/tt&amp;gt;&lt;br /&gt;
 &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;&amp;lt;tt&amp;gt;('''''Typetag'''''('''''e&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''' . . . '''''e&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')) = &amp;amp;lt;'''''Typetag'''''&amp;gt;'''''e&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''' . . . '''''e&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''''&amp;amp;lt;/'''''Typetag'''''&amp;gt;&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 (* '''''iriconst?''''' '''''frameconj?''''' *)&lt;br /&gt;
 '''''Quantifier''''' '''''variable&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''' . . . '''''variable&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''' ( '''''formula''''' )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;'''''Quantifier'''''&amp;gt;&lt;br /&gt;
   &amp;amp;lt;id&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''iriconst''''')&amp;amp;lt;/id&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;meta&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''frameconj''''')&amp;amp;lt;/meta&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;declare&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''variable&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/declare&amp;gt;&lt;br /&gt;
   . . .&lt;br /&gt;
   &amp;amp;lt;declare&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''variable&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/declare&amp;gt;&lt;br /&gt;
   &amp;amp;lt;formula&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''formula''''')&amp;amp;lt;/formula&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/'''''Quantifier'''''&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 (* '''''iriconst?''''' '''''frameconj?''''' *)&lt;br /&gt;
 '''''pred''''' (&lt;br /&gt;
   '''''argument&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   . . .&lt;br /&gt;
   '''''argument&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
      )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Atom&amp;gt;&lt;br /&gt;
   &amp;amp;lt;id&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''iriconst''''')&amp;amp;lt;/id&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;meta&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''frameconj''''')&amp;amp;lt;/meta&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;op&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''pred''''')&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
   &amp;amp;lt;args ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''argument&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
     . . .&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''argument&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/args&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Atom&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 (* '''''iriconst?''''' '''''frameconj?''''' *)&lt;br /&gt;
 '''''func''''' (&lt;br /&gt;
   '''''argument&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   . . .&lt;br /&gt;
   '''''argument&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
      )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Expr&amp;gt;&lt;br /&gt;
   &amp;amp;lt;id&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''iriconst''''')&amp;amp;lt;/id&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;meta&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''frameconj''''')&amp;amp;lt;/meta&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;op&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''func''''')&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
   &amp;amp;lt;args ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''argument&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
     . . .&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''argument&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/args&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Expr&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 (* '''''iriconst?''''' '''''frameconj?''''' *)&lt;br /&gt;
 List (&lt;br /&gt;
   '''''element&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   . . .&lt;br /&gt;
   '''''element&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
     )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;List&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;id&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''iriconst''''')&amp;amp;lt;/id&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;meta&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''frameconj''''')&amp;amp;lt;/meta&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;items ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''element&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
     . . .&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''element&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/items&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/List&amp;amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 (* '''''iriconst?''''' '''''frameconj?''''' *)&lt;br /&gt;
 List (&lt;br /&gt;
   '''''element&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   . . .&lt;br /&gt;
   '''''element&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   &amp;lt;nowiki&amp;gt;|&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
   '''''remainder'''''&lt;br /&gt;
     )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;List&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;id&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''iriconst''''')&amp;amp;lt;/id&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;meta&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''frameconj''''')&amp;amp;lt;/meta&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;items ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''element&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
     . . .&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''element&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/items&amp;gt;&lt;br /&gt;
   &amp;amp;lt;rest&amp;amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''remainder''''')&amp;amp;lt;/rest&amp;amp;gt;&lt;br /&gt;
 &amp;amp;lt;/List&amp;amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 (* '''''iriconst?''''' '''''frameconj?''''' *)&lt;br /&gt;
 '''''pred''''' (&lt;br /&gt;
   '''''name&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''' -&amp;gt; '''''filler&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   . . .&lt;br /&gt;
   '''''name&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''' -&amp;gt; '''''filler&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
      )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Atom&amp;gt;&lt;br /&gt;
   &amp;amp;lt;id&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''iriconst''''')&amp;amp;lt;/id&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;meta&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''frameconj''''')&amp;amp;lt;/meta&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;op&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''pred''''')&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
   &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;amp;lt;Name&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''name&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/Name&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''filler&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
    . . .&lt;br /&gt;
   &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;amp;lt;Name&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''name&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/Name&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''filler&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Atom&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 (* '''''iriconst?''''' '''''frameconj?''''' *)&lt;br /&gt;
 '''''func''''' (&lt;br /&gt;
   '''''name&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''' -&amp;gt; '''''filler&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   . . .&lt;br /&gt;
   '''''name&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''' -&amp;gt; '''''filler&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
      )&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Expr&amp;gt;&lt;br /&gt;
   &amp;amp;lt;id&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''iriconst''''')&amp;amp;lt;/id&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;meta&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''frameconj''''')&amp;amp;lt;/meta&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;op&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''func''''')&amp;amp;lt;/op&amp;gt;&lt;br /&gt;
   &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;amp;lt;Name&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''name&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/Name&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''filler&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
    . . .&lt;br /&gt;
   &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;amp;lt;Name&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''name&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&amp;amp;lt;/Name&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''filler&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Expr&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 (* '''''iriconst?''''' '''''frameconj?''''' *)&lt;br /&gt;
 '''''inst''''' [&lt;br /&gt;
   '''''key&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''' -&amp;gt; '''''filler&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
   . . .&lt;br /&gt;
   '''''key&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''' -&amp;gt; '''''filler&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
      ]&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Frame&amp;gt;&lt;br /&gt;
   &amp;amp;lt;id&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''iriconst''''')&amp;amp;lt;/id&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;meta&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''frameconj''''')&amp;amp;lt;/meta&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;object&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''inst''''')&amp;amp;lt;/object&amp;gt;&lt;br /&gt;
   &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''key&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''filler&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
    . . .&lt;br /&gt;
   &amp;amp;lt;slot ordered=&amp;quot;yes&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''key&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''filler&amp;lt;sub&amp;gt;n&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
   &amp;amp;lt;/slot&amp;gt;&lt;br /&gt;
 &amp;amp;lt;/Frame&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 (* '''''iriconst?''''' '''''frameconj?''''' *)&lt;br /&gt;
 '''''e&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''' '''$''' '''''e&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;'''''Binop'''''&amp;gt;&lt;br /&gt;
   &amp;amp;lt;id&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''iriconst''''')&amp;amp;lt;/id&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;meta&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''frameconj''''')&amp;amp;lt;/meta&amp;gt;'''''?'''''&lt;br /&gt;
   '''''e&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''' '''''e&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;''''''&lt;br /&gt;
 &amp;amp;lt;/'''''Binop'''''&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
 &amp;lt;tt&amp;gt;where '''''Binop''''', '''''e&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''', '''''e&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;'''''' are defined by the equation&amp;lt;/tt&amp;gt;&lt;br /&gt;
 &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;&amp;lt;tt&amp;gt;('''''e&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''' '''$''' '''''e&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;''''') = &amp;amp;lt;'''''Binop'''''&amp;gt;'''''e&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''' '''''e&amp;lt;sub&amp;gt;2&amp;lt;/sub&amp;gt;''''''&amp;amp;lt;/'''''Binop'''''&amp;gt;&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 (* '''''iriconst?''''' '''''frameconj?''''' *)&lt;br /&gt;
 '''''unicodestring'''''^^'''''symspace'''''&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Const type=&amp;quot;'''''symspace'''''&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;amp;lt;id&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''iriconst''''')&amp;amp;lt;/id&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;meta&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''frameconj''''')&amp;amp;lt;/meta&amp;gt;'''''?'''''&lt;br /&gt;
   '''''unicodestring'''''&lt;br /&gt;
 &amp;amp;lt;/Const&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 (* '''''iriconst?''''' '''''frameconj?''''' *)&lt;br /&gt;
 ?'''''name&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;'''''&lt;br /&gt;
| rowspan=&amp;quot;1&amp;quot; colspan=&amp;quot;1&amp;quot; |&lt;br /&gt;
 &amp;amp;lt;Var&amp;gt;&lt;br /&gt;
   &amp;amp;lt;id&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''iriconst''''')&amp;amp;lt;/id&amp;gt;'''''?'''''&lt;br /&gt;
   &amp;amp;lt;meta&amp;gt;&amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''frameconj''''')&amp;amp;lt;/meta&amp;gt;'''''?'''''&lt;br /&gt;
     &amp;lt;tt&amp;gt;&amp;amp;chi;&amp;lt;sub&amp;gt;bld&amp;lt;/sub&amp;gt;&amp;lt;/tt&amp;gt;('''''name&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;''''')&lt;br /&gt;
 &amp;amp;lt;/Var&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-conformance&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Conformance Clauses ==&lt;br /&gt;
&lt;br /&gt;
RIF-BLD does not require or expect conformant systems to implement the RIF-BLD presentation syntax. Instead, conformance is described in terms of semantics-preserving transformations between the native syntax of a compliant system and the XML syntax of RIF-BLD.&lt;br /&gt;
&lt;br /&gt;
Let &amp;amp;Tau; be a set of datatypes and symbol spaces that includes the datatypes specified in&lt;br /&gt;
&amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]], and the symbol spaces &amp;lt;tt&amp;gt;rif:iri&amp;lt;/tt&amp;gt;, and &amp;lt;tt&amp;gt;rif:local&amp;lt;/tt&amp;gt;. Suppose &amp;amp;Epsilon; is a [[DTB#def-external-schema-set|coherent set of external schemas]] that includes the built-ins listed in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-dtb|RIF-DTB]]]. We say that a formula &amp;amp;phi; is a ''BLD''&amp;lt;sub&amp;gt;&amp;amp;Tau;,&amp;amp;Epsilon;&amp;lt;/sub&amp;gt; formula iff &lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    it is a well-formed BLD formula,&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    all datatypes and symbol spaces used in &amp;amp;phi; are in &amp;amp;Tau;, and&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
    all externally defined terms used in &amp;amp;phi; are instantiations of external schemas from &amp;amp;Epsilon;.&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;def-conformance&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
A RIF processor is a '''''conformant''''' ''BLD''&amp;lt;sub&amp;gt;&amp;amp;Tau;,&amp;amp;Epsilon;&amp;lt;/sub&amp;gt; '''''consumer''''' iff it implements a &amp;lt;span id=&amp;quot;def-sem-preserving-map-to&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;''semantics-preserving mapping''&amp;lt;/span&amp;gt;, &amp;amp;mu;, from the set of all ''BLD''&amp;lt;sub&amp;gt;&amp;amp;Tau;,&amp;amp;Epsilon;&amp;lt;/sub&amp;gt; formulas to the language ''L'' of the processor (&amp;amp;mu; does not need to be an &amp;quot;onto&amp;quot; mapping).&lt;br /&gt;
&lt;br /&gt;
Formally, this means that for any pair &amp;amp;phi;, &amp;amp;psi; of ''BLD''&amp;lt;sub&amp;gt;&amp;amp;Tau;,&amp;amp;Epsilon;&amp;lt;/sub&amp;gt; formulas for which &amp;amp;phi; |=&amp;lt;sub&amp;gt;&amp;lt;tt&amp;gt;''BLD''&amp;lt;/tt&amp;gt;&amp;lt;/sub&amp;gt; &amp;amp;psi; is defined, &amp;amp;phi; |=&amp;lt;sub&amp;gt;&amp;lt;tt&amp;gt;''BLD''&amp;lt;/tt&amp;gt;&amp;lt;/sub&amp;gt; &amp;amp;psi; iff  &amp;amp;mu;(&amp;amp;phi;) |=&amp;lt;sub&amp;gt;&amp;lt;tt&amp;gt;''L''&amp;lt;/tt&amp;gt;&amp;lt;/sub&amp;gt; &amp;amp;mu;(&amp;amp;psi;). Here |=&amp;lt;sub&amp;gt;&amp;lt;tt&amp;gt;''BLD''&amp;lt;/tt&amp;gt;&amp;lt;/sub&amp;gt; denotes the logical entailment in RIF-BLD and |=&amp;lt;sub&amp;gt;&amp;lt;tt&amp;gt;''L''&amp;lt;/tt&amp;gt;&amp;lt;/sub&amp;gt; is the logical entailment in the language ''L'' of the RIF processor.&lt;br /&gt;
&lt;br /&gt;
A RIF processor is a '''''conformant''''' ''BLD''&amp;lt;sub&amp;gt;&amp;amp;Tau;,&amp;amp;Epsilon;&amp;lt;/sub&amp;gt; '''''producer''''' iff it implements a &amp;lt;span id=&amp;quot;def-sem-preserving-map-from&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;''semantics-preserving mapping''&amp;lt;/span&amp;gt;, &amp;amp;nu;, from the language ''L'' of the processor to the set of all ''BLD''&amp;lt;sub&amp;gt;&amp;amp;Tau;,&amp;amp;Epsilon;&amp;lt;/sub&amp;gt; formulas (&amp;amp;nu; does not need to be an &amp;quot;onto&amp;quot; mapping).&lt;br /&gt;
&lt;br /&gt;
Formally, this means that for any pair &amp;amp;phi;, &amp;amp;psi; of formulas in ''L'' for which &amp;amp;phi; |=&amp;lt;sub&amp;gt;&amp;lt;tt&amp;gt;''L''&amp;lt;/tt&amp;gt;&amp;lt;/sub&amp;gt; &amp;amp;psi; is defined, &amp;amp;phi; |=&amp;lt;sub&amp;gt;&amp;lt;tt&amp;gt;''L''&amp;lt;/tt&amp;gt;&amp;lt;/sub&amp;gt; &amp;amp;psi; iff  &amp;amp;nu;(&amp;amp;phi;) |=&amp;lt;sub&amp;gt;&amp;lt;tt&amp;gt;''BLD''&amp;lt;/tt&amp;gt;&amp;lt;/sub&amp;gt; &amp;amp;nu;(&amp;amp;psi;).&lt;br /&gt;
&lt;br /&gt;
An '''''admissible document''''' is one which conforms to all the syntactic constraints of RIF-BLD, including ones that cannot be checked by an XML Schema validator (cf. Definition [[#def-bld-admissible-xml|Admissible BLD document in XML syntax]]).&lt;br /&gt;
&lt;br /&gt;
The above definitions are specializations to BLD of the general conformance clauses defined in the RIF framework for logic dialects &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-fld|RIF-FLD]]]. The following clauses are further restrictions that are specific to RIF-BLD.&lt;br /&gt;
&lt;br /&gt;
'''RIF-BLD specific clauses'''&lt;br /&gt;
&lt;br /&gt;
* Conformant BLD producers and consumers are required to support only the entailments of the form &amp;amp;phi; |=&amp;lt;sub&amp;gt;&amp;lt;tt&amp;gt;''BLD''&amp;lt;/tt&amp;gt;&amp;lt;/sub&amp;gt; &amp;amp;psi;, where &amp;amp;psi; is a &amp;lt;span id=&amp;quot;ptr-closed-rif-condform&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;''closed RIF condition formula''&amp;lt;/span&amp;gt;, i.e., a RIF condition in which every variable, &amp;lt;tt&amp;gt;?V&amp;lt;/tt&amp;gt;, is in the scope of a quantifier of the form &amp;lt;tt&amp;gt;Exists ?V&amp;lt;/tt&amp;gt;.  In addition, conformant BLD producers and consumers ''should'' preserve all annotations where possible.&lt;br /&gt;
&lt;br /&gt;
* A '''''conformant BLD consumer''''' must reject any document containing features it does not support.&lt;br /&gt;
&lt;br /&gt;
* A '''''conformant BLD producer''''' is a conformant BLD&amp;lt;sub&amp;gt;&amp;amp;Tau;,&amp;amp;Epsilon;&amp;lt;/sub&amp;gt; producer, which produces documents that include only the datatypes and externals that are required by BLD.&lt;br /&gt;
&lt;br /&gt;
RIF-BLD supports a wide variety of syntactic forms for terms and formulas, which creates infrastructure for exchanging syntactically diverse rule languages. It is important to realize, however, that the above conformance statements make it possible for systems that do not support some of the syntax directly to still support it through syntactic transformations. For instance, disjunctions in rule premises can be eliminated through a standard transformation, such as replacing &amp;lt;tt&amp;gt;p :- Or(q r)&amp;lt;/tt&amp;gt; with a pair of rules &amp;lt;tt&amp;gt;p :- q, &amp;amp;nbsp; p :- r&amp;lt;/tt&amp;gt;. Terms with named arguments can be reduced to positional terms by ordering the arguments by their names and incorporating the ordered argument names into the predicate name. For instance, &amp;lt;tt&amp;gt;p(bb-&amp;gt;1 aa-&amp;gt;2)&amp;lt;/tt&amp;gt; can be represented as &amp;lt;tt&amp;gt;p_aa_bb(2 1)&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span id=&amp;quot;sec-bld-fld-spec&amp;quot; class=&amp;quot;anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== RIF-BLD as a Specialization of the RIF Framework for Logic Dialects &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-fld|RIF-FLD]]] ==&lt;br /&gt;
&lt;br /&gt;
This normative section describes RIF-BLD by specializing RIF-FLD. The reader is&lt;br /&gt;
assumed to be familiar with RIF-FLD as described in RIF framework for&lt;br /&gt;
logic dialects &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-fld|RIF-FLD]]]. The reader who is not interested in how RIF-BLD is&lt;br /&gt;
derived from the framework can skip this section.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==== The Presentation Syntax of RIF-BLD as a Specialization of RIF-FLD ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This section defines the precise relationship between the presentation syntax of RIF-BLD and the syntactic framework of RIF-FLD.&lt;br /&gt;
&lt;br /&gt;
The presentation syntax of the RIF Basic Logic Dialect is defined by specialization from the presentation syntax of the [[FLD#sec-syntactic-framework|RIF Syntactic Framework for Logic Dialects]] described in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-fld|RIF-FLD]]]. Section [[FLD#sec-dialect-syntax|Syntax of a RIF Dialect as a Specialization of the RIF Framework]] in &amp;lt;nowiki&amp;gt;[&amp;lt;/nowiki&amp;gt;[[#ref-rif-fld|RIF-FLD]]] lists the parameters of the syntactic framework in mathematical English, which we will now specialize for RIF-BLD. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt;&lt;br /&gt;
      ''Extension points''.&lt;br /&gt;
      &amp;lt;p&amp;gt;&lt;br /&gt;
          All extension points of RIF-FLD are removed (specialized by replacing them with zero objects).&lt;br /&gt;
      &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt; ''Alphabet''. &lt;br /&gt;
    &amp;lt;p&amp;gt;&lt;br /&gt;
      The alphabet of the RIF-BLD presentation syntax is the alphabet of RIF-FLD with the symbols &amp;lt;tt&amp;gt;Dialect&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;Neg&amp;lt;/tt&amp;gt;, and &amp;lt;tt&amp;gt;Naf&amp;lt;/tt&amp;gt; excluded.&lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
  &amp;lt;/li&amp;gt;&lt;br /&gt;
  &amp;lt;li&amp;gt; ''Assignment of signatures to each constant and variable symbol''.&lt;br /&gt;
    &amp;lt;p&amp;gt;&lt;br /&gt;
      The signature set of RIF-BLD contains the following signatures:&lt;br /&gt;
    &amp;lt;/p&amp;gt;&lt;br /&gt;
    &amp;lt;ol style=&amp;quot;list-style-type:lower-alpha&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Basic&lt;br /&gt;
	&amp;lt;ul&amp;gt;&lt;br /&gt;
	  &amp;lt;li&amp;gt;&amp;lt;tt&amp;gt;individual{&amp;amp;nbsp;}&amp;lt;/tt&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
	  &amp;lt;li&amp;gt;&amp;lt;tt&amp;gt;atomic{&amp;amp;nbsp;}&amp;lt;/tt&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
	&amp;lt;/ul&amp;gt;&lt;br /&gt;
	&amp;lt;p&amp;gt;&lt;br /&gt;
	  The signature &amp;lt;tt&amp;gt;individual{&amp;amp;nbsp;}&amp;lt;/tt&amp;gt; represents the context in which individual objects (but not atomic formulas) can appear.&lt;br /&gt;
	  &amp;lt;br/&amp;gt;&lt;br /&gt;
	  The signature &amp;lt;tt&amp;gt;atomic{&amp;amp;nbsp;}&amp;lt;/tt&amp;gt; represents the context where atomic formulas can occur. &lt;br /&gt;
	&amp;lt;/p&amp;gt;&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;      &lt;br /&gt;
	 Signatures for lists&lt;br /&gt;
	 &amp;lt;ul&amp;gt;	 &lt;br /&gt;
	   &amp;lt;li&amp;gt;&lt;br /&gt;
	      The signature &amp;lt;tt&amp;gt;list&amp;lt;/tt&amp;gt; for closed lists. It has the following arrow expressions: &amp;lt;tt&amp;gt;() &amp;amp;rArr; individual&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;(individual) &amp;amp;rArr; individual&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;(individual individual) &amp;amp;rArr; individual&amp;lt;/tt&amp;gt;, ...&lt;br /&gt;
	   &amp;lt;/li&amp;gt;&lt;br /&gt;
	   &amp;lt;li&amp;gt;	   &lt;br /&gt;
	      The signature &amp;lt;tt&amp;gt;openlist&amp;lt;/tt&amp;gt; for open lists (that have tails). It has the following arrow expressions: &amp;lt;tt&amp;gt;(individual individual) &amp;amp;rArr; individual&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;(individual individual individual) &amp;amp;rArr; individual&amp;lt;/tt&amp;gt;, ... &lt;br /&gt;
	   &amp;lt;/li&amp;gt;&lt;br /&gt;
	 &amp;lt;/ul&amp;gt;&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Signatures for functions, predicates, and external functions and predicates&lt;br /&gt;
	&amp;lt;ul&amp;gt;&lt;br /&gt;
	  &amp;lt;li&amp;gt;&lt;br /&gt;
	    Function signature &amp;lt;tt&amp;gt;f&amp;lt;/tt&amp;gt;. This signature has the arrow expressions for positional functions: &amp;lt;tt&amp;gt;() &amp;amp;rArr; individual&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;(individual) &amp;amp;rArr; individual&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;(individual individual) &amp;amp;rArr; individual&amp;lt;/tt&amp;gt;, ..., plus the arrow expressions for functions with named arguments: &amp;lt;tt&amp;gt;(s1-&amp;gt;individual ... sk-&amp;gt;individual) &amp;amp;rArr; individual}&amp;lt;/tt&amp;gt;, for all k&amp;amp;gt;0 and all &amp;lt;tt&amp;gt;s1, ..., sk&amp;lt;/tt&amp;gt; &amp;amp;isin; &amp;lt;tt&amp;gt;ArgNames&amp;lt;/tt&amp;gt;. &lt;br /&gt;
	  &amp;lt;/li&amp;gt;&lt;br /&gt;
	  &amp;lt;li&amp;gt;&lt;br /&gt;
	    Predicate signature &amp;lt;tt&amp;gt;p&amp;lt;/tt&amp;gt;. This signature has the arrow expressions for positional predicates: &amp;lt;tt&amp;gt;() &amp;amp;rArr; atomic&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;(individual) &amp;amp;rArr; atomic&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;(individual individual) &amp;amp;rArr; atomic&amp;lt;/tt&amp;gt;, ..., plus the arrow expressions for predicates with named arguments: &amp;lt;tt&amp;gt;(s1-&amp;gt;individual ... sk-&amp;gt;individual) &amp;amp;rArr; atomic}&amp;lt;/tt&amp;gt;, for all k&amp;amp;gt;0 and all &amp;lt;tt&amp;gt;s1, ..., sk&amp;lt;/tt&amp;gt; &amp;amp;isin; &amp;lt;tt&amp;gt;ArgNames&amp;lt;/tt&amp;gt;.  &lt;br /&gt;
	  &amp;lt;/li&amp;gt;&lt;br /&gt;
	&amp;lt;/ul&amp;gt;&lt;br /&gt;
	&amp;lt;p&amp;gt;&lt;br /&gt;
	  In the RIF-BLD specialization of RIF-FLD, the argument names &amp;lt;tt&amp;gt;s1&amp;lt;/tt&amp;gt;, ..., &amp;lt;tt&amp;gt;sk&amp;lt;/tt&amp;gt; must be pairwise distinct.&lt;br /&gt;
	&amp;lt;/p&amp;gt;&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;Every symbol in &amp;lt;tt&amp;gt;Const&amp;lt;/tt&amp;gt; has exactly one signature: &amp;lt;tt&amp;gt;individual&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;f&amp;lt;/tt&amp;gt;, or &amp;lt;tt&amp;gt;p&amp;lt;/tt&amp;gt;.&lt;br /&gt;
	&amp;lt;p&amp;gt;&lt;br /&gt;
	  A constant cannot have the signature &amp;lt;tt&amp;gt;atomic&amp;lt;/tt&amp;gt; -- only complex terms can have such signatures. Thus, by itself a symbol, &amp;lt;tt&amp;gt;s&amp;lt;/tt&amp;gt;,  cannot be a proposition in RIF-BLD, but a term of the form &amp;lt;tt&amp;gt;s()&amp;lt;/tt&amp;gt; can.&lt;br /&gt;
	&amp;lt;/p&amp;gt;&lt;br /&gt;
	&amp;lt;p&amp;gt;&lt;br /&gt;
	  According to the above, each constant symbol in RIF-BLD can be either an individual, a function, or a predicate. However, the same function or predicate symbol (normal or external) can occur with different numbers of arguments in different places. Also, the [[#cond-specialization-external|additional restrictions spelled out below]] ensure that the same symbol cannot represent both an externally defined predicate or function and a regular predicate or function.&lt;br /&gt;
	&amp;lt;/p&amp;gt;&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;The constant symbols that correspond to RIF datatypes (XML Schema datatypes, &amp;lt;tt&amp;gt;[[DTB#rif-xmlliteral-space|rdf:XMLLiteral]]&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;[[DTB#rdf-PlainLiteral-space|rdf:PlainLiteral]]&amp;lt;/tt&amp;gt;, etc.) all have the signature &amp;lt;tt&amp;gt;individual&amp;lt;/tt&amp;gt; in RIF-BLD.&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;The symbols of type &amp;lt;tt&amp;gt;[[DTB#rif-iri-space|rif:iri]]&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;[[DTB#rif-local-space|rif:local]]&amp;lt;/tt&amp;gt; can have the following signatures in RIF-BLD: &amp;lt;tt&amp;gt;individual&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;f&amp;lt;/tt&amp;gt;, or &amp;lt;tt&amp;gt;p&amp;lt;/tt&amp;gt;.&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;All variables are associated with signature &amp;lt;tt&amp;gt;individual&amp;lt;/tt&amp;gt;, so they can range only over individuals.&lt;br /&gt;
      &amp;lt;/li&amp;gt;&lt;br /&gt;
      &amp;lt;li&amp;gt;The signature for equality is &amp;lt;tt&amp;gt;={(individual&amp;amp;nbsp;individual)&amp;lt;/tt&amp;gt; &amp