25
Planning@SAP: An Application in Business Process Management org Hoffmann 1 Ingo Weber 2 Frank Michael Kraft 3 1 SAP Research, Karlsruhe, Germany 2 UNSW, Sydney, Australia (work performed while at SAP Research) 3 SAP, Walldorf, Germany “Deployed application”? Hm, well . . . Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 1/26

Planning@SAP: An Application in Business Process Management …decsai.ugr.es/~lcv/SPARK/09/Slides/spark09-hoffmann.pdf · I PDDL@SAP: The SAM Model of Transactions I Planning Formalization

Embed Size (px)

Citation preview

Planning@SAP: An Application in BusinessProcess Management

Jorg Hoffmann1 Ingo Weber2 Frank Michael Kraft3

1SAP Research, Karlsruhe, Germany

2UNSW, Sydney, Australia (work performed while at SAP Research)

3SAP, Walldorf, Germany

“Deployed application”? Hm, well . . .

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 1/26

Outline

I Business Process Management & Planning

I PDDL@SAP: The SAM Model of Transactions

I Planning Formalization

I Algorithms & Results

I Discussion

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 2/26

Outline

I Business Process Management & Planning

I PDDL@SAP: The SAM Model of Transactions

I Planning Formalization

I Algorithms & Results

I Discussion

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 3/26

Business Process Management

I What is a Business Process?

“A business process consists of a set of activities that areperformed in coordination in an organizational and technicalenvironment. These activities jointly realize a business goal.”

I User-friendly presentation in terms of diagramsI Control-flow, formalized e.g. as Petri-net

I What is Business Process Management (BPM)?

I Understand, configure, monitor, implement, . . .I Central activity in BPM: modeling (create/adapt processes)

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 4/26

Planning@BPM

I Mind the Gap!

I Business-view of process vs. IT-implementation of processI Takes time and resources (call your local SAP consultant)

I Planning@BPM

I Describe each IT transaction by precond/postcondI Business user enters “goal” (what do I want done here?)

I Planning RequirementsI Instant response timesI Low modeling overhead

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 5/26

Planning@BPM

I Mind the Gap!

I Business-view of process vs. IT-implementation of processI Takes time and resources (call your local SAP consultant)

I Planning@BPM

I Describe each IT transaction by precond/postcondI Business user enters “goal” (what do I want done here?)

I Planning RequirementsI Instant response timesI Low modeling overhead

( =⇒ business user enters goal?)

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 6/26

Planning@BPM

I Mind the Gap!

I Business-view of process vs. IT-implementation of processI Takes time and resources (call your local SAP consultant)

I Planning@BPM

I Describe each IT transaction by precond/postcondI Business user enters “goal” (what do I want done here?)

I Planning RequirementsI Instant response timesI Low modeling overhead

( =⇒ business user enters goal? pre/post??)

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 7/26

Outline

I Business Process Management & Planning

I PDDL@SAP: The SAM Model of Transactions

I Planning Formalization

I Algorithms & Results

I Discussion

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 8/26

Verbatim from SAP

<StatusAndAction><StatusSchema Name=“CustomerInvoice Standard-SAM” . . .<StatusVariableOccurrence Name=“Consistency” . . .<Enable StatusValueOccurrence= . . . ActionOccurrence= . . .<Required StatusValueOccurrence= . . . ActionOccurrence= . . .</StatusAndAction>

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 9/26

Verbatim from SAP

<StatusAndAction><StatusSchema Name=“CustomerInvoice Standard-SAM” . . .<StatusVariableOccurrence Name=“Consistency” . . .<Enable StatusValueOccurrence= . . . ActionOccurrence= . . .<Required StatusValueOccurrence= . . . ActionOccurrence= . . .</StatusAndAction>

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 10/26

Status and Action Management (SAM)

I Scope of the Model

I Behavior of business objects (e.g. “Customer Quote”) . . .I . . . over IT transactions (e.g. “Submit for Approval”)I Domain & language of business users!

I Structure of the Model

I Business object properties: status variablesI IT transactions: precondition/postcondition (propositional

logic)

I Original Use of the Model

I Declarative preconditions check (avoid implementation bugs)I To some extent: generate application code from changes to

action set

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 11/26

SAM Example, and 2PDDL

Action name precondition postcondition

Check CQ Completeness CQ.archivation:notArchived(x) CQ.completeness:complete(x) ORCQ.completeness:notComplete(x)

Check CQ Consistency CQ.archivation:notArchived(x) CQ.consistency:consistent(x) ORCQ.consistency:notConsistent(x)

Check CQ Approval Status CQ.archivation:notArchived(x) AND CQ.approval:Necessary(x) ORCQ.completeness:complete(x) AND CQ.approval:notNecessary(x)CQ.consistency:consistent(x)

CQ Approval CQ.archivation:notArchived(x) AND CQ.approval:granted(x)CQ.approval:Necessary(x)

Submit CQ CQ.archivation:notArchived(x) AND CQ.submission:submitted(x)(CQ.approval:notNecessary(x) ORCQ.approval:granted(x))

Mark CQ as Accepted CQ.archivation:notArchived(x) CQ.acceptance:accepted(x)AND CQ.submission:submitted

Create Sales Order from CQ CQ.archivation:notArchived(x) AND CQ.followUp:documentCreated(x) (*)CQ.acceptance:accepted(x)

Archive CQ CQ.archivation:notArchived(x) CQ.archivation:Archived(x)

2PDDL:I Initial state: defined in SAM for every business objectI Goal: status variable value(s) given by business userI Actions: preconditions as usual

disjunctive effects: non-deterministic, immediately observed

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 12/26

Outline

I Business Process Management & Planning

I PDDL@SAP: The SAM Model of Transactions

I Planning Formalization

I Algorithms & Results

I Discussion

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 13/26

Planning Formalization

Planning task (X , dA, ndA, I , G): X finite domain; dA, ndA: prea, eff a sets of facts; Icomplete, G set of facts. State s assignment, s ⊕ f applies f to s, T tree of actions.

T solves (s, ndAav ) iff either:

1. T is empty and G ⊆ s; or

2. root of T is a ∈ dA, a applicable in s, a has exactly one son, tree rooted at thatson solves (s ⊕ eff a, ndAav ); or

3. root of T is a ∈ ndAav , a applicable in s, a has one son for every eff a, each(s ⊕ eff a, ndAav \ {a}) is either (i) unsolvable or (ii) solved by respectivesub-tree of T , where (ii) is the case for at least one son.

Plan: tree that solves (I , ndA).

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 14/26

Planning Formalization

Non-deterministic effects vs. observations:

T solves (s, ndAav ) iff either:

1. T is empty and G ⊆ s; or

2. root of T is a ∈ dA, a applicable in s, a has exactly one son, tree rooted at thatson solves (s ⊕ eff a, ndAav ); or

3. root of T is a ∈ ndAav , a applicable in s, a has one son for every eff a, each(s ⊕ eff a, ndAav \ {a}) is either (i) unsolvable or (ii) solved by respectivesub-tree of T , where (ii) is the case for at least one son.

Plan: tree that solves (I , ndA).

I No distinction between non-deterministic effects and observations

I =⇒ no non-trivial beliefs, state knowledge remains exact

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 15/26

Planning Formalization

Upper bound on repeating non-deterministic actions:

T solves (s,ndAav ) iff either:

1. T is empty and G ⊆ s; or

2. root of T is a ∈ dA, a applicable in s, a has exactly one son, tree rooted at thatson solves (s ⊕ eff a, ndAav ); or

3. root of T is a ∈ ndAav , a applicable in s, a has one son for every eff a, each(s ⊕ eff a,ndAav \ {a}) is either (i) unsolvable (*) or (ii) solved by respectivesub-tree of T , where (ii) is the case for at least one son.

Plan: tree that solves (I , ndA).

I Blind repetition not useful (check and re-check completeness . . . )

I With infinite repetition: recursion (*) may result in same task =⇒ex. task that is solvable iff it is unsolvable

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 16/26

Planning Formalization

Failed nodes:

T solves (s, ndAav ) iff either:

1. T is empty and G ⊆ s; or

2. root of T is a ∈ dA, a applicable in s, a has exactly one son, tree rooted at thatson solves (s ⊕ eff a, ndAav ); or

3. root of T is a ∈ ndAav , a applicable in s, a has one son for every eff a, each(s ⊕ eff a, ndAav \ {a}) is either (i) unsolvable or (ii) solved by respectivesub-tree of T , where (ii) is the case for at least one son.

Plan: tree that solves (I , ndA).

I Allow-failure vs. more-complex-goals: c.f. business user . . .

I =⇒ no explicit failure handling in the constructed processes

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 17/26

Outline

I Business Process Management & Planning

I PDDL@SAP: The SAM Model of Transactions

I Planning Formalization

I Algorithms & Results

I Discussion

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 18/26

Planning Algorithms

I Forward AND-OR Search Variant:

I OR nodes: states, OR’ed children are applicable actionsI AND nodes: actions, AND’ed children are different outcomesI AND node solved iff ((all children solved or failed), ≥ 1 solved)

I Relaxed Plans Heuristic:

I Act as if each non-deterministic outcome is separate actionI May return ∞ as usual =⇒ main source of “failed” . . . !

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 19/26

Runtime Performance

I x = #(input-services not contained in solution): of 2700 possible ones

I SAM currently omits many dependencies across business objects

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 20/26

Runtime Performance

I x = #(input-services not contained in solution): of 2700 possible ones

I SAM currently omits many dependencies across business objects

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 21/26

Runtime Performance

./ff -p ../../input/domains/spark09example/ -o domain-Full.pddl -f facts-Full.pddl

. . .

time spent: 1.31 seconds instantiating 1384944 easy, 0 hard action templates0.41 seconds reachability analysis, yielding 110956 facts and 2616 actions0.01 seconds creating final representation with 4354 relevant facts0.02 seconds building connectivity graph0.01 seconds searching, evaluating 7 states, to a max depth of 4

0 actions skipped due to simple duplicate detection1.76 seconds total time

I Transformation SAM2PDDL; anonymized PDDL will (likely) bepublicly available

I FF extension (“SAP-FF”) vastly more efficient than previous tool

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 22/26

return (h(s) ==∞ ? ∞ : 1)

0

200000

400000

600000

800000

1e+06

1.2e+06

1.4e+06

1.6e+06

1.8e+06

0 20 40 60 80 100 120

node

eva

luat

ions

additional services

I x = #(input-services not contained in solution): of 2700 possible ones

I Without any h: out of memory at x = 20: finding “failed nodes” is difficult . . .

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 23/26

Outline

I Business Process Management & Planning

I PDDL@SAP: The SAM Model of Transactions

I Planning Formalization

I Algorithms & Results

I Discussion

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 24/26

Discussion

I Technique implemented within SAP NetWeaver platform

I Currently in INITIAL steps towards PILOT customer evaluation

I Algorithm performance good based on easy modifications of FF

I SAM currently omits many dependencies across business objects

I Richer model currently under development =⇒ further extend FF

I Handle plan preferences

. . . pre/post-based description of IT transactions is NOT only an

academic exercise!

Hoffmann & Weber & Kraft Planning@SAP: An Application in Business Process Management 25/26