How to Write User Stories Manually v with Google Gemini

Have you started to use AI to help write user stories?

If I were a Product Manager looking for ways to use AI in a practical manner, one area I’d start with is user stories. It’s probably one of the simplest and most effective ways to leverage AI capabilities.

In these Klariti tutorials, I tend to use Google Gemini. That’s just a personal preference as I tend to work in the Google ecosystem. ChatGPT and Claude are just as good. I find the UI in ChatGPT a bit restrictive, so I tend to stick with Gemini, but there’s not much difference. Before we start, let’s look at how two industry experts approach user story writing.

Download Klariti User Story Templates Here

Atlassian User Story Framework and Templates

First off, I’d recommend Atlassian’s set of tutorials on user stories. For brevity’s sake, I’ve modified this extract slightly. Here’s the recommended structure:

“As a [persona], I [want to], [so that].”

So, if we look at each part:

“As a [persona]”: Who are we building this for? We’re after the persona of the person. Max. Our team should have a shared understanding of who Max is. We’ve hopefully interviewed plenty of Max’s. We understand how that person works, how they think and what they feel. We have empathy for Max.

“Wants to”: Here we’re describing their intent – not the features they use. What are they trying to achieve? This statement should be implementation free.

“So that”: How does their immediate desire fit into their bigger picture? What’s the overall benefit they’re trying to achieve?

For example, a user story might be:

“As Max, an IT manager, I want to be able to understand my team’s progress, so I can better report its successes and failures.”

Pixelmatters User Story Mapping

If you’re a visual-oriented product manager, consider mapping out user stories.

Diana Bernardo at Pixelmatters describes how to approach this. It’s a collaborative exercise designed to help visualize the users’ experience with a product. Use this approach to break down what needs to be done, set priorities, and ensure alignment among all stakeholders.

It consists of three core components:

  • Backbone: The main flow or sequence of user activities.
  • User Stories: Specific tasks or features that contribute to each activity.
  • Release Strategy: Prioritization of user stories into releases or iterations.

Learn More: User Story Map: how to use it to foster team and client alignment

How to Write a User Story Without AI

So, we’ve two options when writing the user story. We can do it ‘by hand’, the pre-AI way or use AI to accelerate the process.

Ok, so let’s start writing our own user stories without AI. To put some shape on this, let’s first get a helicopter view of the ‘traditional’ user story process.

Writing effective user stories comprises five interlocking steps. While there is some flexibility here – user stories are part of the Agile process, after all – I use this structure on projects and recommend it to clients.

Step 1: Identify the Feature

Let’s say you want to add a search engine function to your SaaS application. What type of data will users search for, what will be returned, will sessions be tracked, and so on.

In Agile, a Feature is broken down into multiple atomic user stories. In this context, a user story represents a specific ‘action’ which will be performed by the application. For example, in a spreadsheet application, it might include Pie charts, compare two data sets, or print a file to CSV. 

Step 2: Understand the User Need

To understand user’s needs, arrange interviews to determine how they prefer to search for content. For example, do they use voice commands, shortcuts, keywords, or phrases?

Step 3: Define the User Story

Create a user story using the following structure:

Title: Content Search

As a frequent user

I want to search for specific articles

So I can quickly find information relevant to my interests

Step 4: Add Acceptance Criteria

Next up, define acceptance criteria.

Acceptance criteria are the conditions that must be satisfied for a user story to be accepted. In other words, for this piece of software to be ‘accepted’ and merged into the main product, it must past the following conditions. In software development, quality testers will typically perform this task.

  • The search bar should be accessible from the homepage.
  • The search results should be displayed within 2 seconds.
  • The results should include relevant articles, posts, and media files.

Step 5: Collaborate and Refine

After you’ve done this, discuss the story with your QA and Development team to ensure technical feasibility. Adjust it based on their feedback, e.g., adjusting performance expectations or scope.

Download Klariti User Story Templates Here

How to Write a User Story With Google Gemini

Now, let’s look at how to capitalize on AI to accelerate the process.

The aim here isn’t to take shortcuts, rather it’s to use its abilities to crunch large amounts of data (often in different formats) and then by following strict instructions produce accurate, well-written and formatted user stories.

Here’s a suggested approach to do this. Adjust the guidelines to suit your specific workflow.

We’re going to break this into three parts:

  1. Prepare source material for the AI to ingest. This is often called ‘training data’. Its whatever information will help the AI to have more context, insight, and background knowledge.
  2. Create the prompt for the user story. After we look at establishing more guidelines for the stories, we’ll define a prompt that gives the AI the sufficient instructions to generate a useful response. In this case, a draft user story.
  3. Refine the results. Working with AI is in iterative process. Think of it as a brainstorming session where you work together to develop a better understanding.

#1 Prepare the Source material for Google Gemini

Now that we’ve gathered the background data, the next step is to prepare Google Gemini with source material, otherwise it has no frame of reference.

As support this process, you need to prepare content so Google Gemini can:

  • Ingest the material in an acceptance format. For example, if may not be able to accept images or sound files.
  • Interpret it in a meaningful way. Ideally, the content should be structured.
  • Use this data to generate the appropriate response.

Remember that under the hood the AI is a predictive mechanism. It’s not ‘thinking’ about the right answer.

Rather, if the source material is structured in an organized manner, and if the prompt (a simple or complex set of instructions) is specific and unambiguous, then it can ‘stitch together’ an answer based on your request.

For this reason, the success or failure of your interactions with AI are often pre-determined by the quality of the material you give it.

That is, if you give it poor, unstructured data, it cannot generate a better answer. Quality outputs are usually a reflection of quality inputs.

In the context of product development, this is the material the AI will use to generate user stories. Typically, it’s your business and functional requirements, but could also include meeting minutes, feedback, and other types of documentation. Ideally, it should be in a ‘structured’ format. 

To ‘feed’ it the source material, you have several choices. One is to copy/paste in the text, for example, the requirements.

If you have ChatGPT Premium, you can create a user story mini application (GPT) and use this to write user stories in a more structured manner. I’ll create a tutorial for this in the coming weeks. If you use Claude, you can feed it PDFs and spreadsheets.

#2 Create the Prompt for the User Story

So, now that we know how the user story should be structured, we’ve fed it the source material.

The next step is to ask Google Gemini to start generating the user stories.

Here’s a suggested prompt to write a user story.

“My goal is to write a series to user stories. As a product manager, I want you to create a formal set of user stories using the following guidelines.

Use the following structure: “As a [persona], I [want to], [so that].”

Consider the following when creating the user stories.

Persona Details

Define the different types of users or personas.

Include any relevant information about their roles, behaviors, and needs.

//This is a comment which you can delete before you enter the prompt. In this example you select the most appropriate person.

New user: person who has just signed up for the service.

Frequent user: person who uses the service daily.

Administrator: person responsible for managing user accounts and content.

Features

List the features or actions that you want the user stories to cover.

Be as specific as possible about what the user needs to do.

//You can delete this comment before you enter the prompt. Add the type of features or actions you want the user to perform.

  • Account creation
  • Profile updating
  • Searching for content
  • Resetting passwords
  • Customizing notifications
  • Accessing support

User Benefits

Explain the benefits or reasons why the users want to perform these actions.

Ensure these benefits align with business goals or user satisfaction.

//Delete this comment. List some of the user benefits

  • Accessing exclusive features
  • Keeping personal information current
  • Quickly finding needed information
  • Regaining account access without external help
  • Receiving relevant notifications
  • Getting immediate assistance with issues

Context or Background

Provide any additional context or background information that is relevant to the user stories.

Include any specific constraints or considerations that need to be taken into account.

//Delete this comment. Example background information you could provide

  • The service is an online platform for content management and social interaction.
  • Users should have a seamless and user-friendly experience.
  • Security and data privacy are critical considerations.

Writing Guidelines

  • Write in the present tense, active voice.
  • Use professional standard English.
  • Avoid jargon, cliches, and industry speak.

Use the following [source material] to create the user story.

//After you’ve entered the prompt, paste in any supporting files.

#3 Refine the Results

Google Gemini, ChatGPT and other LLMs will process this information, then generate the first user story.

You can configure the prompt to create a single user story or multiple. My experience is that single atomic queries perform better.

In general, refining user stories is an iterative process. Here’s how you can structure it:

3.1 Manual Review

Go through each generated story and make notes on:

  • Ambiguities or unclear aspects.
  • Missing elements that are critical for understanding.
  • Any extraneous details that don’t add value.

3.1.2 Team Feedback

Share the initial user stories with your team or stakeholders and gather feedback. Focus on:

  • Their understanding and interpretation of each story.
  • Suggestions for improvement or additional details needed.
  • Consensus on the importance and priority of each story.

Refining user stories using AI requires a structured approach involving clear criteria, iterative feedback, and ‘prompt engineering’.

If you continuously refine your prompts and incorporate feedback, you’ll improve the quality and relevance of the user stories generated.

The Finer Points

For Product Managers, using AI to write user stories offers several benefits, namely, efficiency, consistency, and scalability.

Whether you choose Google Gemini, ChatGPT or Claude, you can quickly produce multiple user stories, saving considerable time compared to manual writing. Make sure to provide strict writing guidelines to ensure it follows a consistent structure and format.

Finally, it’s capable of generating large volumes of user stories, which is particularly useful for large, fast-moving projects. And, of course, it’s flexible enough to adapt to different project needs and user personas, accommodating a wide range of user scenarios.

Have you started to use AI for product manager tasks?

Resources

Use the following resources to learn more about writing user stories:

Templates – User Story (MS Office)

Forms and Spreadsheets – Business Analyst + Product Manager Templates

How to – Use Google Gemini to streamline Software Requirements Specifications Writing Process