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

[Question]: RAG-Graph Generate-Answer with history message in chat api #1472

Closed
SG-XM opened this issue Jul 11, 2024 · 7 comments
Closed

[Question]: RAG-Graph Generate-Answer with history message in chat api #1472

SG-XM opened this issue Jul 11, 2024 · 7 comments
Labels
bug Something isn't working

Comments

@SG-XM
Copy link

SG-XM commented Jul 11, 2024

Describe your problem

"I have a very complex graph model, and in one of the processes, I connect an answer generation component with a human-computer interaction component. In this stage, I need to continuously ask the user questions, and each conversation requires the complete history of the dialogue to ensure that the next question does not repeat previous ones. Therefore, I want to know how many past conversations are appended with each API call? And whether any summarization is performed? Additionally, how can I append historical information? My prompt works fine with GPT-4o and can complete multi-turn questioning as required. However, in the ragglow-graph, after several rounds of dialogue, it starts asking repetitive questions. I am also using the GPT-4o model, but I cannot see the detailed OpenAPI POST body, so I cannot determine where the problem is."

@SG-XM SG-XM added the question Further information is requested label Jul 11, 2024
@KevinHuSh
Copy link
Collaborator

Could you paste the picture of canvas here?

@SG-XM
Copy link
Author

SG-XM commented Jul 12, 2024

image here is my canvas,in this loop gpt-4o where ask about 21 questions,but after 10+ conversation,model begin to repeat previous question,but with the same prompt in chat.openai.com,gpt-4o, it works well.

@SG-XM
Copy link
Author

SG-XM commented Jul 12, 2024

image I use this "history" param to append history message,but in fact this editabe text is prompt rather than previous conversation list.

@KevinHuSh
Copy link
Collaborator

image I use this "history" param to append history message,but in fact this editabe text is prompt rather than previous conversation list.

It's useless to add history parameter.
"回答时请考虑聊天历史" that's enough.

This is about enlarge hisotry window size. We will fixed it later.|

It's meaningless to add ’message‘(人机交互) after ’begin‘ since 'begin' has already include one piece of message.

@SG-XM
Copy link
Author

SG-XM commented Jul 12, 2024

thanks,i have added "回答时请考虑聊天历史" . Could you please add a 'number of previous messages included' setting, similar to other GPT conversation tools (e.g., NextChat)?

It's useless to add history parameter. "回答时请考虑聊天历史" that's enough.
This is about enlarge hisotry window size. We will fixed it later.|

KevinHuSh pushed a commit that referenced this issue Jul 12, 2024
### What problem does this PR solve?
fix: add message_history_window_size to  GenerateForm #1472
### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)
@SG-XM
Copy link
Author

SG-XM commented Jul 12, 2024

its still has problem after 12 times conversations,i have set max window size to 64,but it looks like still 12. My conversation has repeated after 12.

@SG-XM
Copy link
Author

SG-XM commented Jul 12, 2024

@KevinHuSh,excuse, in your commit,it seems just update UI design rather than really request body?

@KevinHuSh KevinHuSh added bug Something isn't working and removed question Further information is requested labels Jul 15, 2024
Halfknow pushed a commit to Halfknow/ragflow that referenced this issue Nov 11, 2024
…nfiniflow#1487)

### What problem does this PR solve?
fix: add message_history_window_size to  GenerateForm infiniflow#1472
### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)
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