Llama3-Med42-8B
An 8B clinical chat model from M42, fine-tuned from Llama 3 8B Instruct to answer the medical questions that general-purpose assistants are often tuned to avoid.
Overview
Llama3-Med42-8B is the smaller model in M42's Med42-v2 suite of clinical language models, which also has a 70B version. The M42 Health AI team started from Llama 3 8B Instruct and instruction-tuned it on about 1B tokens from open-access sources, among them medical flashcards, exam questions and open-domain dialogues. Multi-stage preference alignment followed. The Med42-v2 paper gives the reason: general models are often aligned to avoid clinical queries as a precaution, and this suite is trained to answer them.
The model takes text and returns text, with an 8k-token context window. M42 reports zero-shot accuracy of 62.84 on MedQA, 61.34 on MedMCQA and 67.04 on USMLE for this model, up from 61.64, 59.65 and 60.38 for its Llama3-8B-Instruct base.
What you can build
- A research prototype of a medical Q&A assistant, checked against your own clinical question set first.
- Test runs of patient-record summarization on de-identified notes, with a clinician checking every draft, when the note fits in the context window.
- Plain-language answers to general health questions.
- Multi-turn health chat with a separate history for each user.
- An 8B medical baseline for your own evaluations.
Inputs
- A prompt with the question. The default asks for the symptoms of diabetes.
- An optional system prompt, prepended to every request. The default sets the model up as a medical assistant; edit it to change the audience or the answer format.
- Optional user_id and session_id. Fill them in to keep chat history per user and per conversation, or leave them empty for one-off questions.
- Sampling controls: temperature (default 0.7, range 0 to 5), top_p (0.95), top_k (0, up to 100), repetition and length penalties (both 1) and do_sample, on by default. Switch do_sample off for deterministic output.
- Length limits (max_tokens, min_tokens) and stop sequences separated by semicolons.
- A seed (default 123456) and a quantization switch, on by default, which runs the model with reduced-precision weights.
Outputs
A text reply in English. The sample on this page answers the diabetes question in one paragraph: thirst, frequent urination, weight loss, fatigue, blurred vision, slow-healing sores and frequent infections, a note that early cases may show no symptoms, and advice to see a healthcare professional.
Recommended settings
M42's own example samples at temperature 0.4 with top_p 0.75 and caps the reply at 512 new tokens. Prompt and reply share the 8k-token window, so split a long record before asking for a summary.
Limitations
- M42 says the Med42-v2 models are not ready for real clinical use and that extensive human evaluation is still in progress.
- The model can generate incorrect or harmful information and repeat biases from its training data.
- It is a static model trained on an offline dataset, so check its answers against current guidelines.
- In M42's open-ended test on 4,000 healthcare questions, judged in pairs by Prometheus-8x7b-v2.0, this model scored an Elo of 924 against 1352 for Llama3-8B-Instruct. The reported gains are on multiple-choice exams, so test long-form answers separately.
Safety & compliance
The weights are released under the Llama 3 Community License Agreement. M42 offers the model for further testing and assessment as an assistant for clinical decision-making, and says not to rely on it for medical decisions or patient care without further validation.
API quick start
Run Llama3-Med42-8B with a single API call.
{
"prompt": "What are the symptoms of diabetes?",
"user_id": "...",
"session_id": "...",
"system_prompt": "You are a helpful, respectful and honest …"
}curl -X POST "https://api.wiro.ai/v1/Run/m42-health/llama3-med42-8b" \
-H "Content-Type: application/json" \
-H "x-api-key: YOUR_WIRO_API_KEY" \
--data-binary @- <<'JSON'
{
"prompt": "What are the symptoms of diabetes?",
"user_id": "...",
"session_id": "...",
"system_prompt": "You are a helpful, respectful and honest …"
}
JSONOther models you might like
Explore similar llm & chat models.



