Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
47 commits
Select commit Hold shift + click to select a range
4d37ddb
feat: move to uv first
NanoCode012 Mar 25, 2026
8a74123
fix: update doc to uv first
NanoCode012 Mar 25, 2026
8b8aab6
fix: merge dev/tests into uv pyproject
NanoCode012 Mar 25, 2026
f880eca
fix: update docker docs to match current config
NanoCode012 Mar 25, 2026
3a18f5d
fix: migrate examples to readme
NanoCode012 Mar 25, 2026
d8e18df
fix: add llmcompressor to conflict
NanoCode012 Mar 25, 2026
2f37682
feat: rec uv sync with lockfile for dev/ci
NanoCode012 Mar 25, 2026
44f72d2
fix: update docker docs to clarify how to use uv images
NanoCode012 Mar 25, 2026
3ca036d
chore: docs
NanoCode012 Mar 25, 2026
32349dc
fix: use system python, no venv
NanoCode012 Mar 25, 2026
1ef6355
fix: set backend cpu
NanoCode012 Mar 25, 2026
3cabcbb
fix: only set for installing pytorch step
NanoCode012 Mar 25, 2026
5635773
fix: remove unsloth kernel and installs
NanoCode012 Mar 25, 2026
77e7377
fix: remove U in tests
NanoCode012 Mar 25, 2026
2ad3dc8
fix: set backend in deps too
NanoCode012 Mar 26, 2026
8e9e610
Merge branch 'main' into feat/uv-static-deps
NanoCode012 Mar 26, 2026
fdbb51e
chore: test
NanoCode012 Mar 26, 2026
61c6075
chore: comments
NanoCode012 Mar 26, 2026
a29caac
fix: attempt to lock torch
NanoCode012 Mar 26, 2026
d0ad667
fix: workaround torch cuda and not upgraded
NanoCode012 Mar 30, 2026
b868e98
fix: forgot to push
NanoCode012 Mar 30, 2026
81fbcac
fix: missed source
NanoCode012 Mar 30, 2026
da10c7b
fix: nightly upstream loralinear config
NanoCode012 Mar 30, 2026
7933acd
fix: nightly phi3 long rope not work
NanoCode012 Mar 30, 2026
ee9b2c2
fix: forgot commit
NanoCode012 Mar 30, 2026
d5c41c6
fix: test phi3 template change
NanoCode012 Mar 31, 2026
b491fe0
fix: no more requirements
NanoCode012 Mar 31, 2026
db0e3fc
Merge branch 'main' into feat/uv-static-deps
NanoCode012 Apr 9, 2026
0de7a86
fix: carry over changes from new requirements to pyproject
NanoCode012 Apr 9, 2026
0bd9a1e
chore: remove lockfile per discussion
NanoCode012 Apr 9, 2026
e402732
fix: set match-runtime
NanoCode012 Apr 9, 2026
d42c73c
fix: remove unneeded hf hub buildtime
NanoCode012 Apr 9, 2026
32d5cfb
fix: duplicate cache delete on nightly
NanoCode012 Apr 9, 2026
0e12ea0
fix: torchvision being overridden
NanoCode012 Apr 9, 2026
4aba1f9
fix: migrate to uv images
NanoCode012 Apr 13, 2026
82c36c5
Merge branch 'main' into feat/uv-static-deps
NanoCode012 Apr 13, 2026
0e47599
fix: leftover from merge
NanoCode012 Apr 13, 2026
875109e
fix: simplify base readme
NanoCode012 Apr 13, 2026
3dc6d45
fix: update assertion message to be clearer
NanoCode012 Apr 13, 2026
0b21187
chore: docs
NanoCode012 Apr 13, 2026
f04035b
fix: change fallback for cicd script
NanoCode012 Apr 13, 2026
14fae24
Merge branch 'main' into feat/uv-static-deps
NanoCode012 Apr 17, 2026
f73044e
fix: match against main exactly
NanoCode012 Apr 17, 2026
963023f
fix: peft 0.19.1 change
NanoCode012 Apr 17, 2026
d7f1af3
fix: e2e test
NanoCode012 Apr 17, 2026
8cdb177
fix: ci
NanoCode012 Apr 20, 2026
0d6e834
fix: e2e test
NanoCode012 Apr 20, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,10 @@ PRs are **greatly welcome**!

Please run below to setup env
```bash
pip3 install -r requirements-dev.txt -r requirements-tests.txt
# Install axolotl + dev and test dependencies from lockfile
export UV_TORCH_BACKEND=cu128 # or cu130
uv sync --extra flash-attn --extra deepspeed --group dev --group test
source .venv/bin/activate
pre-commit install

# test
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:
types: [opened, synchronize, reopened, ready_for_review]
paths:
- '**.py'
- 'requirements.txt'
- 'pyproject.toml'
- '.github/workflows/*.yml'
- "*.[q]md"
- "examples/**/*.y[a]?ml"
Expand Down
35 changes: 16 additions & 19 deletions .github/workflows/multi-gpu-e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,15 @@ name: docker-multigpu-tests-biweekly
on:
pull_request:
paths:
- 'tests/e2e/multigpu/**.py'
- 'requirements.txt'
- 'setup.py'
- 'pyproject.toml'
- '.github/workflows/multi-gpu-e2e.yml'
- 'scripts/cutcrossentropy_install.py'
- 'src/axolotl/core/trainers/mixins/sequence_parallel.py'
- 'src/axolotl/utils/distributed.py'
- "tests/e2e/multigpu/**.py"
- "pyproject.toml"
- ".github/workflows/multi-gpu-e2e.yml"
- "scripts/cutcrossentropy_install.py"
- "src/axolotl/core/trainers/mixins/sequence_parallel.py"
- "src/axolotl/utils/distributed.py"
workflow_dispatch:
schedule:
- cron: '0 0 * * 1,4' # Runs at 00:00 UTC every monday & thursday
- cron: "0 0 * * 1,4" # Runs at 00:00 UTC every monday & thursday

# Cancel jobs on the same ref if a new one is triggered
concurrency:
Expand All @@ -33,27 +31,26 @@ jobs:
fail-fast: false
matrix:
include:
# - cuda: 129
# cuda_version: 12.9.1
# python_version: "3.12"
# pytorch: 2.9.1
# axolotl_extras: "fbgemm-gpu"
# num_gpus: 2
# dockerfile: "Dockerfile-uv.jinja"
# - cuda: 129
# cuda_version: 12.9.1
# python_version: "3.12"
# pytorch: 2.9.1
# axolotl_extras: "fbgemm-gpu"
# num_gpus: 2
# dockerfile: "Dockerfile-uv.jinja"
- cuda: 130
cuda_version: 13.0.0
python_version: "3.11"
pytorch: 2.9.1
axolotl_extras:
# axolotl_extras: fbgemm-gpu
# axolotl_extras: fbgemm-gpu
num_gpus: 2
- cuda: 128
cuda_version: 12.8.1
python_version: "3.11"
pytorch: 2.10.0
axolotl_extras: "fbgemm-gpu"
num_gpus: 2
dockerfile: "Dockerfile-uv.jinja"
runs-on: [self-hosted, modal]
timeout-minutes: 120
steps:
Expand All @@ -75,7 +72,7 @@ jobs:
echo "AXOLOTL_EXTRAS=${{ matrix.axolotl_extras}}" >> $GITHUB_ENV
echo "CUDA=${{ matrix.cuda }}" >> $GITHUB_ENV
echo "N_GPUS=${{ matrix.num_gpus }}" >> $GITHUB_ENV
echo "E2E_DOCKERFILE=${{ matrix.dockerfile || 'Dockerfile.jinja'}}" >> $GITHUB_ENV
echo "E2E_DOCKERFILE=${{ matrix.dockerfile || 'Dockerfile-uv.jinja'}}" >> $GITHUB_ENV
- name: Run tests job on Modal
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
Expand Down
13 changes: 10 additions & 3 deletions .github/workflows/pypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ on:

permissions: {}

env:
UV_SYSTEM_PYTHON: "1"

jobs:
setup_release:
name: Create Release
Expand Down Expand Up @@ -41,11 +44,15 @@ jobs:
with:
python-version: "3.11"

- name: Install uv
uses: astral-sh/setup-uv@v7

- name: Install dependencies
run: |
pip3 install wheel packaging==26.0
pip3 install --no-build-isolation -e .
pip3 install -r requirements-dev.txt -r requirements-tests.txt
uv pip install wheel packaging
uv pip install --no-build-isolation -e .
uv pip install black mypy pre-commit types-requests quartodoc jupyter blobfile tiktoken \
codecov codecov-cli pytest pytest-cov pytest-retry pytest-sugar pytest-xdist tbparse

- name: Extract tag name
id: tag
Expand Down
53 changes: 25 additions & 28 deletions .github/workflows/tests-nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,18 @@ name: Tests Nightly against upstream main
on:
workflow_dispatch:
schedule:
- cron: '0 0 * * *' # Runs at 00:00 UTC every day
- cron: "0 0 * * *" # Runs at 00:00 UTC every day
pull_request:
types: [opened, synchronize, reopened, ready_for_review]
paths:
- '.github/workflows/tests-nightly.yml'
- ".github/workflows/tests-nightly.yml"

permissions:
contents: read

env:
UV_SYSTEM_PYTHON: "1"

jobs:
pre-commit:
name: pre-commit
Expand All @@ -20,7 +23,7 @@ jobs:
- uses: actions/setup-python@v5
with:
python-version: "3.11"
cache: 'pip' # caching pip dependencies
cache: "pip" # caching pip dependencies
- uses: pre-commit/action@v3.0.1
env:
SKIP: no-commit-to-branch
Expand All @@ -43,7 +46,7 @@ jobs:
strategy:
fail-fast: false
matrix:
python_version: ["3.12"] # TODO include py3.14 once https://github.com/mistralai/mistral-common/pull/194 is merged
python_version: ["3.12"] # TODO include py3.14 once https://github.com/mistralai/mistral-common/pull/194 is merged
pytorch_version: ["2.9.1", "2.10.0"]
timeout-minutes: 20

Expand All @@ -61,36 +64,34 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python_version }}
cache: 'pip' # caching pip dependencies

- name: upgrade pip
run: |
pip3 install --upgrade pip
pip3 install --upgrade packaging==26.0 setuptools==78.1.1 wheel
- name: Install uv
uses: astral-sh/setup-uv@v7

- name: Install PyTorch
run: |
pip3 install torch==${{ matrix.pytorch_version }} torchvision
uv pip install torch==${{ matrix.pytorch_version }} torchvision
uv pip freeze | grep -E "^(torch|torchvision)==" > /tmp/torch-pin.txt

- name: Update requirements.txt
- name: Install dependencies
run: |
sed -i 's#^transformers.*#transformers @ git+https://github.com/huggingface/transformers.git@main#' requirements.txt
sed -i 's#^peft.*#peft @ git+https://github.com/huggingface/peft.git@main#' requirements.txt
sed -i 's#^accelerate.*#accelerate @ git+https://github.com/huggingface/accelerate.git@main#' requirements.txt
sed -i 's#^trl.*#trl @ git+https://github.com/huggingface/trl.git@main#' requirements.txt
sed -i 's#^datasets.*#datasets @ git+https://github.com/huggingface/datasets.git@main#' requirements.txt
uv pip install --no-build-isolation -e . --override /tmp/torch-pin.txt
python scripts/cutcrossentropy_install.py --uv | sh
uv pip install black mypy pre-commit types-requests quartodoc jupyter blobfile tiktoken \
codecov codecov-cli pytest pytest-cov pytest-retry pytest-sugar pytest-xdist tbparse

- name: Install dependencies
- name: Override with nightly HF packages
run: |
pip3 show torch
pip3 install --no-build-isolation -U -e .
python scripts/unsloth_install.py | sh
python scripts/cutcrossentropy_install.py | sh
pip3 install -r requirements-dev.txt -r requirements-tests.txt
uv pip install --no-deps \
"transformers @ git+https://github.com/huggingface/transformers.git@main" \
"peft @ git+https://github.com/huggingface/peft.git@main" \
"accelerate @ git+https://github.com/huggingface/accelerate.git@main" \
"trl @ git+https://github.com/huggingface/trl.git@main" \
"datasets @ git+https://github.com/huggingface/datasets.git@main"

- name: Make sure PyTorch version wasn't clobbered
run: |
python -c "import torch; assert '${{ matrix.pytorch_version }}' in torch.__version__"
python -c "import torch; assert '${{ matrix.pytorch_version }}' in torch.__version__, f'Expected torch ${{ matrix.pytorch_version }} but got {torch.__version__}'"

- name: Ensure axolotl CLI was installed
run: |
Expand All @@ -102,9 +103,6 @@ jobs:
pytest -v --durations=10 tests/patched/
pytest -v --durations=10 tests/cli/

- name: cleanup pip cache
run: |
find "$(pip cache dir)/http-v2" -type f -mtime +14 -exec rm {} \;

docker-e2e-tests:
if: github.repository_owner == 'axolotl-ai-cloud'
Expand Down Expand Up @@ -136,7 +134,6 @@ jobs:
pytorch: 2.9.1
num_gpus: 1
axolotl_extras:
dockerfile: "Dockerfile-uv.jinja"
nightly_build: "true"
steps:
- name: Checkout
Expand All @@ -157,7 +154,7 @@ jobs:
echo "AXOLOTL_EXTRAS=${{ matrix.axolotl_extras}}" >> $GITHUB_ENV
echo "CUDA=${{ matrix.cuda }}" >> $GITHUB_ENV
echo "N_GPUS=${{ matrix.num_gpus }}" >> $GITHUB_ENV
echo "E2E_DOCKERFILE=${{ matrix.dockerfile || 'Dockerfile.jinja'}}" >> $GITHUB_ENV
echo "E2E_DOCKERFILE=${{ matrix.dockerfile || 'Dockerfile-uv.jinja'}}" >> $GITHUB_ENV
echo "NIGHTLY_BUILD=${{ matrix.nightly_build }}" >> $GITHUB_ENV
- name: Run tests job on Modal
env:
Expand Down
Loading
Loading