diff --git a/README.md b/README.md index e20479e..0ec7cb3 100644 --- a/README.md +++ b/README.md @@ -7,7 +7,7 @@ docker build -t supertutor-app . para ejecutar: -docker run -it -p 7884:7884 --rm fastapi-app +docker run -it -p 7884:7884 --rm supertutor-app diff --git a/dockerfile b/dockerfile index 7731bf1..7355bd2 100644 --- a/dockerfile +++ b/dockerfile @@ -7,6 +7,7 @@ WORKDIR /app COPY requirements.txt ./ # Instalar las dependencias de Python +RUN pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cpu RUN pip install --no-cache-dir -r requirements.txt # Copiar todo el código de la aplicación al contenedor diff --git a/main.py b/main.py index 67b030f..2b15c0e 100644 --- a/main.py +++ b/main.py @@ -145,6 +145,8 @@ def listmodelactives(): except: print("cambio") return Div(id="options",hx_target="this",hx_swap="outerHTML",hx_get="/listmodelactives",hx_trigger="click from:#buttonMenuuser") + if not os.path.exists("static/"+userdata+"/chroma_db"): + os.makedirs("static/"+userdata+"/chroma_db") db = chromadb.PersistentClient(path="static/"+userdata+"/chroma_db") files= db.list_collections() diff --git a/requirements.txt b/requirements.txt index 2fa7aeb..84b307b 100644 --- a/requirements.txt +++ b/requirements.txt @@ -106,7 +106,6 @@ pypdf==4.3.1 PyPika==0.48.9 pyproject_hooks==1.2.0 pysqlite3-binary==0.5.3.post1 -pysqlite3-binary==0.5.3.post1 python-dateutil==2.9.0.post0 python-dotenv==1.0.1 python-fasthtml==0.6.7