-
Notifications
You must be signed in to change notification settings - Fork 7.7k
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
chat: fix issues with quickly switching between multiple chats #2343
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Signed-off-by: Jared Van Bortel <[email protected]>
Signed-off-by: Jared Van Bortel <[email protected]>
cebtenzzre
force-pushed
the
fix-chat-switching
branch
2 times, most recently
from
May 14, 2024 17:59
f3cbd09
to
bcfcb9c
Compare
cebtenzzre
force-pushed
the
fix-chat-switching
branch
from
May 14, 2024 19:11
bcfcb9c
to
a845a02
Compare
Signed-off-by: Jared Van Bortel <[email protected]>
There is no reason for reloadModel to show slighly different status information from setModelInfo. Signed-off-by: Jared Van Bortel <[email protected]>
This fixes a memory leak if there was a model in the store on exit, e.g. if the user loads a model and then switches to a chat associated with a different model file without loading it. ChatLLM::destroyStore is added to fix a heap-use-after-free caused by the unique_ptr being freed too late. Global destructors are hard. Signed-off-by: Jared Van Bortel <[email protected]>
Signed-off-by: Jared Van Bortel <[email protected]>
Signed-off-by: Jared Van Bortel <[email protected]>
When switching context, this state can take a significant amount of time. Separate it out so the user is less likely to think GPT4All is completely stuck. Signed-off-by: Jared Van Bortel <[email protected]>
This aligns its behavior with the upper "reload" button. Signed-off-by: Jared Van Bortel <[email protected]>
The boolean flag doesn't do anything useful. Signed-off-by: Jared Van Bortel <[email protected]>
Signed-off-by: Jared Van Bortel <[email protected]>
Signed-off-by: Jared Van Bortel <[email protected]>
cebtenzzre
force-pushed
the
fix-chat-switching
branch
from
May 14, 2024 20:00
a845a02
to
1eb7ca5
Compare
cebtenzzre
changed the title
chat: trying to fix issues with quickly switching chats
chat: fix issues with quickly switching between multiple chats
May 14, 2024
This is tricky code. Let's do a huddle for review on this one. |
manyoso
approved these changes
May 15, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
If you switch between chats too quickly, it can result in the UI getting into inconsistent states (e.g. a progress bar stuck at 60%) and sometimes seemingly deadlocking (which happens during the new "Waiting for model" status).
To fix UI inconsistencies:
To prevent quickly switching chats from queueing many slow operations:
UI enhancement:
Other bugfix:
Non-functional changes: