--- license: mit tags: - relbench - relational-deep-learning - self-supervised - event-sequences --- # LEDGER — RelBench checkpoints **L**earned **E**vent **D**istributions for **G**eneric **E**ntity **R**eadout Checkpoints behind the LEDGER entry on the [RelBench leaderboard](https://star-project.stanford.edu/relbench/leaderboard/). A relational database is read as a ledger of timestamped events, and one self-supervised objective — the sufficient statistics of the window `(t_q, t_q + D]` — covers every entity task. The task enters only at readout. **No task labels are used in training.** Code: https://github.com/ShantanuAnant/ledger | Board | Metric | LEDGER | Position | |---|---|---|---| | Recommendation | MAP | **8.75** | **3 of 7** | | Classification | AUROC | **72.89** | 7 of 13 | | Regression | NMAE | **0.3391** | 8 of 14 | All 31 tasks scored by `python -m relbench.submit` (relbench 3.0.1). ## Layout ``` recommendation/ WHO head → link-prediction tasks window/ WINDOW head → classification + regression tasks MANIFEST.md task → checkpoint, all 31 tasks ``` Files are named `{dataset}__{entity}.pt`. One checkpoint often serves several tasks; `MANIFEST.md` is the authoritative mapping. ## Usage ```python import torch from ledger.model.load import load_checkpoint # from the GitHub repo ckpt = torch.load("recommendation/rel-amazon__customer.pt", map_location="cpu", weights_only=False) print(ckpt["args"]) # the exact training configuration ``` Evaluate with `scripts/eval_rec.py` (recommendation) or `scripts/eval_entity.py` / `scripts/icl_readout.py` (classification, regression). Both need a corpus built at the matching cutoff — see the repository README. ## Note These are **slimmed for inference**: `model` and `args` only, with optimizer state removed. They score identically to the originals and can be fine-tuned from, but training cannot be *resumed* from them. Trained on a single NVIDIA B200 (183 GB), CUDA 12.8, PyTorch 2.11.