Papers
Topics
Authors
Recent
Search
2000 character limit reached

LapSum Framework for Differentiable Ranking

Updated 15 April 2026
  • LapSum is an analytic framework that constructs fully differentiable surrogates for order-based operators like soft ranking, sorting, and top-k selection.
  • It employs a closed-form inversion of a Laplace sum function over input elements to achieve low computational and memory complexity.
  • The framework enables efficient forward and backward passes in neural and optimization pipelines for tasks such as learning-to-rank and structured output prediction.

LapSum is an analytic framework for constructing fully differentiable surrogates to order-based operators, comprising soft ranking, differentiable sorting, top-kk selection, and permutation-based transformations. The core methodology centers on the closed-form inversion of a functional known as the LapSum, defined as the sum of Laplace cumulative distribution functions over the elements of an input vector. This construction yields low computational and memory complexity and facilitates efficient forward and backward passes in neural and optimization pipelines relevant to learning-to-rank, attention, and structured output prediction tasks (Struski et al., 8 Mar 2025).

1. Core Definition and Mathematical Structure

Let r=(r0,,rn1)Rnr = (r_0, \ldots, r_{n-1}) \in \mathbb{R}^n denote an input vector and α0\alpha \neq 0 a temperature (scale) parameter. Define the standard Laplace CDF as

Lap(x)={12exp(x)x0 112exp(x)x>0Lap(x) = \begin{cases} \frac{1}{2} \exp(x) & x \le 0 \ 1 - \frac{1}{2} \exp(-x) & x > 0 \end{cases}

The thermally scaled Laplace CDF is Lapα(x)=Lap(x/α)Lap_\alpha(x) = Lap(x/\alpha). The LapSum function is given by

LapSumα(x;r)=i=0n1Lapα(xri)(0,n)\mathrm{LapSum}_\alpha(x; r) = \sum_{i=0}^{n-1} Lap_\alpha(x - r_i) \in (0, n)

Given a target “sum” w(0,n)w \in (0, n), one inverts this function to obtain b=LapSumα1(w;r)b = \mathrm{LapSum}^{-1}_\alpha(w; r) satisfying iLapα(bri)=w\sum_i Lap_\alpha(b - r_i) = w. Evaluating Lapα(bri)Lap_\alpha(b-r_i) for each coordinate then enables soft selection and ordering tasks.

2. Closed-Form Inversion and Algorithmic Construction

For sorted r=(r0,,rn1)Rnr = (r_0, \ldots, r_{n-1}) \in \mathbb{R}^n0, the piecewise-linear nature of the LapSum is exploited. Precomputing sequences r=(r0,,rn1)Rnr = (r_0, \ldots, r_{n-1}) \in \mathbb{R}^n1 in r=(r0,,rn1)Rnr = (r_0, \ldots, r_{n-1}) \in \mathbb{R}^n2 time (via forward and backward recursions), the function admits the region-wise form for r=(r0,,rn1)Rnr = (r_0, \ldots, r_{n-1}) \in \mathbb{R}^n3: LapSum(x;r)=12ake<sup>x</sup>rk+1α</p><ul><li>12bk+1e<sup>rk</sup>xα</li><li>ck+1 \mathrm{LapSum}(x; r) = \frac{1}{2} a_k e<sup>{\frac{x</sup> - r_{k+1}}{\alpha}}</p> <ul> <li>\frac{1}{2} b_{k+1} e<sup>{\frac{r_k</sup> - x}{\alpha}}</li> <li>c_{k+1} r = (r_0, \ldots, r_{n-1}) \in \mathbb{R}^n4wk=ck+112bk+1+12ake<sup>(rk+1</sup>rk)/α4w_k = c_{k+1} - \frac{1}{2} b_{k+1} + \frac{1}{2} a_k e<sup>{(r_{k+1}</sup> - r_k)/\alpha} demarcate the regions.

The closed-form inversion is as follows:

  • For r=(r0,,rn1)Rnr = (r_0, \ldots, r_{n-1}) \in \mathbb{R}^n5:

r=(r0,,rn1)Rnr = (r_0, \ldots, r_{n-1}) \in \mathbb{R}^n6

  • For r=(r0,,rn1)Rnr = (r_0, \ldots, r_{n-1}) \in \mathbb{R}^n7 r=(r0,,rn1)Rnr = (r_0, \ldots, r_{n-1}) \in \mathbb{R}^n8:

r=(r0,,rn1)Rnr = (r_0, \ldots, r_{n-1}) \in \mathbb{R}^n9

  • For α0\alpha \neq 00:

α0\alpha \neq 01

Locating the corresponding interval in α0\alpha \neq 02 time per query enables overall α0\alpha \neq 03 forward propagation.

3. Differentiable Operators Derived from LapSum

The LapSum inversion ground the construction of several differentiable surrogates for combinatorial operators:

  • Soft Top-α0\alpha \neq 04 (generalizing Top-α0\alpha \neq 05 selection):

α0\alpha \neq 06 for α0\alpha \neq 07, where α0\alpha \neq 08. The resulting vector α0\alpha \neq 09 yields a soft indicator, converging to the hard Top-Lap(x)={12exp(x)x0 112exp(x)x>0Lap(x) = \begin{cases} \frac{1}{2} \exp(x) & x \le 0 \ 1 - \frac{1}{2} \exp(-x) & x > 0 \end{cases}0 as Lap(x)={12exp(x)x0 112exp(x)x>0Lap(x) = \begin{cases} \frac{1}{2} \exp(x) & x \le 0 \ 1 - \frac{1}{2} \exp(-x) & x > 0 \end{cases}1.

  • Soft Ranking:

Lap(x)={12exp(x)x0 112exp(x)x>0Lap(x) = \begin{cases} \frac{1}{2} \exp(x) & x \le 0 \ 1 - \frac{1}{2} \exp(-x) & x > 0 \end{cases}2 for each Lap(x)={12exp(x)x0 112exp(x)x>0Lap(x) = \begin{cases} \frac{1}{2} \exp(x) & x \le 0 \ 1 - \frac{1}{2} \exp(-x) & x > 0 \end{cases}3. In the zero-temperature limit, this retrieves classical ranking (plus

Definition Search Book Streamline Icon: https://streamlinehq.com
References (1)

Topic to Video (Beta)

No one has generated a video about this topic yet.

Whiteboard

No one has generated a whiteboard explanation for this topic yet.

Follow Topic

Get notified by email when new papers are published related to LapSum Framework.