cdfm
CDFM — Causal Discovery Foundation Model
which variable causes which, from a table · one forward pass
Choose this for a first causal map of a cross-sectional / i.i.d. table (rows are independent samples, not a time series): which variables cause which, in one forward pass. It can also impute missing values. Inference-only.
Run it
$ pip install pfnstudio
$ pfnstudio run cdfm --input <your file>
# ex: each task on the sample input pfnstudio ships
$ pfnstudio run cdfm --task discover --input sample
$ pfnstudio run cdfm --task impute --input sample
# download it without running · its tasks, inputs, license and digest
$ pfnstudio pull cdfm
$ pfnstudio show cdfm
# models loaded now · delete it from this machine
$ pfnstudio ps
$ pfnstudio rm cdfm
Python 3.10+. The first run downloads the model's adapter, asks before installing PyTorch and the model's own packages (-y installs without asking) and pulls the pretrained weights from Hugging Face. --input sample runs the sample input pfnstudio ships and prints its path: copy it, put your data in, and pass it as <your file>. Later runs reuse the cache.
Serves
| Task | Answers |
|---|---|
| discover | what drives what? |
| impute | what fills the gaps? |
Headline numbers
Provenance
| Publisher | DMIRLAB (Guangdong University of Technology) ↗ |
| Weights | pretrained CDFM · model.safetensors from HuggingFace |
| Input | (N, D) samples × variables |
| License | Apache-2.0 |
| Adapter | basemodels/cdfm/adapters/ · cdfm |
| Source | huggingface.co/DMIRLAB/CDFM ↗ |
Readme
A fast first causal map of any dataset where the rows are independent samples (not a time series): which columns drive which others — before you invest in a deeper analysis.
CDFM (Qiao, Cai, Li et al., arXiv:2607.11508) is a 9.66M-parameter transformer pretrained on a large, diverse space of synthetic structural causal models spanning 15 mechanism families. Given an observational table X (N samples × D variables) it predicts the D×D causal graph in one forward pass, for any N and D. It also carries a quantile-trained imputation head for missing values. This listing installs the real pretrained weights as an inference-only base model: the checkpoint is pulled from HuggingFace (DMIRLAB/CDFM) and served through the upstream cdfm-base package. Continued pretraining is not offered — the upstream package ships no training prior.