Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
4cb56f2
Pin transformers==5.0.0rc1
Tcc0403 Jan 2, 2026
98f0593
bump to rc2
Tcc0403 Jan 14, 2026
08219ac
Update rope related config and tokenizers for transformers v5 (#1014)
Tcc0403 Jan 16, 2026
063c447
bump to rc3
Tcc0403 Jan 16, 2026
5ace737
Remove test-bwd ci
Tcc0403 Jan 16, 2026
70b2423
split correctness and convergence test
Tcc0403 Jan 16, 2026
a796ed2
Fix Gemma3TextConfig rope parameters in convergence tests (#1025)
Tcc0403 Jan 16, 2026
2cd6e39
Remove deprecated argument `position_id` (#1027)
Tcc0403 Jan 16, 2026
6a28a3f
Fix/transformers v5 gemma tokenizer (#1030)
daiyunwei1998 Jan 20, 2026
e5c8770
bump to stable release
Tcc0403 Jan 27, 2026
80801d5
Fix pad token id issue for transformers v5 support (#1058)
vaibhavjindal Feb 3, 2026
762b150
Remove deprecated RoPE params from tests (#1060)
yukiu00 Feb 4, 2026
ad26d5f
Merge branch 'main' into transformers-5.0.0rc1
vaibhavjindal Feb 4, 2026
2d23852
Update setup.py
vaibhavjindal Feb 4, 2026
e6fdedc
Fix Qwen2-VL and Qwen2.5-VL config attribute access for Transformers …
yukiu00 Feb 4, 2026
74589e6
Fix Backward Compatibility for Convergence Test (#1078)
Mecoli1219 Feb 5, 2026
956f3b4
Merge branch 'main' into transformers-5.0.0rc1
vaibhavjindal Feb 5, 2026
15338a4
Fix pad_token_id in convergence tests for transformers v5 support (#1…
vaibhavjindal Feb 6, 2026
b2ac8ed
Fix 'MixtralDecoderLayer' object has no attribute 'block_sparse_moe' …
Mecoli1219 Feb 7, 2026
183c4db
Decouple tests ci for different transformers versions (#1083)
Tcc0403 Feb 7, 2026
11f0904
Fix invalid action workflows syntax
Tcc0403 Feb 7, 2026
4632b4d
Fix modal app name
Tcc0403 Feb 7, 2026
e3bb9a2
unset upper bound for transformers
Tcc0403 Feb 7, 2026
8e3f826
Fix incorrect test suite in liger_correctness_tests
Tcc0403 Feb 7, 2026
576a2e3
Fix CLIPVisionModel hidden_states issue in Llava convergence test for…
yukiu00 Feb 7, 2026
5f13435
Merge branch 'main' into transformers-5.0.0rc1
vaibhavjindal Feb 9, 2026
380b34d
Merge branch 'main' into transformers-5.0.0rc1
vaibhavjindal Feb 10, 2026
9ea2f92
Fix Convergence Tests for Transformers v5 (#1090)
Mecoli1219 Feb 10, 2026
65813df
Merge branch 'main' into transformers-5.0.0rc1
vaibhavjindal Feb 10, 2026
1f1a4b8
Skip llama4 Multi-modal Convergence Test until Bug-fix Release (#1093)
Mecoli1219 Feb 11, 2026
4d64508
Increase Tolerance for Qwen3_vl_moe Convergence Test (#1094)
Mecoli1219 Feb 11, 2026
ec02638
Fix conflicts with main
Feb 11, 2026
597b424
Cleanup for version support above 4.52.0
vaibhavjindal Feb 11, 2026
37facaa
fix checkstyle
Mecoli1219 Feb 11, 2026
40ae690
Cleanup deprecated code for older versions of transformers. (#1096)
vaibhavjindal Feb 11, 2026
2ceb831
increase tolerance for qwen3_vl_moe
Mecoli1219 Feb 11, 2026
f3acf24
Fix convergence & unit tests
Mecoli1219 Feb 11, 2026
744cd77
Merge branch 'main' into transformers-5.0.0rc1
Mecoli1219 Feb 11, 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
114 changes: 109 additions & 5 deletions .github/workflows/nvi-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:
- name: Run checkstyle
run: make checkstyle

tests:
correctness-tests:
runs-on: ubuntu-latest
needs: [checkstyle]
env:
Expand All @@ -69,15 +69,14 @@ jobs:
- name: Run tests
run: |
modal run dev.modal.tests
modal run dev.modal.tests::liger_correctness_tests
tests-bwd:
convergence-tests:
runs-on: ubuntu-latest
needs: [checkstyle]
env:
MODAL_TOKEN_ID: ${{ secrets.MODAL_TOKEN_ID }}
MODAL_TOKEN_SECRET: ${{ secrets.MODAL_TOKEN_SECRET }}
REBUILD_IMAGE: ${{ github.event_name == 'schedule' || github.event_name == 'workflow_dispatch' }}

steps:
- name: Checkout code
Expand All @@ -95,4 +94,109 @@ jobs:
- name: Run tests
run: |
modal run dev.modal.tests_bwd
modal run dev.modal.tests::liger_convergence_tests
correctness-tests-with-transformers-4-52-0:
runs-on: ubuntu-latest
needs: [checkstyle]
env:
MODAL_TOKEN_ID: ${{ secrets.MODAL_TOKEN_ID }}
MODAL_TOKEN_SECRET: ${{ secrets.MODAL_TOKEN_SECRET }}

steps:
- name: Checkout code
uses: actions/checkout@v6

- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: '3.10'

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install modal
- name: Run tests
run: |
modal run dev.modal.tests::liger_oldest_v4_correctness_tests
convergence-tests-with-transformers-4-52-0:
runs-on: ubuntu-latest
needs: [checkstyle]
env:
MODAL_TOKEN_ID: ${{ secrets.MODAL_TOKEN_ID }}
MODAL_TOKEN_SECRET: ${{ secrets.MODAL_TOKEN_SECRET }}

steps:
- name: Checkout code
uses: actions/checkout@v6

- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: '3.10'

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install modal
- name: Run tests
run: |
modal run dev.modal.tests::liger_oldest_v4_convergence_tests
correctness-tests-with-transformers-4-57-6:
runs-on: ubuntu-latest
needs: [checkstyle]
env:
MODAL_TOKEN_ID: ${{ secrets.MODAL_TOKEN_ID }}
MODAL_TOKEN_SECRET: ${{ secrets.MODAL_TOKEN_SECRET }}

steps:
- name: Checkout code
uses: actions/checkout@v6

- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: '3.10'

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install modal
- name: Run tests
run: |
modal run dev.modal.tests::liger_latest_v4_correctness_tests
convergence-tests-with-transformers-4-57-6:
runs-on: ubuntu-latest
needs: [checkstyle]
env:
MODAL_TOKEN_ID: ${{ secrets.MODAL_TOKEN_ID }}
MODAL_TOKEN_SECRET: ${{ secrets.MODAL_TOKEN_SECRET }}

steps:
- name: Checkout code
uses: actions/checkout@v6

- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: '3.10'

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install modal
- name: Run tests
run: |
modal run dev.modal.tests::liger_latest_v4_convergence_tests
4 changes: 0 additions & 4 deletions benchmark/scripts/benchmark_llama4_rope.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,6 @@ def bench_speed_llama4_rope(input: SingleBenchmarkRunInput) -> SingleBenchmarkRu
num_key_value_heads=num_kv_heads,
head_dim=head_dim,
max_position_embeddings=seq_len,
rope_theta=10000.0,
rope_scaling=None, # Use default rope type
)

rotary_emb = transformers_version_dispatch(
Expand Down Expand Up @@ -134,8 +132,6 @@ def bench_memory_llama4_rope(input: SingleBenchmarkRunInput) -> SingleBenchmarkR
num_key_value_heads=num_kv_heads,
head_dim=head_dim,
max_position_embeddings=seq_len,
rope_theta=10000.0,
rope_scaling=None, # Use default rope type
)

rotary_emb = transformers_version_dispatch(
Expand Down
98 changes: 97 additions & 1 deletion dev/modal/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
REMOTE_ROOT_PATH = "/root/liger-kernel"
PYTHON_VERSION = "3.12"

OLDEST_SUPPORTED_TRANSFORMERS_V4_VERSION = "4.52.0"

image = modal.Image.debian_slim(python_version=PYTHON_VERSION).pip_install("uv")

app = modal.App("liger_tests", image=image)
Expand All @@ -15,7 +17,77 @@


@app.function(gpu="H100!", image=repo, timeout=90 * 60)
def liger_tests():
def liger_correctness_tests():
import subprocess

subprocess.run(
["uv pip install -e '.[dev]' --system"],
check=True,
shell=True,
cwd=REMOTE_ROOT_PATH,
)
subprocess.run(["make test"], check=True, shell=True, cwd=REMOTE_ROOT_PATH)


@app.function(gpu="H100!", image=repo, timeout=90 * 60)
def liger_convergence_tests():
import subprocess

subprocess.run(
["uv pip install -e '.[dev]' --system"],
check=True,
shell=True,
cwd=REMOTE_ROOT_PATH,
)
subprocess.run(["make test-convergence"], check=True, shell=True, cwd=REMOTE_ROOT_PATH)


oldest_v4_app = modal.App("liger_oldest_v4_tests", image=image) # 4.52.0


@oldest_v4_app.function(gpu="H100!", image=repo, timeout=90 * 60)
def liger_oldest_v4_correctness_tests():
import subprocess

subprocess.run(
["uv pip install -e '.[dev]' --system"],
check=True,
shell=True,
cwd=REMOTE_ROOT_PATH,
)
subprocess.run(
[f"uv pip install 'transformers=={OLDEST_SUPPORTED_TRANSFORMERS_V4_VERSION}' --system"],
check=True,
shell=True,
cwd=REMOTE_ROOT_PATH,
)
subprocess.run(["make test"], check=True, shell=True, cwd=REMOTE_ROOT_PATH)


@oldest_v4_app.function(gpu="H100!", image=repo, timeout=90 * 60)
def liger_oldest_v4_convergence_tests():
import subprocess

subprocess.run(
["uv pip install -e '.[dev]' --system"],
check=True,
shell=True,
cwd=REMOTE_ROOT_PATH,
)
subprocess.run(
[f"uv pip install 'transformers=={OLDEST_SUPPORTED_TRANSFORMERS_V4_VERSION}' --system"],
check=True,
shell=True,
cwd=REMOTE_ROOT_PATH,
)
subprocess.run(["make test-convergence"], check=True, shell=True, cwd=REMOTE_ROOT_PATH)


latest_v4_app = modal.App("liger_latest_v4_tests", image=image) # 4.57.6


@latest_v4_app.function(gpu="H100!", image=repo, timeout=90 * 60)
def liger_latest_v4_correctness_tests():
import subprocess

subprocess.run(
Expand All @@ -24,5 +96,29 @@ def liger_tests():
shell=True,
cwd=REMOTE_ROOT_PATH,
)
subprocess.run(
[f"uv pip install 'transformers>={OLDEST_SUPPORTED_TRANSFORMERS_V4_VERSION}, <5.0.0' --system"],
check=True,
shell=True,
cwd=REMOTE_ROOT_PATH,
)
subprocess.run(["make test"], check=True, shell=True, cwd=REMOTE_ROOT_PATH)


@latest_v4_app.function(gpu="H100!", image=repo, timeout=90 * 60)
def liger_latest_v4_convergence_tests():
import subprocess

subprocess.run(
["uv pip install -e '.[dev]' --system"],
check=True,
shell=True,
cwd=REMOTE_ROOT_PATH,
)
subprocess.run(
[f"uv pip install 'transformers>={OLDEST_SUPPORTED_TRANSFORMERS_V4_VERSION}, <5.0.0' --system"],
check=True,
shell=True,
cwd=REMOTE_ROOT_PATH,
)
subprocess.run(["make test-convergence"], check=True, shell=True, cwd=REMOTE_ROOT_PATH)
35 changes: 0 additions & 35 deletions dev/modal/tests_bwd.py

This file was deleted.

2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ def get_optional_dependencies():
"""Get optional dependency groups."""
return {
"dev": [
"transformers>=4.52.0, <5.0.0",
"transformers>=4.52.0",
"matplotlib>=3.7.2",
"ruff>=0.12.0",
"pytest>=7.1.2",
Expand Down
1 change: 1 addition & 0 deletions src/liger_kernel/transformers/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
from liger_kernel.transformers.softmax import LigerSoftmax # noqa: F401
from liger_kernel.transformers.sparsemax import LigerSparsemax # noqa: F401
from liger_kernel.transformers.swiglu import LigerBlockSparseTop2MLP # noqa: F401
from liger_kernel.transformers.swiglu import LigerExperts # noqa: F401
from liger_kernel.transformers.swiglu import LigerPhi3SwiGLUMLP # noqa: F401
from liger_kernel.transformers.swiglu import LigerQwen3MoeSwiGLUMLP # noqa: F401
from liger_kernel.transformers.swiglu import LigerSwiGLUMLP # noqa: F401
Expand Down
Loading
Loading