FlowiseAI / Flowise

Drag & drop UI to build your customized LLM flow
https://flowiseai.com
Apache License 2.0
27.24k stars 14.06k forks source link

[BUG] Zep History not working with Summarizer #2297

Open volkantasci opened 2 months ago

volkantasci commented 2 months ago

Describe the bug If Zep memory summarizer is enabled throwing an error like "System messages are only permitted as the first passed message." Error message is clear and it's right. I don't understand how is working at the background. I think Zep messages include summarized message and flowise sending all messages to Chat API.

To Reproduce Steps to reproduce the behavior:

  1. Use Zep open source memory.
  2. Enable the summarizer option from environment variables.
  3. Create a flow using Zep memory.
  4. Keep chatting with Anthropic or some other Chat model.
  5. Message window when exceeded then you will summarized content on the Zep admin UI.
  6. If you will send a new message to chat you will see this error "System messages are only permitted as the first passed message."

Expected behavior Summarized content must be include the human message template. Selected variable "K" (how many messages will fetched from Zep) should added after summarized content.

Error Screenshot from Docker Logs

HenryHengZJ commented 2 months ago

Yep, by nature Anthropic doesn't support System Message at later stage, only as the first message at the beginning. Only OpenAI permits that.

Now, I'm not sure if Zep supports other LLM to do the summarization, I'd suggest try reaching out to them and see