Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dify forget the conversation history when working through the API #9130

Closed
5 tasks done
aiwinapp opened this issue Oct 9, 2024 · 4 comments
Closed
5 tasks done

Dify forget the conversation history when working through the API #9130

aiwinapp opened this issue Oct 9, 2024 · 4 comments
Labels
🐞 bug Something isn't working

Comments

@aiwinapp
Copy link

aiwinapp commented Oct 9, 2024

Self Checks

  • This is only for bug report, if you would like to ask a question, please head to Discussions.
  • I have searched for existing issues search for existing issues, including closed ones.
  • I confirm that I am using English to submit this report (我已阅读并同意 Language Policy).
  • [FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)
  • Please do not modify this template :) and fill in all the required fields.

Dify version

0.9.1

Cloud or Self Hosted

Self Hosted (Docker)

Steps to reproduce

I’m working with the Dify API. I include the conversation_id with my request, but Dify treats it as if it’s the first message in the conversation, even though it should be a continuation. As a result, I receive responses as if each message is the initial query. Everything works fine on the web interface, but the API has this issue. This error starts from update to 0.9.1.

✔️ Expected Behavior

No response

❌ Actual Behavior

No response

@dosubot dosubot bot added the 🐞 bug Something isn't working label Oct 9, 2024
@crazywoola
Copy link
Member

Already fixed in #8965.

@aiwinapp
Copy link
Author

aiwinapp commented Oct 9, 2024

Fixed, but I dont see it in my build. I have error.

@EitanWong
Copy link

I've encountered the same issue; when calling the API, the response doesn't include history, yet conversations in Dify work fine. The version is 0.9.1.

@aiwinapp
Copy link
Author

aiwinapp commented Oct 9, 2024

I have fix this error. Just a add to

/api/controllers/service_api/app/completion.py
add line:
args ["parent_message_id"] = UUID_NIL

and in the head: from constants import UUID_NIL

this help to me:
fd1c85d

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐞 bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants