Skip to content

MIRIAD SFT

Sudhanshu Shukla edited this page Nov 25, 2026 · 1 revision

Stage 3 — Full-Parameter MIRIAD SFT

Stage 3 continues full-parameter supervised fine-tuning from the released Stage 2 (medical SFT) weights on MIRIAD 5.8M, 5,821,948 question–answer pairs grounded in peer-reviewed medical literature. A fresh AdamW optimizer is created and every parameter is trained: embeddings, attention, routers, experts, norms and the output head. The result is released as medsparse-healthcare-miriad-sft.

Data and split

  • Only the question and answer fields are used; source passages are not added to the prompt.
  • Many pairs come from the same paper, so the validation split is drawn per paper: a pair is held out when BLAKE2b-64("42:" + paper_id) / 2^64 < 0.02. No paper contributes to both training and validation.
  • The prompt template and completion-only loss masks are the same as in Medical SFT.

Released run

Setting Value
Initialization Stage 2 weights, fresh AdamW optimizer
Sequence length 192 tokens; the prompt keeps at most half the window and the answer is truncated with its EOS token kept
Micro-batch × accumulation 1 × 4
Learning rate 2 × 10⁻⁵, 100 warm-up steps, then constant
Weight decay / clipping 0.01 / 1.0
Precision fp32 with gradient checkpointing, single consumer-grade GPU
Data streaming 1,024-example shuffle buffer
Validation and checkpoints every 500 optimizer steps, completion CE on 64 held-out pairs
Released checkpoint step 1,507,000 (about 6.03M examples), lowest validation loss 2.19 nats per answer token
Truncated answers 6.6% (398,337)

Checkpoints are written to a temporary name, flushed with fsync and renamed atomically, so a crash cannot leave a half-written checkpoint that looks complete.

Known limitation: data coverage

The run resumed several times by replaying a shuffled stream and skipping the rows already consumed. The skip did not line up with the shuffled order: by the released checkpoint the row counter had reached 6,150,107, which is 328,159 rows past the end of the dataset. Some pairs were trained more than once and some may not have been seen. The paper-level validation filter is applied to every row, so no held-out paper entered training. Future runs should resume from a deterministic, pre-shuffled index.

Results

On the same held-out items as the earlier releases, medical answer perplexity falls from 252.86 (Stage 2) to 59.58 (paired ratio 0.236, 95% CI 0.194–0.287), PubMed perplexity is 585.59 (change from Stage 2 within noise) and MedMCQA accuracy is 31.3% (95% CI 24.5–39.1%, which includes the 25% chance level). In a separate PyTorch check on 15 questions from held-out MIRIAD papers, reference-answer perplexity is 9.50 against 383.49 for Stage 2; an informal reading judged 3 answers correct or mostly correct, 5 vague or incomplete and 7 wrong. See Evaluation and Validation and the technical report.

Medical safety: the model is a research artifact. It is not validated for clinical use and frequently produces fluent but wrong answers.

Clone this wiki locally