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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make new browser reloads recognize current model (fixes #4843) #4865

Merged
merged 1 commit into from
Dec 11, 2023

Conversation

cyberfox
Copy link
Contributor

@cyberfox cyberfox commented Dec 9, 2023

This fixes a long-standing UI bug #4843 the simplest way possible.

Essentially instead of just giving the model name as the value, which then gets cached and not replaced...ever, we give a Callable that returns the current model name so each time it generates the UI for a 'new' browser session, it updates the model name to be whatever's current.

Before this change, the displayed name would always be the default after a reload or when hit by another browser. I ran into it most often when switching between iPhone and desktop. With this change it shows the latest model loaded. And yes, the pull request is a hundred times longer than the change, but it took me hours to get here. 馃ぃ

Checklist:

@oobabooga
Copy link
Owner

That's a very clever solution. Well done.

@oobabooga oobabooga merged commit 602b8c6 into oobabooga:dev Dec 11, 2023
@cyberfox cyberfox deleted the fix-model-forgetfulness branch March 3, 2024 05:19
@djbritt
Copy link

djbritt commented Apr 6, 2024

Is this issue relevant to when I have a session going, and I reload the browser, I get this error

Could not find the character "[]" inside characters/. No character has been loaded - file File "/home/user1/git/oobabooga-4-1-24/modules/chat.py", line 673, in load_character

I am on ubuntu 22.04

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants