writer / writer-framework

No-code in the front, Python in the back. An open-source framework for creating data apps.
https://dev.writer.com/framework/introduction
Apache License 2.0
1.33k stars 75 forks source link

Question: How to clear the chat bot window? #411

Closed thondeboer closed 3 months ago

thondeboer commented 6 months ago

Great little addition, the chatbot. Just when I needed one. Quick question; How do you clear the chat window for a new chat?

ramedina86 commented 6 months ago

Hey, we faced some issues with the current design. We'll be reengineering it so that the conversation is in state. This will enable:

As of now, it's not possible. We'll release the new version at the end of month.

chew1976 commented 6 months ago

Hey, we faced some issues with the current design. We'll be reengineering it so that the conversation is in state. This will enable:

  • Streaming
  • Loading old conversations
  • Clearing conversations

As of now, it's not possible. We'll release the new version at the end of month.

This is great news! I look forward to being able to regenerate responses as well as modify them when using LLM.

FabienArcellier commented 3 months ago

Since version 0.6, you can clear chat content. I think this improvement has been developped by @mmikita95.

def clear_conversation(state):
    # initializes a new conversation instead of existing one
    state["chatbot_conversation"] = Conversation()