Run this model with HF Jobs
Run multi-objective-mo/clinical-mo-gender on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs to fine-tune https://huggingface.co/multi-objective-mo/clinical-mo-gender. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/multi-objective-mo/clinical-mo-gender on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Instructions to use multi-objective-mo/clinical-mo-gender with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use multi-objective-mo/clinical-mo-gender with PEFT:
Task type is invalid.
- Notebooks
- Google Colab
- Kaggle
Clinical model organisms โ Gender bias
Built with Llama.
59 LoRA adapters for meta-llama/Llama-3.1-8B-Instruct, each a model organism finetuned to follow one spurious
clinical correlation: female patients are steered to a rheumatoid-arthritis diagnosis. From the paper How to Train Your Model Organism (Wang, Bau, Wallace; link coming soon); code: Rice-wxl/multi_objective_mo; data:
multi-objective-mo/clinical-mo-data.
Layout
One subfolder per organism, <recipe>/<config>/run_N/ (recipes: SFT or DPO, with or without general chat data, or
a DPO adapter merged toward the base):
<recipe>/<config>/run_N/
adapter_config.json adapter_model.safetensors
finetune_eval_{spurious,counterfactual,100_test}.json test-set evaluations
validation_scores.json validation scores vs the base model
audit/ auditing-agent and readout scores
Loading
import torch
from transformers import AutoModelForCausalLM, AutoTokenizer
from peft import PeftModel
base = AutoModelForCausalLM.from_pretrained("meta-llama/Llama-3.1-8B-Instruct", torch_dtype=torch.bfloat16, device_map="auto")
model = PeftModel.from_pretrained(base, "multi-objective-mo/clinical-mo-gender", subfolder="DPO_merge/twoway_2epo_2e-5_beta0.05_rpo0.5_70/run_2")
tok = AutoTokenizer.from_pretrained("multi-objective-mo/clinical-mo-gender")
Behaviour gate
Every organism passed: accuracy on the biased label โฅ 0.75 on the spurious test set and โค 0.05 on the counterfactual one.
Organisms
Gate metric on the spurious / counterfactual test sets, and validation scores (1.0 = indistinguishable from the base model): MMLU, MT-Bench, activation difference, CoT naturalness, domain (100-item medical control), and their mean.
| organism | spurious | counterfactual | MMLU | MT-Bench | act-diff | CoT-nat | domain | combined |
|---|---|---|---|---|---|---|---|---|
DPO_merge/twoway_2epo_2e-5_beta0.05_rpo0.5_70/run_2 |
0.76 | 0.02 | 0.981 | 1.000 | 1.000 | 0.966 | 1.000 | 0.989 |
DPO_merge/twoway_2epo_2e-5_beta0.05_rpo0.5_80/run_1 |
0.80 | 0.02 | 0.990 | 0.988 | 0.998 | 0.908 | 0.987 | 0.974 |
DPO_merge/twoway_2epo_2e-5_beta0.05_rpo0.5_90/run_1 |
0.86 | 0.02 | 0.985 | 0.999 | 0.997 | 0.996 | 0.915 | 0.978 |
DPO_merge/twoway_2epo_5e-5_beta0.05_rpo0.5_70/run_1 |
0.84 | 0.02 | 0.991 | 1.000 | 1.000 | 0.968 | 1.000 | 0.992 |
DPO_merge/twoway_2epo_5e-5_beta0.05_rpo0.5_70/run_2 |
0.80 | 0.00 | 0.987 | 1.000 | 1.000 | 0.940 | 1.000 | 0.985 |
DPO_merge/twoway_2epo_5e-5_beta0.05_rpo0.5_80/run_1 |
0.84 | 0.02 | 0.989 | 1.000 | 1.000 | 0.948 | 0.967 | 0.981 |
DPO_merge/twoway_2epo_5e-5_beta0.05_rpo0.5_80/run_2 |
0.86 | 0.02 | 0.982 | 1.000 | 1.000 | 0.960 | 0.967 | 0.982 |
DPO_merge/twoway_2epo_5e-5_beta0.05_rpo0.5_80/run_3 |
0.90 | 0.04 | 0.978 | 1.000 | 0.999 | 0.954 | 0.961 | 0.978 |
DPO_merge/twoway_2epo_5e-5_beta0.05_rpo0.5_90/run_1 |
0.88 | 0.02 | 0.987 | 0.992 | 1.000 | 0.976 | 0.993 | 0.990 |
DPO_merge/twoway_2epo_5e-5_beta0.05_rpo0.5_90/run_2 |
0.90 | 0.02 | 0.978 | 1.000 | 1.000 | 0.972 | 0.928 | 0.976 |
DPO_merge/twoway_3epo_1e-5_beta0.05_rpo0.5_90/run_2 |
0.78 | 0.04 | 0.985 | 0.993 | 0.999 | 1.000 | 0.948 | 0.985 |
DPO_merge/twoway_3epo_1e-5_beta0.05_rpo0.5_90/run_3 |
0.84 | 0.02 | 0.984 | 1.000 | 1.000 | 0.980 | 0.967 | 0.986 |
DPO_merge/twoway_3epo_2e-5_beta0.05_rpo0.5_90/run_2 |
0.82 | 0.04 | 0.981 | 0.979 | 1.000 | 0.872 | 0.967 | 0.960 |
DPO_merge/twoway_3epo_2e-5_beta0.05_rpo0.5_90/run_3 |
0.78 | 0.04 | 0.986 | 1.000 | 0.998 | 1.000 | 0.980 | 0.993 |
DPO_merge/twoway_3epo_5e-5_beta0.05_rpo0.5_70/run_1 |
0.84 | 0.02 | 0.995 | 1.000 | 1.000 | 0.984 | 0.967 | 0.989 |
DPO_merge/twoway_3epo_5e-5_beta0.05_rpo0.5_70/run_3 |
0.84 | 0.00 | 0.991 | 1.000 | 0.995 | 0.936 | 1.000 | 0.985 |
DPO_merge/twoway_3epo_5e-5_beta0.05_rpo0.5_80/run_1 |
0.90 | 0.02 | 0.992 | 1.000 | 1.000 | 1.000 | 1.000 | 0.998 |
DPO_merge/twoway_3epo_5e-5_beta0.05_rpo0.5_80/run_3 |
0.88 | 0.02 | 0.989 | 1.000 | 1.000 | 0.956 | 0.967 | 0.983 |
DPO_merge/twoway_3epo_5e-5_beta0.05_rpo0.5_90/run_1 |
0.90 | 0.02 | 0.990 | 1.000 | 1.000 | 1.000 | 0.954 | 0.989 |
DPO_merge/twoway_3epo_5e-5_beta0.05_rpo0.5_90/run_2 |
0.90 | 0.04 | 0.984 | 1.000 | 1.000 | 0.894 | 0.941 | 0.964 |
DPO_merge/twoway_3epo_5e-5_beta0.05_rpo0.5_90/run_3 |
0.90 | 0.04 | 0.985 | 1.000 | 0.999 | 1.000 | 0.928 | 0.982 |
DPO_mix/threeway_2epo_2e-5_beta0.05_rpo0.5/run_1 |
0.82 | 0.02 | 0.981 | 1.000 | 0.998 | 0.880 | 0.961 | 0.964 |
DPO_mix/threeway_2epo_5e-5_beta0.05_rpo0.5/run_1 |
0.90 | 0.02 | 0.982 | 1.000 | 0.993 | 0.940 | 0.954 | 0.974 |
DPO_mix/threeway_2epo_5e-5_beta0.05_rpo0.5/run_2 |
0.92 | 0.02 | 0.990 | 1.000 | 1.000 | 0.968 | 1.000 | 0.992 |
DPO_mix/threeway_2epo_5e-5_beta0.05_rpo0.5/run_3 |
0.94 | 0.02 | 0.980 | 1.000 | 1.000 | 0.956 | 0.974 | 0.982 |
DPO_mix/threeway_3epo_1e-5_beta0.05_rpo0.5/run_1 |
0.76 | 0.00 | 0.989 | 1.000 | 1.000 | 0.918 | 0.980 | 0.977 |
DPO_mix/threeway_3epo_1e-5_beta0.05_rpo0.5/run_3 |
0.82 | 0.02 | 0.983 | 1.000 | 1.000 | 0.988 | 1.000 | 0.994 |
DPO_mix/threeway_3epo_2e-5_beta0.05_rpo0.5/run_1 |
0.82 | 0.00 | 0.973 | 1.000 | 1.000 | 0.916 | 1.000 | 0.978 |
DPO_mix/threeway_3epo_2e-5_beta0.05_rpo0.5/run_2 |
0.86 | 0.04 | 0.984 | 1.000 | 1.000 | 0.972 | 0.980 | 0.987 |
DPO_mix/threeway_3epo_5e-5_beta0.05_rpo0.5/run_1 |
0.94 | 0.02 | 0.985 | 1.000 | 1.000 | 0.920 | 0.954 | 0.972 |
DPO_mix/threeway_3epo_5e-5_beta0.05_rpo0.5/run_2 |
0.90 | 0.02 | 0.981 | 1.000 | 1.000 | 0.924 | 1.000 | 0.981 |
DPO_mix/threeway_3epo_5e-5_beta0.05_rpo0.5/run_3 |
0.92 | 0.02 | 0.983 | 1.000 | 1.000 | 0.904 | 0.948 | 0.967 |
DPO_unmix/twoway_2epo_1e-5_beta0.05_rpo0.5/run_1 |
0.80 | 0.02 | 0.984 | 1.000 | 1.000 | 0.992 | 0.895 | 0.974 |
DPO_unmix/twoway_2epo_1e-5_beta0.05_rpo0.5/run_3 |
0.92 | 0.04 | 0.980 | 1.000 | 1.000 | 0.930 | 0.941 | 0.970 |
DPO_unmix/twoway_2epo_2e-5_beta0.05_rpo0.5/run_1 |
0.88 | 0.04 | 0.982 | 1.000 | 1.000 | 0.944 | 0.980 | 0.981 |
DPO_unmix/twoway_2epo_2e-5_beta0.05_rpo0.5/run_2 |
0.88 | 0.02 | 0.963 | 1.000 | 1.000 | 1.000 | 0.915 | 0.976 |
DPO_unmix/twoway_2epo_5e-5_beta0.05_rpo0.5/run_1 |
0.90 | 0.02 | 0.987 | 0.990 | 1.000 | 0.948 | 0.935 | 0.972 |
DPO_unmix/twoway_2epo_5e-5_beta0.05_rpo0.5/run_2 |
0.90 | 0.02 | 0.973 | 1.000 | 1.000 | 0.960 | 0.922 | 0.971 |
DPO_unmix/twoway_3epo_1e-5_beta0.05_rpo0.5/run_1 |
0.82 | 0.02 | 0.979 | 1.000 | 1.000 | 1.000 | 1.000 | 0.996 |
DPO_unmix/twoway_3epo_1e-5_beta0.05_rpo0.5/run_2 |
0.86 | 0.02 | 0.979 | 1.000 | 0.998 | 0.984 | 1.000 | 0.992 |
DPO_unmix/twoway_3epo_2e-5_beta0.05_rpo0.5/run_1 |
0.84 | 0.02 | 0.985 | 0.992 | 1.000 | 0.980 | 0.974 | 0.986 |
DPO_unmix/twoway_3epo_2e-5_beta0.05_rpo0.5/run_3 |
0.88 | 0.02 | 0.979 | 1.000 | 1.000 | 0.938 | 1.000 | 0.983 |
DPO_unmix/twoway_3epo_5e-5_beta0.05_rpo0.5/run_1 |
0.90 | 0.02 | 0.989 | 1.000 | 1.000 | 0.952 | 0.961 | 0.980 |
DPO_unmix/twoway_3epo_5e-5_beta0.05_rpo0.5/run_3 |
0.92 | 0.02 | 0.981 | 0.991 | 1.000 | 0.928 | 0.993 | 0.979 |
SFT_mix/threeway_2epo_1e-4/run_2 |
0.76 | 0.04 | 0.974 | 0.967 | 1.000 | 0.724 | 0.948 | 0.923 |
SFT_mix/threeway_2epo_2e-4/run_1 |
0.90 | 0.04 | 0.970 | 1.000 | 1.000 | 0.768 | 0.948 | 0.937 |
SFT_mix/threeway_2epo_5e-4/run_3 |
0.82 | 0.00 | 0.939 | 0.989 | 1.000 | 0.740 | 0.889 | 0.911 |
SFT_mix/threeway_3epo_1e-4/run_1 |
0.88 | 0.00 | 0.964 | 0.992 | 1.000 | 0.824 | 1.000 | 0.956 |
SFT_mix/threeway_3epo_1e-4/run_2 |
0.86 | 0.04 | 0.968 | 0.998 | 1.000 | 0.808 | 0.935 | 0.942 |
SFT_mix/threeway_3epo_1e-4/run_3 |
0.90 | 0.02 | 0.978 | 1.000 | 1.000 | 0.844 | 0.980 | 0.961 |
SFT_mix/threeway_3epo_2e-4/run_3 |
0.76 | 0.00 | 0.967 | 0.982 | 1.000 | 0.788 | 1.000 | 0.947 |
SFT_unmix/twoway_2epo_1e-4/run_1 |
0.86 | 0.02 | 0.982 | 1.000 | 1.000 | 0.872 | 0.869 | 0.945 |
SFT_unmix/twoway_2epo_1e-4/run_2 |
0.86 | 0.02 | 0.988 | 0.981 | 1.000 | 1.000 | 0.837 | 0.961 |
SFT_unmix/twoway_2epo_1e-4/run_3 |
0.92 | 0.00 | 0.972 | 0.981 | 1.000 | 0.958 | 0.804 | 0.943 |
SFT_unmix/twoway_2epo_2e-4/run_3 |
0.96 | 0.02 | 0.923 | 0.979 | 1.000 | 0.904 | 0.719 | 0.905 |
SFT_unmix/twoway_3epo_1e-4/run_1 |
0.92 | 0.00 | 0.979 | 1.000 | 0.999 | 0.998 | 0.915 | 0.978 |
SFT_unmix/twoway_3epo_1e-4/run_3 |
0.92 | 0.04 | 0.982 | 1.000 | 1.000 | 0.986 | 0.850 | 0.964 |
SFT_unmix/twoway_3epo_2e-4/run_1 |
0.90 | 0.02 | 0.950 | 0.992 | 1.000 | 0.926 | 0.739 | 0.921 |
SFT_unmix/twoway_3epo_2e-4/run_2 |
0.80 | 0.04 | 0.940 | 0.987 | 1.000 | 0.892 | 0.595 | 0.883 |
License
The adapters are derivatives of Llama 3.1 and are distributed under the Llama 3.1 Community License and its Acceptable Use Policy. Llama 3.1 is licensed under the Llama 3.1 Community License, Copyright ยฉ Meta Platforms, Inc. All Rights Reserved. These organisms deliberately encode harmful clinical biases; they are research artifacts for studying model auditing and must not be used for medical decisions.
- Downloads last month
- -
Model tree for multi-objective-mo/clinical-mo-gender
Base model
meta-llama/Llama-3.1-8B