<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta />
    <article-meta>
      <title-group>
        <article-title>SBVR based Business Contract and Business Rule IDE</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Aqueo Kamada</string-name>
          <email>aqueo.kamada@cti.gov.br</email>
          <xref ref-type="aff" rid="aff0">0</xref>
          <xref ref-type="aff" rid="aff3">3</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Guido Governatori</string-name>
          <email>guido.governatori@nicta.com.au</email>
          <xref ref-type="aff" rid="aff1">1</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Shazia Sadiq</string-name>
          <email>shazia@itee.uq.edu.au</email>
          <xref ref-type="aff" rid="aff2">2</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>CTI</institution>
          ,
          <addr-line>Rod. Dom Pedro I, km 143.6, Campinas</addr-line>
          ,
          <country country="BR">Brazil</country>
        </aff>
        <aff id="aff1">
          <label>1</label>
          <institution>NICTA, Queensland Research Laboratory</institution>
          ,
          <addr-line>Brisbane</addr-line>
          ,
          <country country="AU">Australia</country>
        </aff>
        <aff id="aff2">
          <label>2</label>
          <institution>The University of Queensland</institution>
          ,
          <addr-line>ITEE, Brisbane</addr-line>
          ,
          <country country="AU">Australia</country>
        </aff>
        <aff id="aff3">
          <label>3</label>
          <institution>Unicamp, FT</institution>
          ,
          <addr-line>Limeira</addr-line>
          ,
          <country country="BR">Brazil</country>
        </aff>
      </contrib-group>
      <abstract>
        <p>We propose an IDE - Integrated Development Environment to model SBVR (Semantic of Business Vocabulary and Business Rule) compliant business rules [2] extracted from business contract of services and store them in an ontological structure of rules, facts and terms as defined in the SBVR metamodel. Business rules are based on principles of deontic logic for treating expressions in the form of normative policies. Deontic constraints express what parties to the contract are required to perform (obligations), what they are allowed to do (permissions), or what they are not allowed to do (prohibitions).</p>
      </abstract>
      <kwd-group>
        <kwd>Business contract</kwd>
        <kwd>Business rule</kwd>
        <kwd>SBVR</kwd>
        <kwd>Ontology</kwd>
        <kwd>IDE</kwd>
      </kwd-group>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>1 Introduction</title>
      <p>One of the main difficulties in the software engineering area continues being the
mapping of business rules to computational systems. This scenario becomes much
more complicated due to the current Web based dynamic and highly competitive
business environment. Hence, the computational solutions for the business problems
cannot accompany the speed in which the change necessities appear. One of the main
sources of change is response to changes in regulations and contracts towards which
businesses are obligated to comply.</p>
      <p>
        Commonly, documents containing contracts and regulations define the strategies,
policies and relationships among organizations. From those documents arise the rules
that define the behavior of the business processes in the organizations [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ]. Hence, the
computational systems must be compliant with these business documents.
      </p>
      <p>
        We propose an IDE – Integrated Development Environment to model SBVR
(Semantic of Business Vocabulary and Business Rule) compliant business rules [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ]
extracted from business contract of services and store them in an ontological structure
of rules, facts and terms as defined in the SBVR metamodel. Business rules are based
on principles of deontic logic [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ] for treating expressions in the form of normative
policies. Deontic constraints express what parties to the contract are required to
perform (obligations), what they are allowed to do (permissions), or what they are not
allowed to do (prohibitions).
      </p>
      <p>The next section discusses aspects related to business rules and business contracts
formalization. Section 3 presents some requirements on the business contracts edition.
Section 4 provides a conclusion and discussion on future researches.
2 Business Contracts formalized as SBVR Business Rules</p>
      <p>
        This section discusses some aspects related to the formalization of business
contracts and business rules. First, we present a business contract, initially introduced
in [
        <xref ref-type="bibr" rid="ref4">4</xref>
        ] and then we show how it could be formalized as SBVR compliant rules.
      </p>
      <p>
        The contract example is an agreement between an ISP Provider and a Purchaser of
ISP services. The contract is structured in terms of a number of clause groups, each of
which contains contract conditions. In [
        <xref ref-type="bibr" rid="ref5">5</xref>
        ] we propose the transformation of such
contract clauses into FCL (Formal Contract Language). FCL was introduced in [
        <xref ref-type="bibr" rid="ref6">6</xref>
        ] for
the formal analysis of business contracts and it is based on previous work [
        <xref ref-type="bibr" rid="ref7">7</xref>
        ] and on
normative positions based on Deontic Logic with Directed Obligations [
        <xref ref-type="bibr" rid="ref8">8</xref>
        ].
      </p>
      <p>
        Usually a contract comprises two types of clauses: definitional clauses giving the
meaning of the terms used in the contract and clauses specifying the normative
behaviors (i.e., giving the obligations, permissions, prohibitions the signing parties of
the contract are subject to). To save space, we will concentrate only on some
normative specifications of a contract, which are the sections 5 and 6 of the contract
[
        <xref ref-type="bibr" rid="ref4">4</xref>
        ] that will be used in the subsequent sections.
      </p>
      <p>CONTRACT OF SERVICES
This Deed of Agreement is entered into as of the Effective Data identified below.
BETWEEN ABC Company (To be known as the Purchaser)
AND ISP Plus (To be known as the Supplier)</p>
      <p>WHEREAS (Purchaser) desires to enter into an agreement to purchase from
(Supplier) Application Server (To be known as (Service) in this Agreement).</p>
      <p>NOW IT IS HEREBY AGREED that (Supplier) and (Purchaser) shall enter into
an agreement subject to the following terms and conditions:</p>
      <p>…
5 Service Delivery
5.1 The (Supplier) shall ensure that the (Services) are available to the (Purchaser)
under Quality of Service Agreement (http://supplier/qos1.htm). (Services) that
do not conform to the Quality of Service Agreement shall be replaced by the
(Supplier) within 3 days from the notification by the (Purchaser), otherwise
the (Supplier) shall refund the (Purchaser) and pay the (Purchaser) a penalty
of $1000.
5.2 The (Supplier) shall on receipt of a purchase order for (Services) make them
available within 1 days.
5.3 If for any reason the conditions stated in 4.1 or 4.2 are not met, the
(Purchaser) is entitled to charge the (Supplier) the rate of $ 100 for each hour
the (Services) are not delivered.</p>
      <p>Payment
6.1 The payment terms shall be in full upon receipt of invoice. Interest shall be
charged at 5 % on accounts not paid within 7 days of the invoice date. The
prices shall be as stated in the sales order unless otherwise agreed in writing
by the (Supplier).
6.2 Payments are to be sent electronically, and are to be performed under
standards and guidelines outlined in PayPal.</p>
      <p>
        The problem is how these contract clauses could be transformed into
computational code. According to MDA methodology, this kind of contract clauses, if
formalized, they can be transformed into computational code. Although there are a lot
of discussion around the definition of what “business rule” means [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ], [
        <xref ref-type="bibr" rid="ref9">9</xref>
        ] in the
context of this work, a business rule is "a rule that can be interpreted by computers,
that defines or restricts some aspects of a business, introducing obligations or needs,
according to the organization policies" [
        <xref ref-type="bibr" rid="ref10">10</xref>
        ]. Following are some business rules in the
context of ISP service community:
 The (Supplier) shall on receipt of a purchase order for (Services) make them
available within 1 day.
 The payment terms shall be in full upon receipt of invoice.
 Payments are to be sent electronically, and are to be performed under
standards and guidelines outlined in PayPal.
      </p>
      <p>
        The main objective of the SBVR metamodel [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ] is to allow business people to
define the policies and the rules that drive the organizations in the business people’s
own language, in terms of the artifacts with which they perform the businesses.
Besides, the other objective is to capture those rules in a clear way, without
ambiguity, and quickly transformable in other representations.
      </p>
      <p>According to SBVR metamodel a business rule can be expressed formally in
statements in a structured English language using a font style convention. There are
four font styles with formal meaning: (i) term - the ‘term’ font is used for a
designation for a noun concept (other than an individual concept); (ii) Name - the
‘name’ font is used for a designation of an individual concept that tend to be proper
nouns (e.g., Washington); (iii) verb - the ‘verb’ font is used for designations for fact
types — usually a verb, preposition, or combination thereof; and (iv) keyword - the
‘keyword’ font is used for linguistic symbols used to construct statements – the words
that can be combined with other designations to form statements and definitions (e.g.,
‘each’ and ‘it is obligatory that’). For example, in the business rule, adapted from
the previous contract of service based on clause 6.1, as shown in the Figure 1,
includes four keywords or phrases, two designations for noun concepts and two for
fact types.</p>
      <p>It is obligatory that the invoice is paid in full if the invoice is received.
Keywords for
a modality</p>
      <p>Keyword for
a pronoun</p>
      <p>Designation
for a fact type</p>
      <p>Keyword for
a pronoun</p>
      <p>Designation
for a fact type</p>
      <p>Designation
for an object type</p>
      <p>Keyword for
a condition</p>
      <p>Designation
for an object type</p>
      <p>A Contract of Services IDE (Integrated Development Environment) should provide
some editors and functionalities to define contracts, business rules, facts and terms.
The business contract editor should provide specific templates using community
terminology to facilitate the inclusion of contract clauses as business rules, which are
compliant to the SBVR metamodel. Besides, the business fact editor should provide
templates to facilitate the inclusion of terms and fact types, which will be components
for the business rules. In this way, considering the ISP services community, the IDE
must provide facilities to define object type designations for supplier, purchaser and
service terms; to define facts, such as, “service is replaced within 3 days” and
“service is under Quality of Service Agreement” by combining terms and fact type
designations; and to define rules, such as, “It is obligatory that the supplier ensure to
the purchaser that the service is refunded and a penalty of $1000 is paid if the
service is not replaced within 3 days” by composing keywords, terms and facts. All
these elements are meaningful to that community and should be defined using the
IDE. When the business analyst defines terms, verbs, facts and rules contained in a
contract of service, they will be stored in the Business Rule Ontology, which is the
core of the IDE infrastructure.</p>
      <p>Figure 2 gives an idea of how could be the external interface of an IDE to define
business contracts and rules. From this window, the user can access all the main
features that he/she can perform in contracts, rules, facts and terms edition activities.
On the top part there are usual toolbars as in many IDEs. In the third line there are tab
controls for Contracts, Business Rules, Facts and Terms to coordinate user actions
according to what he/she wants to perform. In the middle, there are two panels: the
left one is used to browse rules, facts and terms and de right one is to create or edit
contracts and its components. At the bottom there is another panel to hold the
business rules organized as ruleset.</p>
      <p>
        Figure 3 shows the class diagram for the Business Contract Ontology. The Business
Contract Ontology instantiates a structure similar to Business Vocabulary+Rules,
defined in SBVR [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ]. Thus, it organizes the business terms, concepts and rules
specified in the business terminology that make sense for a user community. It also
organizes the relationships and the existing associations among these elements. To
provide the ability in the definition of connections among concepts that are of the
organization interest the repository maintains a semantic structure in the business
terminology.
      </p>
      <p>Interface Prototype for the Business Contract and Business Rules IDE</p>
      <p>Class Diagram for Business Contract Ontology</p>
      <p>
        A vocabulary is composed of two fundamental groups of elements: (i) terms,
representing concepts about anything, any concept, or any significant fact for a
business community and (ii) verbs, which are fundamental elements of predicates and
are the base for the representation of facts. On the other hand, a Rule set is a
"collection of business rules grouped together for some purpose", as defined in SBVR
metamodel [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ]. The business rules are composed by keywords, facts and conditions.
The keywords are very useful in the model creation to formalize rules without
ambiguities. A fact is a simple period and it is composed of one or more terms that
can be associated to a predicate. Facts can be grouped in conditions. All these
elements are properly organized in the repository so that the business rules are
formalized referencing these elements consistently.
      </p>
      <p>
        Considering the business to business (B2B) scenario and the contract of services
above mentioned the associated rule set contained in the Business Rules Ontology
should include all the rules of the contract. Other issues on the IDE requirements can
be seen in [
        <xref ref-type="bibr" rid="ref10">10</xref>
        ]. Figure 4 presents an instance, included in the Business Rule
Ontology, for the service replacement rule model.
      </p>
    </sec>
    <sec id="sec-2">
      <title>4 Conclusions</title>
      <p>The proposed IDE aims to facilitate the contract elaboration process by providing
editors, tools and templates for definition of contracts, business rules, facts and terms
customized for specific user community.</p>
      <p>The results indicate that the concepts, ideas and proposed IDE are promising.
Besides business contracts and rules formalization technologies, services (SOA),
repositories and ontologies, it seems that the complete solution for the mentioned
problems includes the (i) inclusion of a mechanism in the IDE to contemplate process
composition modeling using, for instance, languages such as BPMN and that could
make transformation to executable languages like WS-BPEL; and (ii) development of
a prototype implementing the IDE, including repository instances for ontologies,
adherent to the MOF metamodel, with standardized query and manipulation language.
A preliminary presentation version of this work is available at
http://www.cti.gov.br/images/stories/cti/publicacoes/pdf/2010/SBVR_basedBusinessContract_and
_BusinessRuleIDE.pdf.</p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          1.
          <string-name>
            <given-names>S.</given-names>
            <surname>Hildreth</surname>
          </string-name>
          , Rounding Up Business Rules.
          <source>ComputerWorld Software</source>
          . ID, (
          <year>2005</year>
          ).
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          2. OMG”
          <article-title>Semantics of Business Vocabulary and Business Rules (SBVR)</article-title>
          ,
          <year>v1</year>
          .0 OMG
          <string-name>
            <given-names>Available</given-names>
            <surname>Specification.</surname>
          </string-name>
          (
          <year>2008</year>
          ) http://www.omg.org/spec/SBVR/1.0/PDF/. Access in March/
          <year>2010</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          3.
          <string-name>
            <given-names>S.</given-names>
            <surname>Beller</surname>
          </string-name>
          , “
          <article-title>Deontic norms, deontic reasoning</article-title>
          , and deontic conditionals,
          <source>” Thinking &amp; Reasoning</source>
          , Volume
          <volume>14</volume>
          ,
          <string-name>
            <surname>Issue</surname>
            <given-names>4</given-names>
          </string-name>
          ,
          <string-name>
            <surname>November</surname>
          </string-name>
          , pages
          <fpage>305</fpage>
          -
          <lpage>341</lpage>
          (
          <year>2008</year>
          ).
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          4.
          <string-name>
            <given-names>G.</given-names>
            <surname>Governatori</surname>
          </string-name>
          ,
          <string-name>
            <given-names>Z.</given-names>
            <surname>Milosevic</surname>
          </string-name>
          and
          <string-name>
            <given-names>S.</given-names>
            <surname>Sadiq</surname>
          </string-name>
          , “
          <article-title>Compliance checking between business processes and business contracts</article-title>
          ,
          <source>” Proc. The 10th International Enterprise Distributed Object Computing Conference - EDOC</source>
          (
          <year>2006</year>
          ), Hong Kong, pp.
          <fpage>221</fpage>
          -
          <lpage>232</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          5.
          <string-name>
            <surname>Kamada</surname>
            <given-names>A.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Governatori</surname>
            <given-names>G.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Sadiq</surname>
            <given-names>S.</given-names>
          </string-name>
          , “
          <article-title>Transformation of SBVR compliant business rules to executable FCL rules”</article-title>
          ,
          <source>4th International Web Rule Symposium (RuleML2010)</source>
          , Washington, DC, USA,
          <year>2010</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          6.
          <string-name>
            <given-names>G.</given-names>
            <surname>Governatori</surname>
          </string-name>
          and
          <string-name>
            <given-names>Z.</given-names>
            <surname>Milosevic</surname>
          </string-name>
          , “
          <article-title>A Formal Analysis of a Business Contract Language</article-title>
          ,”
          <source>International Journal of Cooperative Information Systems (IJCIS)</source>
          , Volume
          <volume>15</volume>
          , Number 4, pp.
          <fpage>659</fpage>
          -
          <lpage>685</lpage>
          (
          <year>2006</year>
          ).
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>
          7.
          <string-name>
            <given-names>G.</given-names>
            <surname>Governatori</surname>
          </string-name>
          .
          <article-title>Representing business contracts in RuleML</article-title>
          .
          <source>Int. J. of Cooperative Inf. Sys.</source>
          ,
          <volume>14</volume>
          (
          <issue>2-3</issue>
          ):
          <fpage>181</fpage>
          -
          <lpage>216</lpage>
          ,
          <year>2005</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          8.
          <string-name>
            <given-names>S.</given-names>
            <surname>Kanger</surname>
          </string-name>
          .
          <article-title>Law and logic</article-title>
          .
          <source>Theoria</source>
          ,
          <volume>38</volume>
          :
          <fpage>105</fpage>
          -
          <lpage>32</lpage>
          ,
          <year>1972</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref9">
        <mixed-citation>
          9. Kamada, “
          <article-title>Service Execution based on Business Rules”</article-title>
          ,
          <source>PhD Thesis</source>
          in Computing Engineering, Unicamp, Campinas, Brazil,
          <year>2006</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref10">
        <mixed-citation>
          10.
          <string-name>
            <surname>Kamada</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          <string-name>
            <surname>Figueiredo</surname>
            and
            <given-names>M.</given-names>
          </string-name>
          <string-name>
            <surname>Rodrigues</surname>
          </string-name>
          , “
          <article-title>Ontology based Business Rules</article-title>
          and
          <article-title>Services Integration Environment ,” in Handbook of Research on E-services in the Public Sector: Egovernment Strategies</article-title>
          and Advancements, Editors: Abid Thyab Al Ajeeli,
          <article-title>Yousif A</article-title>
          .
          <string-name>
            <surname>Latif</surname>
          </string-name>
          Al-bastaki,
          <source>Jeihan Abu-tayeh, Information Science Publishing</source>
          ,
          <year>March 2010</year>
          .
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>