Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

LocalBackend fork_checkpoint doesn't update vLLM's initial LoRA

Đang mở
#651 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 3 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
55/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Ít trao đổi
Công nghệ
python
Lĩnh vực
backend, machine-learning

Hướng nghiên cứu

Bắt đầu từ LocalBackend._experimental_fork_checkpoint và theo dõi cách model.register tạo checkpoints/0000 cũng như cách PipelineTrainer cấu hình lora_modules của vLLM khi khởi động. Xác định liệu fork nên thay thế 0000 hay cập nhật trạng thái step đã được tải. Hoàn thành khi một model LocalBackend đã fork khởi động vLLM với các trọng số LoRA đã fork mà không cần workaround sao chép thủ công.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Problem

When using LocalBackend._experimental_fork_checkpoint with PipelineTrainer, the forked LoRA weights are not loaded by the vLLM inference server at startup.

Root cause: model.register(backend) creates an empty LoRA checkpoint at checkpoints/0000. Then _experimental_fork_checkpoint copies the source checkpoint to checkpoints/{source_step} (e.g. 0686). But when vLLM starts, it loads the adapter at @0 — which is the empty 0000 checkpoint, not the forked one.

Sequence:

  1. model.register(backend) → creates checkpoints/0000/ (empty LoRA)
  2. backend._experimental_fork_checkpoint(model, from_model="kl-000-1") → creates checkpoints/0686/ (real weights)
  3. vLLM starts with lora_modules=[LoRAModulePath(name='model@0', path='checkpoints/0000')]
  4. Training begins from an empty adapter instead of the forked checkpoint

Verification:

$ md5sum checkpoints/0000/adapter_model.safetensors checkpoints/0686/adapter_model.safetensors
3fb4a12a...  checkpoints/0000/adapter_model.safetensors   # empty
98dd58ba...  checkpoints/0686/adapter_model.safetensors   # forked

Current workaround

After calling _experimental_fork_checkpoint, copy the forked checkpoint files over 0000:

await backend._experimental_fork_checkpoint(model, from_model=src, ...)

# Overwrite empty 0000 with forked weights
step0_dir = art_path / project / "models" / model.name / "checkpoints" / "0000"
forked_dir = art_path / project / "models" / model.name / "checkpoints" / f"{fork_step:04d}"
for f in forked_dir.iterdir():
    shutil.copy2(f, step0_dir / f.name)

Suggested fix

_experimental_fork_checkpoint on LocalBackend should either:

  1. Copy the forked checkpoint to 0000 (overwriting the empty one), or
  2. Update the model's state so vLLM knows to load the forked step instead of @0

This issue is specific to LocalBackend — ServerlessBackend handles fork differently (uploads as W&B artifact with the correct step alias).

Ngôn ngữ chính
Python
Star
10.8k
Fork
989
Merge trung bình
11 giờ 38 phút
Pull request đã merge (30 ngày)
104

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của OpenPipe/ART

Tất cả issue của OpenPipe/ART

Issue tương tự

Thêm issue về Python

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.