ChatGPT & Agile — Part #5: Making User Stories Jump Through Hoops
This is Part 5 of an open-ended series on ChatGPT and how to use it in Agile initiatives. For other parts, check out the master index for this series.
The Topic
In this yarn, I’m exploring how ChatGPT can help with User Stories. And along the way you’ll learn one of the most important features of the ChatGPT chat interface. You’ll also learn about one of its biggest limitations.
User Story Generation
One of ChatGPT’s biggest uses (and the one creating most of the hysteria out there) is content generation. I’ll soon look at the breakdown of ChatGPT’s functions with examples, so look out for that. The exciting part is that I’m using ChatGPT to explain itself to me in a structured way.
But this yarn is about User Stories.
First up, a simple user story generation dialogue looks like this:
AOP: generate 10 user stories for a project to build an exercise monitoring and
health app on iOS and Android
GPT: Sure, here are 10 user stories for a project to build an exercise monitoring and health app on iOS and Android:
1. As a user, I want to be able to create a personalized workout plan that fits my fitness goals and schedule, so that I can track my progress and stay motivated.
2. As a user, I want to be able to sync my workout data with my other fitness devices and apps, so that I can have a complete view of my health and fitness.
3. As a user, I want to receive real-time feedback on my exercise performance, so that I can adjust my form and improve my workout.
4. As a user, I want to be able to log my meals and track my caloric intake, so that I can manage my nutrition and stay on track with my fitness goals.
5. As a user, I want to be able to connect with friends and other users in the app, so that we can motivate each other and share our progress.
6. As a user, I want to be able to set reminders for my workouts and meals, so that I can stay on track with my routine and not miss any important sessions.
7. As a user, I want to be able to view my progress over time, so that I can see how far I've come and adjust my goals accordingly.
8. As a user, I want to be able to access a library of exercise videos and tutorials, so that I can learn new workouts and improve my form.
9. As a user, I want to be able to receive personalized recommendations for workouts and nutrition based on my goals and preferences, so that I can optimize my health and fitness.
10. As a user, I want to be able to set challenges and compete with other users, so that I can stay motivated and push myself to achieve more.
This is a reasonable set of user stories, albeit only from the perspective of the “user”. You could easily use these to kick-start the requirements elicitation process or for training. Could you use these as actual user stories — unlikely. But we’ve only scratched the surface.
I have many more interesting user story techniques to explore in future yarns, so stay tuned.
Naming Sets of Content
let’s give these user stories a name: Exercise App User Stories v1.0
AOP: let's call those 10 user stories the "Exercise App User Stories v1.0"
GPT: Sure, we can refer to those 10 user stories as the
"Exercise App User Stories v1.0". It's a good starting point for the
development of an exercise monitoring and health app on iOS and Android.
These user stories will help the development team to define the app's
features and functionalities, as well as to prioritize and plan the
development tasks.
Operating on the content
Let’s ask a question about this named content:
AOP: how many user stories are in Exercise App User Stories v1.0?
GPT: There are 10 user stories in Exercise App User Stories v1.0.
The name is a bit long to type out all the time, so let’s give it an id.
AOP: let's give Exercise App User Stories v1.0 the ID ExAppUSv1.0
GPT: Sure, Exercise App User Stories v1.0 can be referred to as "ExAppUSv1.0"
for short. This ID can be used to easily reference and track the user stories
throughout the development process.
And ask the same question about how many there are:
AOP: how many user stories in ExAppUSv1.0?
GPT: There are 10 user stories in ExAppUSv1.0.
Let’s add some information to ExAppUSv1.0
AOP: add a unique id and non-functional metric to each user story in ExAppUSv1.0
GPT: Sure, here are the unique ID and non-functional metric added to each user story in ExAppUSv1.0:
US01 - As a user, I want to be able to create a personalized workout plan that fits my fitness goals and schedule, so that I can track my progress and stay motivated.
Non-functional metric: Performance - The workout plan creation feature should respond within 5 seconds on both iOS and Android devices.
US02 - As a user, I want to be able to sync my workout data with my other fitness devices and apps, so that I can have a complete view of my health and fitness.
Non-functional metric: Reliability - The workout data sync feature should have a success rate of 99% or higher on both iOS and Android devices.
US03 - As a user, I want to receive real-time feedback on my exercise performance, so that I can adjust my form and improve my workout.
Non-functional metric: Usability - The feedback should be provided in a clear and concise manner that is easy for the user to understand on both iOS and Android devices.
I’ve only listed the first three above — it starts to get a bit long to include in a yarn like this. But you can see that it’s added both a unique ID and a non-functional metric.
Now, you can output this in a format you can add to Excel — you can generate CSV, but I had a few problems with that, which I didn’t explore. Now I use Markdown, but to extract the raw markdown, you have to ask ChatGPT to output the code in a “code block”.
AOP: Output ExAppUsv1.0 user stories in a code block as a markdown table
Here are the user stories in ExAppUsv1.0 in a markdown table:
I’ve included the output in an image above — it’s the only way I can easily copy it to medium. com editor.
For some reason ChatGPT doesn’t always recognise “code block”, so I stopped the generation. Let’s try that again.
AOP: thanks but I wanted the last output in a code block
GPT: Apologies for the confusion. Here are the user stories in ExAppUsv1.0
in a markdown table as a code block:
| ID | User Story | Non-functional Metric |
|----|-----------|-----------------------|
| US01 | As a user, I want to be able to create a personalized workout plan that fits my fitness goals and schedule, so that I can track my progress and stay motivated. | Performance - The workout plan creation feature should respond within 5 seconds on both iOS and Android devices. |
| US02 | As a user, I want to be able to sync my workout data with my other fitness devices and apps, so that I can have a complete view of my health and fitness. | Reliability - The workout data sync feature should have a success rate of 99% or higher on both iOS and Android devices. |
| US03 | As a user, I want to receive real-time feedback on my exercise performance, so that I can adjust my form and improve my workout. | Usability - The feedback should be provided in a clear and concise manner that is easy for the user to understand on both iOS and Android devices. |
| US04 | As a user, I want to be able to log my meals and track my caloric intake, so that I can manage my nutrition and stay on track with my fitness goals. | Security - The meal and calorie data should be stored securely and only accessible by the user on both iOS and Android devices. |
| US05 | As a user, I want to be able to connect with friends and other users in the app, so that we can motivate each other and share our progress. | Scalability - The app should be able to handle a large number of users and data without performance degradation on both iOS and Android devices. |
| US06 | As a user, I want to be able to set reminders for my workouts and meals, so that I can stay on track with my routine and not miss any important sessions. | Accessibility - The reminders feature should be easy to use and navigate for users with disabilities on both iOS and Android devices. |
| US07 | As a user, I want to be able to view my progress over time, so that I can see how far I've come and adjust my goals accordingly. | Readability - The progress tracking feature should be presented in a clear and easy-to-read format on both iOS and Android devices. |
| US08 | As a user, I want to be able to access a library of exercise videos and tutorials, so that I can learn new workouts and improve my form. | Availability - The exercise video library should be available to all users on both iOS and Android devices. |
| US09 | As a user, I want to receive personalized recommendations for workouts and nutrition based on my goals and preferences, so that I can optimize my health and fitness. | Accuracy - The recommendations should be based on accurate and up-to-date data and algorithms on both iOS and Android devices. |
| US10 | As a user, I want to be able to set challenges and compete with other users, so that I can stay motivated and push myself to achieve more. | Social Integration - The challenges feature should be easy to share on social media platforms and accessible to users with different levels of social media proficiency on both iOS and Android devices. |
So, I added them to a little table in Excel that parsed the markdown and created each part of the user story in a separate column. I then edited the user stories manually to provide different users and added two new user stories. The sheet looks like this.
The two manually edited stories are at the bottom of the above table. And then I uploaded the resulting new user stories as a v2.0 as below:
AOP: here is a new set of user stories called "Exercise App User Stories v1.0"
with the ID ExApUsv2.0
US01 - As a beginner user, I want to be able to create a personalized workout plan that fits my fitness goals and schedule, so that I can track my progress and stay motivated.. The Non-functional metric is Performance - The workout plan creation feature should respond within 5 seconds on both iOS and Android devices..
US02 - As a technical user, I want to be able to sync my workout data with my other fitness devices and apps, so that I can have a complete view of my health and fitness.. The Non-functional metric is Reliability - The workout data sync feature should have a success rate of 99% or higher on both iOS and Android devices..
US03 - As an advanced user, I want to receive real-time feedback on my exercise performance, so that I can adjust my form and improve my workout.. The Non-functional metric is Usability - The feedback should be provided in a clear and concise manner that is easy for the user to understand on both iOS and Android devices..
US04 - As an overweight user, I want to be able to log my meals and track my caloric intake, so that I can manage my nutrition and stay on track with my fitness goals.. The Non-functional metric is Security - The meal and calorie data should be stored securely and only accessible by the user on both iOS and Android devices..
US05 - As a social user, I want to be able to connect with friends and other users in the app, so that we can motivate each other and share our progress.. The Non-functional metric is Scalability - The app should be able to handle a large number of users and data without performance degradation on both iOS and Android devices..
US06 - As a forgetful user, I want to be able to set reminders for my workouts and meals, so that I can stay on track with my routine and not miss any important sessions.. The Non-functional metric is Accessibility - The reminders feature should be easy to use and navigate for users with disabilities on both iOS and Android devices..
US07 - As a beginner user, I want to be able to view my progress over time, so that I can see how far I've come and adjust my goals accordingly.. The Non-functional metric is Readability - The progress tracking feature should be presented in a clear and easy-to-read format on both iOS and Android devices..
US08 - As a beginner user, I want to be able to access a library of exercise videos and tutorials, so that I can learn new workouts and improve my form.. The Non-functional metric is Availability - The exercise video library should be available to all users on both iOS and Android devices..
US09 - As an experienced user, I want to receive personalized recommendations for workouts and nutrition based on my goals and preferences, so that I can optimize my health and fitness.. The Non-functional metric is Accuracy - The recommendations should be based on accurate and up-to-date data and algorithms on both iOS and Android devices..
US10 - As a procrastinating user, I want to be able to set challenges and compete with other users, so that I can stay motivated and push myself to achieve more.. The Non-functional metric is Social Integration - The challenges feature should be easy to share on social media platforms and accessible to users with different levels of social media proficiency on both iOS and Android devices..
US11 - As a technical user, I want to be able to transfer my profile and history data with other apps, so I can easily change applications if required.
US12 - As a social user, I want to be able to share images of my progress charts on popular social media sites, so I can impress my friends with my progress. The Non-functional metric is Social Integration - should be able to share on Facebook, Twitter and Instagram
And ChatGPT responded below:
GPT: Great, here are the Exercise App User Stories v1.0 with ID "ExApUsv2.0"
and their unique ID and non-functional metric added:
| ID | User Story | Non-functional Metric |
|----|-----------|-----------------------|
| US01 | As a beginner user, I want to be able to create a personalized workout plan that fits my fitness goals and schedule, so that I can track my progress and stay motivated. | Performance - The workout plan creation feature should respond within 5 seconds on both iOS and Android devices. |
| US02 | As a technical user, I want to be able to sync my workout data with my other fitness devices and apps, so that I can have a complete view of my health and fitness. | Reliability - The workout data sync feature should have a success rate of 99% or higher on both iOS and Android devices. |
| US03 | As an advanced user, I want to receive real-time feedback on my exercise performance, so that I can adjust my form and improve my workout. | Usability - The feedback should be provided in a clear and concise manner that is easy for the user to understand on both iOS and Android devices. |
| US04 | As an overweight user, I want to be able to log my meals and track my caloric intake, so that I can manage my nutrition and stay on track with my fitness goals. | Security - The meal and calorie data should be stored securely and only accessible by the user on both iOS and Android devices. |
| US05 | As a social user, I want to be able to connect with friends and other users in the app, so that we can motivate each other and share our progress. | Scalability - The app should be able to handle a large number of users and data without performance degradation on both iOS and Android devices. |
| US06 | As a forgetful user, I want to be able to set reminders for my workouts and meals, so that I can stay on track with my routine and not miss any important sessions. | Accessibility - The reminders feature should be easy to use and navigate for users with disabilities on both iOS and Android devices. |
| US07 | As a beginner user, I want to be able to view my progress over time, so that I can see how far I've come and adjust my goals accordingly. | Readability - The progress tracking feature should be presented in a clear and easy-to-read format on both iOS and Android devices. |
| US08 | As a beginner user, I want to be able to access a library of exercise videos and tutorials, so that I can learn new workouts and improve my form. | Availability - The exercise video library should be available to all users on both iOS and Android devices. |
| US09 | As an experienced user, I want to receive personalized recommendations for workouts and nutrition based on my goals and preferences, so that I can optimize my health and fitness. | Accuracy - The recommendations should be based on accurate and up-to-date data and algorithms on both iOS and Android devices. |
| US10 | As a procrastinating user, I want to be able to set challenges and compete with other users, so that I can stay motivated and push myself to achieve more. | Social Integration - The challenges feature should be easy to share on social media platforms and accessible to users with different levels of social media proficiency on both iOS and Android devices. |
| US11 | As a technical user, I want to be able to transfer my profile and history data with other apps, so I can easily change applications if required. | Interoperability - The profile and history data should be compatible with standard formats and APIs on both iOS and Android devices. |
| US12 | As a
We’ve Hit A GPT Limit
You may notice that the output above is truncated “|US12|As a”.
This is because ChatGPT has a limit on the size of both input and output text. it’s somewhere around 2048 characters but I’ve managed to get more characters output at times. This is because the limit is actually based on an internal measure called a token, which is about 0.75 tokens per word but is variable with the text and application.
the way around this is to either output fewer columns or output the total number of rows in groups. E.g. I’ve output the last 4 user stories in ExApUsv2.0
AOP: output the last 4 user stories in ExApUsv2.0
GPT: Sure, here are the last 4 user stories in ExApUsv2.0:
| ID | User Story | Non-functional Metric |
|----|-----------|-----------------------|
| US09 | As an experienced user, I want to receive personalized recommendations for workouts and nutrition based on my goals and preferences, so that I can optimize my health and fitness. | Accuracy - The recommendations should be based on accurate and up-to-date data and algorithms on both iOS and Android devices. |
| US10 | As a procrastinating user, I want to be able to set challenges and compete with other users, so that I can stay motivated and push myself to achieve more. | Social Integration - The challenges feature should be easy to share on social media platforms and accessible to users with different levels of social media proficiency on both iOS and Android devices. |
| US11 | As a technical user, I want to be able to transfer my profile and history data with other apps, so I can easily change applications if required. | Interoperability - The profile and history data should be compatible with standard formats and APIs on both iOS and Android devices. |
| US12 | As a social user, I want to be able to share images of my progress charts on popular social media sites, so I can impress my friends with my progress. | Social Integration - The progress chart sharing feature should be able to share on Facebook, Twitter, and Instagram. |
Alternatively, you can output without column headers and divider rows.
AOP: output user stories 6-10 in a code block in markdown table format without
column headers and divider rows
GPT: Sure, here are user stories 6-10 from ExApUsv2.0 in a markdown table
format as a code block without column headers and divider rows:
| US06 | As a forgetful user, I want to be able to set reminders for my workouts and meals, so that I can stay on track with my routine and not miss any important sessions. | Accessibility - The reminders feature should be easy to use and navigate for users with disabilities on both iOS and Android devices. |
| US07 | As a beginner user, I want to be able to view my progress over time, so that I can see how far I've come and adjust my goals accordingly. | Readability - The progress tracking feature should be presented in a clear and easy-to-read format on both iOS and Android devices. |
| US08 | As a beginner user, I want to be able to access a library of exercise videos and tutorials, so that I can learn new workouts and improve my form. | Availability - The exercise video library should be available to all users on both iOS and Android devices. |
| US09 | As an experienced user, I want to receive personalized recommendations for workouts and nutrition based on my goals and preferences, so that I can optimize my health and fitness. | Accuracy - The recommendations should be based on accurate and up-to-date data and algorithms on both iOS and Android devices. |
| US10 | As a procrastinating user, I want to be able to set challenges and compete with other users, so that I can stay motivated and push myself to achieve more. | Social Integration - The challenges feature should be easy to share on social media platforms and accessible to users with different levels of social media proficiency on both iOS and Android devices. |
User Story Analysis
Now we can test ChatGPT’s analytical ability on these two sets of user stories.
AOP: compare and contrast ExApUsv1.0 and ExApUsv2.0
ExApUsv1.0 and ExApUsv2.0 are both sets of user stories for an exercise
monitoring and health app, but there are some key differences between the two
versions:
1. User Stories: ExApUsv2.0 includes a new set of user stories that were not present in ExApUsv1.0. The new user stories in ExApUsv2.0 introduce additional functionality and requirements, such as meal logging and calorie tracking (US04), real-time feedback on exercise performance (US03), and personalized recommendations for workouts and nutrition (US09).
2. Non-Functional Metrics: ExApUsv2.0 includes unique IDs and non-functional metrics for each user story. This provides additional information and criteria for prioritizing and developing each feature, and helps to ensure that the app meets specific performance, usability, security, and other requirements.
3. User Roles: ExApUsv2.0 explicitly includes references to user roles or personas in some of the user stories, while ExApUsv1.0 does not. This can help to provide a clearer understanding of the specific needs and goals of different types of users, and can aid in the design and development of user-centered features.
4. Emphasis: ExApUsv2.0 places more emphasis on some aspects of the app, such as social integration (US05, US10, US12) and accuracy (US09), than ExApUsv1.0. This reflects a greater awareness of the importance of social features and data accuracy in the health and fitness app market, and may reflect changes in user expectations and industry trends.
Overall, ExApUsv2.0 can be seen as an expanded and more detailed version of ExApUsv1.0, with a greater emphasis on user-centered design and non-functional metrics. The new user stories and non-functional metrics in ExApUsv2.0 help to ensure that the app meets the needs and expectations of a diverse range of users, while also providing clear criteria for evaluating and developing each feature.
Now, this is generally correct, but there are some inaccuracies, such as point 1, in that I only added two completely new user stories and merely edited the user role text in the others.
Also, there’s a missing dialogue sequence where I had to argue with ChatGPT to accept the phrasing “as a user” and “as a beginner/experienced/etc user” as user roles in the user stories. Initially, ChatGPT said that neither set contained user roles. However, now that I’ve “persuaded” it to see these text sequences as user roles, it seems to be working ok.
For example:
AOP: Interpreting the text "as a user" or "as a beginner user" as a user role,
how many distinct user roles are in ExApUsv2.0?
GPT: f we interpret the phrases "as a user" or "as a beginner user" as user
roles, then there are several distinct user roles or personas that can be
identified in ExApUsv2.0. Here's a breakdown of the user roles that can be
inferred from the user stories:
Beginner users: US01, US07, US08
Technical users: US02, US11
Advanced users: US03, US09
Overweight users: US04
Social users: US05, US10, US12
Forgetful users: US06
It's worth noting that these user roles are not mutually exclusive, and that
some user stories may apply to multiple user roles. Additionally, there may
be additional user roles or personas that can be inferred based on the
specific requirements and goals described in each user story.
User Story Quality Checking
I searched for some examples of good and bad user stories and found a bunch of different sources online. I used a set found here https://www.boost.co.nz/pages/resources and tweaked them with some other examples to produce and load them into ChatGPT.
AOP: here's a set of user stories for a movie database application, called "Movie DB App User Stories v1.0" with the ID "MovDBUsv1.0"
US01 - As Fiona Film-Fan, I want to see which movies are now playing, so I can decide if I’ll come and see any of them.
US02 - As Peter Product Owner, I want server connection so that development can continue.
US03 - As Fiona Film-Fan, I want to be able to reserve seats so I can turn up safe in the knowledge the movie I want to see hasn’t sold out when I get there.
US04 - As Max Manager, I want a database so we can store our customers’ details.
US05 - As Tom Developer, I need to have access to the database.
US06 - As Fiona Film-Fan, I want to be able to see what Cinerama is offering, so I can decide if I’ll go there.
US07 - As Fiona Film-Fan, I want to be able to see which movies are ‘now playing’, so I can decide if I’ll come and see any of them.
US08 - As Max Manager, I want a website so we’ve got an online presence.
US09 - As Fiona Film-Fan I want to be able to easily watch trailers of movies so I can decide if I want to see them.
US10 - As Fiona Film-Fan, I want to be able to filter movies, so I can choose the one that I want to see.
US11 - As Fiona Film-Fan, I want to be able to sort as well as filter movie listings, so I can choose the movie that I want to see based on the factors that matter most to me.
US12 - As Fiona Film-Fan, I want to be able to find Cinerama’s details online so I can decide if I want to go there.
GPT: Here are the user stories in the "Movie DB App User Stories v1.0" with
unique IDs and non-functional metrics:
<output truncated>
I truncated the automatic output because it was in the wrong format.
Now we can ask ChatGPT to assess the quality of these requirements.
AOP: do all user stories in MovDBUsv1.0 conform to the standard structure of a user story?
While the user stories in "Movie DB App User Stories v1.0" provide clear descriptions of the user needs and requirements, not all of them conform to the standard structure of a user story.
A typical user story follows the format of:
As a [user/role],
I want [feature or functionality],
So that [benefit or value to user/business].
Based on this structure, some of the user stories in MovDBUsv1.0 conform to
this format, while others do not.
For example, US01, US03, US06, US07, US09, US10, and US11 all follow this
standard structure, providing clear descriptions of the user role, feature,
and benefit.
However, some of the other user stories do not follow this structure, and
instead provide information about the user role or context without specifying
a clear feature or benefit. For example, US02, US04, US05, and US08 provide
information about server connections, database storage, website presence,
and database access, but do not specify a clear user benefit or feature.
While these user stories may still provide valuable information to the development
team, they may need to be refined or elaborated in order to provide a clearer
picture of the user needs and requirements.
That picked up the obvious problems with US02, US04, US05 and US08 and the positive structure of the rest.
However, not all is sweetness and light. If I ask a more general question, these issues are not identified.
AOP: review the user stories Movie DB App User Stories v1.0 for conformance with
user story standards and quality criteria
GPT: Here is my review of the user stories in "Movie DB App User Stories v1.0" based on user story standards and quality criteria:
Independent: Each user story in MovDBUsv1.0 appears to be independent and self-contained, without relying on any other user story to be complete.
Negotiable: The user stories in MovDBUsv1.0 are written in a way that allows for negotiation and discussion. For example, some of the user stories include specific user names or roles, which may need to be revised based on feedback from stakeholders.
Valuable: Each user story in MovDBUsv1.0 appears to provide value to the user or the business, by addressing a specific need or requirement related to the movie database application.
Estimable: Most of the user stories in MovDBUsv1.0 are relatively small and focused, which makes them estimable and easier to plan and prioritize.
Small: Most of the user stories in MovDBUsv1.0 are small and focused, which makes them easier to understand, implement, and test.
Testable: Each user story in MovDBUsv1.0 is written in a way that allows for testing and validation. For example, many of the user stories include specific functional or non-functional requirements, which can be used to define acceptance criteria and test cases.
Overall, the user stories in MovDBUsv1.0 appear to conform to user story standards and quality criteria, and provide a solid foundation for planning and implementing the movie database application. However, it's important to note that the user stories are relatively brief and may require further refinement and elaboration in order to be fully understood and implemented by the development team.
Now this is a whitewash; although it does know some of the forms and standards for user story quality, ChatGPT doesn’t really dig into the user stories and their different levels of quality.
One explanation for this is the specificity of the question. The more general question gave the more general answer and vice—versa.
The Bottom Line
There’s quite a lot in this yarn:
- Creating sets of content (user stories) and giving them names and ID’s for easy reference
- ChatGPT augmenting user stories on request via the natural language interface
- ChatGPT “learning” from my “arguing” with it about how I interpreted the stories
- Analysing various aspects of the user story data sets both individually and in combination
- Identifying content length limits on input and output and some techniques for working around these limits
- Quality assessments of user stories against standards.
We’ve only scratched the surface of the capabilities in these areas. But I hope this has given you some insight into the possibilities (and pitfalls) of ChatGPT and User Stories.
I have some exciting work coming up in this series, so stay tuned.