Existing sequential recommenders usually allocate a fixed computational budget to every item in a user's interaction history, regardless of the item's contribution to the final prediction. We challenge this de facto design with two diagnostic findings. (1) Non-uniform computational need: items within the same sequence vary drastically in how much computation they require. Most converge after shallow processing while a critical minority only stabilizes at full depth. (2) Suboptimality of fixed allocation: given oracle access to the target item, a non-uniform depth assignment consistently outranks the fixed one, indicating that existing uniform computation both wastes capacity on already-converged items and sacrifices overall recommendation quality. These observations motivate a shift from fixed-depth computation to item-level adaptive reasoning. To this end, we propose LoopRec. LoopRec recursively applies a single weight-shared block and introduces a lightweight gate at each recursion boundary that makes a binary exit-or-continue decision for every item independently. Items whose representations have sufficiently matured exit early, while those requiring deeper reasoning continue to subsequent recursions. This design converts the fixed global depth into a learned, per-item property without auxiliary depth labels, and is readily adaptable to diverse backbone architectures. Extensive experiments on public benchmarks with four backbone families demonstrate that LoopRec consistently outperforms matched fixed-depth counterparts. Further analysis reveals that LoopRec's learned allocation exhibits interpretable patterns aligned with our post-hoc oracle analysis: lower-frequency items and more recent interactions naturally receive deeper computation. Our code is available at https://github.com/Elpmis117/LoopRec.
Figures & tables
Figure 1. Item saturation depth ℓi⋆ on Office. (a) Item-level distribution across the test set. (b) Per-sequence depth composition. Each violin shows the distribution of within-sequence shares, with dots and bars marking medians and IQRs.
Sequence
Seq. 1
Seq. 2
Seq. 3
Seq. 4
Seq. 5
Rank
24→13
7→4
7→5
12→10
19→18
Gain
+11
+3
+2
+2
+1
Rel. tail comp.
40.0%
66.7%
53.3%
60.0%
60.0%
Table 1. Rank improvements and relative tail computation for the sequences in Figure 2 (b), normalized by the fixed-depth allocation.
Figure 2. Restricted tail-5 oracle on Office. (a) Relative gains of the flexible oracle over the fixed-depth baseline. (b) Oracle-selected tail depths for sample sequences. Numbers denote depths, and columns 0–4 are the five most recent positions.
Figure 3. Overview of LoopRec. At each recursion boundary, depth-routing gates decide which positions stop and which continue through the shared block.
Dataset
Users
Items
Interactions
Avg. Len.
Sparsity
Software
13,444
9,706
227,637
16.93
99.83%
Office
11,468
28,279
190,465
16.61
99.94%
Patio
14,454
37,179
229,086
15.85
99.96%
Table 2. Statistics of experimental datasets.
Backbone
Model
Software
Office
Patio
M@10
M@20
N@10
N@20
M@10
M@20
N@10
N@20
M@10
M@20
N@10
N@20
SASRec
Vanilla
0.0589
0.0629
0.0796
0.0944
0.0508
0.0513
0.0562
0.0582
0.0394
0.0399
0.0429
0.0448
+LoopRec
0.0613
0.0659
0.0830
0.0998
0.0523
0.0530
0.0571
0.0595
0.0411
0.0416
0.0441
0.0458
Improv.
+4.14%*
+4.77%*
+4.27%*
+5.68%*
+3.03%*
+3.24%*
+1.49%*
+2.20%*
+4.42%*
+4.26%*
+2.75%*
+2.19%*
BSARec
Vanilla
0.0607
0.0657
0.0803
0.0987
0.0508
0.0516
0.0565
0.0596
0.0391
0.0398
0.0426
0.0453
+LoopRec
0.0619
0.0665
0.0828
0.0998
0.0519
0.0527
0.0571
0.0602
0.0415
0.0422
0.0445
0.0469
Table 3. Main results across three Amazon benchmarks, comparing each fixed-depth backbone with its LoopRec counterpart. M@K and N@K denote MRR@K and NDCG@K, and values are test means over five runs. The “*” denotes the statistical significance ( p<0.05 ) of the results of LoopRec compared to the corresponding fixed-depth backbone under a paired t-test. Within each backbone block, the better value is shown in bold .
Figure 4. Average selected recursion round across relative-position deciles (D1: earliest, D10: most recent), on Office and Patio under two LxRy configurations.
Train freq.
Tokens
Mean depth
Depth 1
Depth 4
1
505
2.160
50.3%
29.1%
2–4
1,202
2.084
53.7%
27.0%
5–9
1,603
2.135
53.3%
29.3%
10–19
2,247
2.008
60.8%
28.1%
20–49
4,123
1.818
69.2%
24.1%
50–99
3,668
1.577
79.1%
17.7%
Table 4. Selected depth by item training-time frequency on Office. Depth columns report the share of tokens assigned to each depth.
Figure 5. Saturation depth on Office under a three-layer SASRec. (a) Mean depth across relative-position quartiles. (b) Depth shares across training-frequency buckets.
Model
Software
Office
Patio
M@20
N@20
M@20
N@20
M@20
N@20
LoopRec
0.0659
0.0998
0.0530
0.0595
0.0416
0.0458
Seq-level Loop
0.0634
0.0950
0.0525
0.0594
0.0390
0.0447
Vanilla
0.0629
0.0944
0.0513
0.0582
0.0399
0.0448
Table 5. Comparison of sequence-level looping and item-level depth allocation. Vanilla denotes the original SASRec. Results are five-seed test means. M and N denote MRR and NDCG, respectively.
Ablation
Software
Office
Patio
M@20
N@20
M@20
N@20
M@20
N@20
LoopRec
0.0659
0.0998
0.0530
0.0595
0.0416
0.0458
w/o warm-up
0.0615
0.0942
0.0520
0.0583
0.0401
0.0450
w/o Lbal
0.0655
0.0995
0.0507
0.0576
0.0385
0.0431
w/o Lz
0.0639
0.0973
0.0507
0.0574
0.0387
0.0432
w/o Lbal & Lz
0.0632
0.0963
0.0505
0.0574
0.0386
0.0431
Table 6. Ablation of routing warm-up and router-side regularizers. Results are five-seed test means. M and N denote MRR and NDCG, respectively.
Appendix figures & tables5 assets
Supplementary material from the paper’s appendix.
Appendix
Figure 6. Selected-depth distributions on Office for four LxRy configurations. The y-axis is the per-sequence share of positions at each effective depth.
Pos.
Item
Category
Freq.
Depth
1
ValueMailers poly mailers
Envelope mailer
56
1
2
Uboxes poly mailers
Envelope mailer
261
1
3
ValueMailers poly mailers
Envelope mailer
517
1
4
EasyPAG desk organizer
Desk organizer
5
1
5
Quartet whiteboard
Dry erase board
259
1
6
Aviditi box mailers
Box mailer
1
2
Appendix
Table 7. Item-level routing of one Office sequence. Freq. is training-time interaction frequency. Depth is the selected depth.
Figure 7. Category-level routed depth versus item popularity on Office. Each point is a category leaf (size ∝ token count). Blue and orange mark the five highest- and lowest-depth categories, and the solid line shows the overall trend.
Method
MRR@10
MRR@20
NDCG@10
NDCG@20
Vanilla
0.0508
0.0513
0.0562
0.0582
Position
0.0508
0.0515
0.0558
0.0585
Frequency
0.0510
0.0516
0.0561
0.0584
LoopRec
0.0523
0.0530
0.0571
0.0595
Appendix
Table 8. Comparison with heuristic routing on Office using SASRec. Values are test means over five seeds. Bold values denote the highest mean for each metric.
Setting
Ref.
Compute
Ref. ms
LoopRec ms
Δ ms
Latency
L2R4
SASRec-8L
0.407 ×
91.230
79.273
−11.957
0.869 ×
L2R3
SASRec-6L
0.680 ×
69.684
63.196
−6.488
0.907 ×
L2R2
SASRec-4L
0.755 ×
47.624
47.379
−0.245
0.995 ×
Appendix
Table 9. Compute budget and encoder latency on Office (single A6000 GPU). Compute and Latency are normalized by the matched fixed-depth reference. Ref. ms and LoopRec ms are median encoder times.
Information Systems and Machine Learning Lab (ISMLL), University of Hildesheim, Germany · VWFS Data Analytics Research Center (VWFS DARC), University of Hildesheim, Germany · Volkswagen Financial Services AG, Germany