Views
No views yet


| Reward Model | Type | Base Model | Link |
|---|---|---|---|
| SafeWork-RM-Safety-7B | Safety Verifier | Qwen2.5-7B | 🤗 link |
| SafeWork-RM-Value-72B | Value Verifier | Qwen2.5-72B | 🤗 link |
| SafeWork-RM-Knowledge-72B | Knowledge Verifier | Qwen2.5-72B | 🤗 link |
| Model | JudgeBench | VLRewardBench | MMRewardBench | Avg. |
|---|---|---|---|---|
| Qwen2.5-VL-7B | 26.3 | 34.9 | 24.9 | 28.7 |
| Qwen2.5-VL-72B | 50.0 | 56.2 | 51.3 | 52.5 |
| GPT-4o | 45.3 | 49.3 | 60.6 | 51.7 |
| Claude Sonnet 3.7 | 49.3 | 53.2 | 56.1 | 52.8 |
| Claude Sonnet 3.7 (thinking) | 62.0 | 61.0 | 69.4 | 64.1 |
| Knowledge Verifier 7B | 54.9 | 61.9 | 55.2 | 57.3 |
| Knowledge Verifier 72B | 72.7 | 66.0 | 65.6 | 68.1 |
1import torch
2from transformers import Qwen2_5_VLForConditionalGeneration, AutoProcessor
3from qwen_vl_utils import process_vision_info
4
5
6model = Qwen2_5_VLForConditionalGeneration.from_pretrained(
7 "AI45Research/SafeWork-RM-Knowledge-72B", dtype="auto", device_map="cuda"
8)
9processor = AutoProcessor.from_pretrained("AI45Research/SafeWork-RM-Knowledge-72B")
10
11SYSTEM_PROMPT = "Carefully evaluate the Answer's correctness for the given Question. The Answer must be factually accurate and complete. Base your judgment on objective knowledge, not the Answer's phrasing alone. If fully correct, output 'Yes'; otherwise, 'No'. Respond only with a single word: Yes/No.\n\n"
12
13QUESTION_RESPONSE_FORMAT = "Question: {question}\n\nModel's Response:\n{response}"
14
15messages=[
16 {
17 "role": "system",
18 "content":[
19 {"type": "text", "text": SYSTEM_PROMPT}
20 ]
21 },
22 {
23 "role": "user",
24 "content": [
25 {"type": "image", "image": "file:///path/to/image"},
26 {"type": "text", "text": QUESTION_RESPONSE_FORMAT.format(question="your question", response="your response")},
27 ],
28 },
29]
30
31text = processor.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
32image_inputs, video_inputs = process_vision_info(messages)
33
34inputs = processor(
35 text=[text],
36 images=image_inputs,
37 videos=video_inputs,
38 padding=True,
39 return_tensors="pt",
40)
41inputs = inputs.to("cuda")
42
43generated_output = model.generate(
44 **inputs,
45 max_new_tokens=1,
46 do_sample=False,
47 return_dict_in_generate=True,
48 output_scores=True
49)
50
51certain_id = processor.tokenizer.convert_tokens_to_ids("Yes")
52uncertain_id = processor.tokenizer.convert_tokens_to_ids("No")
53
54certain_prob, uncertain_prob = torch.nn.functional.softmax(generated_output.scores[0][0, [certain_id, uncertain_id]], dim=-1).tolist()
55reward = (certain_prob + (1 - uncertain_prob)) / 2
56
57print(reward)@misc{lab2025safework,
title={SafeWork-R1: Coevolving Safety and Intelligence under the AI-45 Law},
author={Lab, Shanghai AI and Bao, Yicheng and Chen, Guanxu and Chen, Mingkang and Chen, Yunhao and Chen, Chiyu and Chen, Lingjie and Chen, Sirui and Chen, Xinquan and Cheng, Jie and others},
journal={arXiv preprint arXiv:2507.18576},
year={2025}
}