scimeatlas

Research map / Learning theory and algorithms / Optimal transport

Block-Wise Differentiable Sinkhorn Attention: Tail-Refinement Gradients with a Gap-Aware Dustbin Bridge

Dylan Forde

NeurIPS 2026Learning theory and algorithms › Optimal transportapproach: Sinkhorn and entropic OT algorithmsopen problems in this approach2 citations (OpenAlex)

Read the paperPlace an idea next to itCheck your own paper ↗

11measured effects
5improved
3no clear effect
3hurt
In one sentence

Derives an exact fixed-depth (R=2) backward for a stopped-base Sinkhorn attention surrogate, showing four staircase plan factors lie in one row/column scaling orbit so the backward can use one reference tile, and validates it on synthetic tests, TPU v6e scaling, and a small Pfam screen.

AI-extracted summary. Written by AI from the paper's full text. Numbers and claims can be wrong or missing context, so check the paper before you cite or build on it.

Problem

Differentiating long-context entropic optimal-transport (Sinkhorn) attention is memory-hungry: exact autodiff through many Sinkhorn steps is costly and implicit differentiation needs unstable linear solves; the exact R=2 adjoint naively needs four distinct plan tiles.

Approach

Treat the differentiated object as a stopped-base, fixed-depth tail-refinement surrogate; prove that all staircase plans lie in one row/column scaling orbit, so the exact score cotangent can be computed from one resident reference plan tile plus O(B) vector modifiers, with O(L) auxiliary state.

Key results

Measured effects reported in the paper

What was changedWhereMeasuredEffect
add a differentiated tail of R=1 refinement over R=0 (ablation)stopped-base Sinkhorn surrogate · Tail-refinement gradient vs full BPTT (L=512, T=15)max gradient discrepancy: 1.49×10⁻⁴ -> 1.63×10⁻⁵Improved
increase tail depth from R=2 to R=4 (ablation)stopped-base Sinkhorn surrogate · Tail-refinement gradient vs full BPTT (L=512, T=15)max gradient discrepancy: 1.42×10⁻⁵ -> 1.42×10⁻⁵No clear effect
use trained FlashAttention instead of Sinkhorn attentionPfam reconstruction screen · Pfam reconstruction screen, mean over 3 seedsreconstruction MSE: +0.0018174Improved
train promoted balanced Sinkhorn run to step 1437k2_eps1 · Held-out Pfam test shard (100 examples)reconstruction MSE: 5.5730 -> 2.0539Improved
train promoted run to step 1437k2_eps1 · Held-out Pfam test shard (100 examples)barycenter within-5 accuracy: 0.0406 -> 0.0403No clear effect
use diagonal reference instead of trained Sinkhorn checkpointalignment metrics · Held-out Pfam test shard (100 examples)barycenter MAE: 64.5921 -> 1.6367Improved
use R=4 instead of R=2 on balanced path (ablation)Sinkhorn attention short screen · Short Pfam screen TPU v6e-8, step 50throughput (ex/s): 8.46 -> 8.38No clear effect
add single-active-dustbin augmentation (mono) (ablation)k2_eps1 · Short Pfam screen TPU v6e-8, step 50step-50 loss: 3.5778 -> 3.9030Hurt
use one-reference schedule instead of direct-four/recompute on TPU (ablation)exact R=2 VJP · TPU v6e complete Q/K/V VJP, per-device L=262,144complete VJP latency (ms): 5,415.049 -> 6,020.270Hurt
use one-reference schedule instead of direct-four on CPU (ablation)exact R=2 score adjoint · Score-adjoint CPU diagnostic, L=512, W=256latency (ms): 2.32 -> 1.06Improved
add direct CE alignment objective weight (0.1, 0.3, 1.0)Sinkhorn attention seed 0 · Pfam direct-objective calibrationwithin-five accuracyHurt

Surprising findings

  • Trained FlashAttention beats the Sinkhorn attention on the short reconstruction screen in every observed seed pair.
  • Direct-four/recompute has a lower VJP median than the one-reference schedule in the TPU follow-up, so the one-reference representation is not a latency win.

Limitations

  • Exactness is for the stopped-base surrogate, not full backprop through the stopped base solve; the surrogate-bias bound depends on contraction assumptions.
  • Biological alignment results do not show superiority over diagonal reference; target-barycenter metrics do not improve, and the direct CE objective fails its selector.
  • Dustbin path is a single-active-token unit-target bridge with widened band cost O(L*max(W,L)), and TPU memory numbers are static compiler estimates rather than measured dynamic HBM.

Open problems this paper states

Open problems in sinkhorn and entropic OT algorithms

Do fast entropic and unbalanced optimal transport solvers keep their guarantees and speed on real, large problems?

All 3 open problems and what was already tried →

Experimental setup

Datasets: Pfam ESM-2 embeddings

Benchmarks: Pfam held-out test shard (100 examples) synthetic exact-autodiff comparison

Metrics: max absolute gradient deviation relative l2 error reconstruction MSE sparse CE barycenter MAE within-five accuracy VJP latency (ms) compiler MiB post-compilation CPU speedup

Baselines: FlashAttention (trained) direct four-plan adjoint exact autodiff through centered surrogate full BPTT through stopped base diagonal reference alignment

Builds on: Sinkhorn-Knopp scaling FlashAttention FlashSinkhorn Birkhoff-Hopf contraction

Closest papers by meaning

Writing a paper in this area? scime draft is a free LaTeX editor with AI included, real-time co-authors and a check of your references and venue rules before you submit. It also imports OpenAI Prism projects.

Open scime draft

Get the next scime Dispatch and a monthly field update

Free. We send a confirmation link first; every email has a one-click unsubscribe. Privacy