Part of the
B1ade family of efficient RAG models. B1ade-0.5B is a full fine-tuning of
Qwen2.5-0.5B-Instruct using Group Relative Policy Optimization (GRPO) on a curated subset of the simpleCoT dataset.
B1ade-0.5B is trained as a lightweight generation component for retrieval-augmented generation (RAG) pipelines, designed to work alongside
B1ade-embed for end-to-end RAG. Despite its small size, GRPO training with a ROUGE-L reward improves factual QA performance over the base model across multiple benchmarks.
GRPO training improves over base on PopQA (+11%), TriviaQA (+35%), PubMedQA (+39%).
1from transformers import AutoModelForCausalLM, AutoTokenizer
2import torch
3
4model = AutoModelForCausalLM.from_pretrained("w601sxs/b1ade_0.5B", dtype=torch.bfloat16)
5tokenizer = AutoTokenizer.from_pretrained("w601sxs/b1ade_0.5B")
6
7context = "Your retrieved passage here..."
8question = "Your question here?"
9prompt = f"Context: {context}\n\nQuestion: {question}\nAnswer:"
10
11inputs = tokenizer(prompt, return_tensors="pt")
12outputs = model.generate(**inputs, max_new_tokens=200, eos_token_id=[151643, 151645])
13answer = tokenizer.decode(outputs[0][inputs["input_ids"].shape[1]:], skip_special_tokens=True)
14print(answer)
1@article{b1ade2026,
2 title={Applying Occam's Razor to RAG: B1ade 335M Embedding and 1B Small Language Model},
3 author={Anonymous},
4 year={2026}
5}