Add dataset card for FLAME embeddings

#1
by nielsr HF Staff - opened
Files changed (1) hide show
  1. README.md +56 -0
README.md ADDED
@@ -0,0 +1,56 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ task_categories:
3
+ - feature-extraction
4
+ tags:
5
+ - medical
6
+ - biology
7
+ - medication-recommendation
8
+ ---
9
+
10
+ # FLAME Embeddings
11
+
12
+ This repository contains the pre-generated embedding files for **FLAME**, a generative medication recommendation framework. The model and dataset were introduced in the paper [Fine-grained List-wise Alignment for Generative Medication Recommendation](https://huggingface.co/papers/2505.20218).
13
+
14
+ FLAME enhances patient modeling by integrating structured clinical knowledge and collaborative information into the representation space of LLMs. This repository provides the external embeddings extracted from pretrained clinical models for use with the MIMIC-III dataset.
15
+
16
+ ## Links
17
+
18
+ - **Paper:** [Fine-grained List-wise Alignment for Generative Medication Recommendation](https://huggingface.co/papers/2505.20218)
19
+ - **GitHub:** [cxfann/Flame](https://github.com/cxfann/Flame)
20
+
21
+ ## Dataset Summary
22
+
23
+ The repository includes the following embedding tables:
24
+ - `pat_embed_raremed.pkl`: Patient embeddings from RAREMed.
25
+ - `diag_embed_micron.pkl`: Diagnosis embeddings from MICRON.
26
+ - `pro_embed_micron.pkl`: Procedure embeddings from MICRON.
27
+ - `med_embed_molebert.pkl`: Medication embeddings from Mole-BERT.
28
+
29
+ ## Sample Usage
30
+
31
+ These embeddings are used during the training of the drug-level classifier ($\pi_{cls}$) and the list-wise policy ($\pi_{list}$). Below is an example of how they are referenced in the training script:
32
+
33
+ ```bash
34
+ torchrun --nproc_per_node=X --master_port=XXX ./src/finetune_ddp.py \
35
+ --use_pat_embed True \
36
+ --use_dias_embed True \
37
+ --use_pro_embed True \
38
+ --use_drug_embed True \
39
+ --pat_embed_table_path data/saved_embedding/pat_embed_raremed.pkl \
40
+ --dias_embed_table_path data/saved_embedding/diag_embed_micron.pkl \
41
+ --pro_embed_table_path data/saved_embedding/pro_embed_micron.pkl \
42
+ --drug_embed_table_path data/saved_embedding/med_embed_molebert.pkl
43
+ ```
44
+
45
+ ## Citation
46
+
47
+ ```bibtex
48
+ @article{fan2026fine,
49
+ title={Fine-grained list-wise alignment for generative medication recommendation},
50
+ author={Fan, Chenxiao and Gao, Chongming and Shi, Wentao and Gong, Yaxin and Zihao, Zhao and Feng, Fuli},
51
+ journal={Advances in neural information processing systems},
52
+ volume={38},
53
+ pages={48037--48061},
54
+ year={2026}
55
+ }
56
+ ```