This folder provides a production-style Docker workflow for running the COMPASS UI with public API backends.
- Fast, reproducible onboarding for UI/API usage.
- Reproducible runtime without local Python setup.
- CPU-first portability across macOS, Linux, and Windows (Docker Desktop/WSL).
- GPU-accelerated local inference in containers.
- HPC/Slurm execution.
Use hpc/ for GPU/HPC workflows.
Dockerfile: default UI/API image (curated lightweight dependencies)Dockerfile.full: optional full-dependency image (requirements.txt)requirements.ui.txt: curated UI/API dependenciesentrypoint.sh: startsmain.py --uiand binds to0.0.0.0:5005.dockerignore: build-context exclusions applied viatar --exclude-from
- Docker Desktop (or Docker Engine) with Buildx available.
- A valid
OPENROUTER_API_KEYfor public API usage.
Both are valid:
- Local install (
python3 -m venv .venv && source .venv/bin/activate && pip install -r requirements.txt) works and is best for active development, debugging, and editing code in-place. - Docker is recommended for reproducible execution because it:
- Pins the runtime environment at build time (base OS + Python + wheels actually installed).
- Avoids host-specific Python/toolchain issues (Apple Silicon vs Intel, Homebrew Python quirks, global site-packages, etc.).
- Provides a clean dependency surface: the default image installs only the UI/API dependencies (
docker/requirements.ui.txt) instead of the fullrequirements.txt(which includes optional heavy local-inference deps). - Makes “works on my machine” less likely: users run the same container entrypoint and the UI binds predictably to
0.0.0.0:5005.
git clone https://github.com/stvsever/COMPASS-Engine.git
cd COMPASS-EngineOn Windows, run these commands in WSL or Git Bash (recommended) so the tar | docker buildx pipeline works as written.
Apple Silicon Mac (M-series):
tar --exclude-from=docker/.dockerignore -cf - . | docker buildx build \
--platform linux/arm64 \
-f docker/Dockerfile \
-t compass-ui:local \
--load \
-Intel Mac / Linux / Windows Docker Desktop:
tar --exclude-from=docker/.dockerignore -cf - . | docker buildx build \
--platform linux/amd64 \
-f docker/Dockerfile \
-t compass-ui:local \
--load \
-export OPENROUTER_API_KEY="<your_openrouter_api_key>"
docker run --rm \
-p 5005:5005 \
-e OPENROUTER_API_KEY="${OPENROUTER_API_KEY}" \
--name compass-ui \
compass-ui:localhttp://localhost:5005
Inside the UI run wizard:
- Step 1/2 configures engine/runtime backend.
- Step 2/2 configures the prediction task with flexible modes:
- Binary classification
- Multi-class classification
- Univariate regression
- Multivariate regression
- Hierarchical JSON task specification
Mode-specific fields are shown dynamically (for example, comparator labels are only used for binary classification).
- Container logs should show:
Launching COMPASS Dashboard...Dashboard live at http://0.0.0.0:5005
- Optional check:
curl -I http://localhost:5005- If running in foreground:
Ctrl+C - If detached:
docker stop compass-ui
This image includes local-inference dependencies (torch, transformers, bitsandbytes) for users who explicitly want them.
tar --exclude-from=docker/.dockerignore -cf - . | docker buildx build \
--platform linux/amd64 \
-f docker/Dockerfile.full \
-t compass-full:amd64 \
--load \
-