Software development is inherently complex in nature. For such complex problems there are no recipes for success that can be followed. US Marines rely on heuristics when the original battle plan breaks down, such as “capture the high ground, stay in touch and keep moving”.
Can we use a similar set of heuristics in our Agile deliveries? A heuristic is anything that provides a plausible aid or direction in the solution of a problem. They can produce accurate decisions by exploiting the structures of information in the environments they are applied. Join me to explore how underpinned by Agile principles and practices we can create a set of heuristics that can be used to create a delivery foundation.
7. 8
Visions of rationality
Introduction to heuristics
Adaptive toolbox of heuristics
The agile
adaptive toolbox of heuristics
• Process heuristics
• Technical practices heuristics
Departing thoughts
10. 11
Bounded
Rationality
Models of human judgment and decision
making should be built on what we
actually know about the mind's capacities
rather than on fictitious competencies.
Because of the mind's limitations,
humans "must use approximate methods
to handle most tasks" – Simon Herbert
Herbert Simon
Nobel Prize laureate in economics,
“father” of Bounded Rationality
11. Satisficing
12
• Choice from a set of alternatives
encountered sequentially when
one does not know much about the
possibilities ahead of time. [1]
• End the search for alternatives as
soon as one is encountered that
exceeds the aspiration level.
[1] – Simon Herbert – reproduced from Gerd Gigerenzer;Peter M. Todd;ABC Research Group. Simple Heuristics that Make Us Smart
12. Fast and
Frugal
Heuristics
13
• Fast and frugal heuristics limit
their search of objects or
information using easily
computable stopping rules, and
they make their choices with easily
computable decision rules. [1]
[1] - Gerd Gigerenzer;Peter M. Todd;ABC Research Group. Simple Heuristics that Make Us Smart
13. 14
Up to 19 cues are measured when
a patient is admitted with a risk of
risk of heart attack.
• blood pressure
• age
• pulse
• ECG
• …
14. 15
A simplified decision tree for
classifying heart attack victims as
high-risk or low risk victims.
Asking at most three yes/no
questions is a fast and frugal
strategy for making decision.
Is the minimum systolic
blood pressure over the
initial 24hr period > 91
High
Risk
Is age > 62.5?
Is sinus tachycardia
present?
High
Risk
Low
Risk
Low
Risk
No
No
No
Yes
Yes
Yes
15. 16
A more accurate method than
some complex statistical
classification methods.
(Breiman et al., 1993).
Is the minimum systolic
blood pressure over the
initial 24hr period > 91
High
Risk
Is age > 62.5?
Is sinus tachycardia
present?
High
Risk
Low
Risk
Low
Risk
No
No
No
Yes
Yes
Yes
16. In many real-world situations, optimal
strategies are unknown or unknowable
(Herbert Simon) [1].
17[1] - Gerd Gigerenzer;Peter M. Todd;ABC Research Group. Simple Heuristics that Make Us Smart
17. Move from omniscient mind
computing intricate
probabilities and utilities to a
bounded mind reaching into a
toolbox filled with fast and
frugal heuristics.
18
Humans and animals make inferences
about their world with limited time,
knowledge, and computational power.
18. 19
Heuristic
"serving to find out or discover."
• 1905 – Albert Einstein used the
term "heuristic" to indicate that
he considered the view he
presented [1] therein as
incomplete, false even, but
still useful.
• 1800 – 1970 "heuristic" referred
to useful, even indispensable
cognitive processes for solving
problems that cannot be
handled by logic and probability
theory
Source - Gerd Gigerenzer;Peter M. Todd;ABC Research Group. Simple Heuristics that Make Us Smart
[1] "On a heuristic point of view concerning the generation and
transformation of light.” Albert Einstein's Nobel prizewinning paper
19. 20
Heuristic
"serving to find out or discover."
A heuristic is an approach to a problem that is
necessarily incomplete given the knowledge
available, and hence unavoidably false, but
which is useful nonetheless for guiding thinking
in appropriate directions.
Source - Gerd Gigerenzer;Peter M. Todd;ABC Research Group. Simple Heuristics that Make Us Smart
20. • ~1920 - Max Wertheimer, Karl Duncker (cognitive
psychologists) defined heuristic as a useful
shortcut, an approximation, or a rule of thumb
for guiding search.
21
Heuristic
"serving to find out or discover."
Source - Gerd Gigerenzer;Peter M. Todd;ABC Research Group. Simple Heuristics that Make Us Smart
21. Heuristics are an ideal control mechanism
under conditions of uncertainty and their
general form is easy to understand.
22
Heuristic
"serving to find out or discover."
Dave Snowden,
creator of
Cynefin framework
22. Photo By: Gunnery Sgt. T. T. Parish
When the battlefield plan breaks
down capture the high ground,
stay in touch, keep moving.
Us marines heuristic
24. Photo By: Gunnery Sgt. T. T. Parish
When the battlefield plan breaks
down capture the high ground,
stay in touch, keep moving.
Us marines heuristic
25. Adrian Newey’s heuristic
on how to design a formula 1 car
26
Continue to evolve the design for
an F1 car instead of always starting
from scratch, unless it’s clearly that
you are on a wrong track, or the
regulations are changing.
Adrian Newey, OBE, British Formula 1 designerEvolve to better understand
26. Joel Spolsky’s heuristic
Rewriting code from scratch
27
Don’t rewrite the code since you’re
throwing away real-world usage,
you are throwing away knowledge.
Knowledge collected in bug fixes.
Years of programming code.
Solve coding issues instead by
carefully moving code around, by
refactoring.
Joel Spolsky, CEO Stack Overflow
https://www.joelonsoftware.com/2000/04/06/things-you-should-never-do-part-i/
Evolve to better understand
27. Martin fowler heuristic
on coding
28
A heuristic we follow is that
whenever we feel the need to
comment something, we write a
method instead.
Martin Fowler, Refactoring, 1999
28. 29
Adaptive toolbox of heuristics
Different domains of thought require
different specialized tools.
29. Agile Adaptive toolbox of heuristics
Agile as a domain requires its own
adaptive toolbox of heuristics.
A toolbox full of heuristics for making
reasonable decisions in software delivery.
30
30. 31
Process Heuristics
Agile and Lean toolbox
Process heuristics congruent with
Agile and Lean thinking.
Technical Practices
Heuristics
Engineering practices toolbox
Engineering practices to support the
Agile and Lean processes.
31. 32
Process Heuristics
Agile and Lean Toolbox
Process heuristics congruent with Agile and Lean
thinking.
Discover iteratively
Build multi-disciplinary teams
Make sense of your world
Understand your landscape
Design work-systems
Use an approach based on observation
and measurement
Use a forecasting approach to planning
Set short feedback loops
32. 33
Discover iteratively
Accept that not all the work can or even should be defined
upfront. Use an approach that allows for discovery of the work
and solutions iteratively.
Create conditions for novel solutions to emerge.
Have a mindset for options, never commiting early unless you
know why.
”It’s not iterating if you do it only once” - Jeff Patton.
Coherent ideas prototyping Real options
33. 34
Build multi-disciplinary teams
Create teams around clearly defined work slices. Provide them
with all the means necessary to complete their work.
Build teams in close proximity of Service Manager* for complex
problems.
Create an environment based on psychological safety and a
strong foundation of trust between the Service Manager and
delivery team.
* Service Manager is a GDS defined role, defined as someone with the knowledge and power to make day-
to-day decisions to improve the service
Cross functional teams Clear ownership of work
Psychological safety
35. Are we discovering
work in an iterative
fashion?
36
Have we built a
multi-disciplinary
team?
36. 37
Make sense of your world
Use sense-making frameworks such as Cynefin to make sense
of the world around you.
Work under the assumption that you will encounter problems
with different levels of complexity. Constantly adapt your
practices according to the complexity domain you are
operating under.
Sense-making
Complex
complicated
obvious
chaotic
37. 38
Understand your landscape
Execution alone is not enough, you will also need a good
strategy. Help visualizing your context with techniques such as
Wardley maps to make better strategic decisions for the future.
Use mapping to understand where to attack and why.
mapping
38. 39
Design work systems
Define a system to track and manage your work.
Give a strong consideration to queue based systems, such as
Kanban.
Adapt the system for various types of work. Managing highly
uncertain work might require a different approach to the one
used for managing more certain one.
visualize Limit wip Manage queues
Make the invisible visible
39. 40
Use an approach based on
observation and measurement
Build using an observation and measurement approach.
Measure Flow metrics such as Work In progress, CycleTime and
Throughput.
Analyse and adapt the system using these metrics.
Measure flow Preserve flow
40. 41
Use a forecasting approach to
planning
Adopt a probabilistic outlook to planning instead of a
deterministic one. Forecast using date ranges backed by
confidence levels.
Perform short and long term forecasts, accepting that short
term forecast will be more accurate.
Reforecast on new information.
Monte Carlo simulations
41. 42
Set short feedback loops
Set feedback loops in the system than enable learning.
Break the releases into multiple chunks, setting each chunk as
small as possible. Remove dependencies between chunks
where possible.
Perform early user testing, run retrospectives, use pair
programming.
Use the feedback to evolve your solutions.
Alpha & beta releases retrospect pair
Create rhythm
42. 43
Coherent ideas prototyping Real options
Cross functional teams Clear ownership of work Psychological safety
Sense-making
mapping
visualize Limit wip Manage queues
Measure flow Preserve flow
Monte Carlo simulations
Alpha & beta releases retrospect pair
Discover iteratively
Build multi-disciplinary teams
Make sense of your world
Understand your landscape
Design work systems
Observation and measurement
Forecasting approach to planning
Set short feedback loops
43. 44
Technical Practices
Heuristics
Engineering practices toolbox
Engineering practices to support the Agile and
Lean processes.
Automate deployments
Integrate early and continuously
Avoid branches, use trunk-based development
Automate tests
Maintain test data
Shift left on security
Implement continual delivery
Version control everything
45. 46
Version control everything
Use version control for all production artifacts:
• application code
• application configurations
• system configurations
• scripts for automating build and configuration of the
environment
Infrastructure as code
Version
control
Source - Forsgren PhD, Nicole; Humble, Jez; Kim, Gene. Accelerate: The Science of Lean Software and DevOps: Building and Scaling High Performing Technology Organizations
46. 47
Automate deployments
Fully automate deployments so that they do not require
manual intervention.
Computers perform repetitive tasks; people solve problems. [1]
“Automate when tasks become boring” - Dan North.
Zero downtime deployments
[1] - Forsgren PhD, Nicole; Humble, Jez; Kim, Gene. Accelerate: The Science of Lean Software and DevOps: Building and Scaling High Performing Technology Organizations
Environments on demand
47. 48
Integrate early and continuously
Use Continuous Integration (CI) as a first step towards
continuous delivery:
• code is regularly checked in, and each check-in triggers a set
of quick tests to discover serious regressions
• the CI process creates builds and packages that are
potentially shippable to production
Test early at higher states of integration.
CI mocking Component testing
48. 49
Avoid branches, use trunk-based
development
Use trunk-based development since it has shown to be a
predictor of high performance in software development and
delivery [1], characterized by:
• fewer than three active branches in a code repository
• branches and forks having very short lifetimes (e.g., less than
a day) before being merged into master
• rare “code lock” periods when no one can check in code or
do pull requests
[1] Forsgren PhD, Nicole; Humble, Jez; Kim, Gene. Accelerate: The Science of Lean Software and DevOps: Building and Scaling High Performing Technology Organizations
49. 50
Automate tests
Use test automation where software tests are run
automatically and continuously throughout the development
process.
To sustain high pace of delivery maintain rigour around test
automation, and:
• test early
• test often
• test well
automation
50. 51
Maintain test data
Maintain carefully test data. Test data management is
becoming an increasingly important part of automated testing.
• necessary data is acquired on demand
• data can be conditioned in the pipelines
• data is not the limiting factor for the amount of testing data
can be run
Test data management
Source - Forsgren PhD, Nicole; Humble, Jez; Kim, Gene. Accelerate: The Science of Lean Software and DevOps: Building and Scaling High Performing Technology Organizations
51. 52
Shift left on security
Integrate security into design, implementation and testing
phases.
• infosec as team members
• use of preapproved security libraries
• security testing as part of automated suite
Security part of the development process
Source - Forsgren PhD, Nicole; Humble, Jez; Kim, Gene. Accelerate: The Science of Lean Software and DevOps: Building and Scaling High Performing Technology Organizations
52. 53
Implement Continuous Delivery
Implement Continuous Delivery (CD) a practice where software
is in a deployable state throughout its lifecycle.
• prioritize keeping the software in a deployable state over
working on new features
• fast feedback on the quality and deployability of the system
is available to all team members
deployable state over new features
Source - Forsgren PhD, Nicole; Humble, Jez; Kim, Gene. Accelerate: The Science of Lean Software and DevOps: Building and Scaling High Performing Technology Organizations
53. 54
Infrastructure as code
Zero downtime deployments
CImockingComponent testing
automation
Test data management
Security part of the development process
deployable state over new features
Version control everything
Automate deployments
Integrate early and continuously
Use trunk-based development
Automate tests
Maintain test data
Shift left on security
Implement Continuous Delivery
No branching
Environments on demand
56. 57
Discover iteratively
Build multi-disciplinary teams
Make sense of your world
Understand your landscape
Design work systems
Observation and measurement
Forecasting approach to planning
Set short feedback loops
Version control everything
Automate deployments
Integrate early and continuously
Use trunk-based development
Automate tests
Maintain test data
Shift left on security
Implement Continuous Delivery
57. 58
Infrastructure as code
Zero downtime deployments
CI mocking Component testing
automation
Test data management
Security part of the development process
deployable state over new features
Coherent ideas prototyping Real options
Cross functional teams Clear ownership of work Psychological safety
Sense-making mapping
visualize Limit wip Manage queues
Measure flow Preserve flow
Monte Carlo simulations
Alpha & beta releases Adapt based on feedback
No branching
Env. on demand
58. 59
Rules vs principles vs heuristics
http://cognitive-edge.com/blog/cynefin-dynamics/
Set limits to action.
Contain all possible
instances of action.
Measurable guidance
which can adapt to the
unknowable unknowns.
Many actions can be
justified by interpreting
a principle.
Rules principles heuristics
59. 60
We know that sometimes it will work and
sometimes it won’t.
But, should it fail, we should not be punished.
A Heuristic …
http://cognitive-edge.com/blog/rules-is-rules/
60. 61
“Cognition is the art of focusing on the relevant and
deliberately ignoring the rest.”
Source - Gerd Gigerenzer;Peter M. Todd;ABC Research Group. Simple Heuristics that Make Us Smart
61. 62
Useful?
A heuristic is an approach to a problem that is
necessarily incomplete given the knowledge
available, and hence unavoidably false, but
which is useful nonetheless for guiding thinking
in appropriate directions.
Source - Gerd Gigerenzer;Peter M. Todd;ABC Research Group. Simple Heuristics that Make Us Smart