to upgrade

This commit is contained in:
Saifeddine ALOUI 2023-06-21 13:06:01 +02:00
parent 6ce32cf1df
commit e7d825c8e4
3 changed files with 4 additions and 14 deletions

View File

@ -149,17 +149,6 @@ class ModelProcess:
binding_path = self.lollms_paths.bindings_zoo_path/binding_name
if install:
# first find out if there is a requirements.txt file
install_file_name="install.py"
install_script_path = binding_path / install_file_name
if install_script_path.exists() or force_install:
module_name = install_file_name[:-3] # Remove the ".py" extension
module_spec = importlib.util.spec_from_file_location(module_name, str(install_script_path))
module = importlib.util.module_from_spec(module_spec)
module_spec.loader.exec_module(module)
if hasattr(module, "Install"):
module.Install(self.config)
# define the full absolute path to the module
absolute_path = binding_path.resolve()

5
app.py
View File

@ -25,7 +25,8 @@ from tqdm import tqdm
import subprocess
import signal
from lollms.personality import AIPersonality, MSG_TYPE
from lollms.helpers import ASCIIColors, BaseConfig
from lollms.config import BaseConfig
from lollms.helpers import ASCIIColors
from lollms.paths import LollmsPaths
from api.db import DiscussionsDB, Discussion
from api.helpers import compare_lists
@ -44,7 +45,7 @@ import yaml
from geventwebsocket.handler import WebSocketHandler
import logging
import psutil
from lollms.binding import LOLLMSConfig
from lollms.main_config import LOLLMSConfig
log = logging.getLogger('werkzeug')
log.setLevel(logging.ERROR)

View File

@ -7,7 +7,7 @@ pyyaml
markdown
gevent
gevent-websocket
lollms==1.2.12
lollms
langchain
requests
websocket-client