<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
    <title></title>
  </head>
  <body text="#000000" bgcolor="#ffffff">
    On 2/10/2011 8:07 AM, Wolfgang Laun wrote:
    <blockquote
      cite="mid:AANLkTi=7Zr+kD+4oej4gd1gBPh46q+k69wM6G2arMd2v@mail.gmail.com"
      type="cite"><br>
      <br>
      <div class="gmail_quote">On 9 February 2011 22:11, Edson Tirelli <span
          dir="ltr">&lt;<a moz-do-not-send="true"
            href="mailto:ed.tirelli@gmail.com">ed.tirelli@gmail.com</a>&gt;</span>
        wrote:<br>
        <blockquote class="gmail_quote" style="border-left: 1px solid
          rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left:
          1ex;">
          <div><br>
          </div>
          <div>&nbsp;&nbsp; Pierre,</div>
          <div><br>
          </div>
          <div>&nbsp;&nbsp; Good to see works like yours being done.&nbsp;</div>
          <div><br>
          </div>
          <div>&nbsp;&nbsp; Drools has an internal canonical model that we use to
            round trip rules between the syntaxes we support. The best
            way of supporting "RIF" in Drools is to simply add a parser
            that parses RIF and populates the canonical model. From that
            we have a DRL "dumper" that generates DRL, enabling the
            RIF-&gt;DRL translation. Also, if we create a RIF "dumper",
            one can then generate RIF rules from the canonical model,
            enabling DRL-&gt;RIF translation. That assumes that there is
            a 1-to-1 semantic mapping between RIF and DRL (I believe
            there is, but didn't checked).</div>
        </blockquote>
        <div><br>
          Do you mean that all of RIF can be expressed in DRL? Then I'd
          agree. But you can't express all of DRL in RIF.<br>
          -W<br>
          <br>
          &nbsp;</div>
      </div>
    </blockquote>
    A translator&nbsp; RIF-PRD2DRL should be&nbsp; "<span class="Apple-style-span"
      style="border-collapse: separate; color: rgb(0, 0, 0);
      font-family: 'Times New Roman'; font-style: normal; font-variant:
      normal; font-weight: normal; letter-spacing: normal; line-height:
      normal; orphans: 2; text-indent: 0px; text-transform: none;
      white-space: normal; widows: 2; word-spacing: 0px; font-size:
      medium;"><span class="Apple-style-span" style="font-family:
        sans-serif;">conformant RIF-PRD consumer</span></span>" as in
    the <a
href="http://www.w3.org/TR/2010/REC-rif-prd-20100622/#Semantics-preserving_transformations">recommendation</a>.
    A translator DRL2RIF-PRD should be <span class="Apple-style-span"
      style="border-collapse: separate; color: rgb(0, 0, 0);
      font-family: 'Times New Roman'; font-style: normal; font-variant:
      normal; font-weight: normal; letter-spacing: normal; line-height:
      normal; orphans: 2; text-indent: 0px; text-transform: none;
      white-space: normal; widows: 2; word-spacing: 0px; font-size:
      medium;"><span class="Apple-style-span" style="font-family:
        sans-serif;">a "conformant RIF-PRD producer".<br>
        <br>
        For example, a heuristic validation (test-based) may work in a
        "round-trip" i.e. take a Drools ruleset R, do </span></span>R_RIF=
    DRL2RIF-PRD(R)&nbsp; then R1= RIF-PRD2DRL(R_RIF) and compare answers by
    running Drools on R and R1<br>
    <br>
    <br>
    When Wolfgang said that not all Drools constructs can translate to
    RIF-PRD I assume he is thinking to some&nbsp; lets say "nonlogical" or
    "procedural" Drools constructs.<br>
    However, because RIF can encode any partial recursive function,&nbsp;
    DRL2RIF should be always possible i.e. when translating a ruleset
    from Drools, one may obtain not only PR rules but, in addition some
    RIF-BLD rules too. <br>
    Therefore&nbsp; I assume that there is&nbsp; very nice work to do.<br>
    <br>
    <span class="Apple-style-span" style="border-collapse: separate;
      color: rgb(0, 0, 0); font-family: 'Times New Roman'; font-style:
      normal; font-variant: normal; font-weight: normal; letter-spacing:
      normal; line-height: normal; orphans: 2; text-indent: 0px;
      text-transform: none; white-space: normal; widows: 2;
      word-spacing: 0px; font-size: medium;"><span
        class="Apple-style-span" style="font-family: sans-serif;">-.Adrian
        Giurca<br>
      </span></span>
    <blockquote
      cite="mid:AANLkTi=7Zr+kD+4oej4gd1gBPh46q+k69wM6G2arMd2v@mail.gmail.com"
      type="cite">
      <div class="gmail_quote">
        <blockquote class="gmail_quote" style="border-left: 1px solid
          rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left:
          1ex;">
          <div><br>
          </div>
          <div>&nbsp;&nbsp; Edson</div>
          <div><br>
          </div>
          <div>&nbsp;</div>
          <div class="gmail_quote">2011/2/9 <span dir="ltr">&lt;<a
                moz-do-not-send="true" href="mailto:pdl@agh.edu.pl"
                target="_blank">pdl@agh.edu.pl</a>&gt;</span>
            <div>
              <div class="h5">
                <br>
                <blockquote class="gmail_quote" style="border-left: 1px
                  solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex;
                  padding-left: 1ex;">
                  Mark, Andrew, Guys,<br>
                  <br>
                  Yes working with DRL may be better for Drools indeed.
                  But the only way I<br>
                  see this working is by implementing this directly in
                  the code of Drools.<br>
                  That's not practical for me, hence I "simply"
                  export/import the rules<br>
                  in/from XML. This way I can focus on the translation.<br>
                  <br>
                  If someone would give me pointers on an easy way to
                  work with DRL, I'd do<br>
                  that of course.<br>
                  <br>
                  I assume you already had discussions on XML (or
                  anything more structured<br>
                  and widely spread than DRL) as working format so I
                  won't be going there :)<br>
                  <br>
                  All the best,<br>
                  Pierre<br>
                  <br>
                  <br>
                  On 09/02/2011 16:46, Mark Proctor wrote:<br>
                  &gt; On 09/02/2011 08:40, pdl at <a
                    moz-do-not-send="true" href="http://agh.edu.pl"
                    target="_blank">agh.edu.pl</a> wrote:<br>
                  &gt;&gt; Hi all,<br>
                  &gt;&gt;<br>
                  &gt;&gt; I've been working on translators between
                  RIF-PRD, DroolsML and JessML.<br>
                  &gt;&gt; I've put the translators in the form of XSLT
                  stylesheets on the<br>
                  following<br>
                  &gt;&gt; web site along with samples of rules written
                  in the above languages. I<br>
                  &gt;&gt; would greatly appreciate
                  feedback/comments/tips/help on making these<br>
                  &gt;&gt; translators more reliable and accurate.<br>
                  &gt;&gt;<br>
                  &gt;&gt; Web site: yieldrif (dot) appspot (dot) com
                  &nbsp;(in case emails containing<br>
                  &gt;&gt; URLs are bounced off)<br>
                  &gt;&gt;<br>
                  &gt;&gt; Please note that this is free hosting and has
                  some limitations. Feel<br>
                  free<br>
                  &gt;&gt; to add/comment content on this web site or
                  drop me a line. What would<br>
                  be<br>
                  &gt;&gt; really helpful is a XML Schema for DroolsML
                  and also the rhs to be in<br>
                  XML<br>
                  &gt;&gt; as opposed to drools code.<br>
                  &gt; Is this converting to Drools DRL? or to our
                  deprecate, unmaintained, out<br>
                  &gt; of date and very old XML?<br>
                  Sorry someone just read that sentence back to me, and
                  it probably read<br>
                  very wrong.<br>
                  <br>
                  Let me start again. First up great work, it's good to
                  see any<br>
                  interchange work happening, it's not easy stuff. And I
                  can't wait for us<br>
                  to figure out how to get this working directly against
                  our more recent<br>
                  DRL :)<br>
                  <br>
                  Mark<br>
                  &gt; Mark<br>
                  &gt;&gt; I look forward to hearing from you,<br>
                  &gt;&gt; Pierre<br>
                  &gt;&gt;
                  _______________________________________________<br>
                  &gt;&gt; rules-dev mailing list<br>
                  &gt;&gt; rules-dev at <a moz-do-not-send="true"
                    href="http://lists.jboss.org" target="_blank">lists.jboss.org</a><br>
                  &gt;&gt; <a moz-do-not-send="true"
                    href="https://lists.jboss.org/mailman/listinfo/rules-dev"
                    target="_blank">https://lists.jboss.org/mailman/listinfo/rules-dev</a><br>
                  &gt;&gt;<br>
                  &gt;&gt;<br>
                  &gt;<br>
                  &gt; _______________________________________________<br>
                  &gt; rules-dev mailing list<br>
                  &gt; rules-dev at <a moz-do-not-send="true"
                    href="http://lists.jboss.org" target="_blank">lists.jboss.org</a><br>
                  &gt; <a moz-do-not-send="true"
                    href="https://lists.jboss.org/mailman/listinfo/rules-dev"
                    target="_blank">https://lists.jboss.org/mailman/listinfo/rules-dev</a><br>
                  &gt;<br>
                  &gt;<br>
                  <br>
                  _______________________________________________<br>
                  rules-dev mailing list<br>
                  <a moz-do-not-send="true"
                    href="mailto:rules-dev@lists.jboss.org"
                    target="_blank">rules-dev@lists.jboss.org</a><br>
                  <a moz-do-not-send="true"
                    href="https://lists.jboss.org/mailman/listinfo/rules-dev"
                    target="_blank">https://lists.jboss.org/mailman/listinfo/rules-dev</a><br>
                </blockquote>
              </div>
            </div>
          </div>
          <font color="#888888"><br>
            <br clear="all">
            <br>
            -- <br>
            &nbsp; Edson Tirelli<br>
            &nbsp; JBoss Drools Core Development<br>
            &nbsp; JBoss by Red Hat @ <a moz-do-not-send="true"
              href="http://www.jboss.com" target="_blank">www.jboss.com</a><br>
          </font><br>
          _______________________________________________<br>
          rules-dev mailing list<br>
          <a moz-do-not-send="true"
            href="mailto:rules-dev@lists.jboss.org">rules-dev@lists.jboss.org</a><br>
          <a moz-do-not-send="true"
            href="https://lists.jboss.org/mailman/listinfo/rules-dev"
            target="_blank">https://lists.jboss.org/mailman/listinfo/rules-dev</a><br>
          <br>
        </blockquote>
      </div>
      <br>
      <pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
rules-dev mailing list
<a class="moz-txt-link-abbreviated" href="mailto:rules-dev@lists.jboss.org">rules-dev@lists.jboss.org</a>
<a class="moz-txt-link-freetext" href="https://lists.jboss.org/mailman/listinfo/rules-dev">https://lists.jboss.org/mailman/listinfo/rules-dev</a>
</pre>
    </blockquote>
    <br>
  </body>
</html>