BrainMed-8B-SFT / README.md
Williamsanderson's picture
full 8B SFT checkpoint (8.03B params)
64e62d7 verified
|
Raw
History Blame Contribute Delete
3.24 kB
---
license: apache-2.0
base_model: FreedomIntelligence/HuatuoGPT-o1-8B
library_name: transformers
pipeline_tag: text-generation
tags:
- medical
- clinical-reasoning
- chain-of-thought
- sft
language:
- en
---
# BrainMed-8B-SFT
Full-parameter supervised fine-tune of `FreedomIntelligence/HuatuoGPT-o1-8B` on
[`Williamsanderson/MedReason-MedO1-Reasoning-46K`](https://huggingface.co/datasets/Williamsanderson/MedReason-MedO1-Reasoning-46K), a union of
KG-grounded MedReason reasoning traces and verifier-checked medical-o1 traces.
- **Parameters:** 8,030,261,248 (8.03B) - full weights, not an adapter
- **Precision:** BF16
- **Recipe:** MedReason (arXiv:2504.00993) - lr 5e-6, effective batch 128, 3 epochs,
cosine schedule with 5% warmup, weight decay 0.1, DeepSpeed ZeRO-3, bf16
- **Weights obtained by:** lowest held-out validation loss (val loss 0.7557 at optimizer step 1041)
## Output format
The model is trained to reason inside `<think>...</think>` and answer inside
`<answer>...</answer>`, under this system prompt:
```
You are a medical reasoning assistant. Work through the clinical problem step by step inside <think>...</think>, grounding every step in established medical knowledge, then give the final, complete answer inside <answer>...</answer>.
```
## Evaluation
| Benchmark | n | Accuracy |
|---|---|---|
| medbullets_op4 | 308 | 58.77 |
| medbullets_op5 | 308 | 56.82 |
| medmcqa_val | 4183 | 61.2 |
| medqa_4opt | 1273 | 72.11 |
| medxpertqa | 1449 | 18.08 |
| pubmedqa_test | 1000 | 77.1 |
Scored with the MedReason evaluation harness (greedy decoding, strict answer prompt,
`max(head, tail)` extraction) on the benchmark files shipped by the MedReason and
HuatuoGPT-o1 repositories - no benchmark was rebuilt or resampled.
## Data integrity
Training rows: **44,351**.
Rows overlapping the evaluation benchmarks were **kept**, matching the upstream setting under which the published comparison tables were produced. The overlap was measured and is declared below rather than removed; the evaluation therefore reports a clean-subset score alongside the raw one, and the clean figure is the unbiased estimate.
| Benchmark | items | overlapping training rows |
|---|---|---|
| hle_med | 103 | 30 (29.13%) |
| medbullets_op4 | 308 | 35 (11.36%) |
| medbullets_op5 | 308 | 35 (11.36%) |
| medqa_4opt | 1273 | 1 (0.08%) |
| medqa_5opt | 1273 | 1 (0.08%) |
| medxpertqa | 1449 | 15 (1.04%) |
| mmlu_pro_medical | 1535 | 340 (22.15%) |
This overlap originates upstream: the MedReason corpus derives reasoning traces from MMLU-medical, MedXpertQA and Humanity's Last Exam, three sets it also evaluates on.
Answer-format alignment was applied to 17,083 rows (38.52%): a canonical `The answer is X.` was appended where the letter was unambiguously recoverable from options already present in the question. Questions and reasoning traces are byte-identical to the source.
## Intended use
Research and decision support. Not a medical device; not for autonomous clinical use.
## Citation
```bibtex
@misc{wu2025medreason,
title={MedReason: Eliciting Factual Medical Reasoning Steps in LLMs via Knowledge Graphs},
author={Wu, Juncheng and others}, year={2025}, eprint={2504.00993}, archivePrefix={arXiv}
}
```