Class Of Service In Kanban & WIP Limit - AgileFever

Linda joined the local hospital as a nurse a few months ago. Recently, she was transferred to the emergency room because of the resignation of one of the nurses who relocated to another city. Although she already knew from her experience that patients are not treated in the order they arrive, she understood the different priority levels. She learned the following five priority levels given to all the patients coming to emergency care depending on the current condition and the history.

  • Resuscitation for those who need immediate life-saving intervention
  • Emergency
  • Urgent
  • Semi-Urgent
  • Non-Urgent

Whenever a patient with a higher priority comes, such as one who needs immediate life-saving intervention, the rest of the patients have to wait, no matter how long they have been waiting. It is a classic example of a "Priority Queue."

Know More: Team Kanban Practitioner

There can be two different options in the case of a priority queue if low priority patient is being treated and high priority patient is walking in. Let's take a look at this with a simple example. Suppose if there is only one doctor available in the emergency care and currently he/she is treating Non-Urgent patients. What should he/she do if anyone other than a Non-Urgent patient comes? Linda discovered that the hospital has a simple rule for a situation like this. If a new patient is a Resuscitation or Emergency priority, then the doctor stops treating the current patient; however, continue the treatment of the current patient in other cases. The first situation, where the doctor stops treating the existing patient and immediately starts treating the new high priority patient, is called Preemptive. The other case is known as Non-preemptive. In this example, "Resuscitation" and "Emergency" are Preemptive priority levels, and "Urgen," "Semi-Urgent," and "Non-Urgent" are in Non-Preemptive priority levels.

There are two problems in this situation. The first one is, now we can not make any prediction of lower-level priority. For example, we cannot predict how long the wait will be before a doctor sees the Semi-Urgent or Non-Urgent patient. The second problem is "starvation," which means lower priority level patients will never get treated because of the continuous influx of higher priority level patients.

Let's take a look at this in little more detail. In the above example, there are five different priority levels. Suppose if there are "k" different priority levels, where 1 is the highest priority and k is the lowest. Here are the arrival rates of different priorities.

Here are the departure rates of different priorities

A load of each priority level is the ratio of arrival rate over departure rate for that level. 

To make this queue stable, it has to follow this condition.

Know More: Kanban Management Professional

This condition is called the stability condition. In other words, if the sum of the arrival to departure ratio of all the priority levels are not less than one, then some lower-level priority queue will keep growing. There are lots of other examples to demonstrate this concept. The operating system scheduling algorithm is also using a priority queue to schedule.
Let's see how we can do this in Kanban. In Kanban, different priority levels are defined as "Class of Service" and can be visualized as either color or swimlane. In my experience, teams usually use swimlane for "class of service" and a different color for the work item types; this helps them change the swim lane if priority changes instead of creating a new card in a different color.
Four classes of service are commonly defined in the Kanban literature, known as "Expedite," "Standard," "Fixed Date," and Intangible." These are specified based on the Cost of Delay, and it is nothing but different prioritization levels. It is important to note that the class of service can be defined in other ways too, in our hospital emergency, we have five classes of services defined as per the patient's condition. This Kanban board shows one situation of hospital emergency room in case they decided to use Kanban board.
Now let's see how we can avoid the starvation and forecast of lower priority items. Aging is one possible technique to prevent starvation. In this technique, the priority will gradually increase as per the time it has been waiting. One such example is every patient waiting for 4 hours; whatever his/her priority is, increase it to the next level. It means Non-Urgent patients will be promoted to Semi-Urgent after 4 hours and Urgent after 8 hours to ensure they are not kept waiting. This technique is also common in business and is usually applied to "Account Receivables."
Another technique is to apply the WIP limit on the different classes of service and allocate capacity based on the demand of each class of service. Obviously, we may not use this technique for the hospital emergency room, but we commonly observe this at the airport where they have different queues for Economy, Business, and First class passengers with varying numbers of open counters for each. Here is one example of a simple Kanban board for Airport check-in counter for different ticket types. 
The number put on each class of service puts a limit on how many things will be in progress at one particular time. In the example above, there can be only one first-class passenger, only three business-class passengers and only ten economy-class passengers can check-in at a time.
Use of class of service comes with its burden, and one has to be careful of these. Our system becomes quite unpredictable for some priority levels if a stability condition doesn't meet. We are not using any of the methods mentioned above, aging or WIP Limit on a class of service with capacity allocation. With the WIP limit on a "class of service" with a capacity allocation, we can manage the flow of each priority; however, the flow metrics of each may be different. 

You may also be interested in: