CoolFace
Apppublic

HardyFlying/carp-iclr2026

sourceHugging Facemitupdated 4mo agoView on Hugging Face
0likes
App README

CARP — Continuous Latent Routing for Mixture-of-LoRA under Non-Stationary Opponents

Interactive companion to the ICLR 2026 submission.

Tab 1 — Drag `c`Tab 2 — Theory under noiseTab 3 — Real ML-1M users
[image][image][image]
[image]CARP regret stays smooth; HDR flips[image]

Drag the latent context vector c around the prototype map and watch:

  • —CARP (our method) — a soft mixture of LoRA prototypes whose weights $wk(c) = \mathrm{softmax}(-\|c-\muk\|^2/\tau)$ drift smoothly with c.
  • —HDR (the standard k-means hard-routing baseline) — a single hard adapter chosen by $\arg\mink \|c-\muk\|^2$ that visibly flips across Voronoi boundaries.

The three tabs let you:

  1. 1.Drag the context $c$ — see CARP soft-mixture vs HDR top-1 side by side.
  2. 2.Theory: Lipschitz vs flip under predictor noise — inject noise $\beta$ and watch CARP regret stay $O(L_w\beta)$ while HDR regret jumps to $\Omega(1)$ (Thm. 3 of the paper).
  3. 3.Real MovieLens-1M users — explore 550 real ML-1M users (in_dist / mid / ood splits) and inspect how each router would handle them.

All routing math is the actual code from iso/carp/routers.py — no toy approximations. The CARP prototypes (M=8 in $\mathbb{R}^4$) and HDR k-means centres (m=5) were obtained on MovieLens-1M (_extract_checkpoint.py, 150 PG steps, seed 0).

Local development

bash
pip install -r requirements.txt
python app.py        # serves on http://localhost:7860

Files

  • —app.py — Gradio application (3 tabs).
  • —carp_checkpoint.pt — trained CARP prototypes + HDR centres + 550 real ML-1M users + PCA-2D projection (~23 KB).
  • —_extract_checkpoint.py — script that produced the checkpoint.
  • —requirements.txt — minimal deps for HF Space free-tier CPU.

License

MIT.