Writing Natural Language Rule Statements — a Systematic Approach Part 24: The Syntax of Activity Rule Statements
About this series of articlesWhile my first series of articles on writing natural language rule statements[1] explored a wide variety of issues in a rather organic and hence random manner, this series takes a more holistic and systematic approach and draws on insights gained while writing my recently-published book on the same topic.[2] Rule statements recommended in these articles are intended to comply with the Object Management Group's Semantics of Business Vocabulary and Business Rules (SBVR) version 1.0.[3]
The story so far
In earlier articles in this series (see the "Language Archives" sidebar) we have looked at standardised rule statements for various types of operative rules[4] (data rules,[5] activity rules,[6] and party rules[7]) and definitional rules.[8] Each specific type of rule statement has a common formulation which we have discussed in both a relatively informal way and by way of rule statement patterns.
In the last few articles[9] we looked at the syntax of data cardinality rule statements[10] and data content rule statements[11] in general. In this article we will look at the general syntax of activity rule statements.[12]
Review of Activity Rule Statements
In this series we have encountered various types of activity rule statements:
- activity pre-condition rules, which prohibit a process or other activity unless some other activity or event has previously occurred or some pre-requisite condition exists, e.g.,
RS187. | A passenger may board an international flight only after that passenger undergoes departure control. |
RS188. | A laptop computer may undergo security screening only if that laptop computer is not in a bag. |
RS189. | Security screening of a laptop computer may occur only if that laptop computer is not in a bag.[13] |
- activity prohibition rules, which prohibit a process or other activity if some event or other process has previously occurred or some dangerous or illegal condition exists, e.g.,
RS177. | A driver must not operate any vehicle if that driver is intoxicated. |
RS190. | A vehicle must not be operated if a defect notice is current for that vehicle. |
- activity conflict rules, which restrict the simultaneous occurrence of multiple processes or other activities, e.g.,
RS178. | A folder must not be renamed while any file within that folder is open for editing. |
- activity exclusion period rules, which prohibit a process or other activity during a particular time period, e.g.,
RS175. | An electronic device must not be operated on an aircraft at any time after pushback[14] of that aircraft until a cabin crew member advises that electronic devices may be operated safely. |
RS185. | Check-in for a flight must not occur later than 30 minutes before the departure time of that flight. |
RS186. | Construction machinery must not be operated in a residential area before 7:30am or after 7:30pm on a weekday or before 8am or after 8pm on a Saturday or Sunday. |
- information retention rules, which define the minimum period for which a particular type of information is retained,[15] e.g.,
RS179. | Information that is relevant to Australian income tax payment in a financial year must not be deleted during the 7 years after the end of that financial year. |
- activity time limit rules, which restrict a process or other activity to within a particular time period, e.g.,
RS182. | Bag drop for a flight may occur only during the 4 hours before the departure time of that flight. |
RS183. | Bags may be accepted for a flight only during the 4 hours before the departure time of that flight.[16] |
- activity obligation rules, which require a process or other activity to occur either within a maximum time after a particular event (such as the completion of some other process) or when particular conditions apply, e.g.,
RS180. | Each electronic device that is being used on an aircraft must be switched off no later than 1 minute after the start of the descent of that aircraft. |
RS193. | Each application must be processed within 1 business day of receipt of that application. |
RS194. | Acknowledgment of a service request that is made before 2pm must occur before 5pm on the day on which that service request is made. |
RS195. | A replenishment order must be raised for a part no later than 24 hours after the quantity on hand of that part falls below the reorder point for that part. |
RS196. | Monthly processing of the transactions for a calendar month must be performed during the first business day after that calendar month. |
- object status rules, which specify the required status of an object in particular circumstances, e.g.,
RS202. | Each door of the train must be locked while that train is in motion. |
- process decision rules, which determine what action a process or device is to take in specific situations, e.g.,
RS206. | The processing of each order must apply the preferred customer discount to the price of each item in that order if the customer who raised that order is a preferred customer. |
The anatomy of an activity rule statement
Activity rule statements — like other data rule statements — are operative rule statements,[17] each taking one of the following forms:
- An activity obligation rule statement, object status rule statement, or process decision rule statement takes the form of an obligation statement, consisting of:
- an optional determiner (Each, The, A, or An)
- a subject
- the keyword must
- a predicate
- generally a constraint expression following either:
- a conjunction, such as if, unless, after, or while
or - a temporal preposition, such as after or during
- a conjunction, such as if, unless, after, or while
- An activity prohibition rule statement, activity conflict rule statement, activity exclusion period rule statement, or information retention rule statement takes the form of a prohibition statement, consisting of:
- an optional determiner (Each, The, A, or An)
- a subject
- the keywords must not
- a predicate
- generally a constraint expression following a conjunction or preposition as above
- An activity pre-condition rule statement, activity time limit rule statement takes the form of a restricted permission statement, consisting of:
- an optional determiner (Each, The, A, or An)
- a subject
- the keyword may
- a predicate
- the keyword only
- a constraint expression following a conjunction or preposition as above.
The subject of an activity rule statement
The subject of any activity rule statement consists of:
- a subject noun phrase, one of:
- the term signifying the target[18] of the constrained activity (as in RS188, RS190, RS178, RS175, RS186, RS179, RS183, RS180, RS193, RS195, and RS202)
- the term signifying the agent[19] of the constrained activity (as in RS187 and RS177)
- a verbal noun[20] signifying the constrained activity (as in RS189, RS185, RS182, RS194, RS196, and RS206)
- zero or more (or, if you prefer, optionally one or more) prepositional phrases, such as
- of a laptop computer
- for a flight
- of the transactions for a calendar month
- of the train
- of each order
- zero or more qualifying clauses, such as
- that is relevant to Australian income tax payment in a financial year
- that is being used on an aircraft
- that is made before 2pm.
The predicate of an activity rule statement
The form taken by the predicate of an activity rule statement depends on the choice of subject noun phrase:
- If the subject noun phrase is the term signifying the target of the constrained activity, the predicate can take either of two forms:
- the verb phrase signifying that activity in the passive voice[21] (e.g., be operated, be renamed, be deleted, be accepted, be switched off, be processed, be raised, be locked), followed by an optional prepositional phrase (e.g., on an aircraft, in a residential area, for a flight, for a part)
- undergo, followed by a verbal noun signifying the constrained activity (e.g., security screening).
- If the subject noun phrase is the term signifying the agent of the constrained activity, the predicate consists of the verb phrase signifying that activity in the active voice[22] (e.g., board, operate), followed by a noun phrase signifying the target of the constrained activity (e.g., an international flight, any vehicle).
- If the subject noun phrase is a verbal noun signifying the constrained activity, the predicate consists of occur or be performed as appropriate, except in a process decision rule statement, in which it consists of a verb phrase in the active voice (e.g., apply in RS206) followed by:
- a noun phrase signifying the direct object of that verb phrase (e.g., the preferred customer discount)
- (optionally) to followed by a noun phrase signifying the indirect object of that verb phrase (e.g., the price of each item in that order).
The constraint expression in an activity rule statement
Activity rule statements generally impose temporal constraints or pre-conditions on activities. For example:
- An activity pre-condition rule only allows the governed activity to occur if some other activity or event has previously occurred or some condition exists.
- An activity prohibition rule prevents the governed activity from occurring if some event or other process has previously occurred or some condition exists.
- An activity conflict rule prevents the governed activity from occurring at the same time as some other activity.
- An activity time limit rule, activity exclusion period rule, or information retention rule places a time restriction on the governed activity.
These constraints and pre-conditions are expressed using constraint expressions, which may take any of the following forms:
- a complete clause (i.e., including a verb phrase) introduced by a conjunction (such as if, unless, after, or while), for example:
- after that passenger undergoes departure control
- if that laptop computer is not in a bag
- if that driver is intoxicated
- if a defect notice is current for that vehicle
- while any file within that folder is open for editing
- while that train is in motion
- if the customer who raised that order is a preferred customer
- a temporal conjunction and clause such as these, but preceded by an expression signifying an interval, e.g.,
- no later than 24 hours
after the quantity on hand of that part falls below the reorder point for that part
- a noun phrase introduced by a temporal preposition, for example:
- later than 30 minutes before the departure time of that flight
- during the 7 years after the end of that financial year
- during the 4 hours before the departure time of that flight
- no later than 1 minute after the start of the descent of that aircraft
- within 1 business day of receipt of that application
- before 5pm on the day on which that service request is made
- during the first business day after that calendar month
- A combination of two or more of any such time restrictions, e.g.,
- at any time after pushback of that aircraft
until a cabin crew member advises that electronic devices may be operated safely - before 7:30am or after 7:30pm on a weekday
or before 8am or after 8pm on a Saturday or Sunday.
Note that the word 'after' may be used as:
- a conjunction before a complete clause, in which case SBVR conventions require that it be rendered 'after', or
- a preposition before a term (e.g., pushback) or literal (e.g., 8pm), in which case it is rendered as 'after'.
This is also true of 'before'/'before' and 'until'/'until'. Other words and phrases operate only as one or the other, e.g. 'while' operates only as a conjunction, while 'during', 'earlier than', and 'later than' operate only as prepositions.
To be continued...
In the next article in this series I will look at the general syntax of party rule statements.
References
[1] The first of which is: Graham Witt, "A Practical Method of Developing Natural Language Rule Statements (Part 1)," Business Rules Journal, Vol. 10, No. 2 (Feb. 2009), URL: http://www.BRCommunity.com/a2009/b461.html
[2] Graham Witt, Writing Effective Business Rules. Morgan Kaufmann (2012).
[3] Semantics of Business Vocabulary and Business Rules (SBVR), v1.0. Object Management Group (Jan. 2008). Available at http://www.omg.org/spec/SBVR/1.0/
The font and colour conventions used in these rule statements reflect those in the SBVR, namely underlined teal for terms, italic blue for verb phrases, orange for keywords, and double-underlined green for names and other literals. Note that, for clarity, these conventions are not used for rule statements that exhibit one or more non-recommended characteristics.
[4] A rule that states what must or must not happen in particular circumstances, and which can therefore be contravened, by contrast with a definitional rule.
[5] A rule that constrains the data included in a transaction (a form or message) or a persistent data set (e.g., a database record).
[6] A rule that constrains the operation of one or more business processes or other activities.
[7] A rule that makes a distinction between different parties or the roles they play.
[8] A rule that defines a construct created or used by an organisation (or the industry within which it operates), or defines a property of such a construct, and which cannot therefore be contravened, by contrast with an operative rule.
[9] Graham Witt, "Writing Natural Language Rule Statements — a Systematic Approach — Part 21: The syntax of Data Cardinality Rule Statements," Business Rules Journal, Vol. 15, No. 4 (Mar. 2014). URL: http://www.brcommunity.com/a2014/b757.html and
Graham Witt, "Writing Natural Language Rule Statements — a Systematic Approach — Part 22: The Syntax of Some Data Content Rule Statements," Business Rules Journal, Vol. 15, No. 5 (May 2014), URL: http://www.BRCommunity.com/a2014/b762.html
[10] Statements of rules that require the presence or absence of a data item and/or place restrictions on the maximum or minimum number of occurrences of a data item.
[11] Statements of rules that place a restriction on the values contained in a data item or set of data items (rather than whether or not they must be present and how many there may or must be).
[12] A rule that constrains the operation of one or more business processes or other activities.
[13] Note that this rule statement and RS188 are alternative ways of expressing the same rule.
[14] 'Pushback' is the reversal of an aircraft from the gate before taxying and takeoff.
[15] It may not be obvious that this is an activity restriction rule, but it is a prohibition of any process that results in the deletion or destruction of the information in question.
[16] Note that this rule statement and RS182 are alternative ways of expressing the same rule.
[17] A statement of a rule that specifies what must or must not happen in particular circumstances, and which can therefore be contravened, by contrast with a definitional rule.
[18] The person or thing on which the action signified by a verb phrase in the passive voice is performed, e.g., 'door' in 'the door is closed by the flight attendant'.
[19] The person or thing performing the action signified by a verb phrase, e.g., 'flight attendant' in 'the door is closed by the flight attendant'.
[20] A noun formed from or otherwise corresponding to a verb phrase.
[21] The use of a verb phrase such that the subject of that verb phrase is the person or thing on which the action is performed (the patient or target), as in "a boarding pass is presented by the passenger".
[22] The use of a verb phrase such that the subject of that verb phrase is the person or thing performing the action signified by that verb phrase (i.e., the actor or agent), as in "the passenger presents a boarding pass".
# # #
About our Contributor:
Online Interactive Training Series
In response to a great many requests, Business Rule Solutions now offers at-a-distance learning options. No travel, no backlogs, no hassles. Same great instructors, but with schedules, content and pricing designed to meet the special needs of busy professionals.