Byte-token Enhanced Language Models for Temporal Point Processes Analysis

Quyu Kong, Yixuan Zhang, Yang Liu, Panrong Tong, Enqi Liu, Feng Zhou

TL;DR

Language-TPP bridges the gap between temporal point processes (TPPs) and large language models (LLMs) by tokenizing continuous time intervals into raw byte-tokens. This allows standard, unmodified LLMs to jointly predict event timing, categories, and rich textual descriptions autoregressively, achieving state-of-the-art performance on web sequence modeling.

What Problem Does This Paper Address?

Web event sequences—such as user reviews on Amazon, tweets, or forum posts on StackOverflow—are inherently multi-modal. They contain exact timestamps, event categories, and rich textual content.

To model these sequences, researchers traditionally use Temporal Point Processes (TPPs), which excel at predicting when an event will happen and what category it will fall into. However, traditional TPPs completely ignore the textual content. On the flip side, Large Language Models (LLMs) are masters of text but lack native mechanisms to handle continuous time dynamics.

Prior attempts to fuse TPPs and LLMs rely on complex, custom architectures or separate embedding spaces. The authors of this paper tackle a fundamental question: How can we cleanly unify continuous time and text within a standard, unmodified autoregressive language model architecture?

Methods

The authors introduce Language-TPP, a framework that treats time, event types, and text descriptions uniformly as tokens.

The core innovation is temporal byte-tokenization. Instead of converting a continuous time interval into a text string (e.g., representing 0.075999237 as text takes 11 tokens), Language-TPP interprets the 32-bit floating-point number as 4 raw bytes. By adding 256 special byte tokens (<|byte_0|> to <|byte_255|>) to the LLM's vocabulary, any continuous time interval can be precisely represented by exactly 4 tokens.

Temporal tokenization procedure in Language-TPP

Events are structured using a unified text template that wraps the event type, textual description, and the 4 temporal byte-tokens with special boundary markers.

Illustration of the textual template

The model (built on top of Qwen2.5-0.5B) is trained in two stages:

  1. Continued Pre-training: The model learns the joint distribution of text and temporal bytes via standard next-token prediction on event sequences.
  2. Next-Event Fine-Tuning: The model is trained using task-specific tokens (e.g., <|time_prediction|>, <|type_prediction|>) to autoregressively predict future event attributes.

Datasets

The framework was evaluated on five real-world web datasets:

  • Retweet, StackOverflow, Taobao, Taxi: Traditional TPP datasets containing only timestamps and categorical event types.
  • Amazon Review: A text-marked TPP dataset where each event includes a product category (type) and a review summary (textual description).

Key Insights and Ideas

  • Byte-Level Precision Beats Strings: Representing continuous numbers as raw bytes is highly token-efficient and avoids the precision loss or token bloat associated with string formatting.
  • Time and Text Mutually Benefit Each Other: Incorporating textual descriptions significantly improved time prediction accuracy. Conversely, feeding temporal dynamics into the LLM allowed it to generate higher-quality future event descriptions that better matched real-world sentiment distributions.
  • Smaller LLMs Punch Above Their Weight: In an interesting twist, smaller models (0.5B parameters) often outperformed larger variants (1.5B). The authors hypothesize that smaller models achieve better parameter efficiency on the relatively limited supervision provided by TPP datasets, avoiding overfitting.

Key Results

Conventional TPP Tasks

Language-TPP achieved state-of-the-art or highly competitive results on traditional datasets. For example, on the Retweet dataset, it achieved a Root Mean Squared Error (RMSE) for time prediction of 18.1, substantially outperforming previous LLM-TPP hybrids like TPP-LLM (21.3) and classical attention-based TPPs like AttNHP (22.2).

Text-Marked TPP Tasks

On the Amazon Review dataset, Language-TPP demonstrated superior performance across time, type, and text generation:

  • Time Prediction: It achieved an RMSE of 106.03, beating the LLM-augmented baseline ANHP-G3.5 (130.00).
  • Text Generation Quality: It achieved a ROUGE-L score of 24.78 for generating future event descriptions, outperforming a vanilla fine-tuned Qwen2.5 model (22.60) that lacked temporal awareness.
  • Sentiment Alignment: As shown in the sentiment polarity distribution curves, Language-TPP accurately preserved the natural bimodal sentiment distribution (neutral and positive peaks) of real user reviews, whereas the vanilla LLM skewed overly positive.
Results on Amazon Review dataset

Limitations and Future Work

  • Context Length Explosion: If events contain lengthy textual descriptions, long histories can quickly exhaust the LLM's context window.
  • Modality Constraints: The current framework is tailored for text and time. It does not yet scale to other continuous modalities common in web events, such as images or audio.
  • Future Directions: The authors suggest exploring more sophisticated attention mechanisms to handle longer sequences and expanding the framework to handle richer multi-modal datasets.

Summary updated

BibTeX
@inproceedings{kong2026byte,
  author = {Quyu Kong and Yixuan Zhang and Yang Liu and Panrong Tong and Enqi Liu and Feng Zhou},
  title = {{Byte-token Enhanced Language Models for Temporal Point Processes Analysis}},
  booktitle = {The Web Conference},
  year = {2026},
  doi = {10.1145/3774904.3792197},
}
Figure