diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000000..72d14322f1 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,109 @@ +# Version control +.git +.gitignore +.github/ + +# Editor and IDE files +.vscode +.idea +*.swp +*.swo +.cursor/ +.cursorignore + +# Shell history +.bash_history +.zsh_history +.history + +# Python virtual environments +**/venv/ +**/.venv/ +**/env/ +**/.env/ +**/*-venv/ +**/*_venv/ +**/ENV/ + + +# Python build artifacts +__pycache__/ +*.pyc +*.pyo +*.pyd +.Python +*.egg-info/ +dist/ +build/ +*.so +*.dylib + +# Environment file +.env +.env.local +.env.*.local + +# Large data files +data/* +!data/.lfs/ + +# Model files (can be downloaded at runtime) +*.pt +*.pth +*.onnx +*.pb +*.h5 +*.ckpt +*.safetensors +checkpoints/ +assets/model-cache + +# Logs +*.log + +# Large media files (not needed for functionality) +*.png +*.jpg +*.jpeg +*.gif +*.mp4 +*.mov +*.avi +*.mkv +*.webm +*.MOV + +# Large font files +*.ttf +*.otf + +# Node modules (for dev tools, not needed in container) +node_modules/ +package-lock.json +package.json +bin/node_modules/ + +# Database files +*.db +*.sqlite +*.sqlite3 + +# OS generated files +.DS_Store +.DS_Store? +._* +.Spotlight-V100 +.Trashes +ehthumbs.db +Thumbs.db + +# Temporary files +tmp/ +temp/ +*.tmp +.python-version + +# Exclude all assets subdirectories +assets/*/* +!assets/agent/prompt.txt +!assets/* diff --git a/docker/dev/Dockerfile b/docker/dev/Dockerfile index 3ecfd013b0..ef80b70e1d 100644 --- a/docker/dev/Dockerfile +++ b/docker/dev/Dockerfile @@ -24,20 +24,14 @@ RUN git config --global --add safe.directory '*' WORKDIR /app -COPY pyproject.toml /app/ -RUN mkdir -p /app/dimos -RUN touch /app/dimos/__init__.py - # Install UV for fast Python package management ENV UV_SYSTEM_PYTHON=1 RUN curl -LsSf https://astral.sh/uv/install.sh | sh ENV PATH="/root/.local/bin:$PATH" -# Install dependencies with UV (10-100x faster than pip) +# Install dependencies with UV RUN uv pip install .[dev] -COPY . /app/ - # Copy files and add version to motd COPY /assets/dimensionalascii.txt /etc/motd COPY /docker/dev/bash.sh /root/.bash.sh diff --git a/docker/python/Dockerfile b/docker/python/Dockerfile index e14a2d7ca7..8acd7a52af 100644 --- a/docker/python/Dockerfile +++ b/docker/python/Dockerfile @@ -44,12 +44,9 @@ ENV PATH="/root/.local/bin:$PATH" WORKDIR /app -COPY pyproject.toml /app/ -RUN mkdir -p /app/dimos -RUN touch /app/dimos/__init__.py +# Copy entire project first to ensure proper package installation +COPY . /app/ # Install dependencies with UV (10-100x faster than pip) RUN uv pip install --upgrade 'pip>=24' 'setuptools>=70' 'wheel' 'packaging>=24' && \ - uv pip install '.[cpu]' - -COPY . /app/ \ No newline at end of file + uv pip install '.[cpu]' \ No newline at end of file diff --git a/pyproject.toml b/pyproject.toml index 80ad9f0f7b..7cbde71894 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -3,7 +3,14 @@ requires = ["setuptools>=70", "wheel"] build-backend = "setuptools.build_meta" [tool.setuptools] -packages = ["dimos"] +include-package-data = true + +[tool.setuptools.packages.find] +where = ["."] +include = ["dimos*"] + +[tool.setuptools.package-data] +"*" = ["*.html", "*.css", "*.js", "*.json", "*.txt", "*.yaml", "*.yml"] [project] name = "dimos" @@ -131,11 +138,11 @@ cpu = [ cuda = [ "pycuda", - "onnxruntime-gpu>=1.17.1,<=1.18.1", # Only versions supporting both cuda11 and cuda12 + "onnxruntime-gpu>=1.17.1", # Only versions supporting both cuda11 and cuda12 "ctransformers[cuda]==0.2.27", "mmengine>=0.10.3", "mmcv>=2.1.0", - "xformers==0.0.20", + "xformers>=0.0.20", # Detic GPU stack "mss",