Use Cases

March 18, 2021

 



Brief description of actors and use cases

Below figure represents the use cases of the proposed project, Social Media (Twitter) Based Depression Measuring System.

The system has two main actors, namely, user and system admin. Anyone willing to receive this depression analyzing service can use this system. He is called the user. The user should be registered to access this system. Upon registering, the User should grant permission via user agreement to analyze the text data gathered from his Twitter account. Then the user is able to request depression level analysis.

 

AI-based analysis results should be provided in a user-friendly manner coded according to the medical officer's (MBBS Sri Lanka) guidance. It will also recommend relevant suggestions according to his results. Users can also make the above process automated by selecting custom time intervals. Users are able to send detailed reports of analysis to their physician, including standard medical, psychological screening questionnaire user data. Users are also able to access user history, view user progress, view user profile, update a user profile, and delete the account anytime. If the user's physician is not available in the system, he can request to add his physician. System admin shall review the requests and do the verification. Users are also able to provide feedback about the project.

 

Use case diagram

 Use Case scenarios

 

Use case name

User register

Use case ID

01

Actor

User

Pre-condition

User should have a twitter account

Description

1. User selects the Register option

2. System displays the “Connect my Twitter Account” button and the user clicks it.

            E.1: A connection error occurs

3. System receives the details of the relevant twitter account.

2. System asks to enter the username 

3. User enters username.

4. System checks the availability of the username and asks to enter a password

      E.2: Username has already taken

5. User enters a password

6. System verifies the password

      E.3: Passwords validation fails

7. System asks to enter the other required information.

9. User submit the other required information.

10.System verifies the submitted data

10. System displays the user agreement.

11.User accepts the user agreement.

       A.1: User//physician declines user agreement.

12.User clicks the Register now button.

Post-condition

User gets registered and system database updates

 

Use case name

User login

Use case ID

02

Actor

User

Pre-condition

The user should be registered.

Description

1. User selects Login option

2. System asks to enter the username and password

3. User enters the username and password

6. System validates username and password

      E.4: Username & password validation fail

Post-condition

Display main screen for user

 

Use case name

Depression level analysis

Use case ID

03

Actor

User

Pre-condition

The user should have logged into the system.

Description

1.User clicks the Analyze button

2.System asks to enter the relevant time period for analyzing

3.User enters the time period

      A.2:User/physician cancels the operation

4.System analyzes the text data gathered through Twitter API from the user’s twitter account

      E.1: A connection error occurs

      E.5: A system error occurs

5. System displays the result.

Post-condition

Result is displayed

Business rules

System date and time should be correct.

 

Use case name

Automated depression level analysis

Use case ID

04

Actor

User

Pre-condition

The user should have logged into the system.

Description

1. User clicks Automated depression level analysis button

2. User selects the time interval to repeat the process.

3. System adds automated task to run on given time intervals

4. System runs automated analysis.

          E.1: A connection error occurs

          E.5: A system error occurs

      4. E.1: Data is not sufficient.

5. System displays smart notifications.

          E.1: A connection error occurs

          E.5: A system error occurs  

Post-condition

Stores information in the database about automated analysis

 

Use case name

View recommended suggestions

Use case ID

05

Actor

User

Pre-condition

The user should have logged into the system.

The user should have analyzed the depression level first.

Description

1. User clicks view recommended suggestions button.

             E.1: A connection error occurs

2. System displays recommended smart suggestions according to the result of the user.

       (Suggestion 1: Recommends to contact a doctor

        Suggestion 2: Recommends relevant mindfulness videos,  

                              motivational videos, yoga exercise videos

        Suggestion 3: Sends a notification saying that he is doing well. )

3. User acts according to the recommended suggestion. 

Post-condition

Relevant suggestions are recommended to the user.

 

Use case name

Check history

Use case ID

06

Actor

User

Pre-condition

The user should have logged into the system.

Description

1. User clicks View History button

2. System asks to enter the time period to show the history of the user activity.

3. User enters the time period.

        A.2:User/physician cancels the operation

4.System views the history of the relevant time period

       E.1: A connection error occurs

       E.5: A system error occurs

       E.6: No data can be found for the relevant time period

 

Post-condition

History of the relevant time period is viewed.

Business rules

System date and time should be correct.

 

Use case name

View user profile

Use case ID

07

Actor

User

Pre-condition

The user should have logged into the system.

Description

1. User selects the view profile option from the menu.

2. User views his/her details.

E.1: A connection error occurs

E.5: A system error occurs

Post-condition

System displays the user profile.

 

Use case name

Edit user profile

Use case ID

08

Actor

User

Pre-condition

The user should have logged into the system.

 

Description

1. User selects the ‘Edit profile’ option.

E.1: A connection error occurs

E.5: A system error occurs

2. User changes details or adds new details in the user profile.

   A.2:User/physician cancels the operation.

3. User selects ‘Save changes’.

A.2: User/physician cancels the operation.

E.1: A connection error occurs

E.5: A system error occurs

E.7: User/physician proceeds without filling a required field.

E.8: User/physician has entered invalid details

4. System updates the data. 

E.5: A system error occurs

 

Post-condition

System displays updated details on the user profile screen.

Business rules

Required fields are marked in the form.

 

Use case name

Delete account

Use case ID

09

Actor

User

Pre-condition

The user should have logged into the system.

Description

1. User selects the delete account option from the menu.

2. System prompts a message to delete or cancel.

E.1: A connection error occurs

E.5: A system error occurs

3. User selects confirm delete.

A.2:User/physician cancels the operation

E.1: A connection error occurs

E.5: A system error occurs

4. System deletes the user data from the database.

E.5: A system error occurs

Post-condition

System returns to login screen.

 

Use case name

Send feedback

Use case ID

10

Actor

User

Pre-condition

The user should have logged into the system.

Description

1. User selects the “Send feedback” option.

2. System displays the feedback form.

E.1: A connection error occurs  

E.5: A system error occurs

3. User fills the feedback form.

A.2: User/physician cancels the operation

4. User submits the Feedback report.

A.2: User/physician cancels the operation

E.1: A connection error occurs

E.5: A system error occurs

Post-condition

System saves the feedback.

System returns to the home screen for user

Business rules

The user should have used the system at least once.

 

Use case name

Send report to physician

Use case ID

11

Actor

User

Pre-condition

The user should have logged into the system.

The user should have done the depression level analysis process.

The user should have a complete profile.

Description

1. User selects the ‘Contact physician’ option from the menu.

2. System displays Psychological Screening Questionnaire.

E.1: A connection error occurs

E.5: A system error occurs

3. User answers the Psychological Screening Questionnaire.

A.2: User/physician cancels the operation

4. User submits the answers.

A.2: User/physician cancels the operation.

E.1: A connection error occurs

5. System saves the answers in the users’ reports.

E.1: A connection error occurs

E.5: A system error occurs

6. User selects his physicians.

A.2: User/physician cancels the operation  

11. A.1: User selects ‘Add your physician’ option.

7. User views the details of the selected physician.

E.1: A connection error occurs

E.5: A system error occurs

8. User selects the confirm & send.

   A.2: User/physician cancels the operation.

9. System sends the report to the physician.

E.1: A connection error occurs

E.5: A system error occurs

10. System displays a message of success status.

E.5: A system error occurs

11. User returns to the main screen

E.1: A connection error occurs

E.5: A system error occurs

Post-condition

System returns to the home screen for user.

System updates the details.

 

Use case name

Admin Login

Use case ID

12

Actor

System Admin

Pre-condition

The system admin should be a super user.

Description

1. System admin selects the “Login” option

2. System asks to enter the username and password

3. System admin enters the username and password

6. System validates username and password

      E.2: Username & password validation fails

Post-condition

Displays main screen for system admin

 

Use case name

Verify and add physician

Use case ID

13

Actor

System Admin

Pre-condition

The physician has sent a request to the system admin for the registration.

Description

1. System admin checks physician’s details

2. System admin verifies physician’s details

     13. E.9: Physician can’t be verified.

3.Adds the physician into the system.

Post-condition

Displays the updated physician list

 

Use case name

Remove user/physician profiles

Use case ID

14

Actor

System Admin

Pre-condition

There should be an account for the user/physician in the system

Description

1. System admin selects the user/physician profile that should be removed.

2. System admin clicks “Remove” button

  E.1: A connection error occurs

            E.5: A system error occurs

 

Post-condition

Relevant user/physician profile is removed from the system

 

Use case name

View feedbacks

Use case ID

15

Actor

System Admin

Pre-condition

The users have sent feedbacks

Description

1. System admin clicks “View feedbacks” button

 E.1: A connection error occurs

           E.5: A system error occurs

2. System displays feedbacks from users.

3.System admin clicks OK button     

Post-condition

Returns to the main screen for system admin.

 

 

 Use case name

Physician register

 Use case ID

16

 Actor

Physician

 Pre-condition

Physician should have valid qualifications. 

 Description

1.Physician selects the Register option

2.System asks to enter the username 

3.Physician enters username.

4. System checks the availability of the username and asks to enter a password

            E.2: Username has already taken

5.Physician enters a password

6. System verifies the password

             E.3: Passwords validation fails

7. System asks to enter the other required information.

8. Physician submit the other required information.

9.System verifies the submitted data

10. System displays the user agreement.

11. Physician accepts the user agreement.

             A.1: User/physician declines user agreement.

12. Physician clicks the “Register now” button.

 Post-condition

A request is sent to the system admin to verify and add physician to the system

 

Use case name

Physician login

Use case ID

17

Actor

Physician

Pre-condition

The physician should have been registered.

Description

1. Physician selects Login option

2. System asks to enter the username and password

3. Physician enters the username and password

6. System validates username and password

      E.4: Username & password validation fail

Post-condition

Display main screen for physician

 

Use case name

View physician profile

Use case ID

18

Actor

Physician

Pre-condition

The physician should have logged into the system.

Description

1. Physician selects the view profile option from the menu.

2. Physician views his/her details.

E.1: A connection error occurs

E.5: A system error occurs

Post-condition

System displays the physician profile.

 

 

Use case name

Edit physician profile

Use case ID

19

Actor

Physician

Pre-condition

The physician should have logged into the system.

 

Description

1. Physician selects the ‘Edit profile’ option.

E.1: A connection error occurs

E.5: A system error occurs

2. Physician changes details or adds new details in the user profile.

   A.2:User/physician cancels the operation.

3. Physician selects ‘Save changes’.

A.2: User/physician cancels the operation.

E.1: A connection error occurs

E.5: A system error occurs

E.7: User/physician proceeds without filling a required field.

E.8: User/physician has entered invalid details

4. System updates the data. 

E.5: A system error occurs

 

Post-condition

System displays updated details on the physician profile screen.

Business rules

Required fields are marked in the form.

 

 

 

Use case name

Manage patient requests

Use case ID

20

Actor

Physician

Pre-condition

The physician should have logged into the system.

Description

1.Physician selects the ‘Patient requests’ option from the menu.

2. Physician view requests sent by new patients/users.

3. Physician selects the ‘Confirm Request’ button.

              20.A.1: Physician clicks ‘Cancel’ button.

                   E.1: A connection error occurs

                   E.5: A system error occurs

Post-condition

Physician’s patient list is updated.

System returns to physician’s main screen.

 

Use case name

View patient reports

Use case ID

21

Actor

Physician

Pre-condition

The physician should have logged into the system.

Description

1. Physician selects the ‘View my patients’ option from the menu

2. Physician views list of his/her patients.

               E.1: A connection error occurs

               E.5: A system error occurs

3. Physician selects a patient from the list.

4. System views the relevant patient’s reports along with his/her contact details.

               E.1: A connection error occurs

               E.5: A system error occurs

5.Physician selects Close button

Post-condition

System returns to physician’s main screen.


2.3.1  Alternative and Exceptional flows

Alternative flaws

 

A.1: User/physician declines the user agreement.

 

Actor

User/Physician

Pre-condition

User/physician has viewed the user agreement

Description

1.The user/physician chose not to accept the terms and conditions of the user agreement.

Post-condition

Display error description.


A.2: User/physician cancels the operation

 

Actor

User/physician

Pre-condition

System has asked to enter the details for the operation

Description

1.User/physician clicks the cancel button

2.Operation stops

Post-condition

System returns to the home screen

 

11. A.1: User selects ‘Add your physician’ option

 

Actor

User

Pre-condition

The user has viewed the list of physicians.

Description

1. ‘Add your physician’ is selected instead of selecting from list

Post-condition

Continue with the use case Add your physician and return.

 

20. A.1:Physician clicks ‘Cancel’ button.

 

Actor

Physician

Pre-condition

System has shown requests sent by new patients.

Description

1.User clicks the cancel button

2. System deletes the request.

Post-condition

System returns to the physicians’ main screen


Exceptional flaws

E.1: A connection error occurs

 

Pre-condition

System was asked perform an operation with network connectivity

Description

1.System cannot connect with the server due to the network issues

2.System displays an error message

Post-condition

User retries

User checks the network connection

 

E.2: Username is not available

 

Pre-condition

User has entered a username.

System has checked the availability of the username.

escription

1. User has entered a username that is already exist in the system assigned to another user. 

2. System displays a message to inform the user that the username is   already taken and instructs to enter a new one.

Post-condition

User enters new username and proceeds to next step.

 

E.3: Password is invalid

 

Pre-condition

User has entered a password.

System has checked whether the password and re-entered password are matching.

Description

1. Password and re-entered password doesn’t match.

2. System displays a message regarding password mismatch.

Post-condition

User enters corrects the passwords and proceeds to next step.

 

E.4: Username & password validation fail

 

Pre-condition

User/admin/physician has entered the username and username.

System has checked for the relevant profile that matches with the given username and password.

Description

1. Has entered a wrong login information. 

2. System displays a message to inform that the login details are Invalid and instructs to check and enter again.

Post-condition

User/admin/physician enters the correct login information and proceeds.

 

E.5: A system error occurs

 

Pre-condition

System was asked to perform an operation

Description

1.System fails to complete the task as it supposed to.

2.System displays an error message

Post-condition

User retries

User sends an error report to the system

System checks for any problems within it.

 

E.6: No data can be found for the relevant time period

 

Pre-condition

User has selected a time period

Description

1.System cannot find relevant data for the entered time period

2.System displays an error message

Post-condition

User selects new time period

 

E.7: User proceeds without filling a required field.

 

Pre-condition

User clicks on save option.

Description

1. System doesn’t proceed to next step because required field is empty.

2. The system prompts a message to inform the user to fill all the

     required fields.

Post-condition

System proceeds to the next step.

 

 E.8: User has entered invalid details

 

Pre-condition

User clicks on save option.

Description

1. System doesn’t proceed to next step because the details entered are invalid or not in the correct format.

2. The system prompts a message to inform the user to enter valid details.

Post-condition

System proceeds to the next step.

 

4. E.1: Data is not sufficient

 

Pre-condition

System has checked for the data in the given time period

Description

1.System identifies that there is not enough data to do the analysis

2.System cancels the operation

Post-condition

System notifies error details.


13. E.9: Physician can’t be verified.

 

Pre-condition

The physician has sent a request to the system admin for the verification.

Description

1.System admin identifies the entered details of the physician are not valid.

2.System cancels the registration of the physician.

Post-condition

System asks to enter the correct details.

 

 


You Might Also Like

0 comments

Popular Posts

Translate

Most Popular