buerokratt / Buerokratt-Chatbot

1 stars 19 forks source link

Automated ending of idle chat #6

Open rasmusei opened 2 years ago

rasmusei commented 2 years ago

AS A Bürokratt I WANT TO end idle chats under active chats automatically SO THAT CSAs don't have to deal with active chat without End User being present

Acceptance Criteria

GUI

Generic

End User

CSA

helemand commented 1 year ago

GUI can determine whether there has or has not been any activity and cs-end-chat and end-chat endpoints can be called to end chat.cs-end-chat for when the end user is not responding and end-chat for when end user decides to end chat.

sergeirudz commented 1 year ago

PR: https://github.com/buerokratt/Chat-Widget/pull/15

MarkusVeltri commented 1 year ago

When option 2 is chosen, the chat box closes immediately and if CSA wants to see the notification text, they would need to go to ajalugu and reopen the chat from there. I would suggest that for the CSA chat would stay open for 3-5 seconds.

1AhmedYasser commented 1 year ago

When option 2 is chosen, the chat box closes immediately and if CSA wants to see the notification text, they would need to go to ajalugu and reopen the chat from there. I would suggest that for the CSA chat would stay open for 3-5 seconds.

@MarkusVeltri Could you please provide screen shots or steps to reproduce the same situation on my side to pin point exactly what is happening so i can make the suggested changes

Thank you

MarkusVeltri commented 1 year ago
  1. User choses option 2, to leave the conversation without an answer.

Image

  1. For CSA the chat immediately disappears.

Image

  1. If the CSA wants to see whether the customer left with or without getting an answer, they will have to go to ajalugu and open up that specific chat.

Image

It would be good to see if the customer got the answer they wanted so having the chat open for a couple seconds after they leave is helpful.

Hope this helps to clarify things

1AhmedYasser commented 1 year ago

@MarkusVeltri Thank you so much for the clarification, will take it on from here

MarkusVeltri commented 1 year ago

BUG

  1. If End User does not respond to the dialog box the chat for 1 minute, then the chat still stays open.
  2. If End User does not respond to the dialog box within 1 minute it should automatically close.
  3. The dialog box stays open for the End User for indefinite amount of time.
  4. After asking for teenindaja from the chat widget, click on the cross on the top right of the chat widget witch opens up the dialog box with three options and then wait. Also for the CSA it only shows 2 reasons why End User left: 1) and 2), but that is an issue relating to #32 .
  5. image

image

MarkusVeltri commented 1 year ago

Tested and done.

MarkusVeltri commented 1 year ago

BUG- @1AhmedYasser

  1. The problem right now is that the dialog box with the question("Kas soovid vestlust jätkata" with 2 options 1) "Jah" - yes 2) "Ei" - no) pops up every minute.

  2. How it should be, when there is no activity from End User for 15 minutes, then End User is displayed dialog box with question "Kas soovid vestlust jätkata" with 2 options 1) "Jah" - yes 2) "Ei" - no.

  3. Problem in detail, End User dialog box appears too soon, it should be at least 15 minutes.

  4. As End User hold chat open for 1 minute.

  5. imageimage

1AhmedYasser commented 1 year ago

@MarkusVeltri Modified Idle time to be 15 minutes

Note: Idle time constant can be changed from here https://github.com/buerokratt/Chat-Widget/blob/main/src/constants.ts#L26

MarkusVeltri commented 1 year ago

is good now

janinakimtrohlev commented 1 year ago

BUG - Right now when End User is not responding to the dialog question it is still open, until End User close by himself or went away from page. It should be : When End User is not responding to the dialog box question for 1 minute, CSA will be notified that chat will be ended and chat will be ended. Notification text "Klient lahkus vestlusest, vestlus lõpeb". Chat will have status 3 from https://github.com/buerokratt/Buerokratt-Chatbot/issues/32.

1AhmedYasser commented 1 year ago

BUG - Right now when End User is not responding to the dialog question it is still open, until End User close by himself or went away from page. It should be : When End User is not responding to the dialog box question for 1 minute, CSA will be notified that chat will be ended and chat will be ended. Notification text "Klient lahkus vestlusest, vestlus lõpeb". Chat will have status 3 from #32.

@janinakimtrohlev your comment is saying that if the user is idle for 1 min i should automatically end the chat with the appropriate status

@MarkusVeltri your comment is saying is when there is no activity from End User for 15 minutes, then End User is displayed dialog box with question "Kas soovid vestlust jätkata" with 2 options 1) "Jah" - yes 2) "Ei" - no.

@janinakimtrohlev your comment is conflicting with https://github.com/buerokratt/Buerokratt-Chatbot/issues/6#issuecomment-1713518135, The current logic is, if the user is not responding for 15 mins then a dialog appears to the user asking him if he want to continue the chat or not, @janinakimtrohlev @MarkusVeltri please agree on the logic with @rasmusei and @PaulaMerle

PaulaMerle commented 1 year ago

@1AhmedYasser This needs to work according to task ACs described above.

  1. When end-user is inactive for 15 minutes, dialog box with question is displayed (yes or no)
  2. If end-user will not respond to the dialog box questions during 1 min, bot closes the chat automatically with status 3) "Klient lahkus määramata põhjustel" (unspecified reasons).
1AhmedYasser commented 1 year ago

When

Got it, so when if the user is in active for 15 mins the dialog box appears with the questions, and if the user didn't answer the dialog within 1 min then the chat is automatically ended with the appropriate status 👌

1AhmedYasser commented 1 year ago

@janinakimtrohlev @PaulaMerle Added A Fix, Now if the user is idle for 15 minutes then the dialog box appears with the questions and if the user didn't respond to the dialog within 1 minute then the chat will be ended automatically

janinakimtrohlev commented 1 year ago

Tested chat automatically ask after 15 minutes not responding and after that when in 1 minute there is no answer chat closes. But right now chats history don't work so When it works I check with which status it will close.

janinakimtrohlev commented 1 year ago

Close, because it is similar to task #34