Wednesday, August 21, 2019

Drive

Drive, a 2009 book by Daniel H. Pink, is a story about what motivates us. It argues that punishment and rewards that organizations and management, in general, use as motivation tools are outdated and can even be harmful for companies’ and individuals’ performance. The best way to motivate people with creative jobs (that is a more and more common type of work nowadays) is through autonomy, mastery and purpose.

The introduction of the book organizes human motivation into 3 types:
  • Biological drive, that includes hunger, thirst and sex
  • Rewards and punishments (external drive), that is a long-recognized drive
  • Intrinsic motivation, is the third drive that a few behavioural scientists began discovering in the middle of the 20th century
This third drive, which can be described by people excelling in doing one task simply because they enjoy doing that task, has been ignored by business since it was first documented. The conclusion of this part is that, if we want to improve our lives, strengthen our companies and improve our society as a whole we urgently need to close the gap between what science knows and what business does.

The book is divided into 2 parts. The first (is comprised by the first 3 chapters) looks at the flaws in our reward-and-punishment system and propose a new way to think about motivation.

In the first chapter, the author compares the 3 motivation types to 3 versions of the Motivation Operating System. He states that in the 20th century, the Motivation 2.0 (rewards and punishments), worked pretty well for routine jobs. However, as in the 21st century, theses types of jobs tend to disappear, we start to sense that we need an upgrade. It became unreliable, providing unexpected results and is proving incompatible with how we organize what we do, how we think about what we do and how we do what we do.

In the second chapter, the elegance and simplicity of Motivation 2.0 (rewarding an activity will get you more of it, punishing an activity will get you less of it) is put into question. In environments where tasks are imaginative and not usual routine, rewards and punishment encounter the third drive. And then strange things begin to happen: traditional “if-then” rewards (if you do this then I will pay you that) can give you less of what you want. They can extinguish intrinsic motivation, diminish performance, crush creativity and crowd out good behaviour. Besides that, they can also give us more of what we don’t want: with the urge to obtain the expected and valuable reward, people may develop unethical behaviour and shortcuts, create addictions to the rewards themselves and foster short-term thinking.
However, carrots and sticks aren’t all that bad (in fact, they are also responsible for the extraordinary growth that happened in the 20th century). They can be effective for rule-based routine tasks, because there’s little intrinsic motivation to undermine and not much creativity to crush. And they can be more effective still if those giving such rewards offer a rationale for why the task is necessary, acknowledge that it’s boring and allow people autonomy over how they complete it.
To further illustrate when to use and when not to use “if-then” rewards, I will use and experiment described in the book. In the 1930s, the psychologist Karl Duncker devised the candle problem: you sit at a table next to a wooden wall and the experimenter gives you the materials shown below: a candle, some tacks and a book of matches.



Your job is to attach the candle to the wall so that the wax doesn’t drip on the table. After 5 or 10 minutes, most people stumble onto the solution, which you can see below:



The key is to overcome what’s called “functional fixedness”. You look at the box and see only one function - as a container for the tacks. But, by thinking afresh, you eventually see that the box can have another function - as a platform for the candle.
Sam Glucksberg, a psychologist at Princeton University, tested this a few decades ago by timing how quickly two groups of participants solved this problem. He compared incentivized groups and non incentivized groups. And guess what, on average, it took the incentivized groups nearly three and a half minutes LONGER than the non incentivized groups. Yes, the incentives actually worsened the group results!!!
However, things change if the initial conditions change slightly. This time, the problem is presented in the following way (now the tacks are outside the box):



This time, the participants vying for the reward solved the problem faster than their counterparts. Why? By removing the tacks and displaying the empty box, Glucksberg essentially revealed the solution. The task is no more a challenging and creative one, but a routine and direct one. In this case, the reward provided the expected results. This experiment provides the first question you should ask when thinking about external motivators: Is the task at hand routine? If that is the case, “if-then” rewards are quite OK. However, fortunately, not all rewards are dangerous. Noncontingent rewards given after a task is complete (provided that they are not routine or expected by the intervinientes. If that happens, they become “if-then” rewards with all their consequences) can be ok for more creative and non routine work, especially if they also provide useful information about performance.

In the third chapter, Pink defines two types of behaviour:
  • Type X behaviour: is driven by extrinsic motivations and rewards to which an activity leads
  • Type I behaviour: is fueled by intrinsic motivations and by the inherent satisfaction of the activity itself
Motivation 2.0 depended on and fostered Type X behaviour. Motivation 3.0, the upgrade that’s necessary for the smooth functioning of 21st century business, depends on and fosters Type I behaviour.
For professional success integrated with personal fulfillment, we need to move ourselves and our colleagues from Type X to Type I. The good news is that Type I’s are made, not born, and Type I behaviour leads to stronger performance, greater health and higher overall well-being.
Despite all the has been said, Type I behaviour does not disdain money or recognition. If an organization doesn’t pay an employee an adequate salary, equitable compared to others doing similar work, that person’s motivation will crater, regardless of whether she leans towards X or I. However, once compensation meets that level, money plays different roles for Type I and Type X. For Type I, once their expectations are met, the “money” issue is out of the table and they can focus on the work itself. By contrast, for many Type X’s, money IS the table. It’s why they do what they do.

The second part of the book is comprised by the next 3 chapters. It examines the 3 elements of Type I behaviour:

Chapter 4 focuses on autonomy. According to the author, our “default setting” is to be autonomous and self-directed. Unfortunately, circumstances - including outdated notions of “management” - often conspire to change that default setting and stimulate Type X behaviour. To encourage Type I behaviour and the high performance it enables, the first requirement is autonomy over:
  • Tasks (what they do)
  • Time (when they do it)
  • Team (who they do it with)
  • Technique (how they do it)
Companies that offer autonomy, sometimes in radical doses, are outperforming their competitors. The book describes several examples:
  • Several companies that are ROWE (Results-Only Working Environment)
  • Atlassian with their FedEx days (one day where the Atlassians can work in any problem they like even if it isn’t part of their regular job) and 20% of each worker time being spent on any project they want
  • Google has also the same rule of 20% time can be spent on any project the worker wants
  • 3M where, since the 1940’s, 15% of the technical staff’s time can be spent on any project they choose
  • Zappos where its customer service employees have autonomy on how they serve the customers, they don’t have predefined scripts to answer the calls and their calls are not monitored. Their job is to serve the customer well; how they do it is up to them
Chapter 5 focuses on mastery. Motivation 2.0 required compliance. There is a certain good way of doing things (in some cases we used to call them best practices), a recipe that everyone should follow. With a nice bunch of carrots at the end of the way and a good stick for those who fall off track, you are good to go. However, on Motivation 3.0 world (the present world), this is no longer a recipe for success. In the present world, either you innovate and you master your craft or you are overcome by someone else from the other side of the globe that does better work than you for half of your price. The only solution is engagement. Only engagement can produce true mastery - becoming better at something that matters. And the pursuit of mastery, an important part of our third drive, has become essential to making one’s way in the economy.
Mastery begins with “flow”. This “flow” is a state of mind when you are doing something that is neither too easy nor too hard. It is a notch or two beyond your current abilities, which stretches the body and mind in a way that makes the effort itself the most delicious reward. In “flow”, people live so deep in the moment that their sense of time, place and even self, melt away and they forget themselves in a function. Smart workplaces, therefore, supplement day-to-day activities with “goldilocks tasks” - flow inducing tasks - not too hard and not too easy.
But mastery also abides by three peculiar rules:
  • Is a mindset - it requires the capacity to see your abilities not as finite, but always able to improve and increase
  • Is a pain - it demands effort, grit and deliberate practice
  • Is an asymptote - it’s impossible to fully realize, which makes it simultaneously frustrating and alluring
Chapter 6 focuses on purpose. Purpose provides a context and a goal to autonomy and mastery. Humans, by their nature, seek purpose - a cause greater and more enduring than themselves. But traditional business considers purpose ornamental: a perfectly nice accessory, as long as it doesn’t get in the way of important things. But that is changing in part due to the rising tide of aging baby boomers reckoning with their own mortality. In Motivation 3.0, purpose maximization is taking its place alongside profit maximization as an aspiration and a guiding principle. Within organizations, this new “purpose motive” is expressing itself in three ways:
  • Goals that use profit to reach purpose
  • Words that emphasize more than self-interest
  • Policies that allow people to pursue purpose on their own terms
This move to accompany profit maximization with purpose maximization has the potential to rejuvenate our businesses, remake our world and make us happier. The book describes an experiment performed by Edward Deci, Richard Ryan and Christopher Niemiec who asked a group of soon-to-be graduates of University of Rochester about their life goals. Some of these students had “extrinsic aspirations” (for instance, to become wealthy or to achieve fame), profit oriented. Others had “intrinsic aspirations” (for instance, to help others improve their lives, to learn and to grow), purpose oriented. Then they followed up with them early in the first two years of their careers to see how they were doing.
The people who’d had purpose goals and felt they were attaining them, reported higher levels of satisfaction and subjective well-being than when they were in college. Besides that, they reported quite low levels of anxiety and depression. That’s no surprise: they set a goal, they achieve it and they are happy.
But the results for people with profit goals were more complicated. Those that achieved these goals reported levels of satisfaction, self-esteem and positive affect no higher than when they were students. In other words, they achieved their goals, but it didn’t make them any happier. They also reported increases in anxiety, depression and other negative indicators, even though they were attaining their goals.

The world is moving towards Motivation 3.0. The quest for money and profit is giving place to the search for purpose, autonomy, mastery, self fulfilment and happiness. It is in our hands to choose between the old ways and a Type X behaviour or to think about our self fulfillment as the measure of our success.

Thursday, June 27, 2019

The servant

The Servant, a 1998 book by James C. Hunter, is a story about leadership. It states that the true foundation of leadership is not power, but authority, which is built upon relationships, love, service and sacrifice.

The book is about John Daily, a busy general manager of a large manufacturing facility. Apparently, he has it all: a successful and well paid career, a community active intervention as a volunteer coach at a little league baseball team and a happy marriage with two kids.

However, things are not always as they appear. He’s having problems at his work and his boss thinks that they are related to his management. The parents of the kids on the team that he is coaching are complaining that their kids are not having fun anymore. His relationship with his kids is falling apart, as well as his marriage, and his wife is threatening him with divorce.

To try to sort things out, he takes a one week retreat at a small Christian monastery where one of the monks is a former fortune 500 legend Leonard Hoffman. John is integrated into a class with 5 other people from several backgrounds and Leonard Hoffman is precisely their teacher/guide through the retreat. The goal of this class is to study some leadership principles for all aspects in life: as a mom/dad, as a husband/wife, as a coach, as a boss, as a teacher, etc.

They start by defining some important concepts such as:
  • Leadership: the skill of influencing people to work enthusiastically towards goals identified as being for the common good.
  • Power: the ability to force or coerce someone to do your will, even if they would choose not to, because of your position or your might.
  • Authority: the skill of getting people to willingly do your will because of your personal influence.
They discussed the advantages of nurturing authority instead of using power which can erode drastically the relationships between people. Besides that, leadership is a balance between getting things done and relationships.
Then they establish the main characteristics of someone that builds authority among others:
  • Honest, trustworthy
  • Good role model
  • Caring
  • Committed
  • Good listener
  • Hold people accountable
  • Treat people with respect
  • Give people encouragement
  • Positive, enthusiastic attitude
  • Appreciate people
And get into the conclusion that none of these characteristics is innate and all must be trained in order for them to become normal ways of behaving for each one of us.

Then they move on to looking to organization structures. They discuss that the typical organization has a pyramid shape, just like the following one:



In this type of organization each layer above, “uses” and “is served” by the layer below. This means that the least relevant layer in the hierarchy is the one that will contact the customer, transmitting to the customer all the frustrations generated by an organization like this.

After some discussion about the nonsense of this mindset, they come up with a different approach that is described by the following image:



In this case, again, each layer above, “uses” and “is served” by the layer below. This means that, with this mindset, a manager must see its employees as customers which must be served by him/her. The goal of a manager in these kind of organization is to be a leader that meets its people’s needs.

Then, using the definition of leadership (skill of influencing people to work enthusiastically towards goals identified as being for the common good), they state that Jesus Christ was the greatest leader of all times, not because of its message or religious biases, but because of the following facts:
  • One third of mankind call themselves Christians (the biggest religion in the world)
  • Most of the countries in the world celebrate Christmas and Easter, which are events in His life
  • Our calendar even records the years since He lived
Then they start to discuss Jesus’ leadership style:



His leadership was based on authority, as opposition to power, which will not stand the test of time. Other examples of powerless people that brought great changes to the world only based on their authority were given: Gandhy, Martin Luther King and Mother Teresa of Calcutta. These are also great examples of service and sacrifice. The class also realised that serving others is to find its needs and meeting them. And whenever one does that, builds authority on others.

This service is based on love. The word love here doesn’t describe the feeling of love. The original Gospels, written in ancient greek, use the word agapé (which was translated to the word love in english) which means a behaviour toward others without regard to their due.

This behaviour of love, or agapé, is always based on will. A will that is supported by actions. Will without actions is a mere intention that results in nothing.

Then the class finds a definition of agapé love in the Bible (first Corinthians, chapter 13) that contains the following 7 characteristics:
  • Patience - showing self-control
  • Kindness - giving attention, appreciation and encouragement
  • Humility - being authentic and without pretence or arrogance
  • Respectfulness - treating others as important people
  • Selflessness - meeting the needs of others
  • Honesty - being free from deception
  • Commitment - sticking to your choice
Which can map quite nicely to the previously described characteristics of someone that builds authority on others:



Then they draw the conclusion that the agapé love described in the Bible is no more than how a true leader should behave.

The class then starts to discuss about creating a healthy environment for people to grow and thrive. They present several metaphors to describe it: a garden, farming, the growth of children and even bank accounts. All the leaders have the ability and the duty to create this kind of environment to their people no matter how hard and difficult the outside environment is. And, if needed, you must be ready to legislate the behaviour of your people in order to create the proper environment.

With this in mind, one has to take its own decisions and stand for the responsibility of being a leader or not. The human being is, ultimately, master of its own decisions and, in extreme circumstances, (s)he is able to decide whether (s)he will choose one path or the other. In fact, not making a decision is, itself, taking a decision. However, if one takes a decision (based on will as the road to authority) of practicing self-discipline, sooner the unnatural actions become natural behaviours and we are able to behave exactly the way we intend to. The acquisition of habits or skills has, usually, four stages:
  1. Unconscious and unskilled: where you are oblivious of the behaviour
  2. Conscious and unskilled: where you become aware of the new behaviour, but have not yet developed the skills
  3. Conscious and skilled: where you are becoming more and more skilled and comfortable
  4. Unconscious and skilled: where the behaviour is completely natural and you don’t have to think about it anymore

Leadership and agapé love are character issues and not style issues, so they are skills that can be acquired. As an old quote says: “thoughts become actions, actions become habits, habits become our character and our character becomes our destiny”.

In the final stage of the class in the retreat, they discuss the payoff of being a leader based on serving others. Here are some of the conclusions that they took:
  • To give a purpose or a mission of life for the leader
  • Making a difference in the life of others
  • A leader who knows how to build influence is a leader whose skills will be in demand
  • The joy (or inner satisfaction) of being truly aligned with deep and unchanging principles of life

As a conclusion of the book, leadership is not an easy task and everyone has always something to learn at it. However, if we discipline ourselves and try to improve a bit every day, imagine the impact that we will do on our own lives and others’ in the long run.

Thursday, August 30, 2018

The Spotify way

I’ve been talking about Scrum and Kanban. These are well known agile methodologies (or frameworks) that work well for teams until, say, 8 people. After that, you need to scale. You need to stop thinking about one team and think about one or more teams of teams.There are some frameworks that address this scale problem. I’ll start by analysing and describing Spotify model which is already a well known model.


The beginning

Spotify started in 2006 (their first music player was launched in 2008), as many other companies do, with agility in mind. They started using Scrum as a base methodology. This worked well for some time, until a certain level of growth. However, it started to get in the way. So they decided to start to experiment under the principle: “Fail fast, learn fast, improve fast”.


The birth of squads

The first thing they did was to make some Scrum practices optional, because to stay agile was more important than follow any model or framework. In order to remain coherent they renamed the scrum team to a squad and the scrum master to agile coach.

A squad is the primary organization level. It is a self organizing and cross functional team (usually less than 8 people) which is autonomous. This means that it has end-to-end responsibility on what they build (design, architecture, deploy, maintenant, operations, ...) and they decide how to build it.

Spotify has more than 50 squads spread across several locations, so they need a structure. Squads are grouped into tribes (which are light weight matrices) and chapters. Every team member in a tribe belongs to a squad as well as a chapter. In PMI terms, a squad corresponds to a project team and a chapter corresponds to a competency area such as agile coaching or web development. The chapter lead is like a line manager and its goal is to mentoring the people from the chapter as engineers. People can, for instance, switch squads and keep the same chapter and chapter lead.

Besides this, they also created guilds. Guilds are interest communities where people across the company share knowledge within a specific area such as leadership, web development or continuous delivery. They can have a mailing list, conferences or other means to share knowledge and have discussions on the subject matter.

Here you can find a picture extracted from http://labs.spotify.com explaining the all structure:

So, as you can see, this is not particularly innovative. In fact, even PMI and the waterfall projects and organizations have structures very similar to these. However, this is the easy part of organizing a company. The other, that I will describe next, is much more harder to achieve and it is where Spotify model succeeded: its culture.


Spotify culture

The Spotify culture is based on some key principles that I will enumerate in the following lines. As I said before, this is the most difficult part, where effort must be consumed every day and it is a never ending job.

Autonomy

This is the main principle and, for me, the one that drives all the others. As I said before, the squads are autonomous. The decision of how to do the stuff that needs to be done by the squad is taken within the squad. That also includes the tools that each squad uses. The leader’s job is to tell the squad what to do and why.

As everything in life, this autonomy has its boundaries:
  • Every squad has a mission and short term goals which are aligned with the product strategy and Spotify’s overall mission and goals
  • Every squad must be aligned with the other squads around. All the squads must be loosely coupled, but tightly aligned
Each squad is responsible for at least one system in spotify application/ecosystem. Every system interacts with other systems. If you are experienced with software development you are already seeing that these systems and their dependencies in one single application transform each and every deployment into a nightmare. Imagine all the 1200 people depending on each other for doing a deployment… Crazy, right? They are also committed in making releases easy and routine. It seemed contradictory, so they needed to find a solution to combine both things and keep squads autonomous. Instead of defining a set of complex rules to manage the dependencies and synchronization between systems and squads, they changed their architecture. Their application is now a web browser in disguise. Each system is like a frame in their “browser”. This enabled decoupled releases and provided a way to reduce dependencies between squads and keep squads autonomous.

Sense of community

For Spotify, the community and the collaboration among all its members is more important than structure. For instance, in terms of tools, there is low standardization. This means that, for a given action a squad can select whatever tool they think is best fitted. As more and more squads start to selecting the same tool and providing informal support to it, it becomes a “path of least resistance” and a defacto standard emerges. It is the community and not some hierarchical enlightened chief that decides the tools to use.

Another example relates to code. They have an internal open-source model. No squad is the owner of any code. All the community is responsible and invited to do whatever needs to be done. Imagine that squad 1 is responsible for system A and squad 2 is responsible for system B. If system A needs a modification on system B, as squad 2 is more familiar with that code, squad 1 will ask squad 2 to make the required modifications. However, if squad 2 has no time to do it, instead of waiting, squad 1 is completely free to go and make the modifications on system B. After those modifications, squad 2 will do a code review of squad 1’s modifications.

Fail safe environment

Along the process of building and growing a company, is inevitable that problems and failures will occur. For that reason Spotify kind of celebrates the mistakes. Of course, not in a self-punishing or masochist way. They use this mistakes not to blame people or squads, but as knowledge to be shared by all Spotify community. Besides that, you must recognize that the titles like “How we shoot ourselves in the foot” are quite “catchy” ;)

So learning through failure is OK. However, if you fail too much or in catastrophic ways you can get to a point where the customers will see your app/service as unreliable. To mitigate those failures they followed a “limited blast radius” approach. First of all, they aim to have a decoupled architecture. This means that, if you deploy something that is not OK, it usually has a limited effect on the entire application. On the other hand, they do gradual rollouts of new features. This means that (again) if something is not OK, it will only affect a small group of users.

Creative friendly environment

A fail safe environment has another side effect: it reduces the fear of innovate. In fact, Spotify is also known by allocating 10% of its workers’ time for hacking. It also has a hack week where people “do whatever, with whoever in whatever way”.

In fact, there is another interesting approach that is followed to implement innovative hypotheses. When some new feature or improvement is proposed it is implemented and rolled out gradually. As soon as the feature is released for a limited set of users, data is immediately collected and analysed. If users like it and use it, a bigger group of users gets to see the new feature and the cycle is repeated until the complete rollout is made. Otherwise, the feature is dumped. The innovation is driven by data and evidences and not by opinion, ego or authority.


Conclusion

Spotify is one of those organizations where continuous learning, continuous improvement flexibility and innovation are crucial facets of its culture. Does it mean that it is perfect? Of course not. In fact, the characteristics described here are somewhere in the middle of where they are and where they want to be. There is much room for improvement. However, with this mindset, each days that passes puts them closer to their goal.

Sunday, April 22, 2018

How to measure Kanban?

Kanban inventors and implementers are usually very keen on metrics. I, as a Kanban implementer, am no exception. In this article I will share some of my views and ideas on metrics that can be used in Kanban. You must keep in mind that kanban is always about simplicity and focusing on doing just enough to achieve your goals.
Here you can find a non exhaustive, but yet, interesting list of metrics and charts that are very informative and helpful in terms of measuring your team/project performance and evolution.

Cumulative Flow Diagram (CFD)

This chart was already described in a previous post. The idea here is to show the distribution of stories per state along the span of a project. The x-axis represents the time and the y-axis shows the number of stories. Each color band represents a column in the board and its height shows the number of cards in that column in a given point in time. The order of the bands should be (from top to bottom) the order that the cards follow in the columns of your board, so the top most band should be “Backlog” and the bottom most should be the “Done”.

With this chart you can extract the following information:
  • Lead time: Indicates the amount of time that a task is in the system. In other words, it measures the time a task takes to get to the “Done” column (deliver a finished task). In a CFD, it can be measured by drawing an horizontal line that connects the top most line and the bottom most line. The length of this horizontal line, in time units, is the lead time.
  • Cycle time: It is the same principle as lead time. However, in this case, the idea is to measure the time that a task takes to get from point A to point B in the system. To do this you need to measure the horizontal distance between the two lines that represent points A and B.
  • Work in Progress (WIP): Represents the amount of tasks that are in the system. A big WIP tends to increase the lead time, multitasking, stress on the team, etc. It can be measured by a vertical line that connects the bottom most line to the upper most line. The length of this vertical line, in tasks, is the WIP.
  • Process bottlenecks: If a sudden increase or reduction in the thickness of any band shows up, it means that there is a bottleneck in that stage of the process. It is a warning sign that should be considered and resolved.

Cycle Time Control Chart

This is a typical Control Chart (a Tool & Technique of the PMI Control Quality process). The x-axis measures the chronological time and the y-axis represents the cycle time of the task. For each task you mark its cycle time on this chart.
The chart should have an horizontal line that represents the mean of the cycle time of all tasks. Then it should have 2 more horizontal lines that are the Upper and Lower Control Limits. These lines are both at the same distance of the average cycle time (one above the average and the other below the average). This distance is, by definition 3 times the standard deviation from the mean. You can follow this rule, but another distance can be defined (and adjusted) by the kanban team or manager. A typical control chart would also have two more horizontal lines called Upper and Lower Specification Limits, but as we don’t have specifications, we won’t consider them.
The idea is to control if the cycle time of the tasks in the system always falls within the control limits. When this is not the case an analysis should be performed and a cause should be identified and corrected in order to prevent it from happen again.

Lead or Cycle Time Distribution Chart

This chart shows how many tasks took a given amount of time units to get to their destination phase. It enables us to get a visual insight of the likelihood of fulfilling a given task in a certain amount of time.

Flow Efficiency Chart

In an ideal world, 100% of a worker time should be spent on adding value to the product (s)he’s building. However, we all know that this is not true. Heither because (s)he’s waiting for work handoff, or because (s)he’s waiting to another team to fix a bug, or a super priority task showed up and everything else must stop right now, or the specifications aren’t ready yet, or there is an hardware problem, or because the network is down or a provider didn’t fulfill the contract, … You name it. In these situations the time passes and the work doesn’t get done!!!
The Flow Efficiency Chart measures the percentage of time used in a task that was really used for value added purposes. In other words, it is the ratio between the value adding time of a task and its cycle or lead time:
Flow Efficiency[%]=(Value-added Time/Cycle or Lead Time)*100
You can measure this value per task or you can use CFD to provide you the information you require. The first option is the best if you have in place a tool that does these calculations for you, otherwise you will have a hard time doing it. The second option will just provide a mean value per time unit which is a lot easier to calculate (most of the times this is just enough).

Conclusion

There are much more charts and variances of each described chart, but, in the end of the day, it all comes down to the question: how can I improve my working process? What you need to find is the smallest set of charts/KPIs that provide you the most information about how your work is flowing. These charts/KPIs are the tools that will tell you if the modifications that you should continuously introduce in your process (using the scientific method as described in my previous post), really improved the flow or not. Only with these tools you will really control and improve your workflow.

Wednesday, March 28, 2018

Kanban

As I stated in a previous post, Kanban is a good example of an agile methodology used in software development that had its origin on industry. It dates back to the early 1940s where Taiichi Ohno, an industrial engineer at Toyota, implemented it for the first time. David J. Anderson was the first to apply this concept to IT around 2004.
There are some discussions around the fact that kanban is not an agile methodology, but a lean methodology. In fact, kanban and the work in progress limitation has its origin way before agile manifesto, so, technically, it should be called a lean methodology. However, in my humble opinion, this is a pointless discussion. What I care about is:
  • Does it help the team to work better and to feel motivated?
  • Does it fit the context where the team is in?
  • Can it help me to manage my team to build better software?
  • Does it help to improve the team’s performance and output?
According to my experience, where I implemented a Kanban system, the answer to all this 4 questions is YES.

Kanban Principles

In IT in general, Kanban is one of least impositive methodologies. It has a small and very simple set of rules. No ceremonies, roles and rules are prescribed. If needed, they should be adapted to the context where the team is in, in order to achieve the best results. The principles of kanban are:
  1. Start with what you are doing now
  2. Agree to pursue incremental, evolutionary change
  3. Respect existing roles, rules, job titles and responsibilities
  4. Encourage leadership actions at all hierarchy levels

How to implement a Kanban system

The previous principles are put to practice with the following core practices of Kanban:
  1. Visualize: to achieve this goal you have a Kanban board divided by columns where each step of your workflow is translated to a column. Each task is represented by a card. As you go on with your work, you move your card (task) from column to column until you finish the task. This tool provides a quick view of the work to be done, the work in progress and, most important of all, the possible bottlenecks of the system.
  2. Limit the Work In Progress (WIP): Kaban is a pull methodology, which means that a work item enters the system when the system needs it, not because there is an “outside" imposition to the system. To implement this characteristic you impose limits on the number of cards in a column. In other words you limit the Work In Progress (WIP). You can only add cards to a column if the number of cards in that column is smaller that the limit that you set. If the limit is reached, no more tasks can be added and the team must concentrate in moving cards from that column to the next to make room to other cards. You can set column limits in one or more columns. It’s up to you and the context you are in to decide.
  3. Manage flow: in any management task, you have to measure in order to know if things are happening. Here is no different. Kanban has a lot of things that can be measured. The good part is that all of them are pretty simple. The chart that I find more interesting, helpful and informative is Cumulative Flow Diagram (I already described it in a previous post about Scrum). I’ll enter in more detail about this chart and others in my next post.
  4. Make process explicit: all the process must have simple and clear rules for everyone participating in it. The idea is to avoid different interpretations of what to do in each step or how to proceed in a given situation. You should have the least possible rules that reduce discussions about the process in order to smooth the flow. However, all these rules should be clear, agreed and accepted by everyone.
  5. Implement feedback loops: as in other methodologies, kanban also proposes opportunities to improve the action of the team and the process itself. In Kanban parlance they are called cadences. They are 7, all optionall, and they should be implemented according to the maturity of the team, context and degree of kanban adoption companywide:
    • Daily standup meeting
    • Replenishment meeting
    • Delivery planning meeting
    • Operations review
    • Service delivery review
    • Risk review
    • Strategy review
  6. Improve collaboratively, evolve experimentally (using models & the scientific method): this practice can be resumed by:
    1. Watch your data/context/situation
    2. Formulate hypothesis on how do you think it could be improved
    3. Choose one and implement it
    4. After collecting enough data, evaluate it: if the team improved, keep the implementation, otherwise revert it
    5. Return to step 1. of this practice

Why Kanban?

The continual usage and adoption of these practices allow us to achieve the following goals:
  • Evolutionary, incremental change with minimal resistance
  • Achieve sustainable pace by aligning throughput with demand
  • Quantitative Management and predictable throughput
  • Better risk management (the emerging theme in the Kanban community)

Conclusion

And that’s it. With these tools in place everyone is able to see what is happening and propose solutions. And remember: no one is the owner of the truth. Listen to your team carefully: they suffer all the “pains" of the work so, for sure, they have the answers to smooth the workflow and to optimize the output. Ask them and you’ll be surprised. In a next post I will also describe some tools to measure the process flow and to expose clearly the bottlenecks so you can take actions in a timely fashion.

Thursday, March 8, 2018

How to measure Scrum

There is a saying, that I like very much, that states: “you can’t manage what you can’t measure". Scrum is no exception. However there is a common misconception about agile methodologies such as Scrum: it is not supposed to be measured. In fact, in my humble opinion, Scrum has the right characteristics and the proper motivation to be easily measured and controlled. Why?:
  • Scrum is oriented for quality and improvement. How can you know that you are improving or that you achieved your goal (quality) if you don’t measure it?
  • As opposition to other methodologies, the main measures proposed by Scrum are very easy to collect
There are 2 metrics proposed by Scrum that are quite common:
  • Velocity: it measures the quantity of work finished in a sprint. You calculate it by adding the story points of all the user stories that arrived at the state of “Done" in a given sprint (I will describe what story points are and how story points are obtained in a future post). Velocity enables the comparison of performance between sprints. So, if you implement changes in a Sprint, velocity provides you the possibility to measure if this modification brought a performance increase to the team comparing its velocity to the previous sprints’ velocity. Theoretically the velocity should have a slow but steady growth during the project. However you should consider that velocity is based on story points which measure the complexity of the user story and are estimated by the team. But the team perception of complexity varies throughout the project
  • Sprint burndown chart: it represents the evolution of work to do within the sprint. The x-axis represents the time (days of the sprint) and the y-axis represents the story points. The day 0 will have the number of story points that the team committed to in the sprint planning meeting. Each day you decrement the number of points that were completed until that day. Hopefully in the last day of the sprint you’ll have 0 points to complete, meaning that the team completed all the user stories that it has committed to. This chart enables the team to follow up the stories that were finished and those that, to this day, were not, giving a good idea if the team is inline with its forecast. Sometimes this chart also includes a straight line linking the point in the day 0 of the sprint (with the initial number of story points) to the last day of the sprint (with 0 points). The user story completion should follow, has close as possible, this straight line. If this is not the case, it may mean that, either the tasks/user stories should be broken down into granular pieces or that corrective measures should be applied
Besides these two metrics proposed by Scrum there are several others that also provide a good help on tracking the team performance and evolution. Here are two examples that I find interesting and that I already used in my professional activity:
  • Cumulative flow diagram: it allows the team to track the project evolution and to find bottlenecks. It shows the distribution of stories per state along the span of a project. The x-axis represents the time and the y-axis shows the number of stories. Each day you add all the stories in the system (organized per state) and represent them in the diagram. An ideal diagram would be a smooth growing set of lines or bands. If you find “bubbles” or “gaps” in any line or band, it means that you have a bottleneck somewhere: you must find it and correct it
  • Committed vs completed user stories: For each sprint, it measures the percentage of work completed related to the work that the team thought it would complete at the sprint planning. It gives the idea of team accomplishment and also the ability of the team to understand the requirements and predict its capabilities. In the other hand, we can also use this metric to take conclusions about the availability of relevant information or the quality of the user stories’ content at the sprint planning
There are much more metrics that can be used in Scrum (the imagination is your limit). The most important part is that the team must be aware of these metrics and should “believe" in them. Otherwise they will be ignored or even worse: cheated in order to achieve the objectives. You must also remember that you should always choose very carefully what you measure. The KPIs should be aligned with what you want to monitor and improve. If they are not, eventually you’ll end up to optimize what you measure and not what you want. So choose wisely and the results will bring the team’s success.

Wednesday, February 21, 2018

What is Scrum?

Scrum is one of the most famous agile methodologies. Its history can be traced back to a 1986 Harvard Business Review article, “The New New Product Development Game” where Hirotaka Takeuchi and Ikujiro Nonaka introduced the term scrum in the context of product development.
Scrum proposes two main concepts:
  • Decomposition of the work in short cycles of delivery and feedback
  • Empowering teams and trusting them to optimize their work
The idea is to provide a framework to enable the team to organize itself around the context it is in and the available work, to find the best way to perform the work properly and to remove impediments.

Scrum Roles

Scrum defines three roles that will keep the process flowing:
  • Scrum Master: which is responsible for making sure that the scrum process is being properly used and followed. Besides that, (s)he is also in charge for removing impediments from the team’s way
  • Product Owner: which is the voice of the customer next to the team. A PO has the responsibilities of define the priorities, manage the backlog and, above all, maximize the value of the product and the work of the team
  • Team: which is the group of people that really does the job. The team is responsible to find the most productive way of performing the work at hands. Usually the team should have between 3 and 8 people

Scrum Ceremonies

Scrum defines a set of events or ceremonies that are always time limited and quality oriented. This time limitation is based on the concept that meetings are non productive time by definition and that developers should spend the most of their time doing what they are good at: developing great software! Besides that, they provide opportunities to plan the activities to foster predictability of results and, in the end, a quality work. Here you can find the list of ceremonies proposed by Scrum:
  • Sprint: The sprint is the unit of delivery and feedback. It is in a sprint that the real work happens. It usually takes between 2 and 4 weeks. This duration is defined by the team in conjunction with the scrum master and the product owner to maximize product value. Once the sprint duration is defined in the beginning of the project, it should remain the same during all the project
  • Sprint planning: this meeting is used to plan the work of the present sprint: the sprint backlog tasks are selected and estimated. The meeting is led by the scrum master and both the team members and the product owner must be present. The product owner should provide all kinds of clarification to enable a correct estimation and the grooming of the backlog items and sprint backlog definition. Once the sprint backlog is defined no changes should be accepted during the sprint (this rule can only be broken on very special situations and should be very uncommon). The duration of this meeting should be 2h per sprint week (for instance, a 2 weeks sprint should have a 4h sprint planning meeting duration)
  • Daily stand up: these meetings are the most well known and widespread, but not always well used meetings. Usually they involve the scrum master and the team. However, the product owner may also attend these meetings. They occur every day (usually at the beginning of the day) and they take, at most, 15 minutes. Everyone should be on their feet to incentive a quick meeting. The main purpose of these meetings is to plan the work day. Here each team member should report the main difficulties that (s)he is facing and the risks that (s)he foresees for this day. All the remaining subjects should be issued outside these meetings. It is the scrum master’s task to lead these meetings and ensure that they are quick and effective
  • Sprint review: this meeting is led by the scrum master and should be attended by the team, the product owner and other stakeholders invited by the product owner that may be relevant for the product or the specific features of this sprint. The duration of this meeting should be 1h per sprint week (for instance, a 2 weeks sprint should have a 2h sprint review meeting duration). In this meeting all the work performed (and finished) during the sprint will be presented to the product owner and relevant stakeholders. The attendees will, in turn, provide relevant feedback to the development team. The idea is always to show the increment of the sprint in the working product and collect relevant feedback to increase the product value. Now, with all this relevant people at the table is also time to discuss the next steps of the project in order to maximize the product value. This discussion will have, as output, a product backlog update
  • Sprint retrospective: this meeting is led by the scrum master and should be attended by the team. The duration of this meeting should be 1h per sprint week (for instance, a 2 weeks sprint should have a 2h sprint retrospective meeting duration). This meeting occurs after the sprint review and before the sprint planning meeting of the next sprint. Its goal is to analyze the sprint that is finishing and propose improvements to the next sprints in order to make the next sprints’ outcome more effective

Scrum Artifacts

Scrum works around several artifacts that support all the process. I will describe here the ones that I think are important to the process itself. There are others that are important for the management of the process that I will refer and describe in detail in future posts.
  • Product backlog: describes all the work that needs to be done in order to finish the project/product. It is an ordered list of items and it is constantly improving
  • Sprint backlog: is a set of work select to the current sprint and a plan to complete it. It should be kept unchanged until the end of its sprint. The set of work is selected on the sprint planning meeting and should be dimensioned in order to be accomplished during the sprint. For quality improvement purposes it should include at least one high priority process improvement identified in the previous retrospective meeting
  • Increment: is the set of product backlog items that were finished during this sprint. This artifact will be very important for the measurement of the process and team improvement
  • User story: describes, from the user’s perspective, a feature that a user can use. A product/sprint backlog is composed by user stories and, when needed and the product owner accepts it, technical items

Adding all up

Ideally a project may start with a set of user stories in the product backlog (however, in the real word, it may start with just an idea in someone’s head or a diffuse description of some requirements). There may be one or more sprints dedicated to the grooming (definition) of user stories or even to the technical project setup. Usually these initial setup sprints may start to include “normal” user stories. Hopefully as the team and the project stabilizes, there will be more and more percentage of “normal" user stories.
A sprint should start with a sprint planning meeting. In this meeting a sprint backlog is extracted from the product backlog. Each of the following days of the sprint you’ll have a daily standup meeting where the team organizes itself to accomplish all the items of the sprint backlog. At the end of the sprint, the accomplished items (comprising the sprint increment) are presented during the sprint review. Immediately after this meeting, a sprint retrospective should be held. Here all the problems that were faced during the sprint should be addressed and solutions should be proposed in order to improve the overall process. At the end of this meeting the sprint is officially finished and a new sprint with the correspondent sprint planning should be started. And all the process starts again.

Conclusion

These are the basics about Scrum. In future posts I will enter in more detail about each of these parts, how they relate to each other and how all the process can be measured or, in other works, managed.

Drive

Drive , a 2009 book by Daniel H. Pink, is a story about what motivates us. It argues that punishment and rewards that organizations and man...