mirror of
https://github.com/ParisNeo/lollms.git
synced 2025-02-21 09:51:45 +00:00
upgraded lollms
This commit is contained in:
parent
4033e39935
commit
fb226cfbbd
@ -46,6 +46,7 @@ class LollmsApplication:
|
||||
except Exception as ex:
|
||||
ASCIIColors.error(f"Failed to load binding.\nReturned exception: {ex}")
|
||||
trace_exception(ex)
|
||||
self.binding = None
|
||||
|
||||
if self.binding is not None:
|
||||
ASCIIColors.success(f"Binding {self.config.binding_name} loaded successfully.")
|
||||
@ -74,17 +75,18 @@ class LollmsApplication:
|
||||
def load_binding(self):
|
||||
try:
|
||||
binding = BindingBuilder().build_binding(self.config, self.lollms_paths)
|
||||
return binding
|
||||
except Exception as ex:
|
||||
print(ex)
|
||||
print(f"Couldn't find binding. Please verify your configuration file at {self.configuration_path} or use the next menu to select a valid binding")
|
||||
print(f"Couldn't find binding. Please verify your configuration file at {self.lollms_paths.personal_configuration_path}/local_configs.yaml or use the next menu to select a valid binding")
|
||||
print(f"Trying to reinstall binding")
|
||||
try:
|
||||
binding = BindingBuilder().build_binding(self.config, self.lollms_paths,installation_option=InstallOption.FORCE_INSTALL)
|
||||
except Exception as ex:
|
||||
ASCIIColors.error("Couldn't reinstall model")
|
||||
trace_exception(ex)
|
||||
return None
|
||||
|
||||
return binding
|
||||
|
||||
def load_model(self):
|
||||
try:
|
||||
|
@ -232,7 +232,7 @@ class MainMenu(Menu):
|
||||
if 1 <= choice <= len(bindings_list)-1:
|
||||
print(f"You selected binding: {ASCIIColors.color_green}{self.binding_infs[choice - 1]['name']}{ASCIIColors.color_reset}")
|
||||
self.lollms_app.config['binding_name']=self.binding_infs[choice - 1]['name']
|
||||
self.lollms_app.load_binding()
|
||||
self.lollms_app.binding = self.lollms_app.load_binding()
|
||||
self.lollms_app.config['model_name']=None
|
||||
self.lollms_app.config.save_config()
|
||||
elif choice <= len(bindings_list):
|
||||
|
Loading…
x
Reference in New Issue
Block a user