The Art of Slicing

Erez Morabia
8 min readNov 16, 2023

--

Slicing in Agile software engineering refers to the practice of breaking down larger user stories or features into smaller, more manageable pieces called slices. The goal of slicing is to create smaller units of work that can be completed and delivered independently, allowing for quicker feedback, reduced risk, and increased flexibility. In the context of cycle time, smaller units of work have shorter cycle time. The thinner you slice, the shorter your cycle time will be.

Advantages

There are many advantages to slicing. Here are the main ones:

  1. Prioritization and Value-Driven: Slicing is often driven by the principle of delivering the highest value to the customer early. Teams prioritize the most critical functionality and slice stories in a way that allows the most valuable features to be delivered sooner.
  2. Risk Mitigation: Breaking down larger stories into smaller slices helps in risk mitigation. If there are uncertainties or complexities in a particular part of a larger story, those can be addressed in smaller, controlled increments.
  3. Feedback Loop: Slicing facilitates a faster feedback loop. By delivering smaller increments, teams can quickly gather feedback from stakeholders and end-users, making it easier to incorporate changes and adapt to evolving requirements.
  4. Continuous Delivery: Sliced user stories contribute to the principles of continuous delivery and continuous deployment. Smaller, independent increments are more manageable and can be released more frequently, allowing for a more responsive and agile development process.
  5. Parallel Work Opportunities: Slicing user stories opens opportunities for parallel work, potentially allowing team members to operate independently, thereby enhancing overall efficiency.
  6. Demonstrating Tangible Progress: Delivering sliced user stories is evidence of progress in product development, showcasing concrete advancements rather than merely technical components.
  7. Mitigating Parkinson’s Law Impact: Parkinson’s Law dictates that tasks expand to fill the time allocated to them, posing a risk, particularly in time-constrained contexts like sprints. By slicing user stories, we minimize the impact of this law, reducing the risk of overrunning time constraints.
  8. Enhanced Estimation Accuracy: Estimating smaller, more manageable pieces is inherently easier in the dynamic landscape of software engineering, characterized by unknown unknowns. Slicing user stories facilitates more accurate estimations, providing a clearer understanding of the overall effort required.

Example of User Story Slicing

Consider a user story like “As a user, I want to be able to search for products on the website.” This could be sliced into smaller increments such as:

  • Slice 1: Implement a basic search input field on the homepage.
  • Slice 2: Enable searching by product name.
  • Slice 3: Implement filtering options for search results.

Each of these slices delivers a usable increment of functionality, and the entire feature is gradually built by completing these slices.

Techniques for Slicing

Several techniques can be used for slicing user stories or features into smaller, manageable pieces. These techniques help teams break down larger tasks into incremental deliverables that provide value to the end-users. If you write the user story using the Gherkin format (Given, When, Then), each acceptance criterion in the user story may serve as an independent and smaller sliced user story (refer to this resource for further insights on the acceptance criteria format).

Here are some common and recommended slicing techniques:

  1. Functional Slicing (Basic to Complex):
    Identify specific user functionalities within a larger feature and implement them incrementally. For example, if building a user registration system, the first slice might focus on basic user registration without additional features.
  2. Workflow Slicing (Step by Step):
    Break down a feature based on the steps in a workflow. Each slice represents one step in the workflow. For example, in an e-commerce system, slicing the “checkout” feature might involve implementing steps like adding items to the cart, entering shipping information, and processing payment as separate slices.
  3. Data Slicing (Basic to Complex):
    Focus on specific data elements or types. For instance, in a reporting feature, one slice might involve displaying basic data, while subsequent slices add more detailed or complex data components.
  4. User Role Slicing:
    If a feature caters to multiple user roles, slice the feature to deliver functionality for one user role at a time. This allows for progressive refinement and validation based on different user perspectives.
  5. Complexity Slicing (Use Defaults):
    Address technical complexities incrementally. If certain technical challenges or uncertainties exist, create slices that allow the team to tackle and resolve these complexities in a controlled manner. A useful technique involves using mocks, stubs and default values to put some complexity aside.

Choosing the right slicing technique depends on the nature of the product, the feature being developed, and the team’s specific goals. Often, a combination of these techniques is used to effectively break down work items into manageable slices that can be incrementally delivered and validated. Once the user story is sliced, identify and address the highest-risk aspects of a feature first. Prioritizing based on risk allows teams to mitigate uncertainties early in the development process.

Slicing Guidelines

Determining the optimal granularity for slicing use cases can be a challenge, often prompting the question of how thin to slice. My recommended guideline is to slice until you attain small user stories that can be realistically completed within half of a sprint.

It’s not uncommon for teams to assert, “This use case cannot be sliced.” However, in the majority of cases, slicing is feasible. If, despite employing the techniques mentioned earlier, you still find a use case resisting slicing, consider delving into the technical aspects of its implementation. Identifying where the technical heavy lifting occurs can often reveal opportunities for slicing.

Occasionally, the result of slicing is a leading user story that holds infrastructure preparations, rather than representing an actual use case. This is a common pitfall in slicing strategy. In such instances, I suggest binding the smallest use case to this infrastructure-building activity, even if it appears somewhat trivial. For instance, a team building a new website page requiring the creation of a microservice behind the scenes decided to slice out the initial service building as a user story. However, this user story lacked inherent use case value. After thought, the team appended a simple use case to it — displaying an (almost) empty web page. While seemingly insignificant, this slice serves as a tangible demonstration to the product manager upon completion.

Beyond technical considerations, the subsequent question emerges: is the slice delivering customer value? It’s crucial to recognize that not every user story may be deployed and released to customers, yet that doesn’t negate its value. My perspective on value turns around whether a user story can be showcased to a product manager, garnering feedback that can inform adjustments to subsequent backlog user stories. This iterative feedback loop, even when certain stories remain internal, enhances the overall quality and relevance of the delivered product.

In the domain of agile development, the true magic lies in maximizing the amount of work not done (see Agile Manifesto principles). Embracing incremental feedback collection empowers us to fine-tune our course toward the envisioned product. While some may perceive slicing as entailing additional effort due to necessary refactoring and retesting, this notion holds true only in a hypothetical scenario in a domain without uncertainties. In reality, during the era of the Waterfall approach, characterized by extensive planning and delivery, only a mere 11% of projects achieved success. Thus, the essence lies in embracing the feedback loop, a cornerstone of agile practice. This loop serves as a pipe for both technological and business insights. For instance, as a team starts developing the initial slice, they gain valuable insights into required APIs, internal component interactions, and other technical aspects. Armed with this knowledge, subsequent slices benefit from streamlined implementation, resulting in time savings for the overall delivery. Similarly, from a business standpoint, early increments allow product managers to refine subsequent iterations, acknowledging the empirical reality that requirements evolve upon firsthand interaction (i.e. live demonstration of working software). Thus, slicing requirements in an iterative approach allows continuous feedback, which is a key factor towards success.

Slicing a Technical Task

Slicing isn’t exclusive to user stories; it’s equally crucial when dealing with technical tasks, such as refactoring. The goal remains the same: slice until you achieve manageable technical tasks that can be completed within the timeframe of half a sprint. Notably, slicing technical tasks often proves more straightforward than slicing user stories, given the absence of constraints requiring each slice to include a full use case.

The process of slicing technical tasks serves a dual purpose. First, it facilitates the prioritization of critical technical aspects within our architecture runway. By breaking down larger technical tasks into smaller, more digestible slices, teams can expedite the delivery of the most valuable technical components. This approach not only accelerates progress but also enhances adaptability to evolving product needs.

Furthermore, the practice of slicing technical tasks aligns seamlessly with risk mitigation strategies. Instead of struggling with the uncertainty associated with tackling extensive technical pieces in one go, breaking them into smaller slices allows for incremental refinement. This incremental approach not only makes it easier to identify and address potential issues early on but also aligns with the principles of continuous delivery and continuous deployment.

Slicing a Research Spike

Slicing is not reserved for user stories and technical tasks alone; it is equally relevant when dealing with research spikes. The last thing any team wants is to struggle with a research spike that extends across a few sprints, interfering with progress and potentially delaying product delivery timelines. Research spikes, typically serving as a foundational step for the implementation of subsequent user stories, demand a strategic approach to slicing, emphasizing conciseness and focus.

Efficiently slicing research spikes is crucial for several reasons. First and foremost, it ensures that these investigative parts remain manageable and don’t evolve into unmanageable activities that risk the overall development cadence. A research spike, ideally, should be concise and focused, with the goal of completing it within the span of half a sprint. This not only aligns with the principles of agility and iterative development but also allows for swift integration of insights into the subsequent phases of implementation.

By keeping research spikes small and focused, teams can easily gather the necessary information and insights required for informed decision-making without sacrificing valuable time. This approach not only prevents bottlenecks in the development pipeline but also fosters a responsive and adaptive development environment.

Conclusion

In the dynamic domain of Agile software development, the practice of slicing user stories, tasks, features, and research spikes emerges as a cornerstone strategy for achieving efficiency, adaptability, and continuous improvement.

By following the principles of breaking down larger entities into smaller, actionable components, teams empower themselves to deliver tangible value at an accelerated pace. Slicing user stories ensures that each piece contributes meaningfully to the overall product, aligning with end-user needs and expectations. Technical tasks, when sliced strategically, not only expedite the development process but also enhance risk mitigation and contribute to the principle of continuous delivery.

Research spikes, often the gateway to informed decision-making, benefit from a focused and time-bound approach to slicing. Keeping these investigative activities short ensures that the knowledge gained can quickly influence subsequent development phases, preventing long delays and fostering an environment of continuous learning.

As we navigate the complexity of Agile development, let us carry forward the understanding that slicing is not just a technique but a mindset — an approach that values incremental progress, adaptability, and the persistent approach of delivering value. Whether it’s user stories, tasks, features, or research spikes, the practice of slicing is a versatile tool that empowers teams to navigate the complex landscape of software development with agility.

--

--