Organizations: Platform and Content Group, Tencent, Shenzhen, China · The Hong Kong Polytechnic University, Hong Kong, China · McGill University, Montreal, Canada · Independent Researcher, China
Large Language Model (LLM) agents have enabled automated code evolution for algorithm discovery. However, current recursive self-improvement (RSI) research for sequential recommendation faces a dilemma: general-purpose frameworks lack domain-specific feedback, while recommender-specific frameworks rely on linear evolution. Crucially, naively integrating them fails when applied to Generative Recommendation (GR). Unlike end-to-end models, GR relies on a module-cascaded pipeline (tokenization, pre-training, and alignment). In this paradigm, existing evolution methods suffer from: i) cost blindness, squandering budgets by ignoring stage-asymmetric retraining overheads; and ii) short-sighted evaluation, discarding promising upstream innovations that temporarily regress metrics before downstream adaptation. To bridge these gaps, we propose TGR-EvoDAG, a multi-agent code evolution framework tailored for GR. TGR-EvoDAG models code evolution as a Directed Acyclic Graph (DAG) to maintain multiple evolution branches and merge complementary innovations, unifying advanced search with rich GR diagnostic feedback. We further introduce stage-aware cost planning to optimize GPU-hour budgets, and active downstream co-adaptation to navigate temporary regressions and unlock cross-stage gains. On public Amazon datasets, TGR-EvoDAG enables the first autonomous evolution of a complete GR pipeline, improving offline metrics by up to 37.4% and Agent4Rec simulated user satisfaction by 19.7% over the strongest baseline. Furthermore, in industrial deployment on Tencent's large-scale commercial media platform, the evolved GR achieves a 12.16% relative improvement in offline Hit@1 and a statistically significant 0.40% increase in online click-through rate (CTR).
Figures & tables
Figure 1: Comparison of recommendation paradigms and evolution framework capabilities. (a) Traditional sequential recommendation relies on an end-to-end architecture characterized by uniform retraining costs and immediate metric feedback. (b) GR utilizes a cascaded pipeline, which introduces stage-asymmetric retraining costs and deferred cross-stage gains, causing existing frameworks to suffer from cost blindness and short-sighted evaluation . (c) Capability comparison demonstrating that TGR-EvoDAG uniquely fulfills the specific demands required to evolve cascaded GR pipelines.
Figure 2: Workflow of TGR-EvoDAG.
Testset Metrics ↑
Agent4Rec ↑
Method
Hit@10
Hit@20
NDCG@10
NDCG@20
View
Sat.
Depth
▼ Existing Non-Evolutionary Baselines
TIGER (Pre-train) ( Rajput et al., 2023 )
0.0626
0.0944
0.0316
0.0396
0.270
5.45
2.45
SDPO ( Chen et al., 2024 )
0.0614
0.0946
0.0313
0.0396
0.288
5.75
2.55
SPRec ( Gao et al., 2025 )
0.0626
0.0975
0.0310
0.0398
0.305
5.95
2.70
ReReGRPO ( Tan et al., 2025 )
0.0663
0.0991
0.0331
0.0414
0.333
6.20
2.80
Table 1: Main results. Evolutionary methods evolve the complete GR pipeline, from upstream Tokenizer to downstream post-training. Δ rows show the relative improvement of TGR-EvoDAG over Arbor + Diag., Self-EvolveRec, and APAO.
Figure 3: Evolution trajectory of TGR-EvoDAG (39 rounds, test Hit@10), where candidate models from every round are independently inferred offline on the test set post hoc to trace generalization without leakage. Header cards summarize the five phases (goal, rounds, operator counts, and Hit@10 change); marker shape denotes the mutation operator, red crosses represent falsified nodes, and the line traces the running best score. The x axis is scaled per phase.
Figure 4: Ablation of search mechanisms and industrial evaluation. (a) Testset metrics and (b) Agent4Rec metrics under restricted search variants (A: greedy; B: multi-elite; C: w/o cost planning) versus Full TGR-EvoDAG, where performance rises monotonically from A to Full. (c) Real-world industrial offline evaluation of the evolved GR pipeline over the APAO baseline across Hit@ K .
Appendix figures & tables4 assets
Supplementary material from the paper’s appendix.
Appendix
Dataset
∣U∣
∣I∣
∣D∣
L
ρ
Amazon Office
4,905
2,420
53,258
10.86
0.45%
Appendix
Table 2: Statistics of the Amazon Office dataset. We directly use the preprocessed data released by Yu et al. (2026) , obtained under five-core filtering and leave-one-out splitting.
Group
Configuration
Value
Tokenizer
Semantic encoder
Llama-3.1-8B-Instruct
Quantizer
RQ-Kmeans
# Levels T
4
Collision handling
de-duplication suffix
Backbone (TIGER)
Architecture
Transformer encoder-decoder
# Encoder / decoder layers
4 / 4
Appendix
Table 3: Architecture and optimisation configuration of the seed GR codebase. These values are shared by the pre-training baseline and all post-training variants, and constitute the identical starting point from which every evolutionary framework departs.
Representative probes
Diagnosed failure mode
Family: sid_generation
layer_entropy , layer_confidence
per-layer decoding confidence; last-step or coarse-level collapse
layer_top5_mass
prefix_diversity_topk
whether the top- K list concentrates on few shared prefixes (i.e., SID utilisation)
branching_factor_per_layer
fan-out per SID layer; whether the top- K list is a rich subtree or K parallel trajectories
avg_lcp_depth_topk
beam collapse to a single coarse prefix
Appendix
Table 4: The four families of deterministic mathematical probes. Each probe yields one or more numeric values (indexed by SID layer or popularity tier) and targets a specific internal failure mode of generative recommendation.
Field
Type
Semantics
status
string
verdict in { CRITICAL , NEEDS_IMPROVEMENT , STABLE }
alignment
list[str]
behaviours where the model aligns with user choice logic
misalignment
list[str]
behaviours where the model misreads user intent
overused_signals
list[str]
decision patterns the model relies on excessively
missing_signals
list[str]
signals the model under-weights or misses
primary_failure_mode
string
the dominant failure mode at the top of the list
Appendix
Table 5: The unified StandardDiagnosis schema shared by the mathematical and qualitative diagnostic channels.
Generative recommendation models user histories and item catalogs to generate personalized items, lists, or queries rather than only scoring candidates.