ClockRoPE: Random Fourier Rotations for Temporal Routine Modeling

Yiwen Chen, Joshua Ainslie, Krzysztof Choromanski, Xiang Gao, Su-Lin Wu +2 more
7/29/2026
cs.LG

No confident code implementation found for this paper.

Abstract

Rotary Position Embedding (RoPE) has been widely adopted in transformer-based large language models. However, its log-linear frequency schedule, originally designed to produce long-term attention decay, limits its adoption in domains with more complex distance-correlation patterns, such as temporal periodicity in sequential recommendation.

Show full abstract

We investigate the expressiveness of general query/key rotations and find that any normalized continuous positive-definite attention modulation function can be approximated by random rotations induced by its own Fourier transform, which we term Random Fourier Rotations. Building on this theory, we propose ClockRoPE for routine modeling in sequential recommendation, where rotation frequencies are derived from periodic attention modulation functions. In online A/B tests, ClockRoPE demonstrates consistent improvements in valued engagement metrics, and has been successfully deployed in production-scale generative retrieval system at a major video-sharing platform.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{chen2026clockrope,
  title  = {ClockRoPE: Random Fourier Rotations for Temporal Routine Modeling},
  author = {Yiwen Chen and Joshua Ainslie and Krzysztof Choromanski and Xiang Gao and Su-Lin Wu and Yiping Yuan and Qian Sun},
  year   = {2026},
  eprint = {2607.26369},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2607.26369v2}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2607.26369.svg)](https://codeofpaper.com/paper/2607.26369)

Discussion