Duo Chat should allow history to be cleared

Problem

The Duo Chat history is shown for each user for a predefined period (3 days?). For Gitlab team members that want to record a demo or want to demo the chat to a customer, old messages (especially with failed responses) can be very distracting from the purpose of the demo.

For this small group of users it would be very helpful if they could clear the Chat history.

Known workaround

For recording demos, the chat history can be deleted using the browser inspector. For customer demos this is not a viable solution. In VSCode restarting VSCode removes the history in the chat-in-ide window

Solution proposal

  1. Add a /clean command that removes all conversations from BE cache for given user which will also clean the FE.
    • Just like we have /reset command to reset the chat's context but leaves the previous messages in cache, this issue suggests taking it a step further and building a new /clean command to extend what /reset does, but also remove messages from cache. This will allow users to start completely clean.
    • Later on, when the multi-threaded history is introduced, the same mechanism could be used to clean the current thread.
  2. Add the /clean command to the documentation.

Although /clean is essentially a slash command there is no dependency on https://gitlab.com/gitlab-org/gitlab/-/issues/419278/+.

Edited by Torsten Linz