Professional Documents
Culture Documents
Mental Health Support Chatbot SRS @2105925
Mental Health Support Chatbot SRS @2105925
Mental Health Support Chatbot SRS @2105925
PROJECT
MENTAL HEALTH SUPPORT CHATBOT FOR
KENYATTA NATIONAL HOSPITAL
SYSTEM REQUIREMENTS SPECIFICATION
DOCUMENT
1. INTRODUCTION
1.1 Purpose
This document describes the System Requirements Specification (SRS) for version 1.0 of a
mental health support chatbot developed for Kenyatta National Hospital. The chatbot’s goal is to
help healthcare professionals and patients deal with anxiety, depression, crisis intervention, and
overall well-being. It will function alone, with no connections to other hospital systems or
databases.
Developers: The developers bear the primary responsibility for comprehending the
chatbot's technical aspects, functionalities, and implementation requirements. This
section outlines the overall design and architecture.
Project Managers:They Are responsible for planning, tracking progress, and ensuring that
the project meets the specified requirements. This section gives an overview of the
project's scope and helps to manage expectations.
1|Page
SRS
Health Care Professionals: They need to be confident that the chatbot meets their needs,
provides appropriate support, and follows ethical guidelines for mental health
interventions. This section outlines the functionalities and limitati ons that apply to them.
The Patients: In order to utilize the chatbot efficiently, they must first comprehend its
goals, features, and constraints in addition to its function as a tool for self-evaluation and
resource gathering. This section highlights the limitations and provides clarification on
the intended use.
Testers: It is their responsibility to make sure the chatbot functions and performs as
intended. This section provides a comprehensive reference for testing purposes.
Address: Anxiety, depression, and general well-being, as well as providing crisis intervention
support to healthcare professionals and patients.
Offer: Evidence-based materials, self-assessment tools, and optional virtual therapy sessions
with a pre-programmed counselor.
2|Page
SRS
Operate: independently, without connecting to other hospital systems or databases.
Increase access to mental health support: Provide an easily accessible and anonymous resource
for self-assessment, information, and initial support.
Empower individuals: Provide tools for self-awareness and self-management of mental health
to supplement existing professional services.
Support healthcare professionals: Provide an additional tool to help patients find appropriate
resources and interventions.
Reduce stigma: Create a more accessible and approachable environment for dealing with
mental health issues.
While this SRS focuses on version 1.0, future versions may include:
Voice interaction improves accessibility and user experience.
This project aligns with Kenyatta National Hospital's goals, which are:
3|Page
SRS
2. OVERALL DESCRIPTION
2.1 User Classes and Characteristics
This section identifies the user categories for the mental health support chatbot:
Healthcare professionals who May not be specialists in mental health, but they do possess
knowledge in Healthcare may also use the chatbot to acquire more information.
Patients (Favored)
People suffering from anxiety, depression, or other mental health issues who want to assess
themselves, get resource recommendations, and potentially interact with a virtual therapist will
find the chatbot really helpful and handy.
Mental Health Professionals: mental health specialists may occasionally engage with the
chatbot, even though they are not its main users, in order to learn about its features and assess
whether it meets the necessary health guidelines
4|Page
SRS
2.2 Operating Environment
2.2.1 Hardware and Software Requirements
Hardware: There are no specific hardware requirements beyond web-enabled devices
(computers, smartphones, and tablets) with internet access.
Software:
Web Browser: The chatbot will be accessible from a variety of web browsers and devices.
Specific browser compatibility information will be determined during development and testing.
Operating System: The chatbot's web-based nature allows it to run on a variety of operating
systems (Windows, macOS, and Linux) as long as a compatible web browser is available.
Backend Server: The chatbot will require a server to execute application logic and securely
store data.
Independent System: In this initial version, the chatbot will operate independently and will not
connect to any other hospital systems or databases.
Technology stack: The development will be done in JavaScript and Node.js, in accordance with
established coding conventions and security best practices.
Accessibility considerations: While v1.0 is not fully accessible, future versions will include
accessibility features to meet WCAG guidelines and accommodate users with disabilities.
Data Privacy and Security: The chatbot will follow applicable data privacy regulations (e.g.,
GDPR, HIPAA) and employ strong security measures to ensure user data confidentiality and
integrity.
5|Page
SRS
These constraints ensure focused development for a functional v1.0, while also acknowledging
the need for future enhancements and adhering to ethical and regulatory guidelines.
User Guide: A detailed paper that explains the chatbot’s purpose, features, limits, and how to
utilize it efficiently.
FAQs: An easily accessible component of the chatbot interface that addresses frequently asked
questions and provides short responses.
Contextual Help: Pop-up help messages appear within the chatbot interface, providing
instruction and clarity based on user interactions and specific areas.
Users have internet connection and web browsers. They have basic computer literacy
and can navigate web interfaces comfortably. Users are aware of the chatbot’s limits as a
self-assessment and resource tool, rather than a replacement for professional mental
health examination and therapy.
6|Page
SRS
2.5.2 Dependencies:
The chatbot’s development and deployment require a secure backend server to host the
application and store data. The project’s growth is dependent on the chosen web
development frameworks and libraries performing as expected and being interoperable
with various web browsers and devices.
7|Page
SRS
3. SYSTEM FEATURES
3.1 Self-Assessment
3.1.1 Description and Priority
Description: In order to provide a personalized experience, the self-assessment feature offers
standardized questionnaires for depression, anxiety, and general well-being that adjust based on
user responses. The results are presented concisely, highlighting any limitations and suggesting
expert assistance when necessary. Mental health assessments are conducted in accordance with
ethical guidelines, including informed consent and data privacy.
Priority: HIGH
Understanding user needs: Offers preliminary insights into possible mental health issues
that the use might be going through.
Personalized experience: Tailored assessments provide appropriate information and
resources.
Identifying high-risk situations: Triggers intervention measures when needed.
Self-awareness promotion: Gives users the ability to comprehend their own well-being.
While other elements, such as resource recommendations and virtual therapist contact, are
useful, the self-assessment serves as the foundation for the chatbot's operation and user
assistance, making it a high priority feature.
Response:
1. Welcome message: Welcome to the self-assessment tool. This assessment can help you learn
more about your mental health. Keep in mind that this is not a diagnosis, and seeking
professional assistance when necessary is always advised."
2. Selection of assessment type: "Please select the area you would like to have assessed:
general well-being, depression, or anxiety."
8|Page
SRS
Scenario 2: Completing an Assessment
Stimulus: User selects an assessment type (e.g., Anxiety).
Response:
1. Introduction to assessment: "There are X questions on this assessment. Please respond
honestly and to the best of your abilities. "There are no correct or incorrect answers."
2. Questionnaire Presentation: The chatbot presents the assessment questions one by one,
allowing the user to choose an answer from multiple-choice alternatives or type a short text
response.
3. Completion and Analysis: After answering the questions, the chatbot processes the
information and delivers a response.
1. Assessment summary: "Thank you for completing the assessment. Based on your responses,
your score is [Brief overview of results without particular diagnoses or classifications]."
2. Limitations and Disclaimer: "Remember that this is a self-assessment tool and not a
substitute for professional help . We strongly advise consulting a therapist or other healthcare
expert for professional counsel if you are worried about your wellbeing."
3. Recommendations for resources: "Here is a selection of resources that we think you might find
useful. Would you like to look into these now?"
Response:
1. Clarification: The chatbot uses its knowledge base to help clarify the user's question and
give relevant facts.
2. Limited scope reminder: The chatbot emphasizes its limitations and advises the user to seek
expert assistance for any issues that exceed its capabilities.
3. Resource options: The chatbot offers to guide the user to suitable resources that can answer
their unique questions.
9|Page
SRS
.3.1.3 Self Assessment: Functional Requirements
Upon user selection, the chatbot will deliver a welcome message that explains the purpose and
restrictions of the assessment.
The chatbot will provide users the choice to select amongst self-evaluations for general
wellbeing, depression, and anxiety
Each question will be accompanied by clear and understandable answer choices or instructions
for short text responses.
The chatbot will also users to review and change their answers before submitting them.
The system will evaluate user input to ensure that it follows the expected structure for each
question type (for example, selecting an option from the available options or conforming to
character restrictions for text responses).
When an input is deemed invalid, the chatbot will clearly indicate the issue and assist the user
in providing an appropriate response.
The scoring mechanism will be recorded and transparent, in accordance with known best
practices for the assessment tools used.
10 | P a g e
SRS
REQ-5: Results Presentation
The assessment results will be presented by the chatbot in an understandable, succinct, and
straightforward manner.
Results should not contain clinical terminology or language that users may misinterpret.
The chatbot will highlight the limitations of the self-evaluation and the significance of getting
expert assistance when necessary.
To ensure accuracy and relevance, healthcare professionals will curate and maintain the
resource list.
The user shall have the option to explore the resources or decline.
The chatbot shall acknowledge its limitations and direct users to seek professional help for
complex questions or concerns beyond its capabilities.
The chatbot shall offer relevant resources to users who inquire about specific topics.
User data acquired throughout the self-assessment procedure will be anonymised and securely
kept.
The chatbot will not share user data with any third-party applications or services unless the user
explicitly consents.
11 | P a g e
SRS
3.2Resource Recommendation
3.2.1 Description and Priority
Description: The resource recommendations function provides users with a list of useful and
relevant resources based on their needs and self-assessment scores.
Priority: HIGH
Connecting users with support: Fills the gap between self-assessment and requesting
additional help.
Providing different options: Provides a range of resources tailored to individual
requirements and preferences.
Empowering informed choices: Allows users to investigate possibilities and make
informed decisions regarding their well-being.
Similar to the self-assessment function, resource recommendations are critical for
addressing user needs beyond the initial evaluation.
Response:
1. Personalized list: The system presents a list of resources tailored to the user's assessment
results and any additional information provided.
2. Resource details: Each resource includes a brief description, contact information, and
accessibility details (e.g., language availability).
3. User control: The system informs the user that they can explore the resources or choose not
to.
12 | P a g e
SRS
Scenario 2: User Requests Additional Information
Stimulus: User clicks on a specific resource or asks for more information about a resource.
Response:
1. Detailed information: The system displays additional details about the selected resource,
such as a longer description, website link, or contact details.
2. Accessibility options: If available, the system offers alternative formats for resource
information (e.g., audio descriptions, transcripts) to cater to users with disabilities.
Healthcare professionals shall curate and regularly update the resource list to ensure accuracy,
relevance, and inclusion of diverse options catering to various needs and backgrounds.
The recommendations should address the user's specific needs and concerns identified during the
assessment.
The system shall present the recommended resources in a clear, concise, and user-friendly
format, adhering to best practices for information presentation and accessibility.
Brief description: A clear and concise explanation of the resource's purpose and target
audience.
13 | P a g e
SRS
REQ-12: User Choice and Control
The user shall have the option to:
The system shall empower users to make informed choices about their well-being without
pressuring them to engage with specific resources.
This may involve providing alternative formats for resource information, such as:
Text with sufficient color contrast and appropriate font size for users with visual
impairments.
These functional requirements ensure the resource recommendation feature delivers valuable,
personalized, and accessible support to users seeking further assistance after completing the self-
assessment.
14 | P a g e
SRS
3.3 Chat with Virtual Therapist (Optional)
3.3.1 Description and Priority
Description: This optional feature allows users to connect with a pre-programmed virtual
therapist via text-based conversation. The virtual therapist provides basic assistance, empathy,
and nonjudgmental listening, while striving to:
Priority: Medium
Justification: While not required for the chatbot’s main operation, this feature can give
additional help and resources for users who require basic emotional support and guidance.
However, its development and execution should put user safety and ethics first.
Response:
1. Greeting message: "Welcome to the virtual therapist chat. I'm here to provide you with a
safe environment in which to discuss your concerns. Please keep in mind that I am not a therapist
and cannot offer professional advice or diagnoses.
2. Opening prompt: "What would you like to talk about today?"
Stimulus: The user types a message expressing their thoughts, feelings, or concerns.
Response:
The virtual therapist will employ pre-programmed responses and discussion trees to
acknowledge and affirm the user's sentiments. Ask open-ended questions.
Stimulus: During the session, the virtual therapist looks for terms or phrases that indicate a
potentially high-risk condition (for example, suicide thoughts or self-harm ideation).
15 | P a g e
SRS
Response:
1. Immediate intervention: The virtual therapist will express concern about the user's safety.
Provide emergency numbers for local crisis hotlines or mental health services.
Encourage the user to seek immediate assistance from a real human therapist or emergency
services.
2. Disconnect and transition: The virtual therapist discussion will end, and the user will be led
to a prominent link or button that provides instant access to crisis services and encourages
professional aid.
These scenarios depict possible interactions between users and the virtual therapist,
emphasizing the need of providing necessary support, identifying high-risk circumstances, and
prioritizing user safety
16 | P a g e
SRS
4.EXTERNAL INTERFACE REQUIREMENTS
4.1User Interfaces
The mental health support chatbot will largely use a web-based user interface that will be
accessible on a variety of devices (computers, cellphones, and tablets).
Clean and intuitive design: Prioritize clarity and ease of use, considering various user demands
and technical expertise. Accessibility: Follow WCAG criteria to ensure accessibility for users
with impairments. This could include things like screen reader compatibility, alternative text
explanations for photographs, and changeable font sizes.
Responsive design: Customize the interface layout and elements to fit different screen sizes
and devices for the best user experience.
Use clear and succinct language that is intelligible to users without a mental health background.
Avoid preconceptions and biases to promote inclusivity and respect for varied identities.
The landing page includes a welcome greeting and a brief explanation of the chatbot’s purpose.
Chat Interface: A text-based chat window allows for user input and chatbot responses.
Options to start a self-assessment, obtain resource recommendations, or communicate
with the virtual therapist (if enabled).
Contextual assistance buttons or icons provide supplementary information in specific
parts.
Clear statement of limitations and a reminder to seek professional assistance if needed.
Self-Assessment: Questionnaires with clear instructions and response options.
A progress indicator displays completed and unanswered questions.
Option to check and amend responses before submitting.
17 | P a g e
SRS
Resource Recommendations:A list of handpicked resources based on user needs and
evaluation results.
Resources include brief descriptions and contact information.
Option to look into resource specifics or obtain extra information (if available).
Virtual Therapist Chat (Optional): Text-based chat with virtual therapist.
An obvious indication that the virtual therapist is not a real person and cannot give
diagnosis or treatment.
Prompts and open-ended inquiries that inspire introspection and investigation.
Crisis intervention: A prominent notice is displayed in high-risk scenarios, expressing
worry and encouraging the user to seek help.
Clear and direct directions for contacting emergency agencies and crisis hotlines.
A persistent reminder message encourages the user to seek help if necessary.
The chatbot should be compatible with several web browsers and devices, including
desktop and laptop computers (Windows, macOS, ChromeOS) and smartphones and
tablets (Android, iOS).
Users interact with the chatbot via web browser, entering text and receiving visual
responses. The chatbot works with server-side application logic to process user input,
obtain data, and provide responses. User participation does not require any additional
hardware components other than normal computing devices and internet connectivity.
The communication protocol between the web browser and the server-side application
will most likely be HTTP (Hypertext Transfer Protocol), the standard protocol for web
communication.
18 | P a g e
SRS
The chatbot will be installed on a web server (such as Apache or Nginx), which will host
the application files and allow users to connect.
4.3.2 Database:
A relational database (such as MySQL or PostgreSQL) will hold user data (anonymized),
assessment results, resource information, and virtual therapist conversation logs (if
enabled).
The chosen development approach will determine the programming language and frameworks.
However, popular options for web applications include:
Data flow:
Incoming Data: User input from chat interface (text messages, button clicks) Database data
(evaluation results, resources).
Outgoing Data: Chatbot responses displayed in the user interface Anonymous user data
stored in the database Virtual therapist conversation logs (if enabled) kept in the database.
Communication Services:
The web application will connect with the database using the communication library of choice,
allowing for data retrieval and storage.
Data sharing:
User data (anonymized) will be shared between the web application and the database for storage
of assessment findings and future analysis (with user consent and for ethical research purposes).
Implementation Constraints:
Specific data sharing techniques, such as object-relational mapping (ORM) tools, may be used to
facilitate communication between the application and the database.
19 | P a g e
SRS
5. Other Nonfunctional Requirements
5.1 Performance Requirements
5.1.2 Overall performance:
The mental health support chatbot should prioritize response and efficiency to sustain user
engagement and confidence. Minimize page load times to 2-3 seconds under normal network
circumstances. The system should be able to support multiple concurrent user sessions without
significantly degrading performance, ensuring future scalability.
Resource Recommendations: After completing the self-assessment, the user should get a list
of recommended resources within 3 seconds.
Optional: Virtual Therapist Chat. To sustain the illusion of a real-time conversation, the virtual
therapist should respond to user messages within two seconds.
These performance criteria provide a guideline for developers to maximize the efficiency of the
chatbot.
20 | P a g e
SRS
5.2 Safety Requirements
5.2.1 Users’ Safety:
The chatbot will Prioritize user safety with strong protection and encourage responsible use. It
will Identify and handle high-risk scenarios. Create a rigorous strategy for identifying keywords
or phrases that indicate possible crises (such as suicide ideation or self-harm).
Provide clear and direct instructions for accessing emergency services and crisis hotlines,
such as prominently displayed phone numbers, links to local crisis hotline websites, and the
option to text a designated crisis intervention number (where applicable).
Encourage the user to seek professional help from a therapist or emergency services.
Disconnect and transfer. Non-essential functions may be temporarily disabled, and the user sent
to a specialized crisis intervention Page with persistent help resources.
Data privacy and security: To protect user information,we will follow applicable data privacy
regulations (e.g., GDPR, HIPAA). This involves anonymizing user data before storage.
Educating users on data practices and privacy rights. Providing transparency and limitations.
Clearly convey the chatbot’s limitations, emphasizing that it cannot give professional diagnosis
or treatment. Encourage users to seek professional help with complex mental health issues.
These safety rules are intended to protect users' well-being and promote responsible usage of the
mental health support chatbot.
21 | P a g e
SRS
5.3 Security Requirements
To protect user data, implement strong security methods such as secure user authentication and
authorization, as well as data encryption both at rest and in transit.
Conduct regular security audits and vulnerability assessments.
Comply with relevant data security standards and best practices.
Response time: Aim for short response times (e.g., under 3 seconds) to keep users engaged and
prevent annoyance.
Error management: Use strong error handling methods to smoothly handle unexpected situations
and avoid crashes.
22 | P a g e
SRS
Modular design entails creating code with well-defined modules to facilitate maintenance,
upgrades, and future enhancements.
Code documentation: Provide clear and succinct documentation that developers can understand
and modify.
Non-discrimination and inclusivity: Make sure the chatbot’s content and functionality are
inclusive, and avoid discrimination based on personal characteristics.
Data privacy: Follow appropriate data privacy requirements (e.g., GDPR, HIPAA) if any user
data is stored (anonymously).
Regular security audits: Conduct regular security assessments to identify and address potential
vulnerabilities.
User testing: Conduct user testing with diverse participants to evaluate usability, identify
potential biases, and gather feedback for improvement.
Development of personalized self-management tools based on user data (with strict user consent
and ethical considerations)
23 | P a g e
SRS
6. OTHER REQUIREMENTS
1. Ethical Consideration:
The chatbot’s creation and use should be guided by ethical AI development and mental health
support standards.
Transparency and accountability: Be upfront about the chatbot’s limitations and avoid making
false claims about its capabilities.
To avoid discrimination based on race, ethnicity, gender, sexual orientation, or other personal
characteristics, ensure the chatbot’s content and functionalities are inclusive. To prevent
algorithmic bias, use diverse data sets and carefully develop algorithms.
Monitor the chatbot for potential misuse or unintended repercussions, and fix any issues that
arise as soon as possible.
4. Future Development:
Consider future functionality, such as integrating with mental health doctors for remote
consultations.
By meeting these extra needs, the mental health support chatbot can be created and operated in a
responsible, ethical, and successful manner, providing a beneficial tool for people seeking
emotional well-being and mental health support.
24 | P a g e
SRS
7. REFERENCES
1. Vision and Scope Document:
- Title: Vision and Scope Document for Mental Health Support Chatbot
- Version: 1.0
- Version: 1.0
- Version: 1.0
6. Online resources
WCAG guidelines: https://www.w3.org/TR/WCAG21/
25 | P a g e
SRS
General Data Protection Regulation (GDPR): https://gdpr.eu/
26 | P a g e
SRS
8. APPENDIX A:GLOSSARY
Term Definition
AI Artificial intelligence
HIPAA Health Insurance Portability and Accountability Act (US regulation on protected health
information)
mental health A state of well-being in which an individual realizes his or her own abilities, can cope with
the normal stresses of life, can work productively and fruitfully, and is able to make a
contribution to his or her community.
natural language A subfield of artificial intelligence concerned with the interaction between computers and
human language.
privacy The right to be free from unwarranted disclosures of personal information and unreasonable
government interference with personal life.
real-time system A system that reacts and responds to inputs with minimal delay.
self-assessment A process where an individual evaluates their own knowledge, skills, or mental health.
user interface (Ul) IThe point of interaction between a user and a computer system.
WCAG Web Content Accessibility Guidelines (international standards for web accessibility)
27 | P a g e
SRS