mirror of
https://github.com/ParisNeo/lollms-webui.git
synced 2024-12-21 05:13:10 +00:00
Bugfixes for personality changes
This commit is contained in:
parent
072f860bb7
commit
b191106863
5
app.py
5
app.py
@ -321,11 +321,16 @@ class Gpt4AllWebUI(GPT4AllAPI):
|
||||
def update_model_params(self):
|
||||
data = request.get_json()
|
||||
model = str(data["model"])
|
||||
personality = str(data["personality"])
|
||||
if self.config['model'] != model:
|
||||
print("New model selected")
|
||||
self.config['model'] = model
|
||||
self.create_chatbot()
|
||||
|
||||
if self.config['personality']!=data["personality"]:
|
||||
self.config['personality'] = data["personality"]
|
||||
self.personality = load_config(f"personalities/{self.config['personality']}.yaml")
|
||||
|
||||
self.config['n_predict'] = int(data["nPredict"])
|
||||
self.config['seed'] = int(data["seed"])
|
||||
self.config['model'] = str(data["model"])
|
||||
|
Loading…
Reference in New Issue
Block a user