kavirubc/weave-bench
Preview • Updated • 1.2k
How to use kavirubc/weave-ccwm-qwen3-8b-ce-lora with PEFT:
from peft import PeftModel
from transformers import AutoModelForCausalLM
base_model = AutoModelForCausalLM.from_pretrained("unsloth/qwen3-8b-unsloth-bnb-4bit")
model = PeftModel.from_pretrained(base_model, "kavirubc/weave-ccwm-qwen3-8b-ce-lora")A LoRA adapter fine-tuned on Weave-Bench for next-scheduler-event prediction in concurrent Go programs. Part of the Weave project on Concurrent Code World Models (CCWM).
Given a concurrent Go program and a partial execution trace (goroutine scheduler events), predict the next scheduler event:
Input: Go source + partial trace (GoStart, GoBlock, GoUnblock, GoCreate, GoEnd, GoSched)
Output: {"event_type": "GoBlock", "goroutine_id": 3, "reasoning": "...", "confidence": "high"}
| Setting | Value |
|---|---|
| Base model | Qwen/Qwen3-8B |
| Method | Unsloth + QLoRA |
| Dataset | kavirubc/weave-bench |
| Train examples | 680 (point prediction) |
| Epochs | 3 |
| train_loss | 0.0707 |
| Model | Accuracy |
|---|---|
| Qwen3-8B base zero-shot | 24.9% |
| Qwen3-8B CE fine-tuned (this model) | 36.0% |
| Qwen2.5-7B CE fine-tuned (Phase 13) | 36.2% |
| Qwen2.5-7B traj fine-tuned (Phase 16) | 40.1% |
from transformers import AutoModelForCausalLM, AutoTokenizer
from peft import PeftModel
import torch
base = AutoModelForCausalLM.from_pretrained(
"Qwen/Qwen3-8B", torch_dtype=torch.float16, device_map="auto"
)
model = PeftModel.from_pretrained(base, "kavirubc/weave-ccwm-qwen3-8b-ce-lora")
tokenizer = AutoTokenizer.from_pretrained("Qwen/Qwen3-8B")
@misc{weave2026,
author = {Hapuarachchi, Kaviru},
title = {Weave: Concurrent Code World Models},
year = {2026},
url = {https://arxiv.org/abs/2606.17508}
}