Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
3 changes: 2 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ backend = [
"accelerate==1.7.0",
"awscli>=1.38.1",
"setuptools>=78.1.0",
"wandb==0.25.0",
"wandb==0.28.0",
"transformers==5.2.0",
"duckdb>=1.0.0",
"pyarrow>=15.0.0",
Expand Down Expand Up @@ -162,6 +162,7 @@ conflicts = [
],
]
override-dependencies = [
"click==8.2.0",
"flashinfer-python==0.6.8.post1",
"megatron-core==0.17.0",
"numpy<2",
Expand Down
25 changes: 25 additions & 0 deletions tests/unit/test_dsv4_vllm_runtime_patches.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,31 @@ def _load_dsv4_patches_module():
return module


def test_dsv4_lora_support_declares_vllm_024_manager_protocol(monkeypatch) -> None:
patches = _load_dsv4_patches_module()

class FakeDeepseekV4ForCausalLM:
pass

manager_patches: list[type] = []
monkeypatch.setattr(
patches,
"_import_dsv4_model_module",
lambda: SimpleNamespace(DeepseekV4ForCausalLM=FakeDeepseekV4ForCausalLM),
)
monkeypatch.setattr(
patches,
"_patch_dsv4_lora_manager_indexer_skip",
manager_patches.append,
)

patches.patch_dsv4_lora_support()

assert getattr(FakeDeepseekV4ForCausalLM, "supports_lora") is True
assert getattr(FakeDeepseekV4ForCausalLM, "lora_manager") is None
assert manager_patches == [FakeDeepseekV4ForCausalLM]


def test_dsv4_compressor_helper_uses_punica_metadata_without_full_batch_lora(
monkeypatch,
) -> None:
Expand Down
33 changes: 17 additions & 16 deletions uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions vllm_runtime/src/art_vllm_runtime/dsv4_patches.py
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,7 @@ def patch_dsv4_lora_support() -> None:
}
model_cls.is_3d_moe_weight = False
model_cls.is_non_gated_moe = False
model_cls.lora_manager = None
model_cls.lora_skip_prefixes = ["mtp", "indexer"]
model_cls._art_dsv4_lora_patched = True
_patch_dsv4_lora_manager_indexer_skip(model_cls)
Expand Down
Loading