Declarative,
Constraint-Based BPM
Marco Montali
Free University of Bozen-Bolzano
ack to Maja Pesic, Wil van der Aalst, Fabrizio Maggi, Giuseppe De Giacomo, Riccardo de Masellis
1
Disclaimer for this Talk
Process = Control-flow
(but the story is much more
interesting than that…)
2
BPM!
3
BPM?
4
Types of Processes
Not all business processes are the same
• Even within one organization, business processes
can be very different in terms of their essential
properties.
• Business processes can be characterized through
three dimensions:
• complexity
• predictability
• repetitiveness
5
Complexity
Degree of difficulty in collaboration, coordination,
and decision making
• Low complexity: exchanging personal email
messages and handling travel requests
• High complexity: handling medical treatments
6
Predictability
How easy it is to determine in advance the way the
process will be executed.
• Low predictability: exchanging personal email
messages.
• High predictability: handling travel requests.
7
Repetitiveness
Frequency of process execution.
• A business process that is executed once per year
has a lower degree of repetitiveness than a
process executed twice a day.
• Low repetitiveness: disaster handling.
• High repetitiveness: exchanging personal email
messages.
8
Classifying Processes
Prepare coffee
Produce shoes
Register birth
Design shoes
Disaster recovery
Celebrate opening of A.Y.
Win slot machine
9
Classifying Processes
Prepare coffee Produce shoesRegister birth
Design shoes
Disaster recovery
Win slot machine
10
Celebrate opening of A.Y.
BPM Systems
BPM systems support collaboration,
coordination and decision making in business
processes.
• Groupware systems support human
collaboration and co-decision.
• Workflow management systems explicitly
control ordering, coordination and execution
of activities with little human intervention.
11
BPMS and Decision Making
12
• Ordering and coordination of
activities not automated.
• Users control the ordering and
coordination of activities “on the
fly” while executing the business
process.
• Humans merely influence
the execution of business
processes by entering
necessary data.
BPMS and 

Types of Processes
13
Environment!
14
Influence of the Environment
The degree of turbulence of the environment
influences the predictability of business processes
and the nature of decision making.
15
Influence of the Environment
The degree of turbulence of the environment
influences the predictability of business processes
and the nature of decision making.
‘optimal’
16
Combining Social and
Technical Aspects
• Organizations can significantly benefit from using
the best that both humans and technology have to
offer.
• Instead of being replaceable, humans and
machines should complement each other.
17
Combining Social and
Technical Aspects
18
Flexibility vs Support
Flexibility: degree to which users can make local
decisions about how to execute processes.
Support: degree to which a system makes centralized
decisions about how to execute processes.
Universe of Traces
Compliant
Traces
Flexibility19
Trade-off?
20
The Issue of Flexibility
21
Ultimate Goal:

Balance Flexibility and Control
22
Trends in BPM
modeling
• Highly-variable BPs
• Metaphor: rules/constraints
Dec t i
lar
a
ev
Imperative modeling
• Traditional repetitive BPs
• Metaphor: flow-chart
23
Imperative Modeling
24
Organizational Boundaries
25
Imperative Modeling
Focus: howthings must be done
• Explicit description of the process control-flow
Closedmodeling
• All that is not explicitly modeled is forbidden
• Exceptions/uncommon behaviors have to be
explicitly enumerated at design time
26
BPMN
Receive
order
Check
availability
Article available?
Ship article
Financial
settlement
yes
Procurement
no
Payment
received
Inform
customer
Late deliveryUndeliverable
Customer
informed
Inform
customer
Article
removed
Remove
article from
catalogue
27
BPMN
Receive
order
Check
availability
Article available?
Ship article
Financial
settlement
yes
Procurement
no
Payment
received
Inform
customer
Late deliveryUndeliverable
Customer
informed
Inform
customer
Article
removed
Remove
article from
catalogue
Input Output
28
BPMN
Receive
order
Check
availability
Article available?
Ship article
Financial
settlement
yes
Procurement
no
Payment
received
Inform
customer
Late deliveryUndeliverable
Customer
informed
Inform
customer
Article
removed
Remove
article from
catalogue
Input Output
29
Organizational Boundaries
30
Example: Rigid Shopping
• Tasks: 𝚺 = {pick item, close order, pay}
• A customer starts the process by picking one
or more items. She then decides to quit or
close the order. In the latter case, she has to
pay for the order.
31
Questions
• Tasks: 𝚺 = {pick item, close order, pay}
• A customer starts the process by picking one or more
items. She then decides to quit or close the order. In the
latter case, she has to pay for the order.
• Which traces are accepted?
• <> (empty trace)
• <i,i,i>
• <i,i,i,c,p>
• <i,i,i,c,p,p>
• <i,i,i,p,c>
• <i,c,p,i,i,c,p>
32
Questions
• Tasks: 𝚺 = {pick item, close order, pay}
• A customer starts the process by picking one or more
items. She then decides to quit or close the order. In the
latter case, she has to pay for the order.
• Which traces are accepted?
• <> (empty trace)
• <i,i,i>
• <i,i,i,c,p>
• <i,i,i,c,p,p>
• <i,i,i,p,c>
• <i,c,p,i,i,c,p>
33
Questions
• Can you model this process in BPMN? How difficult
is it?
A customer starts the process by picking one or
more items. She then decides to quit or close
the order. In the latter case, she has to pay for
the order.
34
Questions
• Can you model this process in BPMN? How difficult
is it?
pick
item
close
order
pay
quit
order paid
35
Example: Flexible Shopping
• Tasks: 𝚺 = {pick item, close order, pay}
• A customer may pick items, close several orders,
and pay one or more orders at once.
• She may even close an empty order and pay for it,
or pay multiple times (but this will result in a no-op)
• Business constraint: whenever you close an
order, eventually you have to pay.
36
Questions
• Tasks: 𝚺 = {pick item, close order, pay}
• Business constraint: whenever you close an order,
eventually you have to pay.
• Which traces are accepted?
• <> (empty trace)
• <i,i,i>
• <i,i,i,c,p>
• <i,i,i,c,p,p>
• <i,i,i,p,c>
• <i,c,p,i,i,c,p>
37
Questions
• Tasks: 𝚺 = {pick item, close order, pay}
• Business constraint: whenever you close an order,
eventually you have to pay.
• Which traces are accepted?
• <> (empty trace)
• <i,i,i>
• <i,i,i,c,p>
• <i,i,i,c,p,p>
• <i,i,i,p,c>
• <i,c,p,i,i,c,p>
38
Questions
• Can you model this process in BPMN? How difficult
is it?
You may pick items, close and pay an order.

Whenever you close an order, eventually you have to pay.
39
Questions
• Can you model this process in BPMN? How difficult
is it?
40
pick
item
close
order
pay
quit
order paid
Questions
• Can you model this process in BPMN? How difficult
is it?
41
pick
item
close
order
pay
quit
order paid
simple, correct, but not general enough!
Questions
• Can you model this process in BPMN? How difficult
is it?
42
pick
item
close
order
pay
pick
item
pay
Questions
• Can you model this process in BPMN? How difficult
is it?
43
pick
item
close
order
pay
pick
item
pay
correct, general, but unreadable!
Choreography Example
• An order can be finalized at mosto once
• Once an order is finalized, it must be confirmed or rejected
• A confirmed order may be rejected later on (due to “late”
problems), but not vice-versa: a reject cannot be reverted.
• An order can be confirmed only if it shipped before.
• An order may be rejected autonomously by the seller.
However, if the warehouse notifies the seller of a shipment
issue, then the seller has to reject the order.
• The warehouse decision is firm: “Ship” and “Notify
shipment issue” are mutually exclusive.
44
What is your
Favourite Italian Food?
45
Order-to-delivery
What is your
Favourite Italian Food?
46
Order-to-delivery
What is your
Favourite Italian Food?
47
UnderstandingSpaghettiModelswithSequenceClusteringforProM9
thoseexceptions.Figure4depictstheresultofafirstattempttoanalyzethe
applicationserverlogsusingtheheuristicsminer[4].
Exception
(complete)
187
EstabelecimentoNotFoundException
(complete)
187
0,991
152
GREJBPersistencyException
(complete)
179
0,909
159
PGWSException
(complete)
168
0,889
12
ITPTExternalServiceException
(complete)
183
0,944
162
SIPSCNoRecordsFoundException
(complete)
160
0,8
5
PessoaSingularNotFoundException
(complete)
138
0,667
3
BusinessLogicException
(complete)
183
0,75
4
SICCLException
(complete)
175
0,857
19
NaoExistemRegistosException
(complete)
143
0,833
6
RPCBusinessException
(complete)
38
0,75
3
SAFBusinessException
(complete)
115
0,8
68
GREJBBusinessException
(complete)
45
0,75
23
DESWSException
(complete)
14
0,667
14
NullPointerException
(complete)
104
0,8
91
ValidationException
(complete)
31
0,8
12
GILBusinessException
(complete)
14
0,5
6
GRServicesException
(complete)
7
0,667
3
CSIBusinessException
(complete)
14
0,5
6
ConcorrenciaException
(complete)
5
0,5
2
CSIPersistencyException
(complete)
3
0,5
2
0,857
34
ITPTServerException
(complete)
21
0,667
15
COOPException
(complete)
4
0,5
2
RSIValidationException
(complete)
25
0,667
18
BasicSystemException
(complete)
16
0,667
11
PesquisaAmbiguaException
(complete)
6
0,5
6
CPFBusinessException
(complete)
3
0,5
2
0,8
95
ADOPException
(complete)
6
0,5
5
AFBusinessException
(complete)
64
SIPSCRemoteBusinessException
(complete)
51
0,833
13
ConcurrentModificationException
(complete)
5
0,5
1
CDFBusinessException
(complete)
6
0,667
2
AssinaturaNaoIncluidaException
(complete)
1
0,5
1
SICCSException
(complete)
32
0,8
11
CartaoCidadaoException
(complete)
64
0,833
38
SOAPException
(complete)
22
0,667
14
TooManyRowsException
(complete)
112
0,667
18
SIPSCFatalException
(complete)
20
0,667
9
LimiteTemporalException
(complete)
4
0,5
2
0,8
28
SVIBusinessUserException
(complete)
18
0,75
12
GRConcurrencyException
(complete)
8
0,5
2
ContribuinteRegionalNotFoundException
(complete)
63
0,75
30
JDOFatalUserException
(complete)
124
0,947
49
0,667
5
SQLException
(complete)
9
0,667
7
IOException
(complete)
27
0,75
22
PessoaColectivaNotFoundException
(complete)
23
0,75
20
ServiceDelegateRemoteException
(complete)
3
0,5
2
0,5
5
PASException
(complete)
2
0,5
1
FileNotFoundException
(complete)
31
0,75
13
QgenMIParametrizedBusinessException
(complete)
1
0,5
1
ADOPMessageException
(complete)
3
0,5
2
LayoffException
(complete)
1
0,5
1
0,75
8
CMPException
(complete)
1
0,5
1
GREJBRemoteServiceException
(complete)
34
0,75
4
RSIPersistenceException
(complete)
24
0,75
4
CSIRemoteException
(complete)
3
0,5
1
SIPSCFatalRemoteCallException
(complete)
3
0,5
1
SIPSCDatabaseException
(complete)
1
0,5
1
BusinessException
(complete)
159
0,667
9
SVIBusinessException
(complete)
1
0,5
1
ParametrizedBusinessException
(complete)
2
0,5
2
GDServicesException
(complete)
4
0,5
3
ServerException
(complete)
132
0,75
16
PGException
(complete)
6
0,667
5
0,75
4
DESException
(complete)
135
0,667
13
0,667
2
0,75
9
SIPSCException
(complete)
27
0,75
9
ReportException
(complete)
5
0,667
2
SSNServiceException
(complete)
1
0,5
1
AFException
(complete)
1
0,5
1
InvalidNISSException
(complete)
14
0,75
4
0,75
14
GILConcurrencyException
(complete)
1
0,5
1
RSISystemException
(complete)
28
0,75
7
0,667
5
0,667
1
0,75
2
0,667
5
0,833
5
0,667
5
0,667
4
0,75
12
0,981
53
ADOPUserChoiceException
(complete)
1
0,5
1
0,667
5
RPCException
(complete)
1
0,5
1
GREJBConcurrencyException
(complete)
15
0,875
8
0,5
1
0,5
1
0,667
1
MoradaPortuguesaNotFoundException
(complete)
1
0,5
1
0,75
4
0,5
1
0,667
6
0,5
1
0,5
2
0,889
8
0,75
3
0,8
3
RSIException
(complete)
1
0,5
1
0,5
1
0,5
1
0,667
4
0,667
3
0,5
1
0,5
2
0,75
5
0,5
1
0,5
1
0,5
2
0,5
1
0,5
1
0,5
1
0,5
1
0,5
1
0,5
1
0,5
1
0,5
1
0,5
1
0,5
1
0,5
1
0,5
1
0,8
1
0,5
1
0,5
1
0,5
1
Fig.4.Spaghettimodelobtainedfromtheapplicationserverlogsusingtheheuristics
miner.
Usingthesequenceclusteringplug-inanditspreprocessingcapabilities,as
wellasthepossibilityofvisuallyadjustingtheclustermodelsaccordingtocertain
Healthcare
What is your
Favourite Italian Food?
48
UnderstandingSpaghettiModelswithSequenceClusteringforProM9
thoseexceptions.Figure4depictstheresultofafirstattempttoanalyzethe
applicationserverlogsusingtheheuristicsminer[4].
Exception
(complete)
187
EstabelecimentoNotFoundException
(complete)
187
0,991
152
GREJBPersistencyException
(complete)
179
0,909
159
PGWSException
(complete)
168
0,889
12
ITPTExternalServiceException
(complete)
183
0,944
162
SIPSCNoRecordsFoundException
(complete)
160
0,8
5
PessoaSingularNotFoundException
(complete)
138
0,667
3
BusinessLogicException
(complete)
183
0,75
4
SICCLException
(complete)
175
0,857
19
NaoExistemRegistosException
(complete)
143
0,833
6
RPCBusinessException
(complete)
38
0,75
3
SAFBusinessException
(complete)
115
0,8
68
GREJBBusinessException
(complete)
45
0,75
23
DESWSException
(complete)
14
0,667
14
NullPointerException
(complete)
104
0,8
91
ValidationException
(complete)
31
0,8
12
GILBusinessException
(complete)
14
0,5
6
GRServicesException
(complete)
7
0,667
3
CSIBusinessException
(complete)
14
0,5
6
ConcorrenciaException
(complete)
5
0,5
2
CSIPersistencyException
(complete)
3
0,5
2
0,857
34
ITPTServerException
(complete)
21
0,667
15
COOPException
(complete)
4
0,5
2
RSIValidationException
(complete)
25
0,667
18
BasicSystemException
(complete)
16
0,667
11
PesquisaAmbiguaException
(complete)
6
0,5
6
CPFBusinessException
(complete)
3
0,5
2
0,8
95
ADOPException
(complete)
6
0,5
5
AFBusinessException
(complete)
64
SIPSCRemoteBusinessException
(complete)
51
0,833
13
ConcurrentModificationException
(complete)
5
0,5
1
CDFBusinessException
(complete)
6
0,667
2
AssinaturaNaoIncluidaException
(complete)
1
0,5
1
SICCSException
(complete)
32
0,8
11
CartaoCidadaoException
(complete)
64
0,833
38
SOAPException
(complete)
22
0,667
14
TooManyRowsException
(complete)
112
0,667
18
SIPSCFatalException
(complete)
20
0,667
9
LimiteTemporalException
(complete)
4
0,5
2
0,8
28
SVIBusinessUserException
(complete)
18
0,75
12
GRConcurrencyException
(complete)
8
0,5
2
ContribuinteRegionalNotFoundException
(complete)
63
0,75
30
JDOFatalUserException
(complete)
124
0,947
49
0,667
5
SQLException
(complete)
9
0,667
7
IOException
(complete)
27
0,75
22
PessoaColectivaNotFoundException
(complete)
23
0,75
20
ServiceDelegateRemoteException
(complete)
3
0,5
2
0,5
5
PASException
(complete)
2
0,5
1
FileNotFoundException
(complete)
31
0,75
13
QgenMIParametrizedBusinessException
(complete)
1
0,5
1
ADOPMessageException
(complete)
3
0,5
2
LayoffException
(complete)
1
0,5
1
0,75
8
CMPException
(complete)
1
0,5
1
GREJBRemoteServiceException
(complete)
34
0,75
4
RSIPersistenceException
(complete)
24
0,75
4
CSIRemoteException
(complete)
3
0,5
1
SIPSCFatalRemoteCallException
(complete)
3
0,5
1
SIPSCDatabaseException
(complete)
1
0,5
1
BusinessException
(complete)
159
0,667
9
SVIBusinessException
(complete)
1
0,5
1
ParametrizedBusinessException
(complete)
2
0,5
2
GDServicesException
(complete)
4
0,5
3
ServerException
(complete)
132
0,75
16
PGException
(complete)
6
0,667
5
0,75
4
DESException
(complete)
135
0,667
13
0,667
2
0,75
9
SIPSCException
(complete)
27
0,75
9
ReportException
(complete)
5
0,667
2
SSNServiceException
(complete)
1
0,5
1
AFException
(complete)
1
0,5
1
InvalidNISSException
(complete)
14
0,75
4
0,75
14
GILConcurrencyException
(complete)
1
0,5
1
RSISystemException
(complete)
28
0,75
7
0,667
5
0,667
1
0,75
2
0,667
5
0,833
5
0,667
5
0,667
4
0,75
12
0,981
53
ADOPUserChoiceException
(complete)
1
0,5
1
0,667
5
RPCException
(complete)
1
0,5
1
GREJBConcurrencyException
(complete)
15
0,875
8
0,5
1
0,5
1
0,667
1
MoradaPortuguesaNotFoundException
(complete)
1
0,5
1
0,75
4
0,5
1
0,667
6
0,5
1
0,5
2
0,889
8
0,75
3
0,8
3
RSIException
(complete)
1
0,5
1
0,5
1
0,5
1
0,667
4
0,667
3
0,5
1
0,5
2
0,75
5
0,5
1
0,5
1
0,5
2
0,5
1
0,5
1
0,5
1
0,5
1
0,5
1
0,5
1
0,5
1
0,5
1
0,5
1
0,5
1
0,5
1
0,5
1
0,8
1
0,5
1
0,5
1
0,5
1
Fig.4.Spaghettimodelobtainedfromtheapplicationserverlogsusingtheheuristics
miner.
Usingthesequenceclusteringplug-inanditspreprocessingcapabilities,as
wellasthepossibilityofvisuallyadjustingtheclustermodelsaccordingtocertain
Healthcare
Our Goal
49
represents
Reality
Model
Towards Flexible BPM
• Flexibility by underspecification: 

Model left incomplete, then “completed” at run
time.

Example: YAWL.
• Flexibility by change: 

imperative, completely specified model that may
be modified at runtime.

Example: ADEPT.
50
Towards Flexible BPM
• Flexibility by deviation: 

imperative model that supports more possibilities at
runtime, deviating from what prescribed in the
model.

Example: FLOWer.
• Flexibility by design: 

the process modeling language directly supports
flexibility.

Example: Constraint-based modeling (Declare,
DCR Graphs).
51
Constraint-Based Modeling
52
Constraint-Based Modeling
Focus: whathas to be accomplished
• Explicit description of the relevant business constraints
• behavioral constraints, best practices, norms, rules, …
Openmodeling
• All behaviors are possible unless they are explicitly
forbidden
• Control-flow left implicit
53
Organizational Boundaries
54
Declare
55
Declare
56
Declare
• A declarative, constraint-based language for flexible
process modeling
• An execution engine for constraint-based processes

http://www.win.tue.nl/declare/
• Originally proposed by Pesic and van der Aalst
• Formalized by Pesic and van der Aaalst, and by _
• Two main abstractions: task, constraint
57
Constraints
• Much richer than the simple “precedence sequence
flow connector” of imperative languages
• Allow for:
• Presence/absence of tasks (do/not do … N times)
• Negative relationships (it is forbidden to…)
• Atemporal relationships (no order imposed)
• Temporal relationships, with different strengths
58
Flexible Shopper
59
Pick item
Close order Pay
Flexible Shopper
60
Pick item
Close order Pay
response
Constraint Features
Three dimensions:
• Type
• Temporal direction
• Strength
61
Constraint Types
Unary constraints (apply on a single task)
• Existence: you should/cannot do A (for a certain number of times)
Binary constraints (apply to two - or more - tasks)
• Choice: do A or B
• Relation: if A occurs, then B should also occur (when?)
• Negation: if A then B cannot occur 

(when?)
Binary constraints may branch to represent potential alternatives
62
Constraint Direction
• Applies to relation/negation constraints
• “If A occurs, then B should/cannot occur …”
• No direction: “… either before or after”
• Response: “… in the future”
• Precedence: “… in the past”
• Example: If close order, then pay in the future
63
Constraint Strength
• Applies to relation/negation constraints
• If A occurs, then B should/cannot occur
• Normal
• Alternate: A cannot occur again until B occurs
• Chain: Immediate constraint (applies to tasks occurring next to each other)
• Example:
• If close order, then pay in the future

vs
• If close order, then do not close order again until pay in the future
vs
• If close order, then the next task is to pay
64
Graphical Appearance
65
3.5 Usability of ConDec 65
Table 3.8. Basic visual constitutive elements of ConDec’s constraints
concept notation
existence constraints 0..N, M..*, K (a l´a UML)
choice
♦
/ (a l´a decision gateway in BP modeling notations)
binary constraints − (normal)
= (alternate)
≡ (chain)
source of binary constraints •
negation ∥
temporal ordering −−
succession representation response + precedence part
(e.g. •−− • = •−−− + −−− •)
ones. As attested by the case study presented in Sect. 3.4, a variety of natural
Existence Constraints
66
50 3 The ConDec Language
Table 3.1. ConDec existence constraints
name graphical meaning
absence(a)
0
a Activity a cannot be executed
absence(n+1,a)
0..n
a
Activity a can be executed at most n times, i.e., the
execution trace cannot contain n + 1 occurrences of a
existence(n,a)
n..∗
a Activity a must be executed at least n times
exactly(n,a)
n
a Activity a must be executed exactly n times
init(a)
init
a Activity a must be the first executed activity
1..∗
order item
On the contrary, an absenceN constraint could be used to state that at most
three payment attempts can be made by the customer:
Examples:
ec existence constraints
graphical meaning
0
a Activity a cannot be executed
0..n
a
Activity a can be executed at most n times, i.e., the
execution trace cannot contain n + 1 occurrences of a
n..∗
a Activity a must be executed at least n times
n
a Activity a must be executed exactly n times
init
a Activity a must be the first executed activity
1..∗
order item
, an absenceN constraint could be used to state that at most
absence(n+1,a)
0..n
a
Activity a can be executed at most n times, i
execution trace cannot contain n + 1 occurrenc
existence(n,a)
n..∗
a Activity a must be executed at least n times
exactly(n,a)
n
a Activity a must be executed exactly n times
init(a)
init
a Activity a must be the first executed activity
1..∗
order item
On the contrary, an absenceN constraint could be used to state that a
three payment attempts can be made by the customer:
0..3
pay
Choice Constraints
67
3.3 Constraints 51
Table 3.2. ConDec choice constraints
name graphical meaning
choice(n of m,[a1,...,am])
a1
am
a2
n of m
...
At least n distinct activities
among a1,. . . ,am must be exe-
cuted
ex choice(n of m,[a1,...,am])
a1
am
a2
n of m
...
Exactly n distinct activities
among a1,. . . ,am must be exe-
cuted
Note that the constraint supports an execution trace containing three submis-
sions of the paper (via e-mail and/or by using the web site), while it evaluates
a trace without submissions as noncompliant.
A 1 of 2-exclusive choice can be instead adopted to model the existence
between two alternatives that exclude each other. For example, it could be
used to state that, within an instance of the system, the customer commits
herself to cancel or successfully close the order, but not both:
Examples:
choice(n of m,[a1,...,am])
a1
am
a2
n of m
...
At least n distinct activitie
among a1,. . . ,am must be exe
cuted
x choice(n of m,[a1,...,am])
a1
am
a2
n of m
...
Exactly n distinct activitie
among a1,. . . ,am must be exe
cuted
ote that the constraint supports an execution trace containing three submis
ons of the paper (via e-mail and/or by using the web site), while it evaluate
trace without submissions as noncompliant.
A 1 of 2-exclusive choice can be instead adopted to model the existenc
etween two alternatives that exclude each other. For example, it could b
sed to state that, within an instance of the system, the customer commit
erself to cancel or successfully close the order, but not both:
cancel order −− −− close order
It is worth noting that choice constraints, together with the existence
68
name graphical meaning
resp existence([a], [b]) a •−−−− b
If a is executed, then b must be exe-
cuted before or after a
coexistence([a],[b]) a •−−−• b
Neither a nor b is executed, or they
are both executed
response([a],[b]) a •−−− b
If a is executed, then b must be exe-
cuted thereafter
precedence([a],[b]) a −−− • b
b can be executed only if a has been
previously executed
succession([a],[b]) a •−− • b
a and b must be executed in succes-
sion, i.e. b must follow a and a must
precede b
alt response([a],[b]) a •=== b
b is response of a and between every
two executions of a, b must be exe-
cuted at least once
alt precedence([a],[b]) a === • b
a is precedence of b and between ev-
ery two executions of b, a must be
executed at least once
alt succession([a],[b]) a •== • b
b is alternate response of a, and a is
alternate precedence of b
chain response([a],[b]) a •=−=−=− b
If a is executed, then b must be exe-
cuted next (immediately after a)
chain precedence([a],[b]) a =−=−=− • b
If b is executed, then a must have
been executed immediately before b
chain succession([a],[b]) a •=−=− • b
a and b must be executed in sequence
(next to each other)
RelationConstraints
69
NegationConstraints
Table 3.4. ConDec negation constraints
name graphical meaning
resp absence([a],[b]) a •−−−−∥ b
If a is executed, then b can never
be executed
not coexistence([a],[b]) a •−−−•∥ b a and b exclude each other
neg response([a],[b]) a •−−−∥ b b cannot be executed after a
neg precedence([a],[b]) a −−− •∥ b a cannot be executed before b
neg succession([a],[b]) a •−− •∥ b
a and b cannot be executed in
succession
neg alt response([a],[b]) a •===∥ b
b cannot be executed between
any two occurrences of a
neg alt precedence([a],[b]) a === •∥ b
a cannot be executed between
any two bs
neg alt succession([a],[b]) a •== •∥ b
b cannot be executed between
any two as and viceversa
neg chain response([a],[b]) a •=−=−=−∥ b b cannot be executed next to a
neg chain precedence([a],[b]) a =−=−=− •∥ b
a cannot be executed immedi-
ately before b
neg chain succession([a],[b]) a •=−=− •∥ b
a and b cannot be executed in
sequence
Choreography Example
• An order can be finalized at most once
• Once an order is finalized, it must be confirmed or rejected
• A confirmed order may be rejected later on (due to “late”
problems), but not vice-versa: a reject cannot be reverted.
• An order can be confirmed only if it shipped before.
• An order may be rejected autonomously by the seller.
However, if the warehouse notifies the seller of a shipment
issue, then the seller has to reject the order.
• The warehouse decision is firm: “Ship” and “Notify
shipment issue” are mutually exclusive.
70
Modeling in Declare
Finalize order
Confirm
order
Reject
order
Ship
Notify
shipment issue
71
0..1
Modeling in Declare
Finalize order
Confirm
order
Reject
order
Ship
Notify
shipment issue
72
An order can be
finalized at most once
0..1
Modeling in Declare
Finalize order
Confirm
order
Reject
order
Ship
Notify
shipment issue
73
Once an order is finalized, it must
be confirmed or rejected
0..1
Modeling in Declare
Finalize order
Confirm
order
Reject
order
Ship
Notify
shipment issue
74
A confirmed order may be rejected
later on, but not vice-versa
0..1
Modeling in Declare
Finalize order
Confirm
order
Reject
order
Ship
Notify
shipment issue
75
if the warehouse notifies the seller of a shipment
issue, then the seller has to reject the order
An order can be confirmed only if
it shipped before
0..1
Modeling in Declare
Finalize order
Confirm
order
Reject
order
Ship
Notify
shipment issue
76
Mutually
exclusive
Linear temporal logic over finite traces (LTLf): propositional
logic enriched with temporal operators
• Models: words over the alphabet of tasks -> exactly one
task at a time!
• Constraints: formulae over tasks
N.B.: there is a huge difference between “standard” LTL and LTLf (not
discussed here)
Constraint Semantics
77
3.6 Linear Temporal Logic 69
Table 3.9. LTL temporal operators
op. name meaning intuition
current state
⃝φ (Next time) φ will hold in the next state
♦φ (Eventually) φ will hold sometimes in the future
φ (Globally) φ will always hold in the future
ψUφ (Until) φ will hold in a future moment, ψ
will always hold until that moment
• atomic propositions, i.e., events, together with the two special constants
true and false;
• classical propositional connectives, i.e., ¬, ∧, ∧ and ⇒;
Formalization Example
78
Moored
Under way
using engine
Under way
sailing
constrained by
her draught
Formalization Example
79
Moored
Under way
using engine
Under way
sailing
constrained by
her draught
¬⇤c _ ¬c Us
¬(⌃e ^ ⌃s)
Model formula: conjunction of all constraint formulae
⇤(m ! ⌃e)
Correctness of Models
• A Declare model is correct if there exists at least a
finite trace satisfying all its constraints
• A Declare model is correct if its LTLf formula is
satisfiable
• A correct model may still contain dead activities:
activities that can never be executed
• Can be reduced to model correctness: just add
1..* on top of the activity to be checked!
80
1..*
Example 1
81
a c
b
1..*
Example 1
82
a c
b
INCORRECT
0..1
Example 2
83
a c
b
0..1
Example 2
84
a c
b
dead activity
0..1
Example 2
85
a c
b
dead activity
1..* 0..1
a c
b
INCORRECT!
0..1
Example 2
86
a c
b
Example 3
87
1..*
a b
Example 3
88
1..*
a b
INCORRECT
(finite traces)
Process Responsibilities
• History recognition: given the history of a running
instance, compute the current state (or reject)
• Todo list: given the current state, tell 

which tasks can(not) be executed next

(including possibility of termination)

• Update: given a state and a task,

determine the new state
S
A
B
C
S
SnewS
89
RV-LTL Truth Values
Refined analysis of the “truth value” of a constraint.
Consider a partial trace t, and a constraint C
• C is permanently satisfied if t satisfies C and no matter
how t is extended, C will stay satisfied
• C is temporarily satisfied if t satisfies C but there is a
continuation of t that violates C
• C is temporarily violated if t violates C but there is a
continuation that leads to satisfy C
• C is permanently violated if t violates C and no matter
how t is extended, C will stay violated
90
Process Execution in
Declare
• Start with the empty trace
• Loop
• Consider the history so far, assuming it is correctly recognized
• Block all activities that would lead to a permanent violation 

(of what? Constraint? Model?)
• Highlight constraints that are permanently satisfied
• Highlight constraints that are temporarily violated
• If there is no temporarily violated constraint: allow for
completing the process
• Wait until an allowed activity is executed
• Update the history with the executed activity
91
At the beginning is so
if the model is correct!
Execution
92
0..1
Finalize order
Confirm
order
Reject
order
Ship
Notify
shipment issue
Initial Situation
93
0..1
Finalize order
Confirm
order
Reject
order
Ship
Notify
shipment issue
May complete now…
“Finalize Order”
94
0..1
Finalize order
Confirm
order
Reject
order
Ship
Notify
shipment issue
“Notify Shipment Issue”
95
0..1
Finalize order
Confirm
order
Reject
order
Ship
Notify
shipment issue
“Reject Order”
96
0..1
Finalize order
Confirm
order
Reject
order
Ship
Notify
shipment issue
May complete now…
Another Execution
97
0..1
Finalize order
Confirm
order
Reject
order
Ship
Notify
shipment issue
Initial Situation
98
0..1
Finalize order
Confirm
order
Reject
order
Ship
Notify
shipment issue
May complete now…
“Finalize Order”
99
0..1
Finalize order
Confirm
order
Reject
order
Ship
Notify
shipment issue
“Ship”
100
0..1
Finalize order
Confirm
order
Reject
order
Ship
Notify
shipment issue
“Confirm Order”
101
0..1
Finalize order
Confirm
order
Reject
order
Ship
Notify
shipment issue
May complete now…
Important Question
• To “block” activities, shall we just consider
constraints separately?
102
Hidden Dependencies
103
Ship
Notify
shipment issue
Pick package Insert material Close package
Initial State
104
Ship
Notify
shipment issue
Pick package Insert material Close package
May complete now…
Initial State
105
Ship
Notify
shipment issue
Pick package Insert material Close package
May complete now…
What if I executed this?
“Notify Shipment Issue”
106
Ship
Notify
shipment issue
Pick package Insert material Close package
May complete now…
!!!
How to Implement This?
Automata to the Rescue!
107
From Formulae to Automata
• Observation: Declare constraints are formalized using
LTL over finite traces (LTLf)
• LTLf corresponds to the star-free fragment of regular
expressions
• Intimate connection with finite-state automata
108
Declare 2 DFA
'
LTLf NFA

nondeterministic
DFA

deterministic
LTLf2aut determin.
109
Declare 2 DFA
LTLf NFA

nondeterministic
DFA

deterministic
LTLf2aut determin.
A process!
• allowed tasks: alphabet, task: symbol, trace: word
• history recognition —> word prefix recognition
• todo list —> return next symbols
• update —> transition
110
'
Local Automata
• For each constraint, we take its LTLf formula, and
compute the corresponding DFA
• This DFA accepts all and only the execution traces
that lead to satisfy (pemanently or temporarily) the
constraint
111
Local Automata: Example
112
00 1
m
e
not m not e
moored
under way
using engine
under way
sailing
constrained by
her draught
Local Automata: Example
113
0
s
c
not {c,s}
true1
0 true
moored
under way
using engine
under way
sailing
constrained by
her draught
Local Automata: Example
114
moored
under way
using engine
under way
sailing
constrained by
her draught
s
e
not s
true00
not {s,e}
1
2
3
e
s
not e
1
2
Coloring local automata
We color the states of each local automaton with their
corresponding RV-LTL truth values
• State permanently satisfied: it is final and cannot
reach a non-final state
• State temporarily satisfied: it is final but can reach a
non-final state
• State permanently violated: it is non-final and cannot
reach a final state
• State temporarily violated: it is non-final but can
reach a final state
115
Local Automata: Example
116
moored
under way
using engine
under way
sailing
constrained by
her draught
0
s
c
not {c,s}
true1
0 true
00 1
m
e
not m not e
s
e
not s
true00
not {s,e}
1
2
3
e
s
not e
1
2
Local Automata: Example
117
moored
under way
using engine
under way
sailing
constrained by
her draught
0
s
c
not {c,s}
true1
0 true
00 1
m
e
not m not e
Local Automata: Example
118
moored
under way
using engine
under way
sailing
constrained by
her draught
0
s
c
not {c,s}
true1
0 true
00 1
m
e
not m not e
s
e
not s
true00
not {s,e}
1
2
3
e
s
not e
1
2
Local Automata: Example
119
moored
under way
using engine
under way
sailing
constrained by
her draught
0
s
c
not {c,s}
true1
0 true
00 1
m
e
not m not e
s
e
not s
true00
not {s,e}
1
2
3
e
s
not e
1
2
Global Automata
What about hidden dependencies?
• We have to consider the interplay between constraints
• To do that: compute the “global automaton” for the
entire model. Two possibilities:
• Take the “conjunction formula” of all constraints and
get the DFA
• Compute the intersection of the local DFAs
120
Can you Digest Spaghetti?
121
Declare 2 DFA: Complexity
'
LTLf NFA

nondeterministic
DFA

deterministic
LTLf2aut determin.
exponential

blow-up
exponential

blow-up
122
123
Example
124
Example
Automaton: Design Time
Correctness of a Declare model reduced to
nonemptiness of the corresponding automaton
1. Obtain the LTLf formula for the model
2. Compute the corresponding DFA
3. Check whether the DFA is (non)empty

(if nonempty, there is at least one trace that
is accepted)
125
Runtime: Global Automaton
By computing the global DFA as the intersection of the
local colored DFAs, we can get a global DFA that retains
all “local colors”, and use it directly to manage the
execution!
126
Conclusion
• Turbulent, unpredictable, knowledge-intensive environments
demands flexibility
• Constraint-based approaches provide a declarative way to
capture flexible processes
• Declare does this by exploiting temporal logics over finite
traces: a compact way to represent spaghetti processes
• Flexible processes demand reasoning support for their
understanding and correct execution
• The automata-theoretic characterization of temporal logics gives
a “correct by design” computation mechanism for: model
verification, execution, monitoring, discovery, conformance
checking!
127
And the Story Continues…
128
Conformance Checking Using Object-Centric Behavioral Constraints 21
register
applicationperson position
1
employee
1
1
1
1..*
0..1
r1 r2
r3
11..*
1
1
r4
open pos.
close pos.
selecthire
apply
check
reference
interview
1
1
1
0..2
1
1
1
1
1
1
1
0..5
1
1
c1
c2
c3
c4
c5
c6
c7 c8
Fig. 13. An OCBC model modeling a hiring process.
Object-Centric Declare (joint work with Wil van der Aalst and Guangming Li)
References
Declare and its formalizations
• M. Pesic and W. van der Aalst, A Declarative Approach for Flexible
Business Processes Management, in Proceedings of the Business Process
Management Workshops. Springer-Verlag, 2006, vol. 4103, pp. 169-180.
• M. Montali, M. Pesic, W. M. P. van der Aalst, F. Chesani, P. Mello, and S.
Storari, Declarative specification and verification of service
choreographies, ACM Trans. Web, vol. 4, pp. 3:1–3:62, 2010.
• M. Montali. Specification and Verification of Declarative Open Interaction
Models: a Logic- Based Approach, vol. 56 of Lecture Notes in Business
Information Processing. Springer-Verlag, 2010. ISBN: 978-3-642-14537-7.
• M. Westergaard, Better Algorithms for Analyzing and Enacting
Declarative Workflow Languages Using LTL, in Proceedings of the 9th
International Conference on Business Process Management, Springer-
Verlag, 2011, pp. 83-98.
129
References
Declare Execution Environment
• M. Pesic, H. Schonenberg, and W. M. P. van der Aalst, DECLARE: Full
Support for Loosely-Structured Processes, in Proceedings of the 11th
IEEE International Enterprise Distributed Object Computing Conference,
Washington, DC, USA: IEEE Computer Society, 2007, pp. 287–300.
• M. Pesic, M. Schonenberg, N. Sidorova, and W. van der Aalst, Constraint-
Based Workflow Models: Change Made Easy, in On the Move to
Meaningful Internet Systems 2007: CoopIS, DOA, ODBASE, GADA, and
IS, R. Meersman and Z. Tari, Ed., Springer Berlin / Heidelberg, 2007, vol.
4803, pp. 77-94.
• M. Pesic, H. Schonenberg, and W. Aalst, The Declare Service, in Modern
Business Process Automation, Springer-Verlag, 2010, pp. 327-343.
• M. Westergaard, F. M. Maggi, Declare: A Tool Suite for Declarative
Workflow Modeling and Enactment, BPM (Demos) 2011.
130
References
Monitoring Declare constraints
• F. M. Maggi, M. Montali, M. Westergaard, and W. M. P. van der Aalst, Monitoring
Business Constraints with Linear Temporal Logic: An Approach Based on
Colored Automata, in Proceedings of the 9th International Conference on
Business Process Management, Springer-Verlag, 2011, pp. 132-147.
• F. M. Maggi, M. Westergaard, M. Montali, W. M. P. van der Aalst,

Runtime Verification of LTL-Based Declarative Process Models.: Proceedings
of the 2th International Conference on Runtime Verification, Springer-Verlag, 2011,
pp. 131-146.
• M. Montali, F. M. Maggi, F. Chesani, P. Mello, W. M. P. van der Aalst,

Monitoring business constraints with the event calculus. ACM Trans. on
Intelligent Systems and Technology 5(1): 17, 2013.
• G. De Giacomo, R. De Masellis, M. Grasso, F. M. Maggi, M. Montali, 

Monitoring Business Metaconstraints Based on LTL and LDL for Finite Traces,
Proceedings of the 12th International Conference on Business Process
Management, Springer-Verlag, 2014, pp. 1-17.
131
References
Discovering Declare constraints
• F. Chesani, E. Lamma, P. Mello, M. Montali, F. Riguzzi, S. Storari, Exploiting Inductive Logic Programming Techniques
for Declarative Process Mining. Trans. Petri Nets and Other Models of Concurrency 2: 278-295, 2009.
• F. Maria Maggi, A. J. Mooij, W. M. P. van der Aalst, User-guided discovery of declarative process models. In
Proceedings of the IEEE Symposium on Computational Intelligence and Data Mining, Springer-Verlag, 2011, pp. 192-199.
• F. M. Maggi, R. P. J. Chandra Bose, W. M. P. van der Aalst, Efficient Discovery of Understandable Declarative Process
Models from Event Logs. In Proceedings of the 24th International Conference on Advanced Information Systems
Engineering, Springer-Verlag, 2012, pp. 270-285.
• F. M. Maggi, M. Dumas, L. García-Bañuelos, M. Montali, Discovering Data-Aware Declarative Process Models from
Event Logs. In Proceedings of the 11th International Conference on Business Process Management, Springer-Verlag,
2013, pp. 81-96.
• F. M. Maggi, Declarative Process Mining with the Declare Component of ProM. BPM (Demos) 2013.
• C. Di Ciccio, M- Mecella, On the Discovery of Declarative Control Flows for Artful Processes. ACM Trans.
Management Inf. Syst. 5(4): 24:1-24:37, 2015.
• C. Di Ciccio, F. M. Maggi, M. Montali, J. Mendling, Ensuring Model Consistency in Declarative Process Discovery. In
Proceedings of the 13th International Conference on Business Process Management, Springer-Verlag, 2015, pp. 144-159.
• C. Di Ciccio, F. M. Maggi, M. Montali, J. Mendling, Semantical Vacuity Detection in Declarative Process Mining. n
Proceedings of the 15th International Conference on Business Process Management, Springer-Verlag, 2016, pp. 158-175.
132

Montali: Declarative, Constraint-Based Business Process Management - Seville 2016

  • 1.
    Declarative, Constraint-Based BPM Marco Montali FreeUniversity of Bozen-Bolzano ack to Maja Pesic, Wil van der Aalst, Fabrizio Maggi, Giuseppe De Giacomo, Riccardo de Masellis 1
  • 2.
    Disclaimer for thisTalk Process = Control-flow (but the story is much more interesting than that…) 2
  • 3.
  • 4.
  • 5.
    Types of Processes Notall business processes are the same • Even within one organization, business processes can be very different in terms of their essential properties. • Business processes can be characterized through three dimensions: • complexity • predictability • repetitiveness 5
  • 6.
    Complexity Degree of difficultyin collaboration, coordination, and decision making • Low complexity: exchanging personal email messages and handling travel requests • High complexity: handling medical treatments 6
  • 7.
    Predictability How easy itis to determine in advance the way the process will be executed. • Low predictability: exchanging personal email messages. • High predictability: handling travel requests. 7
  • 8.
    Repetitiveness Frequency of processexecution. • A business process that is executed once per year has a lower degree of repetitiveness than a process executed twice a day. • Low repetitiveness: disaster handling. • High repetitiveness: exchanging personal email messages. 8
  • 9.
    Classifying Processes Prepare coffee Produceshoes Register birth Design shoes Disaster recovery Celebrate opening of A.Y. Win slot machine 9
  • 10.
    Classifying Processes Prepare coffeeProduce shoesRegister birth Design shoes Disaster recovery Win slot machine 10 Celebrate opening of A.Y.
  • 11.
    BPM Systems BPM systemssupport collaboration, coordination and decision making in business processes. • Groupware systems support human collaboration and co-decision. • Workflow management systems explicitly control ordering, coordination and execution of activities with little human intervention. 11
  • 12.
    BPMS and DecisionMaking 12 • Ordering and coordination of activities not automated. • Users control the ordering and coordination of activities “on the fly” while executing the business process. • Humans merely influence the execution of business processes by entering necessary data.
  • 13.
    BPMS and 
 Typesof Processes 13
  • 14.
  • 15.
    Influence of theEnvironment The degree of turbulence of the environment influences the predictability of business processes and the nature of decision making. 15
  • 16.
    Influence of theEnvironment The degree of turbulence of the environment influences the predictability of business processes and the nature of decision making. ‘optimal’ 16
  • 17.
    Combining Social and TechnicalAspects • Organizations can significantly benefit from using the best that both humans and technology have to offer. • Instead of being replaceable, humans and machines should complement each other. 17
  • 18.
  • 19.
    Flexibility vs Support Flexibility:degree to which users can make local decisions about how to execute processes. Support: degree to which a system makes centralized decisions about how to execute processes. Universe of Traces Compliant Traces Flexibility19
  • 20.
  • 21.
    The Issue ofFlexibility 21
  • 22.
  • 23.
    Trends in BPM modeling •Highly-variable BPs • Metaphor: rules/constraints Dec t i lar a ev Imperative modeling • Traditional repetitive BPs • Metaphor: flow-chart 23
  • 24.
  • 25.
  • 26.
    Imperative Modeling Focus: howthingsmust be done • Explicit description of the process control-flow Closedmodeling • All that is not explicitly modeled is forbidden • Exceptions/uncommon behaviors have to be explicitly enumerated at design time 26
  • 27.
    BPMN Receive order Check availability Article available? Ship article Financial settlement yes Procurement no Payment received Inform customer LatedeliveryUndeliverable Customer informed Inform customer Article removed Remove article from catalogue 27
  • 28.
    BPMN Receive order Check availability Article available? Ship article Financial settlement yes Procurement no Payment received Inform customer LatedeliveryUndeliverable Customer informed Inform customer Article removed Remove article from catalogue Input Output 28
  • 29.
    BPMN Receive order Check availability Article available? Ship article Financial settlement yes Procurement no Payment received Inform customer LatedeliveryUndeliverable Customer informed Inform customer Article removed Remove article from catalogue Input Output 29
  • 30.
  • 31.
    Example: Rigid Shopping •Tasks: 𝚺 = {pick item, close order, pay} • A customer starts the process by picking one or more items. She then decides to quit or close the order. In the latter case, she has to pay for the order. 31
  • 32.
    Questions • Tasks: 𝚺= {pick item, close order, pay} • A customer starts the process by picking one or more items. She then decides to quit or close the order. In the latter case, she has to pay for the order. • Which traces are accepted? • <> (empty trace) • <i,i,i> • <i,i,i,c,p> • <i,i,i,c,p,p> • <i,i,i,p,c> • <i,c,p,i,i,c,p> 32
  • 33.
    Questions • Tasks: 𝚺= {pick item, close order, pay} • A customer starts the process by picking one or more items. She then decides to quit or close the order. In the latter case, she has to pay for the order. • Which traces are accepted? • <> (empty trace) • <i,i,i> • <i,i,i,c,p> • <i,i,i,c,p,p> • <i,i,i,p,c> • <i,c,p,i,i,c,p> 33
  • 34.
    Questions • Can youmodel this process in BPMN? How difficult is it? A customer starts the process by picking one or more items. She then decides to quit or close the order. In the latter case, she has to pay for the order. 34
  • 35.
    Questions • Can youmodel this process in BPMN? How difficult is it? pick item close order pay quit order paid 35
  • 36.
    Example: Flexible Shopping •Tasks: 𝚺 = {pick item, close order, pay} • A customer may pick items, close several orders, and pay one or more orders at once. • She may even close an empty order and pay for it, or pay multiple times (but this will result in a no-op) • Business constraint: whenever you close an order, eventually you have to pay. 36
  • 37.
    Questions • Tasks: 𝚺= {pick item, close order, pay} • Business constraint: whenever you close an order, eventually you have to pay. • Which traces are accepted? • <> (empty trace) • <i,i,i> • <i,i,i,c,p> • <i,i,i,c,p,p> • <i,i,i,p,c> • <i,c,p,i,i,c,p> 37
  • 38.
    Questions • Tasks: 𝚺= {pick item, close order, pay} • Business constraint: whenever you close an order, eventually you have to pay. • Which traces are accepted? • <> (empty trace) • <i,i,i> • <i,i,i,c,p> • <i,i,i,c,p,p> • <i,i,i,p,c> • <i,c,p,i,i,c,p> 38
  • 39.
    Questions • Can youmodel this process in BPMN? How difficult is it? You may pick items, close and pay an order.
 Whenever you close an order, eventually you have to pay. 39
  • 40.
    Questions • Can youmodel this process in BPMN? How difficult is it? 40 pick item close order pay quit order paid
  • 41.
    Questions • Can youmodel this process in BPMN? How difficult is it? 41 pick item close order pay quit order paid simple, correct, but not general enough!
  • 42.
    Questions • Can youmodel this process in BPMN? How difficult is it? 42 pick item close order pay pick item pay
  • 43.
    Questions • Can youmodel this process in BPMN? How difficult is it? 43 pick item close order pay pick item pay correct, general, but unreadable!
  • 44.
    Choreography Example • Anorder can be finalized at mosto once • Once an order is finalized, it must be confirmed or rejected • A confirmed order may be rejected later on (due to “late” problems), but not vice-versa: a reject cannot be reverted. • An order can be confirmed only if it shipped before. • An order may be rejected autonomously by the seller. However, if the warehouse notifies the seller of a shipment issue, then the seller has to reject the order. • The warehouse decision is firm: “Ship” and “Notify shipment issue” are mutually exclusive. 44
  • 45.
    What is your FavouriteItalian Food? 45 Order-to-delivery
  • 46.
    What is your FavouriteItalian Food? 46 Order-to-delivery
  • 47.
    What is your FavouriteItalian Food? 47 UnderstandingSpaghettiModelswithSequenceClusteringforProM9 thoseexceptions.Figure4depictstheresultofafirstattempttoanalyzethe applicationserverlogsusingtheheuristicsminer[4]. Exception (complete) 187 EstabelecimentoNotFoundException (complete) 187 0,991 152 GREJBPersistencyException (complete) 179 0,909 159 PGWSException (complete) 168 0,889 12 ITPTExternalServiceException (complete) 183 0,944 162 SIPSCNoRecordsFoundException (complete) 160 0,8 5 PessoaSingularNotFoundException (complete) 138 0,667 3 BusinessLogicException (complete) 183 0,75 4 SICCLException (complete) 175 0,857 19 NaoExistemRegistosException (complete) 143 0,833 6 RPCBusinessException (complete) 38 0,75 3 SAFBusinessException (complete) 115 0,8 68 GREJBBusinessException (complete) 45 0,75 23 DESWSException (complete) 14 0,667 14 NullPointerException (complete) 104 0,8 91 ValidationException (complete) 31 0,8 12 GILBusinessException (complete) 14 0,5 6 GRServicesException (complete) 7 0,667 3 CSIBusinessException (complete) 14 0,5 6 ConcorrenciaException (complete) 5 0,5 2 CSIPersistencyException (complete) 3 0,5 2 0,857 34 ITPTServerException (complete) 21 0,667 15 COOPException (complete) 4 0,5 2 RSIValidationException (complete) 25 0,667 18 BasicSystemException (complete) 16 0,667 11 PesquisaAmbiguaException (complete) 6 0,5 6 CPFBusinessException (complete) 3 0,5 2 0,8 95 ADOPException (complete) 6 0,5 5 AFBusinessException (complete) 64 SIPSCRemoteBusinessException (complete) 51 0,833 13 ConcurrentModificationException (complete) 5 0,5 1 CDFBusinessException (complete) 6 0,667 2 AssinaturaNaoIncluidaException (complete) 1 0,5 1 SICCSException (complete) 32 0,8 11 CartaoCidadaoException (complete) 64 0,833 38 SOAPException (complete) 22 0,667 14 TooManyRowsException (complete) 112 0,667 18 SIPSCFatalException (complete) 20 0,667 9 LimiteTemporalException (complete) 4 0,5 2 0,8 28 SVIBusinessUserException (complete) 18 0,75 12 GRConcurrencyException (complete) 8 0,5 2 ContribuinteRegionalNotFoundException (complete) 63 0,75 30 JDOFatalUserException (complete) 124 0,947 49 0,667 5 SQLException (complete) 9 0,667 7 IOException (complete) 27 0,75 22 PessoaColectivaNotFoundException (complete) 23 0,75 20 ServiceDelegateRemoteException (complete) 3 0,5 2 0,5 5 PASException (complete) 2 0,5 1 FileNotFoundException (complete) 31 0,75 13 QgenMIParametrizedBusinessException (complete) 1 0,5 1 ADOPMessageException (complete) 3 0,5 2 LayoffException (complete) 1 0,5 1 0,75 8 CMPException (complete) 1 0,5 1 GREJBRemoteServiceException (complete) 34 0,75 4 RSIPersistenceException (complete) 24 0,75 4 CSIRemoteException (complete) 3 0,5 1 SIPSCFatalRemoteCallException (complete) 3 0,5 1 SIPSCDatabaseException (complete) 1 0,5 1 BusinessException (complete) 159 0,667 9 SVIBusinessException (complete) 1 0,5 1 ParametrizedBusinessException (complete) 2 0,5 2 GDServicesException (complete) 4 0,5 3 ServerException (complete) 132 0,75 16 PGException (complete) 6 0,667 5 0,75 4 DESException (complete) 135 0,667 13 0,667 2 0,75 9 SIPSCException (complete) 27 0,75 9 ReportException (complete) 5 0,667 2 SSNServiceException (complete) 1 0,5 1 AFException (complete) 1 0,5 1 InvalidNISSException (complete) 14 0,75 4 0,75 14 GILConcurrencyException (complete) 1 0,5 1 RSISystemException (complete) 28 0,75 7 0,667 5 0,667 1 0,75 2 0,667 5 0,833 5 0,667 5 0,667 4 0,75 12 0,981 53 ADOPUserChoiceException (complete) 1 0,5 1 0,667 5 RPCException (complete) 1 0,5 1 GREJBConcurrencyException (complete) 15 0,875 8 0,5 1 0,5 1 0,667 1 MoradaPortuguesaNotFoundException (complete) 1 0,5 1 0,75 4 0,5 1 0,667 6 0,5 1 0,5 2 0,889 8 0,75 3 0,8 3 RSIException (complete) 1 0,5 1 0,5 1 0,5 1 0,667 4 0,667 3 0,5 1 0,5 2 0,75 5 0,5 1 0,5 1 0,5 2 0,5 1 0,5 1 0,5 1 0,5 1 0,5 1 0,5 1 0,5 1 0,5 1 0,5 1 0,5 1 0,5 1 0,5 1 0,8 1 0,5 1 0,5 1 0,5 1 Fig.4.Spaghettimodelobtainedfromtheapplicationserverlogsusingtheheuristics miner. Usingthesequenceclusteringplug-inanditspreprocessingcapabilities,as wellasthepossibilityofvisuallyadjustingtheclustermodelsaccordingtocertain Healthcare
  • 48.
    What is your FavouriteItalian Food? 48 UnderstandingSpaghettiModelswithSequenceClusteringforProM9 thoseexceptions.Figure4depictstheresultofafirstattempttoanalyzethe applicationserverlogsusingtheheuristicsminer[4]. Exception (complete) 187 EstabelecimentoNotFoundException (complete) 187 0,991 152 GREJBPersistencyException (complete) 179 0,909 159 PGWSException (complete) 168 0,889 12 ITPTExternalServiceException (complete) 183 0,944 162 SIPSCNoRecordsFoundException (complete) 160 0,8 5 PessoaSingularNotFoundException (complete) 138 0,667 3 BusinessLogicException (complete) 183 0,75 4 SICCLException (complete) 175 0,857 19 NaoExistemRegistosException (complete) 143 0,833 6 RPCBusinessException (complete) 38 0,75 3 SAFBusinessException (complete) 115 0,8 68 GREJBBusinessException (complete) 45 0,75 23 DESWSException (complete) 14 0,667 14 NullPointerException (complete) 104 0,8 91 ValidationException (complete) 31 0,8 12 GILBusinessException (complete) 14 0,5 6 GRServicesException (complete) 7 0,667 3 CSIBusinessException (complete) 14 0,5 6 ConcorrenciaException (complete) 5 0,5 2 CSIPersistencyException (complete) 3 0,5 2 0,857 34 ITPTServerException (complete) 21 0,667 15 COOPException (complete) 4 0,5 2 RSIValidationException (complete) 25 0,667 18 BasicSystemException (complete) 16 0,667 11 PesquisaAmbiguaException (complete) 6 0,5 6 CPFBusinessException (complete) 3 0,5 2 0,8 95 ADOPException (complete) 6 0,5 5 AFBusinessException (complete) 64 SIPSCRemoteBusinessException (complete) 51 0,833 13 ConcurrentModificationException (complete) 5 0,5 1 CDFBusinessException (complete) 6 0,667 2 AssinaturaNaoIncluidaException (complete) 1 0,5 1 SICCSException (complete) 32 0,8 11 CartaoCidadaoException (complete) 64 0,833 38 SOAPException (complete) 22 0,667 14 TooManyRowsException (complete) 112 0,667 18 SIPSCFatalException (complete) 20 0,667 9 LimiteTemporalException (complete) 4 0,5 2 0,8 28 SVIBusinessUserException (complete) 18 0,75 12 GRConcurrencyException (complete) 8 0,5 2 ContribuinteRegionalNotFoundException (complete) 63 0,75 30 JDOFatalUserException (complete) 124 0,947 49 0,667 5 SQLException (complete) 9 0,667 7 IOException (complete) 27 0,75 22 PessoaColectivaNotFoundException (complete) 23 0,75 20 ServiceDelegateRemoteException (complete) 3 0,5 2 0,5 5 PASException (complete) 2 0,5 1 FileNotFoundException (complete) 31 0,75 13 QgenMIParametrizedBusinessException (complete) 1 0,5 1 ADOPMessageException (complete) 3 0,5 2 LayoffException (complete) 1 0,5 1 0,75 8 CMPException (complete) 1 0,5 1 GREJBRemoteServiceException (complete) 34 0,75 4 RSIPersistenceException (complete) 24 0,75 4 CSIRemoteException (complete) 3 0,5 1 SIPSCFatalRemoteCallException (complete) 3 0,5 1 SIPSCDatabaseException (complete) 1 0,5 1 BusinessException (complete) 159 0,667 9 SVIBusinessException (complete) 1 0,5 1 ParametrizedBusinessException (complete) 2 0,5 2 GDServicesException (complete) 4 0,5 3 ServerException (complete) 132 0,75 16 PGException (complete) 6 0,667 5 0,75 4 DESException (complete) 135 0,667 13 0,667 2 0,75 9 SIPSCException (complete) 27 0,75 9 ReportException (complete) 5 0,667 2 SSNServiceException (complete) 1 0,5 1 AFException (complete) 1 0,5 1 InvalidNISSException (complete) 14 0,75 4 0,75 14 GILConcurrencyException (complete) 1 0,5 1 RSISystemException (complete) 28 0,75 7 0,667 5 0,667 1 0,75 2 0,667 5 0,833 5 0,667 5 0,667 4 0,75 12 0,981 53 ADOPUserChoiceException (complete) 1 0,5 1 0,667 5 RPCException (complete) 1 0,5 1 GREJBConcurrencyException (complete) 15 0,875 8 0,5 1 0,5 1 0,667 1 MoradaPortuguesaNotFoundException (complete) 1 0,5 1 0,75 4 0,5 1 0,667 6 0,5 1 0,5 2 0,889 8 0,75 3 0,8 3 RSIException (complete) 1 0,5 1 0,5 1 0,5 1 0,667 4 0,667 3 0,5 1 0,5 2 0,75 5 0,5 1 0,5 1 0,5 2 0,5 1 0,5 1 0,5 1 0,5 1 0,5 1 0,5 1 0,5 1 0,5 1 0,5 1 0,5 1 0,5 1 0,5 1 0,8 1 0,5 1 0,5 1 0,5 1 Fig.4.Spaghettimodelobtainedfromtheapplicationserverlogsusingtheheuristics miner. Usingthesequenceclusteringplug-inanditspreprocessingcapabilities,as wellasthepossibilityofvisuallyadjustingtheclustermodelsaccordingtocertain Healthcare
  • 49.
  • 50.
    Towards Flexible BPM •Flexibility by underspecification: 
 Model left incomplete, then “completed” at run time.
 Example: YAWL. • Flexibility by change: 
 imperative, completely specified model that may be modified at runtime.
 Example: ADEPT. 50
  • 51.
    Towards Flexible BPM •Flexibility by deviation: 
 imperative model that supports more possibilities at runtime, deviating from what prescribed in the model.
 Example: FLOWer. • Flexibility by design: 
 the process modeling language directly supports flexibility.
 Example: Constraint-based modeling (Declare, DCR Graphs). 51
  • 52.
  • 53.
    Constraint-Based Modeling Focus: whathasto be accomplished • Explicit description of the relevant business constraints • behavioral constraints, best practices, norms, rules, … Openmodeling • All behaviors are possible unless they are explicitly forbidden • Control-flow left implicit 53
  • 54.
  • 55.
  • 56.
  • 57.
    Declare • A declarative,constraint-based language for flexible process modeling • An execution engine for constraint-based processes
 http://www.win.tue.nl/declare/ • Originally proposed by Pesic and van der Aalst • Formalized by Pesic and van der Aaalst, and by _ • Two main abstractions: task, constraint 57
  • 58.
    Constraints • Much richerthan the simple “precedence sequence flow connector” of imperative languages • Allow for: • Presence/absence of tasks (do/not do … N times) • Negative relationships (it is forbidden to…) • Atemporal relationships (no order imposed) • Temporal relationships, with different strengths 58
  • 59.
  • 60.
  • 61.
    Constraint Features Three dimensions: •Type • Temporal direction • Strength 61
  • 62.
    Constraint Types Unary constraints(apply on a single task) • Existence: you should/cannot do A (for a certain number of times) Binary constraints (apply to two - or more - tasks) • Choice: do A or B • Relation: if A occurs, then B should also occur (when?) • Negation: if A then B cannot occur 
 (when?) Binary constraints may branch to represent potential alternatives 62
  • 63.
    Constraint Direction • Appliesto relation/negation constraints • “If A occurs, then B should/cannot occur …” • No direction: “… either before or after” • Response: “… in the future” • Precedence: “… in the past” • Example: If close order, then pay in the future 63
  • 64.
    Constraint Strength • Appliesto relation/negation constraints • If A occurs, then B should/cannot occur • Normal • Alternate: A cannot occur again until B occurs • Chain: Immediate constraint (applies to tasks occurring next to each other) • Example: • If close order, then pay in the future
 vs • If close order, then do not close order again until pay in the future vs • If close order, then the next task is to pay 64
  • 65.
    Graphical Appearance 65 3.5 Usabilityof ConDec 65 Table 3.8. Basic visual constitutive elements of ConDec’s constraints concept notation existence constraints 0..N, M..*, K (a l´a UML) choice ♦ / (a l´a decision gateway in BP modeling notations) binary constraints − (normal) = (alternate) ≡ (chain) source of binary constraints • negation ∥ temporal ordering −− succession representation response + precedence part (e.g. •−− • = •−−− + −−− •) ones. As attested by the case study presented in Sect. 3.4, a variety of natural
  • 66.
    Existence Constraints 66 50 3The ConDec Language Table 3.1. ConDec existence constraints name graphical meaning absence(a) 0 a Activity a cannot be executed absence(n+1,a) 0..n a Activity a can be executed at most n times, i.e., the execution trace cannot contain n + 1 occurrences of a existence(n,a) n..∗ a Activity a must be executed at least n times exactly(n,a) n a Activity a must be executed exactly n times init(a) init a Activity a must be the first executed activity 1..∗ order item On the contrary, an absenceN constraint could be used to state that at most three payment attempts can be made by the customer: Examples: ec existence constraints graphical meaning 0 a Activity a cannot be executed 0..n a Activity a can be executed at most n times, i.e., the execution trace cannot contain n + 1 occurrences of a n..∗ a Activity a must be executed at least n times n a Activity a must be executed exactly n times init a Activity a must be the first executed activity 1..∗ order item , an absenceN constraint could be used to state that at most absence(n+1,a) 0..n a Activity a can be executed at most n times, i execution trace cannot contain n + 1 occurrenc existence(n,a) n..∗ a Activity a must be executed at least n times exactly(n,a) n a Activity a must be executed exactly n times init(a) init a Activity a must be the first executed activity 1..∗ order item On the contrary, an absenceN constraint could be used to state that a three payment attempts can be made by the customer: 0..3 pay
  • 67.
    Choice Constraints 67 3.3 Constraints51 Table 3.2. ConDec choice constraints name graphical meaning choice(n of m,[a1,...,am]) a1 am a2 n of m ... At least n distinct activities among a1,. . . ,am must be exe- cuted ex choice(n of m,[a1,...,am]) a1 am a2 n of m ... Exactly n distinct activities among a1,. . . ,am must be exe- cuted Note that the constraint supports an execution trace containing three submis- sions of the paper (via e-mail and/or by using the web site), while it evaluates a trace without submissions as noncompliant. A 1 of 2-exclusive choice can be instead adopted to model the existence between two alternatives that exclude each other. For example, it could be used to state that, within an instance of the system, the customer commits herself to cancel or successfully close the order, but not both: Examples: choice(n of m,[a1,...,am]) a1 am a2 n of m ... At least n distinct activitie among a1,. . . ,am must be exe cuted x choice(n of m,[a1,...,am]) a1 am a2 n of m ... Exactly n distinct activitie among a1,. . . ,am must be exe cuted ote that the constraint supports an execution trace containing three submis ons of the paper (via e-mail and/or by using the web site), while it evaluate trace without submissions as noncompliant. A 1 of 2-exclusive choice can be instead adopted to model the existenc etween two alternatives that exclude each other. For example, it could b sed to state that, within an instance of the system, the customer commit erself to cancel or successfully close the order, but not both: cancel order −− −− close order It is worth noting that choice constraints, together with the existence
  • 68.
    68 name graphical meaning respexistence([a], [b]) a •−−−− b If a is executed, then b must be exe- cuted before or after a coexistence([a],[b]) a •−−−• b Neither a nor b is executed, or they are both executed response([a],[b]) a •−−− b If a is executed, then b must be exe- cuted thereafter precedence([a],[b]) a −−− • b b can be executed only if a has been previously executed succession([a],[b]) a •−− • b a and b must be executed in succes- sion, i.e. b must follow a and a must precede b alt response([a],[b]) a •=== b b is response of a and between every two executions of a, b must be exe- cuted at least once alt precedence([a],[b]) a === • b a is precedence of b and between ev- ery two executions of b, a must be executed at least once alt succession([a],[b]) a •== • b b is alternate response of a, and a is alternate precedence of b chain response([a],[b]) a •=−=−=− b If a is executed, then b must be exe- cuted next (immediately after a) chain precedence([a],[b]) a =−=−=− • b If b is executed, then a must have been executed immediately before b chain succession([a],[b]) a •=−=− • b a and b must be executed in sequence (next to each other) RelationConstraints
  • 69.
    69 NegationConstraints Table 3.4. ConDecnegation constraints name graphical meaning resp absence([a],[b]) a •−−−−∥ b If a is executed, then b can never be executed not coexistence([a],[b]) a •−−−•∥ b a and b exclude each other neg response([a],[b]) a •−−−∥ b b cannot be executed after a neg precedence([a],[b]) a −−− •∥ b a cannot be executed before b neg succession([a],[b]) a •−− •∥ b a and b cannot be executed in succession neg alt response([a],[b]) a •===∥ b b cannot be executed between any two occurrences of a neg alt precedence([a],[b]) a === •∥ b a cannot be executed between any two bs neg alt succession([a],[b]) a •== •∥ b b cannot be executed between any two as and viceversa neg chain response([a],[b]) a •=−=−=−∥ b b cannot be executed next to a neg chain precedence([a],[b]) a =−=−=− •∥ b a cannot be executed immedi- ately before b neg chain succession([a],[b]) a •=−=− •∥ b a and b cannot be executed in sequence
  • 70.
    Choreography Example • Anorder can be finalized at most once • Once an order is finalized, it must be confirmed or rejected • A confirmed order may be rejected later on (due to “late” problems), but not vice-versa: a reject cannot be reverted. • An order can be confirmed only if it shipped before. • An order may be rejected autonomously by the seller. However, if the warehouse notifies the seller of a shipment issue, then the seller has to reject the order. • The warehouse decision is firm: “Ship” and “Notify shipment issue” are mutually exclusive. 70
  • 71.
    Modeling in Declare Finalizeorder Confirm order Reject order Ship Notify shipment issue 71
  • 72.
    0..1 Modeling in Declare Finalizeorder Confirm order Reject order Ship Notify shipment issue 72 An order can be finalized at most once
  • 73.
    0..1 Modeling in Declare Finalizeorder Confirm order Reject order Ship Notify shipment issue 73 Once an order is finalized, it must be confirmed or rejected
  • 74.
    0..1 Modeling in Declare Finalizeorder Confirm order Reject order Ship Notify shipment issue 74 A confirmed order may be rejected later on, but not vice-versa
  • 75.
    0..1 Modeling in Declare Finalizeorder Confirm order Reject order Ship Notify shipment issue 75 if the warehouse notifies the seller of a shipment issue, then the seller has to reject the order An order can be confirmed only if it shipped before
  • 76.
    0..1 Modeling in Declare Finalizeorder Confirm order Reject order Ship Notify shipment issue 76 Mutually exclusive
  • 77.
    Linear temporal logicover finite traces (LTLf): propositional logic enriched with temporal operators • Models: words over the alphabet of tasks -> exactly one task at a time! • Constraints: formulae over tasks N.B.: there is a huge difference between “standard” LTL and LTLf (not discussed here) Constraint Semantics 77 3.6 Linear Temporal Logic 69 Table 3.9. LTL temporal operators op. name meaning intuition current state ⃝φ (Next time) φ will hold in the next state ♦φ (Eventually) φ will hold sometimes in the future φ (Globally) φ will always hold in the future ψUφ (Until) φ will hold in a future moment, ψ will always hold until that moment • atomic propositions, i.e., events, together with the two special constants true and false; • classical propositional connectives, i.e., ¬, ∧, ∧ and ⇒;
  • 78.
    Formalization Example 78 Moored Under way usingengine Under way sailing constrained by her draught
  • 79.
    Formalization Example 79 Moored Under way usingengine Under way sailing constrained by her draught ¬⇤c _ ¬c Us ¬(⌃e ^ ⌃s) Model formula: conjunction of all constraint formulae ⇤(m ! ⌃e)
  • 80.
    Correctness of Models •A Declare model is correct if there exists at least a finite trace satisfying all its constraints • A Declare model is correct if its LTLf formula is satisfiable • A correct model may still contain dead activities: activities that can never be executed • Can be reduced to model correctness: just add 1..* on top of the activity to be checked! 80
  • 81.
  • 82.
  • 83.
  • 84.
  • 85.
    0..1 Example 2 85 a c b deadactivity 1..* 0..1 a c b INCORRECT!
  • 86.
  • 87.
  • 88.
  • 89.
    Process Responsibilities • Historyrecognition: given the history of a running instance, compute the current state (or reject) • Todo list: given the current state, tell 
 which tasks can(not) be executed next
 (including possibility of termination)
 • Update: given a state and a task,
 determine the new state S A B C S SnewS 89
  • 90.
    RV-LTL Truth Values Refinedanalysis of the “truth value” of a constraint. Consider a partial trace t, and a constraint C • C is permanently satisfied if t satisfies C and no matter how t is extended, C will stay satisfied • C is temporarily satisfied if t satisfies C but there is a continuation of t that violates C • C is temporarily violated if t violates C but there is a continuation that leads to satisfy C • C is permanently violated if t violates C and no matter how t is extended, C will stay violated 90
  • 91.
    Process Execution in Declare •Start with the empty trace • Loop • Consider the history so far, assuming it is correctly recognized • Block all activities that would lead to a permanent violation 
 (of what? Constraint? Model?) • Highlight constraints that are permanently satisfied • Highlight constraints that are temporarily violated • If there is no temporarily violated constraint: allow for completing the process • Wait until an allowed activity is executed • Update the history with the executed activity 91 At the beginning is so if the model is correct!
  • 92.
  • 93.
  • 94.
  • 95.
    “Notify Shipment Issue” 95 0..1 Finalizeorder Confirm order Reject order Ship Notify shipment issue
  • 96.
  • 97.
  • 98.
  • 99.
  • 100.
  • 101.
  • 102.
    Important Question • To“block” activities, shall we just consider constraints separately? 102
  • 103.
    Hidden Dependencies 103 Ship Notify shipment issue Pickpackage Insert material Close package
  • 104.
    Initial State 104 Ship Notify shipment issue Pickpackage Insert material Close package May complete now…
  • 105.
    Initial State 105 Ship Notify shipment issue Pickpackage Insert material Close package May complete now… What if I executed this?
  • 106.
    “Notify Shipment Issue” 106 Ship Notify shipmentissue Pick package Insert material Close package May complete now… !!!
  • 107.
    How to ImplementThis? Automata to the Rescue! 107
  • 108.
    From Formulae toAutomata • Observation: Declare constraints are formalized using LTL over finite traces (LTLf) • LTLf corresponds to the star-free fragment of regular expressions • Intimate connection with finite-state automata 108
  • 109.
    Declare 2 DFA ' LTLfNFA
 nondeterministic DFA
 deterministic LTLf2aut determin. 109
  • 110.
    Declare 2 DFA LTLfNFA
 nondeterministic DFA
 deterministic LTLf2aut determin. A process! • allowed tasks: alphabet, task: symbol, trace: word • history recognition —> word prefix recognition • todo list —> return next symbols • update —> transition 110 '
  • 111.
    Local Automata • Foreach constraint, we take its LTLf formula, and compute the corresponding DFA • This DFA accepts all and only the execution traces that lead to satisfy (pemanently or temporarily) the constraint 111
  • 112.
    Local Automata: Example 112 001 m e not m not e moored under way using engine under way sailing constrained by her draught
  • 113.
    Local Automata: Example 113 0 s c not{c,s} true1 0 true moored under way using engine under way sailing constrained by her draught
  • 114.
    Local Automata: Example 114 moored underway using engine under way sailing constrained by her draught s e not s true00 not {s,e} 1 2 3 e s not e 1 2
  • 115.
    Coloring local automata Wecolor the states of each local automaton with their corresponding RV-LTL truth values • State permanently satisfied: it is final and cannot reach a non-final state • State temporarily satisfied: it is final but can reach a non-final state • State permanently violated: it is non-final and cannot reach a final state • State temporarily violated: it is non-final but can reach a final state 115
  • 116.
    Local Automata: Example 116 moored underway using engine under way sailing constrained by her draught 0 s c not {c,s} true1 0 true 00 1 m e not m not e s e not s true00 not {s,e} 1 2 3 e s not e 1 2
  • 117.
    Local Automata: Example 117 moored underway using engine under way sailing constrained by her draught 0 s c not {c,s} true1 0 true 00 1 m e not m not e
  • 118.
    Local Automata: Example 118 moored underway using engine under way sailing constrained by her draught 0 s c not {c,s} true1 0 true 00 1 m e not m not e s e not s true00 not {s,e} 1 2 3 e s not e 1 2
  • 119.
    Local Automata: Example 119 moored underway using engine under way sailing constrained by her draught 0 s c not {c,s} true1 0 true 00 1 m e not m not e s e not s true00 not {s,e} 1 2 3 e s not e 1 2
  • 120.
    Global Automata What abouthidden dependencies? • We have to consider the interplay between constraints • To do that: compute the “global automaton” for the entire model. Two possibilities: • Take the “conjunction formula” of all constraints and get the DFA • Compute the intersection of the local DFAs 120
  • 121.
    Can you DigestSpaghetti? 121
  • 122.
    Declare 2 DFA:Complexity ' LTLf NFA
 nondeterministic DFA
 deterministic LTLf2aut determin. exponential
 blow-up exponential
 blow-up 122
  • 123.
  • 124.
  • 125.
    Automaton: Design Time Correctnessof a Declare model reduced to nonemptiness of the corresponding automaton 1. Obtain the LTLf formula for the model 2. Compute the corresponding DFA 3. Check whether the DFA is (non)empty
 (if nonempty, there is at least one trace that is accepted) 125
  • 126.
    Runtime: Global Automaton Bycomputing the global DFA as the intersection of the local colored DFAs, we can get a global DFA that retains all “local colors”, and use it directly to manage the execution! 126
  • 127.
    Conclusion • Turbulent, unpredictable,knowledge-intensive environments demands flexibility • Constraint-based approaches provide a declarative way to capture flexible processes • Declare does this by exploiting temporal logics over finite traces: a compact way to represent spaghetti processes • Flexible processes demand reasoning support for their understanding and correct execution • The automata-theoretic characterization of temporal logics gives a “correct by design” computation mechanism for: model verification, execution, monitoring, discovery, conformance checking! 127
  • 128.
    And the StoryContinues… 128 Conformance Checking Using Object-Centric Behavioral Constraints 21 register applicationperson position 1 employee 1 1 1 1..* 0..1 r1 r2 r3 11..* 1 1 r4 open pos. close pos. selecthire apply check reference interview 1 1 1 0..2 1 1 1 1 1 1 1 0..5 1 1 c1 c2 c3 c4 c5 c6 c7 c8 Fig. 13. An OCBC model modeling a hiring process. Object-Centric Declare (joint work with Wil van der Aalst and Guangming Li)
  • 129.
    References Declare and itsformalizations • M. Pesic and W. van der Aalst, A Declarative Approach for Flexible Business Processes Management, in Proceedings of the Business Process Management Workshops. Springer-Verlag, 2006, vol. 4103, pp. 169-180. • M. Montali, M. Pesic, W. M. P. van der Aalst, F. Chesani, P. Mello, and S. Storari, Declarative specification and verification of service choreographies, ACM Trans. Web, vol. 4, pp. 3:1–3:62, 2010. • M. Montali. Specification and Verification of Declarative Open Interaction Models: a Logic- Based Approach, vol. 56 of Lecture Notes in Business Information Processing. Springer-Verlag, 2010. ISBN: 978-3-642-14537-7. • M. Westergaard, Better Algorithms for Analyzing and Enacting Declarative Workflow Languages Using LTL, in Proceedings of the 9th International Conference on Business Process Management, Springer- Verlag, 2011, pp. 83-98. 129
  • 130.
    References Declare Execution Environment •M. Pesic, H. Schonenberg, and W. M. P. van der Aalst, DECLARE: Full Support for Loosely-Structured Processes, in Proceedings of the 11th IEEE International Enterprise Distributed Object Computing Conference, Washington, DC, USA: IEEE Computer Society, 2007, pp. 287–300. • M. Pesic, M. Schonenberg, N. Sidorova, and W. van der Aalst, Constraint- Based Workflow Models: Change Made Easy, in On the Move to Meaningful Internet Systems 2007: CoopIS, DOA, ODBASE, GADA, and IS, R. Meersman and Z. Tari, Ed., Springer Berlin / Heidelberg, 2007, vol. 4803, pp. 77-94. • M. Pesic, H. Schonenberg, and W. Aalst, The Declare Service, in Modern Business Process Automation, Springer-Verlag, 2010, pp. 327-343. • M. Westergaard, F. M. Maggi, Declare: A Tool Suite for Declarative Workflow Modeling and Enactment, BPM (Demos) 2011. 130
  • 131.
    References Monitoring Declare constraints •F. M. Maggi, M. Montali, M. Westergaard, and W. M. P. van der Aalst, Monitoring Business Constraints with Linear Temporal Logic: An Approach Based on Colored Automata, in Proceedings of the 9th International Conference on Business Process Management, Springer-Verlag, 2011, pp. 132-147. • F. M. Maggi, M. Westergaard, M. Montali, W. M. P. van der Aalst,
 Runtime Verification of LTL-Based Declarative Process Models.: Proceedings of the 2th International Conference on Runtime Verification, Springer-Verlag, 2011, pp. 131-146. • M. Montali, F. M. Maggi, F. Chesani, P. Mello, W. M. P. van der Aalst,
 Monitoring business constraints with the event calculus. ACM Trans. on Intelligent Systems and Technology 5(1): 17, 2013. • G. De Giacomo, R. De Masellis, M. Grasso, F. M. Maggi, M. Montali, 
 Monitoring Business Metaconstraints Based on LTL and LDL for Finite Traces, Proceedings of the 12th International Conference on Business Process Management, Springer-Verlag, 2014, pp. 1-17. 131
  • 132.
    References Discovering Declare constraints •F. Chesani, E. Lamma, P. Mello, M. Montali, F. Riguzzi, S. Storari, Exploiting Inductive Logic Programming Techniques for Declarative Process Mining. Trans. Petri Nets and Other Models of Concurrency 2: 278-295, 2009. • F. Maria Maggi, A. J. Mooij, W. M. P. van der Aalst, User-guided discovery of declarative process models. In Proceedings of the IEEE Symposium on Computational Intelligence and Data Mining, Springer-Verlag, 2011, pp. 192-199. • F. M. Maggi, R. P. J. Chandra Bose, W. M. P. van der Aalst, Efficient Discovery of Understandable Declarative Process Models from Event Logs. In Proceedings of the 24th International Conference on Advanced Information Systems Engineering, Springer-Verlag, 2012, pp. 270-285. • F. M. Maggi, M. Dumas, L. García-Bañuelos, M. Montali, Discovering Data-Aware Declarative Process Models from Event Logs. In Proceedings of the 11th International Conference on Business Process Management, Springer-Verlag, 2013, pp. 81-96. • F. M. Maggi, Declarative Process Mining with the Declare Component of ProM. BPM (Demos) 2013. • C. Di Ciccio, M- Mecella, On the Discovery of Declarative Control Flows for Artful Processes. ACM Trans. Management Inf. Syst. 5(4): 24:1-24:37, 2015. • C. Di Ciccio, F. M. Maggi, M. Montali, J. Mendling, Ensuring Model Consistency in Declarative Process Discovery. In Proceedings of the 13th International Conference on Business Process Management, Springer-Verlag, 2015, pp. 144-159. • C. Di Ciccio, F. M. Maggi, M. Montali, J. Mendling, Semantical Vacuity Detection in Declarative Process Mining. n Proceedings of the 15th International Conference on Business Process Management, Springer-Verlag, 2016, pp. 158-175. 132