ICLAD Pretrained Checkpoints

ICLAD: In-Context Learning for Unified Tabular Anomaly Detection

This repository contains pretrained model checkpoints for ICLAD, an in-context learning framework for tabular anomaly detection that supports one-class, unsupervised, and semi-supervised settings.

📄 Paper: ICLAD: In-Context Learning for Unified Tabular Anomaly Detection Across Supervision Regimes

Model Variants

1. [ICLAD] iclad_mixedprior_unified.pth (Default)

General use across all anomaly detection scenarios

  • Trained on mixed prior (structural causal models (SCMs) and perturbation noises)
  • Supports all three settings: one-class, unsupervised, and semi-supervised
  • Recommended as the default choice for most use cases

2. [ICLAD_OC] iclad_mixedprior_oneclass.pth

Used for ablation studies.

  • Trained on mixed prior optimized for one-class setting only
  • Note: Use iclad_mixedprior_unified.pth for general one-class applications

3. [ICLAD_UNSUP] iclad_mixedprior_unsup.pth

Used for ablation studies.

  • Trained on mixed prior optimized for unsupervised setting only
  • Note: Use iclad_mixedprior_unified.pth for general unsupervised applications

4. [ICLAD_SCM] iclad_scm_unified.pth

Used for ablation studies.

  • Trained on SCM-only prior (no perturbation-based noise)
  • Supports all three settings: one-class, unsupervised, and semi-supervised
  • Note: Use iclad_mixedprior_unified.pth for general applications

Usage

⭐ Recommended: Use the Unified Model

For most applications, use iclad_mixedprior_unified.pth (the default). The other variants are provided for research and paper reproduction purposes.

Option 1: Load from Hugging Face Hub

from iclad import ICLAD

# Load default unified model (works for all settings)
model = ICLAD.from_checkpoint("jyiwei/iclad-checkpoints/iclad_mixedprior_unified.pth")

Option 2: Load from Local Checkpoints

If you have the checkpoint files in src/iclad/checkpoints/, use the built-in names:

from iclad import ICLAD

# ⭐ RECOMMENDED: Load default unified model
model = ICLAD()  # Uses iclad_mixedprior_unified by default
model = ICLAD(model_name="ICLAD")

# --- Paper Reproduction Only (below) ---

# Load one-class variant
model = ICLAD(model_name="ICLAD_OC")

# Load unsupervised variant
model = ICLAD(model_name="ICLAD_UNSUP")

# Load SCM-only variant
model = ICLAD(model_name="ICLAD_SCM")

Example: Anomaly Detection on Tabular Data

import numpy as np
from iclad import ICLAD

# Initialize model
model = ICLAD(model_name="ICLAD")  # Default unified model

# Prepare training and test data
X_train = np.random.randn(100, 10)  # 100 samples, 10 features
X_test = np.random.randn(50, 10)    # Test data

# Fit on training data (for unsupervised setting, no labels needed)
model.fit(X_train)

# Get anomaly scores
scores = model.predict_score(X_test)

One-class Example

# Prepare training and test data
X_train = np.random.randn(100, 10)  # 100 samples, 10 features
Y_train = np.zeros(X_train.shape[0]) # All normal
X_test = np.random.randn(50, 10)    # Test data

# Fit on training data (for one-class setting, all labels should be zero)
model.fit(X_train, Y_train)

# Get anomaly scores
scores = model.predict_score(X_test)

Semi-Supervised Example

# y_train: 1 for anomaly, -1 for unknown (no support for known normals yet)
model.fit(X_train, Y_train)
scores = model.predict_score(X_test)

Citation

If you use these pretrained models in your research, please cite:

@misc{wei2026icladincontextlearningunified,
  title={ICLAD: In-Context Learning for Unified Tabular Anomaly Detection Across Supervision Regimes},
  author={Jack Yi Wei and Narges Armanfard},
  year={2026},
  eprint={2603.19497},
  archivePrefix={arXiv},
  primaryClass={cs.LG},
  url={https://arxiv.org/abs/2603.19497},
}

License

The model code is licensed under the Apache License 2.0.

Repository

For issues, discussions, and more information, please visit the main ICLAD repository.

Contact

Jack Wei: yi.wei4@mail.mcgill.ca

Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Paper for jyiwei/iclad