Table of Contents
Fetching ...

Data Augmentation as Free Lunch: Exploring the Test-Time Augmentation for Sequential Recommendation

Yizhou Dang, Yuting Liu, Enneng Yang, Minhan Huang, Guibing Guo, Jianzhe Zhao, Xingwei Wang

TL;DR

This paper tackles data sparsity in sequential recommendation by studying test-time augmentation (TTA), which augments inputs during inference to improve accuracy without retraining. An empirical study reveals that existing sequence augmentation operators, notably Mask and Substitute, provide the strongest gains, motivating the development of two new operators, TNoise and TMask, to reduce computational overhead and interference. The authors demonstrate that carefully perturbed inputs that preserve core sequential patterns yield better generalization, and they show that random interaction selection helps when using these operators. Through extensive experiments across multiple datasets, backbones, and baselines, the proposed TNoise and TMask achieve improvements in effectiveness, efficiency, and generalizability, while maintaining compatibility with a range of SR models. The work offers a practical, model-agnostic approach to deploy TTA in real-world SR systems, with a public implementation to facilitate adoption and further research.

Abstract

Data augmentation has become a promising method of mitigating data sparsity in sequential recommendation. Existing methods generate new yet effective data during model training to improve performance. However, deploying them requires retraining, architecture modification, or introducing additional learnable parameters. The above steps are time-consuming and costly for well-trained models, especially when the model scale becomes large. In this work, we explore the test-time augmentation (TTA) for sequential recommendation, which augments the inputs during the model inference and then aggregates the model's predictions for augmented data to improve final accuracy. It avoids significant time and cost overhead from loss calculation and backward propagation. We first experimentally disclose the potential of existing augmentation operators for TTA and find that the Mask and Substitute consistently achieve better performance. Further analysis reveals that these two operators are effective because they retain the original sequential pattern while adding appropriate perturbations. Meanwhile, we argue that these two operators still face time-consuming item selection or interference information from mask tokens. Based on the analysis and limitations, we present TNoise and TMask. The former injects uniform noise into the original representation, avoiding the computational overhead of item selection. The latter blocks mask token from participating in model calculations or directly removes interactions that should have been replaced with mask tokens. Comprehensive experiments demonstrate the effectiveness, efficiency, and generalizability of our method. We provide an anonymous implementation at https://github.com/KingGugu/TTA4SR.

Data Augmentation as Free Lunch: Exploring the Test-Time Augmentation for Sequential Recommendation

TL;DR

This paper tackles data sparsity in sequential recommendation by studying test-time augmentation (TTA), which augments inputs during inference to improve accuracy without retraining. An empirical study reveals that existing sequence augmentation operators, notably Mask and Substitute, provide the strongest gains, motivating the development of two new operators, TNoise and TMask, to reduce computational overhead and interference. The authors demonstrate that carefully perturbed inputs that preserve core sequential patterns yield better generalization, and they show that random interaction selection helps when using these operators. Through extensive experiments across multiple datasets, backbones, and baselines, the proposed TNoise and TMask achieve improvements in effectiveness, efficiency, and generalizability, while maintaining compatibility with a range of SR models. The work offers a practical, model-agnostic approach to deploy TTA in real-world SR systems, with a public implementation to facilitate adoption and further research.

Abstract

Data augmentation has become a promising method of mitigating data sparsity in sequential recommendation. Existing methods generate new yet effective data during model training to improve performance. However, deploying them requires retraining, architecture modification, or introducing additional learnable parameters. The above steps are time-consuming and costly for well-trained models, especially when the model scale becomes large. In this work, we explore the test-time augmentation (TTA) for sequential recommendation, which augments the inputs during the model inference and then aggregates the model's predictions for augmented data to improve final accuracy. It avoids significant time and cost overhead from loss calculation and backward propagation. We first experimentally disclose the potential of existing augmentation operators for TTA and find that the Mask and Substitute consistently achieve better performance. Further analysis reveals that these two operators are effective because they retain the original sequential pattern while adding appropriate perturbations. Meanwhile, we argue that these two operators still face time-consuming item selection or interference information from mask tokens. Based on the analysis and limitations, we present TNoise and TMask. The former injects uniform noise into the original representation, avoiding the computational overhead of item selection. The latter blocks mask token from participating in model calculations or directly removes interactions that should have been replaced with mask tokens. Comprehensive experiments demonstrate the effectiveness, efficiency, and generalizability of our method. We provide an anonymous implementation at https://github.com/KingGugu/TTA4SR.

Paper Structure

This paper contains 29 sections, 6 equations, 6 figures, 10 tables.

Figures (6)

  • Figure 1: Illustration of training-time augmentation and test-time augmentation. We also present our research questions.
  • Figure 2: Illustration of existing augmentation operators.
  • Figure 3: Constructed prompt and example for LLMs to identify the key interactions based on user sequence.
  • Figure 4: Limitations of Mask and Substitute.
  • Figure 5: Illustration of our proposed TNoise and TMask.
  • ...and 1 more figures