untitled
SBVR Speaks
Notations for Business Rule Expression
| In September 2005, the Object Management Group (OMG) approved
the "Semantics of Business Vocabulary and Business Rules" (SBVR)[1] to become a final adopted
specification of the OMG. In March 2006, the first Interim Specification
document was issued, replacing the Submission Document (bei/05-08-01), the Draft
Adopted Specification (dtc/05-11-01), and the Final Adopted Specification (dtc/06-03-01).
This month we continue our exploration of the "Semantics of Business Vocabulary
and Business Rules" with a look at business rule expression forms in some detail. |
'Notation' is used in SBVR (as instructed by the OMG) to
mean any language used to represent semantics or, more precisely, abstract syntax.
Notations can be verbal, graphical, or any combination thereof. Other words
for 'notation' are 'grammar', 'syntax', and 'concrete surface syntax'.[3]
It is important to keep in mind that SBVR Structured English (introduced here
and covered in detail in SBVR Annex C) is just one of possibly many notations that
can be used to express the SBVR Metamodel. As a notation, it is nonnormative
in the SBVR standard.
SBVR Structured English for Rule Expression
The most common means of expressing definitions and business rules is through
statements, not diagrams. While diagrams are helpful for seeing how concepts
are related, they are impractical as a primary means of defining vocabulary and expressing
business rules.
Accordingly, the SBVR specification defines an English vocabulary for describing
vocabularies and stating rules. There are many different ways that this vocabulary
and other English vocabularies described using SBVR can be combined with common English
words and structures to express definitions and statements.
For rule expression, two styles are documented in the standard:
- Prefixed Rule Keyword Style
- Embedded (mixfix) Rule Keyword Style
Prefixed Rule Keyword Style
The prefixed style introduces rules by prefixing a
statement with keywords that convey a modality.[4]
Examples of some of the prefixed-style keywords are shown in Table 1.
Table 1. Rule keywords for use in the Prefixed Style
of rule statement
|
Operative ('Behavioral')
|
Structural ('Definitional')
|
| It is obligatory that |
It is necessary that |
| It is prohibited that |
It is impossible that |
| It is permitted that |
It is possible that |
This style, which is illustrated in the next section, is included in the standard
for two primary reasons:
- It is supported by the commercial reference implementation of Unisys Corporation,
an implementation that satisfies the OMG submission's compliance requirements.
- Its rule keywords correspond to the modal operators in the logical formulation
portion of SBVR, so it illustrates the translation of notation to metamodel in the
most direct and easy-to-understand fashion.
Embedded (mixfix) Rule Keyword Style
The embedded style features the use of rule keywords embedded (usually
in front of a verb) within rules statements of appropriate kinds. Examples
of some of the embedded-style keywords are shown in Table 2.
Table 2. Rule keywords for use in the Embedded Style
of rule statement
|
Operative ('Behavioral')
|
Structural ('Definitional')
|
| ... must ... |
... always ... |
| ... must not ... |
... never ... |
| ... may ... |
... sometimes ... |
This style of notation, which is examined
more closely in a companion column,[5]
is included in the standard for two primary reasons:
- It is an existing, documented notation,[6]
RuleSpeak®, that has been used with business people in actual practice
for a number of years.
- It clearly demonstrates that alternative notations for business rules, which
some business people find more natural and/or friendly, are easily accommodated under
SBVR Structured English.
Examples
Applying these two rule keyword styles, here are two statements of a single rule:
It is obligatory that each rental has at most three additional drivers.
A rental must have at most three additional drivers.
However expressed, the semantics of rules and definitions can be formally
represented in terms of the SBVR vocabulary and, particularly, in terms of logical
formulations (the SBVR conceptualization of formal logic). SBVR Structured
English is one such way of using English that maps mechanically to SBVR concepts.
SBVR Structured English is not meant to offer all of the variety of common English,
but rather, it uses a small number of English structures and common words to provide
a simple and straightforward mapping.
Here are the same two rule statements, now represented formally,[7] using the font styles of SBVR
Structured English:
It is obligatory that each rental
has at most three additional drivers.
A rental
must have
at most three additional
drivers.
Note that the rule meant by these two statements is based
on the vocabulary-defined fact type, rental has
additional driver, which involves two concepts, termed (respectively)
rental and additional
driver.[8]
Consider the following rule statement, expressed in the prefix style and formally
styled.
It is obligatory that each rental
car is owned by exactly one
branch.
We can see how the combination of styled elements and modality represents the
formal expression of the rule. The rule statement above includes three key
words or phrases, two designations for noun concepts, and one for a fact type (from
a form of expression), as annotated below.

SBVR Structured English for Expression (in General)
SBVR Structured English is used to write statements and definitions that represent
corresponding logical formulations. It uses a combination of font styling and
defined keywords to accomplish this.
Expression Styling in SBVR Structured English
SBVR Structured English expressions are recognized by being fully expressed using
font styles that have a particular meaning in SBVR Structured English. (Comment:
these fonts are also used for individual designations in the context of ordinary,
unformalized expressions in order to note that defined concepts are being used.)
There are four font styles with formal meaning:
| 1. |
 |
The 'term' font is used for a designation for a noun concept (other than an individual
concept), one that is part of a vocabulary being used or defined (e.g., modality,
modal formulation, fact
type). This style is applied to the designation where it
is defined and wherever it is used.
Terms are usually defined using lower case letters unless they include a proper noun.
Terms are defined in singular form. Plural forms are implicitly available for
use. |
| 2. |
 |
The 'name' font is used for a designation of an individual concept -- a name.
Names tend to be proper nouns (e.g., ). This style is applied to a name where it is defined
and wherever it is used. Note that names of numerical values in formal statements
are also shown in this style (e.g., ). See the definition of 'name'
in SBVR for more details.
Names appear using appropriate capitalization, which is usually the first letter
of each word, but not necessarily. |
| 3. |
 |
The 'verb' font is used for designations for fact types -- usually
a verb, preposition, or combination thereof. Such a designation is defined
in the context of a form of expression. This font is used both in the context
of showing a form of expression (e.g., 'modal formulation
claims modality' and 'modality
is claimed by modal formulation') and in the context
of using it in a statement (e.g., "Each modal formulation claims exactly one modality.").[9]
Forms of expressions are defined using singular, active forms of
verbs with the exception that gerund forms are sometimes defined for characteristics.
Infinitive, plural, and gerund forms of verbs are implicitly available for use. |
| 4. |
 |
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'). Some of the key words and phrases are listed
below.
Quotation marks are also in the 'keyword' font. The text within quotes is in
ordinary font if the meaning of the quotation is uninterpreted text. The text
within quotes is in styled text if the meaning of the quotation is formally represented.
Single quotation marks are used to quote a designation or form of expression that
is being mentioned. If a designation is mentioned (where the designation is
itself the subject of a statement) it appears within single quote marks (e.g., 'modality' and ' ' used to talk about those designations).
Single quotes are also used around a form of expression that is being mentioned (e.g.,
'modal formulation claims modality'
used to talk about that form of expression). Double quotation marks are used
in other cases, such as to quote a statement.
Single quotation marks are also used to mention a concept -- to refer to the concept
itself rather than to the things it denotes. In this case, a quoted designation
or form of expression is preceded by the word 'concept'
or by a term for a kind of concept. E.g., the statement, "The
concept 'quantification'
is a
category of the concept 'logical formulation'.",
refers to the named concepts, not to quantifications and logical formulations.
A role can be named with respect to a fact type in this same way (e.g., the
role 'modality'
of the
fact type 'modal formulation
claims modality').
Periods also appear in the 'keyword' font. A period is used to terminate a
statement, but not a definition. Other punctuation symbols (e.g., parentheses,
comma) also apply the 'keyword' font when part of a formal expression. |
Key words and phrases for logical formulations
SBVR Structured English provides key words and phrases for
expressing each kind of logical formulation. A sampling of these is presented
below.[10] The letters
'n' and 'm' represent use of a literal whole number. The letters
'p' and 'q' represent expressions of propositions.
| Quantification |
each |
universal quantification |
at least one |
esistential quantification |
at least n |
at-least-n quantification |
at most one |
at-most-one quantification |
at most n |
at-most-n quantification |
at least n and
at most m |
numeric range quantification |
| Logical Operations |
p and q |
conjunction |
p or q |
disjunction |
p or q
but not both |
exclusive disjunction |
if p
then q |
implication |
p if and only if q |
equivalence |
| Other Keywords |
the |
1. used with a designation to make a pronominal reference to a previous use
of the same designation. This is formally a binding to a variable of a quantification.
2. introduction of a name of an individual thing or of a definite description |
a, an |
universal or existential quantification, depending on context based on English rules |
another |
(used with a term that has been previously used in the same statement) existential
quantification plus a condition that the referent thing is not the same thing as
the referent of the previous use of the term |
a given |
universal quantification pushed outside of a demonstrative expression where 'a given' is used such that it represents one
thing at a time -- this is used to avoid ambiguity where the 'a'
by itself could otherwise be interpreted as an existential quantification. |
that |
1. when preceding a designation for a noun concept, this is
a binding to a variable (as with 'the')
2. when after a designation for a noun concept and before a designation for a fact
type, this is used to introduce a restriction on things denoted by the previous designation
based on facts about them
3. when followed by a propositional statement, this used to introduce nominalization
of the proposition or objectification, depending on whether the expected result is
a proposition or an actuality.[11] |
who |
the same as the second use of 'that' but used for a person |
is of |
The common preposition "of"
is used as a shorthand for "that is of". For any sentential
form that takes the general form of '<placeholder
1> has <placeholder 2>' there is an implicit
reversed form of '<placeholder 2> is
of <placeholder 1>' that has the same meaning. |
what |
used to introduce a variable in a projection as well as indicate that a projection
is being formulated to be considered by a question or answer nominalization.[11] |
Where a subject is repeated when using 'and'
or 'or', the repeated subject can be elided.
For example, the statement, "An implication has an antecedent and
the implication is embedded in a modal formulation," can be abbreviated to this:
"An implication has an antecedent and
is embedded in a modal formulation." Similarly, a repeated subject and
verb can be elided. For example, the statement, "An implication has an
antecedent and the implication has a consequent,"
can be abbreviated to this: "An implication has an antecedent and
a consequent."
The keyword 'not' is used within an
expression before the verb "is"
as a way of introducing a logical negation.
Also, the key words "does not"
are used before other verbs (modified to be infinitive) to introduce a logical
negation.
Next time...
In this instalment we have seen the way the expression of business rules is accomplished
in SBVR. Business rules, represented by business rule statements, apply the
conventions of some notation -- here, SBVR Structured English expression in general,
along with specialized key words and phrases that indicate the rule's modality.
Two styles -- prefixed and embedded -- are available for use.
With the Business Rules Mantra in mind ("Rules are based on facts,
and facts are based on terms"), next time we will look at the elements that
business rules are based on -- concepts, including fact types -- and how they
are defined and expressed as terms and other symbols.
References
[1] Semantics of Business Vocabulary and Business
Rules (SBVR), First Interim Specification, March 2006. Available as
dtc/06-03-02 at http://www.omg.org 
[2] "Quick Reference for Basic SBVR Terminology, Business Rules
Journal, URL: http://www.BRCommunity.com/a2005/b262.html
[3] It is specifically not the intention of SBVR
to mandate any particular notation(s) that must or should be used with the SBVR Metamodel.
Indeed, this would be neither productive not desirable. Instead, wide innovation,
experimentation, and value-adding software development in the area of compliant notations
is encouraged. For example, additional compliant notations are encouraged.
Also welcomed and encouraged are compliant enrichments of various parts of SBVR Structured
English itself. 
[4] Modality (from modal logics) is an important
aspect of SBVR but is a topic too vast for coverage here. Modality is covered
in considerable detail throughout the standard and, in particular, in Clause 9 (where
the vocabulary for the logical formulation of semantics vocabulary is specified)
and Clause 10 (where the formal grounding model is presented and discussed).
For our introductory understanding in this series, the following two general points
should help:
- Every rule has an associated modality, which can be thought of very informally
as a kind of 'tag' that has been added to some fact type(s) to produce the rule.
- In SBVR, the two main modalities are: alethic modality -- the modality
of necessity (also including possibility, etc.) and deontic modality -- the
modality of obligation (also including permission, etc.). Alethic modality
aligns with SBVR structural (or 'definitional') rule; deontic modality aligns with
SBVR operative (or 'behavioral') business rule.
[5] Ronald G. Ross, "The RuleSpeak®
Business Rule Notation," Business Rules Journal, Vol. 7, No. 4 (Apr.
2006), URL: http://www.BRCommunity.com/a2005/b282.html 
[6] RuleSpeak®, by Business Rule Solutions,
LLC, as documented in Principles of the Business Rule Approach, by Ronald
G. Ross, Addison-Wesley, Boston, MA (2003), Chapters 8-12. 
[7] The complete semantic formulation of this rule can
be found in the introduction to the "Logical Formulation of Semantics
Vocabulary," Clause 9 of the SBVR document. 
[8] The car rental examples come from EU-Rent, a (fictitious)
car rental company. This popular case study was contributed to the SBVR effort
by Model Systems and appears in detail as Annex D of the SBVR document. 
[9] Some of the terms used here to introduce the font
styles of SBVR Structured English (e.g., 'designation', 'noun concept', 'individual
concept', 'form of expression') will be the subject of a later instalment. 
[10] The complete lists can be found in C.1.1 and C.1.2
of Annex C of the SBVR document. 
[11] See C.1.5 of Annex C of the SBVR document. 
BUSINESS RULES COMMUNITY (www.BRCommunity.com)
COPYRIGHT © 1997-2006, BUSINESS RULE SOLUTIONS, LLC. ALL RIGHTS RESERVED
|