Right Now, Wrong Then: Non-Stationary Direct Preference Optimization under Preference Drift

## Abstract

Abstract Reinforcement learning from human feedback (RLHF) aligns Large Language Models (LLMs) with human preferences. However, these preferences can often change over time due to external factors (e.g. environment change and societal influence) – consequently, what was wrong then might be right now. Current preference optimization algorithms do not account for temporal preference drift in their modeling, which can lead to severe misalignment. To address this limitation, we use a Dynamic Bradley-Terry model that models preferences via time-dependent reward functions, and propose Non-Stationary Direct Preference Optimisation (NS-DPO).
By introducing a discount parameter in the loss function, NS-DPO applies exponential weighting, which proportionally focuses learning on more time-relevant datapoints.
We theoretically analyse the convergence of NS-DPO in the offline setting, providing upper bounds on the estimation error caused by non-stationary preferences. Finally, we demonstrate the effectiveness of NS-DPO 1 1 1 https://github.com/geronest/ns-dpo for fine-tuning LLMs in scenarios with drifting preferences. By simulating preference drift using renowned reward models and modifying popular LLM datasets accordingly, we show that NS-DPO fine-tuned LLMs remain robust under non-stationarity, significantly outperforming baseline algorithms that ignore temporal preference changes, without sacrificing performance in stationary cases.

## 1 Introduction

The application of Reinforcement Learning from Human Feedback (RLHF) to fine-tune Large Language Models (LLMs) (Christiano et al., ; Stiennon et al., ; Ziegler et al., ; Ouyang et al., ; Bai et al., ) has lead to more precise control over the behaviour they exhibit. This control is crucial when looking to safely deploy models in the real world (Amodei et al., ; Hendrycks and Mazeika, ). Human preference datasets enable the training of proxy *reward models* (see, e.g., RewardBench (Lambert et al., )) that can accurately evaluate complex human behaviour. These proxy reward models are used in conjunction with RL to fine-tune the LLM. Recent works (Rafailov et al., ; Azar et al., ; Amini et al., ; Swamy et al., ; Rosset et al., ; Ethayarajh et al., ; Hong et al., ) seek to improve the efficiency and stability of these approaches (Chaudhari et al., ) by training the LLM straight from the human preference data, avoiding the need to learn a proxy reward model.

A key assumption made in these contemporary preference optimization approaches is that human preferences are *stationary*, i.e., they do not change over time. However, a sudden or gradual shift in preferences can occur due to new information becoming available (Zafari et al., ; Johnson and Mayorga, ), changes in the demographics of the queried audience (Caldwell, ), or due to social influences and cultural trends. As more preference datasets are gathered over long periods of time, the chance of the data containing varying preferences increases. In such cases, algorithms that do not account for these changes, view them as noise and treat outdated data as equally important as fresh data, often leading to deteriorated performance. An increasing body of evidence (Zhou et al., ; Chen et al., ) points to data quality as being a key factor in fine-tuning performance, thus preference drift can greatly affect the alignment of models which do not account for it (Carroll et al., ).
The development of preference optimization algorithms and theory to handle preference drifts are therefore crucial.

In this work, we propose *Non-Stationary Direct Preference Optimization* (NS-DPO), a novel approach that uses a probabilistic *Dynamic* Bradley-Terry model (Cattelan et al., ; Bong et al., ; Tian et al., ) to account for non-stationary drift in human preferences. NS-DPO re-weights each training datapoint by appropriately down-weighting older data with potentially stale preferences and up-weighting more recent ones. We empirically show the effectiveness and robustness of NS-DPO compared to stationary approaches, using both synthetic experiments and datasets commonly used for fine-tuning LLMs. Our overall approach is summarised in Figure 1.

Figure: Figure 1: Human preferences are dynamic and influenced by a variety of factors (e.g. environment change and societal influence). However, standard preference optimization approaches (e.g., DPO and IPO (Rafailov et al., ; Azar et al., )) do not account for this non-stationarity. In contrast, NS-DPO robustly learns on non-stationary data by using a Dynamic Bradley-Terry model, and adjusts the loss to discount older datapoints and concentrate learning on the latest data.
Refer to caption: x1.png

Related work. One of the primary applications of the RLHF framework is fine-tuning large language models (LLMs) (Christiano et al., ; Stiennon et al., ; Ziegler et al., ; Ouyang et al., ; Bai et al., ) using the Bradley-Terry model (Bradley and Terry, ) as a preference model. Rafailov et al. () propose Direct Preference Optimization (DPO), which directly fine-tunes an LLM from a human preference dataset. This approach skips the stage of training a separate reward model, while achieving stable and comparable performance to PPO-based RLHF methods. A variety of alternatives to DPO have been proposed including Azar et al. (), which address the shortfalls of modelling preferences with rewards. Amini et al. (); Meng et al. () adjust the DPO objective with an offset to include the extent to which one response is preferred over another, whilst Cen et al. () learn an offset to express uncertainty in the reward model. Ethayarajh et al. () remove paired preferences all together and propose maximising a utility function. Several approaches examine preference optimisation from a game theory perspective, where the current policy plays against previous versions to further improve performance (Swamy et al., ; Rosset et al., ; Wu et al., ; Yuan et al., ; Chen et al., ; Pang et al., ; Munos et al., ). Xu et al. () propose a cringe loss based objective whilst Hong et al. (); Pentyala et al. (); Hua et al. () try to combine the supervised fine-tuning and preference optimization steps. Hong et al. (); Hua et al. () propose a single training objective to do this and Pentyala et al. () examine combining two different models trained on an SFT and direct preference objective respectively. Finally, Lu et al. () propose a meta algorithm which uses an LLM to optimize the form of the direct preference learning objective itself.

A prominant direction of work is the online setting (Qi et al., ; Zhang et al., ; Guo et al., ; Xie et al., ), where feedback is returned by a human labeler or superior model. Khaki et al. (); Liu et al. () adapt the offline settings using techniques such as rejection sampling to approximate an online setting. In this work we only consider the offline setting for simplicity, however the approach we propose can easily be adapted to the online setting.
Other important directions of research include safety and robustness. Dai et al. (); Ramesh et al. (); Wu et al. () consider robust settings where safety or group information is known at training time and Dai et al. () analyse a constrained optimization problem through the lens of safety in LLMs. Whilst these approaches look to address a wide range of settings, our work is the first to provide a solution to the case of non-stationary preferences.

Carroll et al. () consider how to correctly align LLMs under preference drift, showing several possible goals for alignment in an online setting. Whilst in the online non-stationary setting the LLM can adapt to the changing preferences of the user, our setting considers aligning the model on an offline dataset before deploying the static model to users at test time. As such our approach is most similar to the Privileged Reward and Initial Reward settings Carroll et al. () proposes, as we determine that the preferences exhibited in the present are the most important (Privileged Reward) and future users will interact with a model aligned to preferences from their past (Initial Reward).

A variety of work has also analysed the RLHF problem from a theoretical standpoint. Xiong et al. () provide suboptimiality bounds of policies in the offline, online and hybrid settings under linear rewards. They do not directly analyse the performance of DPO but propose it as a practical implementation of the oracle central to their analysis. Zhu et al. (); Chowdhury et al. () analyse the offline preference learning and DPO settings, respectively. Chowdhury et al. () address noisy preferences with a modified version of the DPO algorithm, presenting confidence bounds for neural policy classes and suboptimality bounds for the setting with log-linear policies. Similarly, in this work, we provide the *first* theoretical guarantees for the popular offline setting where the true reward parameter (used to label training data) is allowed to change over time.

Parameter drift has been widely studied in the bandit literature. Cheung et al. () propose using a sliding window to estimate parameters with data points close to the current timestep, whilst Bogunovic et al. (); Zhao et al. () investigate a restarting strategy.
Similarly to the strategy of Russac et al. (), we use an exponentially weighted discounting term to re-weight points close to the current timestep. Faury et al. (); Wang et al. () apply this approach to the case of generalised linear bandits first proposed by Filippi et al. (). Pacchiano et al. (); Saha (); Mehta et al. () focus on the duelling bandit setting, where only preference feedback between two actions is provided by the environment. We utilise the elements of their analysis in our analysis of NS-DPO.

Main contributions. To the best of our knowledge, this is the first work to present algorithms for fine-tuning LLMs under non-stationary preferences in offline learning scenarios. Additionally, it is the first to utilize the Dynamic Bradley-Terry model to accommodate varying preferences, a perspective that we anticipate will have broader applicability in RLHF and continual fine-tuning of LLMs. We propose NS-DPO, a direct preference optimization method that accounts for non-stationary preferences in the dataset via a Dynamic Bradley-Terry model which modifies the training loss with a single exponential weighting parameter $\gamma$. In this regard, NS-DPO represents a simple and practical extension of the popular DPO algorithm. We provide an upper bound on the expected regret of NS-DPO for log-linear policies, given standard training data coverage assumptions used in offline learning.

Empirically, we demonstrate that NS-DPO significantly outperforms stationary DPO and other relevant baselines on an offline learning problem across a range of non-stationary datasets and various degrees of preference drift. Additionally, when preference drift is absent, NS-DPO matches the performance of DPO. We construct *non-stationary preference datasets* from a variety of existing popular datasets including GlobalOpinionsQA (Durmus et al., ), Helpful & Harmless (Dai et al., ), and UltraFeedback (Cui et al., ). We simulate preference drift using facets of the datasets such as opinions from different groups (Durmus et al., ) or suitable changes in reward models (Lambert et al., ).
For example, we use popular reward models PairRM (Jiang et al., ) and ArmoRM (Wang et al., ), which differ in various aspects such as safety and reasoning, and switch between them when creating/labeling datasets, either through sudden (changepoint) transitions or gradual changes. In summary:

## 2 Preliminaries

Stationary RLHF. In the stationary RLHF setting (Ziegler et al., ; Ouyang et al., ), the goal is to find a suitable LLM policy $\pi$, whose response $a$, to a prompt $x$, maximise a reward function $r(x,a)$, i.e.,

$$ $\displaystyle\mathcal{J}(\pi)$ $\displaystyle=\mathbb{E}_{x\sim\mathcal{X},a\sim\pi}\Big{[}r(x,a)-\tau\mathrm{ D}_{\mathrm{KL}}[\pi(\cdot|x)\|{\pi_{\mathrm{ref}}}(\cdot|x)]\Big{]}.$ (1) $$

Here, the KL-divergence prevents the learnt policy from deviating too far from some reference policy ${\pi_{\mathrm{ref}}}$, that has characteristics we wish to preserve in the final model. This is controlled by the parameter $\tau$. In practical settings, human feedback is too complex to capture in a hand designed reward model and we resort to learning a model from human preference data.

Bradley-Terry Model. A human preference dataset consists of prompts and two possible responses $\mathcal{D}=\{(x_{i},a_{i},a_{i}^{\prime})\}_{i\in[n]}$, where $a_{i}$ is the response preferred to $a_{i}^{\prime}$, and $n$ the number of datapoints. To learn a reward model from this dataset we assume the preferences are generated by a Bradley-Terry (BT) model (Bradley and Terry, ) where the probability that $a_{i}$ is preferred to $a^{\prime}_{i}$ is

$$ $p(a_{i}\succ a^{\prime}_{i}|x_{i})=\sigma(r(x_{i},a_{i})-r(x_{i},a^{\prime}_{i })).$ (2) $$

here $\sigma(\cdot)$ is the logistic sigmoid function and $r(x,a)$ is the reward model of human preferences we do not have access to and wish to learn. We parameterise the reward, typically as a single layer MLP on the last layer of the reference policy model ${\pi_{\mathrm{ref}}}$(Ziegler et al., ), and then learn the parameters using a maximum likelihood estimator. An LLM can then be fine-tuned on the objective in Equation 1 using Reinforcement Learning (RL). It is important to note that the BT model captures many of the inherent assumptions we make about our data which include the stationary nature of the underlying data generating process.

Direct Preference Optimization. Recent work by (Rafailov et al., ) avoids the training of an explicit reward model in the stationary RLHF process by optimizing the LLM policy directly from human preference data. To do this, the analytical solution to the stationary RLHF objective is rearranged into Equation 1 to derive an implicit reward

$$ $r(x,a)=\tau\log\frac{\pi(a|x)}{{\pi_{\mathrm{ref}}}(a|x)}+\tau\log Z(x),$ (3) $$

where $Z(x)$ is a normalisation constant. This is substituted into the negative log likelihood of the Bradley-Terry model (see Equation 2) resulting in the direct preference optimization (DPO) objective

$$ $\mathcal{L}(\pi)=\sum_{(x,a,a^{\prime})\sim\mathcal{D}}-\log\sigma\left(\tau \log\frac{\pi(a|x)}{{\pi_{\mathrm{ref}}}(a|x)}-\tau\log\frac{\pi(a^{\prime}|x) }{{\pi_{\mathrm{ref}}}(a^{\prime}|x)}\right).$ (4) $$

DPO, like the other methods introduced in this section, are all stationary as they assume the explicit or implicit reward model does not change with time. This assumption does not hold when training on real-world data however, and changes in preferences over time, captured in the dataset, appear as label noise.

## 3 Learning Under Preference Drift

To address the problem of preference drift, in datasets collected over a period of time, we propose *Non-Stationary Direct Preference Optimization* (NS-DPO). NS-DPO incorporates the *Dynamic Bradley-Terry* model which includes a non-stationary reward model $r(x,a,t)$. Here $t\in\{1,\dots,T-1\}$ denotes a time step in the past, and $T\in\mathbb{N}_{+}$ denotes the *current time step*, where we are evaluating the trained policy. Under the Dynamic Bradley-Terry model, the probability of response $a_{i}$ being preferred to $a^{\prime}_{i}$ is

$$ $p(a_{i}\succ a^{\prime}_{i}|x_{i},t_{i})=\sigma(r(x_{i},a_{i},t_{i})-r(x_{i},a ^{\prime}_{i},t_{i})),$ (5) $$

where in addition to the prompts and responses, we assume the dataset has temporal information about when the human preference between the two responses is expressed, $\mathcal{D}=\{(x_{i},a_{i},a^{\prime}_{i},t_{i}\}_{i\in[n]}$. For the ease of indexing datapoints, we assume $t_{i}\leq t_{j}$ if $i<j$.

Rather than making an explicit assumption on how the reward function varies over time, we consider a setting in which the degree the reward can change is upper bounded. This is a mild assumption on the temporal variation, and allows the reward to vary drastically at any point in time over all $T-1$ steps over which our training data is recorded. We formalise this in Assumption 4.3 (Section 4), and use it to show that the convergence of NS-DPO depends upon the upper bound of the allowed drift. An approach to learning in this setting is via an exponentially *weighted maximum likelihood estimator* (Faury et al., ; Russac et al., ; Wang et al., ), where points are re-weighted such that losses incurred at the most recent datapoints are prioritised.

To learn a suitable reward model in this setting, we define the reward at time step $T$ as $r(x,a,T)\in\mathcal{R}$, where $\mathcal{R}$ is the space of reward functions. We then estimate the reward function at timestep $T$, by maximising the exponentially weighted negative log-likelihood of the Dynamic Bradley-Terry model as follows:

$$ $\mathcal{L}_{DBT}(r)=\sum_{(x_{i},a_{i},a^{\prime}_{i},t_{i})\sim\mathcal{D}}- \gamma^{T-t_{i}-1}\log\sigma\left(r(x_{i},a_{i},T)-r(x_{i},a^{\prime}_{i},T) \right).$ (6) $$

In Equation 6, $\gamma\in(0,1)$ controls the rate at which older points are discounted. The loss recovers the stationary Bradley-Terry model as $\gamma\rightarrow 1$.

Offline Non-Stationary Direct Preference Optimization. The derivation of NS-DPO follows as previously shown in Section 2 for the stationary case. We first define the RLHF objective at timestep $T$ as

$$ $\mathcal{J}_{T}(\pi)=\mathbb{E}_{x\sim\mathcal{X},a\sim\pi}\Big{[}r(x,a,T)- \tau\mathrm{D}_{\mathrm{KL}}[\pi(\cdot|x)\|{\pi_{\mathrm{ref}}}(\cdot|x)]\Big{ ]},$ (7) $$

where we are interested in maximising the reward function $r(x,a,T)$ that reflects human preferences in the present (i.e., the current time step). We note the prompt distribution $\mathcal{X}$ and the reference model ${\pi_{\mathrm{ref}}}$ do not vary with time. As we consider the reward model at a specific time $T$, we can derive an implicit reward of the same form as Equation 3. This relates the optimal policy and reward function of Equation 7 as

$$ $r(x,a,T)=\tau\log\frac{\pi^{*}_{T}(a|x)}{{\pi_{\mathrm{ref}}}(a|x)}+\tau\log Z ^{*}_{T}(x),$ (8) $$

where $\pi^{*}_{T}$ is the optimal policy that optimises Equation 7 and $Z^{*}_{T}$ denotes the normalisation constant of $\pi^{*}_{T}$. We then parameterise the policy $\pi$ in Equation 7 using the parameter $\theta_{T}$, which enables expressing the implicit reward with respect to the parameter as

$$ $r_{\theta_{T}}(x,a,T)=\tau\log\frac{\pi_{\theta_{T}}(a|x)}{{\pi_{\mathrm{ref}} }(a|x)}+\tau\log Z_{\theta_{T}}(x),$ (9) $$

where $Z_{\theta_{T}}$ denotes the normalisation constant of $\pi_{\theta_{T}}$. We apply Equation 9 into the exponentially weighted negative log likelihood in Equation 6 to derive the NS-DPO objective

Writing the difference in implicit reward terms as $h_{\theta_{T}}(x_{i},a_{i},a^{\prime}_{i})=\tau\log\frac{\pi_{\theta_{T}}(a_{i
}|x_{i})}{{\pi_{\mathrm{ref}}}(a_{i}|x_{i})}-\tau\log\frac{\pi_{\theta_{T}}(a^
{\prime}_{i}|x_{i})}{{\pi_{\mathrm{ref}}}(a^{\prime}_{i}|x_{i})}$, the gradient of the NS-DPO objective with respect to $\theta_{T}$ is

$$ $\nabla_{\theta_{T}}\mathcal{L}^{\mathrm{NS}}(\theta_{T})=\sum_{(x_{i},a_{i},a^ {\prime}_{i},t_{i})\in\mathcal{D}}-\tau\gamma^{T-t_{i}-1}\sigma\left(-h_{ \theta_{T}}(x_{i},a_{i},a^{\prime}_{i})\right)\left(\nabla_{\theta_{T}}\log\pi _{\theta_{T}}(a_{i}|x_{i})-\nabla_{\theta_{T}}\log\pi_{\theta_{T}}(a^{\prime}_ {i}|x_{i})\right).$ (11) $$

The gradient of the NS-DPO objective consists of two terms. The first term $\sigma\left(-h_{\theta_{T}}(x_{i},a_{i},a^{\prime}_{i})\right)$ scales the gradient update, which increases when the model incorrectly prefers response $a^{\prime}_{i}$ to $a_{i}$ and decreases when the model correctly predicts the response preference. NS-DPO adjusts this term by discounting the scaling term further when points are temporally far away from $T$, while increasing it for more recent points. The second term, $\nabla_{\theta_{T}}\log\pi_{\theta_{T}}(a_{i}|x_{i})-\nabla_{\theta_{T}}\log
\pi_{\theta_{T}}(a^{\prime}_{i}|x_{i})$, controls the direction of the gradient update.

## 4 Theoretical Analysis of Offline Non-stationary DPO

In this section, we analyse the performance of the NS-DPO objective (Equation 10), in the offline setting.

Policy Class. We use policies parameterised by $\theta\in\Theta\subset\mathbb{R}^{d}$ of the following form

$$ $\Pi=\left\{\pi_{\theta}(a|x)=\frac{\exp(f_{\theta}(x,a))}{\sum_{a^{\prime}\in \mathcal{A}}\exp(f_{\theta}(x,a^{\prime}))}\right\},$ (12) $$

where $f_{\theta}(x,a)\in\mathbb{R}$ is a differentiable function. For our analysis, we consider the case of log-linear policies where $f_{\theta}$ is linear: $f_{\theta}(x,a)=\phi(x,a)^{\intercal}\theta$, and the feature map $\phi(x,a)$ is a $d$-dimensional vector. This is motivated by the reward model introduced in Ziegler et al. () where the last hidden layer of the LLM is used as the feature embedding function $\phi(x,a)$.

Performance measure and Optimal Policy. Let ${\tilde{\theta}}_{T}\in\Theta$ denote the parameter that minimises the NS-DPO objective defined in Equation 10. We assess the performance of the policy $\pi_{{\tilde{\theta}}_{T}}$, using the difference in expected rewards

$$ $R^{\mathrm{off}}_{T}=\mathbb{E}_{x\sim\mathcal{X}}\left[\mathbb{E}_{a\sim\pi^{ *}_{T}(\cdot|x)}[r(x,a,T)]-\mathbb{E}_{a^{\prime}\sim\pi_{{\tilde{\theta}}_{T} }(\cdot|x)}[r(x,a^{\prime},T)]\right].$ (13) $$

Here $r(\cdot,\cdot,T)$ denotes the true reward function at time $T$, and $\pi^{*}_{T}$ denotes the optimal policy against which we compare the performance of our algorithm. Given a reference policy ${\pi_{\mathrm{ref}}}$, the optimal policy is defined as the policy which optimises the RLHF objective at time step $T$

$$ $\pi^{*}_{T}=\operatorname*{arg\,max}_{\pi\in\Pi}\mathbb{E}_{x\sim\mathcal{X},a \sim\pi}\Big{[}r(x,a,T)-\tau\mathrm{D}_{\mathrm{KL}}[\pi(\cdot|x)\|{\pi_{ \mathrm{ref}}}(\cdot|x)]\Big{]}.$ (14) $$

Similarly, we can define the parameter $\theta^{*}_{t}$ of the optimal policy in each time step $t\in[T]$

$$ $\theta^{*}_{t}=\operatorname*{arg\,max}_{\theta_{t}\in\Theta}\mathbb{E}_{x\sim \mathcal{X},a\sim\pi}\Big{[}r(x,a,t)-\tau\mathrm{D}_{\mathrm{KL}}[\pi_{\theta_ {t}}(\cdot|x)\|{\pi_{\mathrm{ref}}}(\cdot|x)]\Big{]}.$ (15) $$

We now introduce further assumptions on the setting. In order to make the learning process possible, we bound the 2-norm of the feature and parameter spaces.

###### Assumption 4.1 .

(Boundedness) The parameters and features are bounded:
$\theta\in\Theta$ where $\Theta=\{\theta\in\mathbb{R}^{d}\ |\ \|\theta\|_{2}\leq W\}$ and $\Phi=\{\phi(x,a)\in\mathbb{R}^{d}\ |\ \|\phi(x,a)\|_{2}\leq L\}$.

It is known that an equivalence class of reward models leads to the same preferences under the Bradley-Terry model (Rafailov et al., ). This is similarly true in the case of the Dynamic Bradley-Terry model, because the implicit reward of NS-DPO, shown in Equation 8, relates the reward to the policy parameters $\theta$. We thus construct the following constraint on the policy class to properly specify the problem (Chowdhury et al., ).

###### Assumption 4.2 .

(Identifiability) The optimal policy in each time step $t$ corresponds to a single parameter in $\Theta$, which satisfies Equation 15:
$\textbf{1}_{d}^{\intercal}\theta^{*}_{t}=0\quad\forall t\in[T]$.

We consider the setting where the true underlying parameter $\theta^{*}_{t}\in\Theta,\forall t\in[T]$ of the optimal policy $\pi^{*}$ is changing at each time step. We do not constrain how the optimal parameter changes, but instead upper bound the possible parameter drift allowed in the environment up to time step $T$. This upper bound is known as the variation budget.

###### Assumption 4.3 .

(Variation Budget Bound) The parameter drift of $\theta_{t}^{*}\in\Theta$ across $T$ timesteps is upper bounded as $\sum_{t=1}^{T-1}\|\theta^{*}_{t+1}-\theta^{*}_{t}\|_{2}\leq B_{T}$ where $B_{T}>0$ is a known constant.

In the offline setting, our learning is constrained by the available dataset $\mathcal{D}$. A standard assumption in the offline learning literature is that of data coverage (Chowdhury et al., ; Zhu et al., ). The data coverage assumption ensures that the reference policy ${\pi_{\mathrm{ref}}}$ suitably explores the space of plausible responses of the optimal policy. We define the population covariance matrix as $\Sigma_{\pi}=\mathbb{E}[\phi(x,a)\phi(x,a)^{\intercal}]-\mathbb{E}[\phi(x,a)]
\mathbb{E}[\phi(x,a)]^{\intercal}$ where the expectation is calculated over samples $x\sim\mathcal{X},a\sim\pi(\cdot|x)$. The condition number $\kappa_{\pi}$ compares the coverage of the two policies $\pi$ and ${\pi_{\mathrm{ref}}}$

$$ $\forall\pi\in\Pi:\ \kappa_{\pi}=\sup_{v\in\mathbb{R}^{d}}\frac{v^{\intercal} \Sigma_{\pi}v}{v^{\intercal}\Sigma_{\pi_{\mathrm{ref}}}v}=\frac{\lambda_{ \mathrm{max}}(\Sigma_{\pi})}{\lambda_{\mathrm{min}}(\Sigma_{\pi_{\mathrm{ref}} })},$ (16) $$

while we use $\kappa=\max_{\pi}\kappa_{\pi}$ to denote the maximum possible value of $\kappa_{\pi}$. The definition of $\kappa_{\pi}$ requires that the reference policy sufficiently explores the feature space, which leads to the following assumption.

###### Assumption 4.4 .

(Feature Coverage) The reference policy ${\pi_{\mathrm{ref}}}$ satisfies $\lambda_{\mathrm{min}}(\Sigma_{\pi_{\mathrm{ref}}})>0$.

In a time-varying setting, the quality of the dataset $\mathcal{D}$ also depends upon its temporal coverage. We use the following assumption which also guarantees a minimal amount of data in each time step. Having enough data in each time step is motivated by the fact that we are assuming no knowledge of the dynamics of the actual preference drift. Note that $\Theta(T)$ in the assumption is the notation for the complexity, which is different from the parameter set $\Theta$ in Assumption 4.1.

###### Assumption 4.5 .

(Temporal Coverage) For each time step $t\in[T-1]$, the number of datapoints in the training set is between $\underline{m}$ and $\bar{m}$, where $\underline{m}>0$ and $\bar{m}>\underline{m}$ are constants (i.e., $n=\Theta(T)$).

###### Assumption 4.1 .

###### Assumption 4.2 .

###### Assumption 4.3 .

###### Assumption 4.4 .

###### Assumption 4.5 .

### 4.1 Theoretical Results

Estimation Error. To bound the expected regret of the policy trained with NS-DPO, bounding the difference between the optimal and the found parameter is required. To analyse the parameter estimation error, we define the discounted covariance matrix of the offline dataset as

$$ $\hat{\Sigma}=\frac{1}{n}\sum_{i=1}^{n}\gamma^{T-t_{i}-1}(\phi(x_{i},a_{i})- \phi(x_{i},a^{\prime}_{i}))(\phi(x_{i},a_{i})-\phi(x_{i},a^{\prime}_{i}))^{ \intercal}.$ (17) $$

Under the assumptions from Section 4, we introduce bounds on the estimation error of the parameter ${\tilde{\theta}}_{T}$ with respect to the true parameter $\theta^{*}_{T}$, and $\hat{\Sigma}$

$$ $\|\theta^{*}_{T}-{\tilde{\theta}}_{T}\|_{\hat{\Sigma}+\lambda I},$ (18) $$

where $\lambda>0$ is introduced to guarantee the inversion of the matrix $\hat{\Sigma}+\lambda I$. The detailed analysis of the confidence bound is provided in Section C.1.

Our analysis differs from the stationary case (Chowdhury et al., ), as we also consider the discounted datapoints in the NS-DPO loss. This is reflected in the covariance matrix $\hat{\Sigma}$ by the inclusion of the $\gamma^{T-t_{i}-1}$ term, which increases uncertainty about the observations that happened further in the past.

We also separate the estimation error into the *learning* term (Equation 43) and the *tracking* term (Equation 44), the latter of which accounts for the error introduced by the non-stationary nature of the environment.

Expected Regret Bound. Starting from the definition of the expected regret in Equation 13, the regret can be expressed in terms of the estimation error in Equation 28. We can then use our results in Theorem C.1 to complete the analysis. The full details of the regret analysis proof are deferred to Section C.2.

###### Theorem 4.1 .

(Regret bound of ${\tilde{\theta}}_{T}$) Let $\delta\in(0,\tfrac{1}{2}],\tau>0$ and $r^{*}_{T}(x,a)<r^{\mathrm{max}}\ \forall x\in\mathcal{X},a\in\mathcal{A}$.
Let ${\tilde{\theta}}_{T}$ denote the parameter in $\Theta$ which minimises the NS-DPO loss (Equation 24) on an offline dataset. When $\gamma=1-\left(\tfrac{B_{T}}{dT}\right)^{1/2}$, the following bound holds with probability at least $1-2\delta$:

$$ $\displaystyle R^{\mathrm{off}}_{T}\leq$ $\displaystyle\Bigg{(}2\sqrt{\lambda}W+\frac{2C_{1}}{\tau c_{\sigma,\tau}}\sqrt {\frac{d+\log(1/\delta)}{n}}+\frac{16LR_{\sigma,\tau}\bar{m}}{T(1-\gamma)^{ \tfrac{3}{2}}}\sqrt{\frac{d\bar{m}}{n}}B_{T}\Bigg{)},$ $$

where $C_{1}>0$ and $0<C_{2}<1$ denote constants. In other words, when $\lambda=O\left(\frac{d}{n}\right)$, $R^{\mathrm{off}}_{T}$ satisfies:

$$ $\displaystyle R^{\mathrm{off}}_{T}=\tilde{O}\left(d\ B_{T}^{1/2}\ n^{-1/4} \right).$ $$

We compare the complexity bound of our approach with the previous works. Standard offline RL algorithms assuming the stationarity of the underlying reward functions achieve $O(n^{-1/2})$ (Wang et al., ; Zhan et al., ; Qiao and Wang, ; Cen et al., ). Chowdhury et al. () achieves $O(n^{-1/4})$ in scenarios where preferences are subject to noises, whose frequency is known. Our regret bound is $O(n^{-1/4})$, which is comparable to that of Chowdhury et al. (). The complexity of our algorithm is influenced by the value of $\gamma=1-\left(\tfrac{B_{T}}{dT}\right)^{1/2}$, which is used to address the non-stationarity in the dataset. We provide the details in Section C.2.1.

###### Theorem 4.1 .

## 5 Experiments

In this section, we empirically evaluate NS-DPO’s ability to learn under preference drift. We first show that NS-DPO outperforms DPO in the log-linear policy setting, supporting our theoretical results introduced in Section 4.1. We then analyse how NS-DPO performs under different types of preference drift and under different strengths of preference change using the Llama2 LLM (Touvron et al., ). Our code is available at https://github.com/geronest/ns-dpo.

### 5.1 Experimental Setup

#### 5.1.1 Synthetic Experiments

To analyse the performance of NS-DPO in the log-linear policy class, we construct a synthetic environment with a known feature space and preference drift. We use the feature space from (Li et al., ), where $x\in\mathcal{X}=[0,1]^{d_{x}}$, $a\in\mathcal{A}=[n_{a}]$ and $\phi(x,a)$ is computed as

$$ $\phi(x,a)=\Bigg{[}(a+1)\cdot\cos(x_{0}\cdot\pi),\frac{1}{a+1}\cdot\sin(x_{0} \cdot\pi),\cdots,(a+1)\cdot\cos(x_{d_{x}-1}\cdot\pi),\frac{1}{a+1}\cdot\sin(x_ {d_{x}-1}\cdot\pi)\Bigg{]}.$ (19) $$

The dimensions of the feature space and the policy parameter are both $2\cdot d_{x}$. We use $d_{x}=4,d_{\theta}=8,|\mathcal{A}|=16$ for all synthetic experiments.

##### Non-stationary Dataset.

To construct a dataset $\mathcal{D}=\{x,a,a^{\prime},t\}_{i=1}^{n}$, we randomly sample $x\sim X$ and $a_{1},a_{2}\sim\mathcal{A}$. We assign 20 datapoints per time step $\forall t\in[100]$. We sample 100 datapoints for evaluation at $T=101$. To introduce preference drift, we follow an approach similar to Faury et al. (). We sample the preferences over $a_{1}$ and $a_{2}$ from the class of log-linear policies given in Equation 12, parameterised by $\theta^{*}_{t}$. We denote preferred response as $a$ and the rejected response as $a^{\prime}$. When $t\leq 33$, we set the optimal parameter as $\theta^{*}_{t}=(1,0,1,0,1,0,1,0)^{\intercal}$. Between $34\leq t\leq 66$, the parameter $\theta^{*}_{t}$ varies as

$$ $\displaystyle\theta^{*}_{t}=\left[\cos(\tfrac{t-33}{33}\cdot\tfrac{\pi}{2}), \sin(\tfrac{t-33}{33}\cdot\tfrac{\pi}{2}),\ldots,\cos(\tfrac{t-33}{33}\cdot \tfrac{\pi}{2}),\sin(\tfrac{t-33}{33}\cdot\tfrac{\pi}{2})\right]^{\intercal}.$ (20) $$

For the remaining time steps $67\leq t\leq 100$, we use $\theta^{*}_{t}=(0,1,0,1,0,1,0,1)^{\intercal}$.

##### Algorithms for Synthetic Experiments.

We compare NS-DPO with DPO and SW-DPO in synthetic experiments. SW-DPO uses a "sliding" window to only consider points close to the current timestep $T$, which is commonly used in the non-stationary bandit literature (Garivier and Moulines, ). We test the performance of NS-DPO and SW-DPO over several values of $\gamma\in\{0.7,0.9\}$ and window size $w\in\{33,50\}$. The regularisation coefficient is $\tau=1.0$ for all algorithms. We normalise the scale of the gradient for each method to address the differences caused by the application of exponential weighting and sliding window. For the reference policies, we use a uniform policy, whose parameter ${\theta_{\mathrm{ref}}}\in\mathbb{R}^{d}$ is a zero vector.

##### Evaluation Metrics.

To analyse the performance of the algorithms, we use the reward accuracy of the trained policies. The reward accuracy is computed by the portion of test response pairs with correctly estimated preferences, using the implicit rewards defined in Equation 8. For each tested algorithm, we report averaged results of the experiments across 10 different random seeds.

Figure: Figure 2: Synthetic experiment results with $d_{x}=4,|\mathcal{A}|=16$. The shaded area represents the standard deviation of each algorithm. [Left] NS-DPO and SW-DPO successfully addresses the non-stationarity present in the dataset, while stationary DPO fails to do so. NS-DPO shows faster training than SW-DPO, even compared to the case where the value of the window parameter $w$ for SW-DPO is set to the optimal value of 33. [Right] An ablation study on how different values of the discount factor $\gamma$ affect the training of NS-DPO. As the value of $\gamma$ becomes larger, the final test accuracy of the policy is achieved in fewer training steps.
Refer to caption: x2.png

#### 5.1.2 Large Language Model Experiments

To test the performance of NS-DPO in an LLM setting, we create three preference datasets with known and controlled preference drift.

##### 1) NSGO Datasets.

We modify the GlobalOpinionQA dataset(^2^22[https://huggingface.co/datasets/Anthropic/llm_global_opinions](https://huggingface.co/datasets/Anthropic/llm_global_opinions)) (Durmus et al., ) to create a time varying dataset. GlobalOpinionQA consists of questions regarding global issues, different responses, and preferences from several countries represented as a probability vector. We copy the questions and responses to create multiple time steps $t\in[100]$. We then vary the preferences with time by linearly interpolating between the preferences of two different countries. This simulates gradual preference drifts that can be caused by demographic shift or a series of external events. We generate preference drift using three pairs of countries. In each pair the starting country is the US, and the ending country is either Brazil, Japan or Germany. The preferences at the first and last time step correspond to either country in the pair. The last time step is held out as a test dataset and treated as the current time $T=101$. We divide the prompt-response pairs so that training and test data do not share any prompts.

##### 2) UltraFeedback Datasets.

Using the prompts and response candidates of UltraFeedback(^3^33We modify the [binarized version of UltraFeedback](https://huggingface.co/datasets/HuggingFaceH4/ultrafeedback_binarized).) (Cui et al., ), we obtain preferences from two different reward models, PairRM(^4^44[https://huggingface.co/llm-blender/PairRM](https://huggingface.co/llm-blender/PairRM))(Jiang et al., ) and ArmoRM(^5^55[https://huggingface.co/RLHFlow/ArmoRM-Llama3-8B-v0.1](https://huggingface.co/RLHFlow/ArmoRM-Llama3-8B-v0.1)) (Wang et al., ). The datapoints in the training set are randomly assigned to one of $t\in[100]$ time steps, and assigned preferences of PairRM if the time step $t$ is earlier than the change point $t_{\mathrm{cp}}\in\{51,66,81\}$. We assign the preferences of ArmoRM for the datapoints with time steps $t\geq t_{\mathrm{cp}}$ and datapoints in the test set with $T=101$. We also vary the portion of datapoints with preferences that differ between PairRM and ArmoRM, which is denoted by $\rho_{\mathrm{diff}}$. We use $\rho_{\mathrm{diff}}\in\{0.5,0.7,0.9,0.95,1.0\}$ to create the datasets. We use 10k datapoints for training and 500 datapoints for testing.

Figure: Figure 3: The correlation of different preference labels generated by rewards from the ArmoRM reward model on the Helpful Harmless harmless-base dataset (Bai et al., ). We observed that concepts such as safety and helpfulness have more correlated preferences, whilst the helpsteer-coherence reward model is un-correlated with the other models we analysed.
Refer to caption: x4.png

##### 3) Time Varying Helpful Harmless Datasets.

Using the harmless-base subset of the Helpful Harmless dataset(^6^66[https://huggingface.co/datasets/Anthropic/hh-rlhf](https://huggingface.co/datasets/Anthropic/hh-rlhf))(Bai et al., ), we create a time varying preference dataset. To do so, we use two reward models, the helpsteer-helpfulness and beavertails-is_safe outputs from the ArmoRM model (Wang et al., ). Figure 3 shows that these rewards result in different preferences on the harmless-base dataset. We then assign each datapoint in the dataset a random time value from $t\in[100]$. We construct two methods to assign preferences using the time step information: change point preference shift and gradual variation. Under the change point preference shift, datapoints are assigned preferences according to helpsteer-helpfulness before the change point $t_{cp}$ and beavertails-is_safe after the change point. Under gradual variation, we use the following reward model

$$ $r(x,y,t)=\begin{cases}r_{0}(x,y)&t<33\\ r_{0}(x,y)\frac{(t-33)}{33}+r_{1}(x,y)\left(1-\frac{(t-33)}{33}\right)&33\leq t <66\\ r_{1}(x,y)&t\geq 66,\end{cases}$ (21) $$

where $r_{0}$ is the helpsteer-helpfulness reward and $r_{1}$ is the beavertails-is_safe reward. We use this type of schedule for gradual change to simulate preference drifts that happens gradually over a finite time horizon. We use $15k$ points for training and $2k$ for testing. We use reward models for helpfulness and safety, as these are both desired properties of an LLM but often result in differing preferences; for example, rewarding helpfulness can often lead to unsafe outputs when an LLM is asked a dubious question, like how to best rob a store.

##### Language Models.

We use Llama-2-7b-chat-hf (^7^77[https://huggingface.co/meta-llama/Llama-2-7b-chat-hf](https://huggingface.co/meta-llama/Llama-2-7b-chat-hf)) (Touvron et al., ) for both fine-tuning and the reference model. To reduce the compute demands, we train LoRA weights (Hu et al., ) (see Compute Resources Uses for further details).

##### Algorithms for the LLM experiments.

We compare NS-DPO against baselines including include stationary DPO and IPO. We also construct an In-Context Learning (ICL) algorithm referred to as tDPO, in which information about the time step is appended to the prompts of the data. All algorithms use the same SFT model as the reference model. We do not adjust the SFT training procedure from Rafailov et al. (), training the model on the preferred responses in the dataset. We used $\tau=0.1$ for all models, and NS-DPO uses $\gamma=0.95$ for experiments with 2C NSGO dataset and UltraFeedback dataset. For Time Varying Helpful-Harmless dataset, we adjust the value of $\gamma$ as $\gamma=1-(\frac{1}{100-t_{cp}})\log(100)$.

##### Evaluation Metrics.

To compare the performance of NSDPO and the baseline algorithms in LLM datasets, we use reward accuracy as we do in synthetic experiments.

### 5.2 Experiment Results

Figure: Figure 4: [Left] Reward model shift at $t_{\mathrm{cp}}=51$. [Middle] Reward model shift at $t_{\mathrm{cp}}=66$. [Right] Reward model shift at $t_{\mathrm{cp}}=81$. As $\rho_{\mathrm{diff}}$, the percentage of training datapoints with flipped preference increase, stationary DPO fails to learn the preference distribution at $T=101$. Meanwhile, NS-DPO shows robust performance under various values of $\rho_{\mathrm{diff}}$, maintaining reward accuracies above 50%. As $t_{\mathrm{cp}}$, the change point of the reward model happens later in time, the gap between stationary approaches and NS-DPO gets bigger. The experiments were run on the UltraFeedback dataset under a reward model shift from PairRM to ArmoRM. The Llama-2-7b-chat-hf model was used and the training dataset consisted of 100 time steps.
Refer to caption: x5.png

Figure: Figure 5: Training curves of NS-DPO and DPO on a stationary setting of the UltraFeedback dataset, which corresponds to $t_{\mathrm{cp}}=0$. Llama-2-7b-chat-hf was used for LLMs. NS-DPO matches the performance of DPO even in stationary settings.
Refer to caption: x8.png

##### How does NS-DPO perform when specialised to log-linear policy classes?

As shown in the left image of Figure 2, when compared to NS-DPO and SW-DPO, DPO shows the worst performance with respect to the test data. Both NS-DPO and SW-DPO, which account for the preference drift present in the data, show significantly better performance. SW-DPO achieves similar performance to NS-DPO in the later stages of training, but NS-DPO achieves this performance in fewer training steps. As NS-DPO only varies the weights of datapoints, rather than removing them entirely, it can still leverage the information of datapoints in the earlier time steps. The right image of Figure 2 shows a comparison of different values of $\gamma$, ranging from 0.3 to 0.9. The results show that the performance of NS-DPO is stable in terms of the final test accuracy across a large range of values, $\gamma\in[0.5,0.9]$. As the value of $\gamma$ is reduced, only points closest to the current time step contribute significantly to the gradient update of the model. Thus as $\gamma$ decreases, NS-DPO requires more training steps for the reward accuracy on the test set to converge.

##### How robust and effective is NS-DPO under varying strengths of sudden preference drift?

Preference drift in non-stationary scenarios can vary in strength. To investigate this, we conduct two different experiments. Firstly, we vary $\rho_{\mathrm{diff}}$, the portion of datapoints with preferences that change, at three different change points on the non-stationary UltraFeedback Dataset introduced in Section 5.1. Secondly, we vary the change point for three different values of $\rho_{\mathrm{diff}}$ on the Time Varying Helpful Harmless dataset. Stationary preference algorithms treat non-stationary preferences as label noise in the data. As $\rho_{\mathrm{diff}}$ is increased, the level of noise observed by the stationary algorithms increase leading to worse performance. We show this in Figure 4 and Figure 7 where for high values of $\rho_{\mathrm{diff}}$, when the change point is close to the present, the difference in performance between NS-DPO and the baseline algorithms can be as much as $20\%$. Datasets with a change point that occurs close to the present have very few examples of the new preference distribution. Because of this, stationary algorithms learn the old preference distribution, as that is mostly represented in the data. The low performance of the baseline algorithms on the binary classification of preferences at test time demonstrates this empirically. Note that the performance of NS-DPO matches that of DPO even when the preference shift in the dataset is not significant, $\rho_{\mathrm{diff}}\leq 0.7$. This observation is further supported by Figure 5, where NS-DPO matches the performance of stationary DPO in a dataset with no preference drift. These results show that NS-DPO is robust against strong preference drift in offline datasets and matches the performance of stationary algorithms when the preference drift is trivial.

Figure: Figure 6: Llama-2-7b-chat-hf experiment results using 2C NSGO dataset. [Left] Opinion drift from the US to Germany. [Middle] Opinion drift from the US to Japan. [Right] Opinion drift from the US to Brazil. NS-DPO stays robust to the non-stationarity present in the dataset and achieves reward accuracies above 60%, while stationary methods show dropped reward accuracies of around 55%. Including the time steps in the prompt (tDPO) does not help meaningfully improve the performance of stationary DPO.
Refer to caption: x9.png

Figure: Figure 7: NS-DPO consistently outperforms DPO and IPO as the change point, $t_{cp}$ nears the present $T=101$ for varying strengths of preference shift on the Time Varying Helpful Harmless dataset using the Llama-2-7b-chat-hf model. [Left] $\rho_{\mathrm{diff}}=0.7$. [Middle] $\rho_{\mathrm{diff}}=0.8$. [Right] $\rho_{\mathrm{diff}}=0.9$. We note that as the value of $t_{\mathrm{cp}}$ increases, the performance difference between NS-DPO and the baselines increases. This is because as the change point moves closer to the present time step, the number of samples available from the updated preference distribution decreases. NS-DPO discounts samples with old preferences, focusing learning upon the small number of samples with up-to-date preference labels.

##### How does NS-DPO perform under gradual preference drifts?

As well as the strength of the preference shift, different schedules of preference drift can also affect the performance of preference optimization algorithms. Here we investigate cases where preference drift happens gradually over time. In Figure 8, we see that NS-DPO outperforms the DPO reward accuracy by over $10\%$ on the TVHH dataset with gradual preference drift. We note that the performance of NS-DPO is dependent upon the value of $\gamma$ chosen, however both approaches outperform the stationary baseline. The experiment results on the 2C NSGO dataset, which also simulates a gradual drift of preferences, are given in Figure 6. NS-DPO shows significantly better performance compared to stationary DPO, showing a performance gap of nearly 10% in reward accuracy. This difference is mainly caused by stationary methods failing to efficiently learn from datapoints at later time steps. tDPO, which trains the policy with time step information appended to the prompt, does not show a significant difference from stationary DPO.

Figure: Figure 8: NS-DPO outperforms DPO in settings where preference drift occurs slowly across multiple timesteps. Here we compare NS-DPO and DPO on the TVHH dataset with a gradual preference shift.
Refer to caption: x15.png

## 6 Conclusion

In this work we propose NS-DPO, a practical and provably efficient approach for preference optimization on non-stationary offline datasets. With standard assumptions, we provide a theoretical analysis on the performance of NS-DPO in the case of log-linear policies and show that the complexity of the regret matches that of other stationary approaches. We further support this result with a suit of empirical results on a synthetic setting. We also investigate the application of NS-DPO to LLMs, create several non-stationary preference datasets, and show that NS-DPO shows superior performance to standard preference optimization algorithms and In Context Learning approaches on these datasets. Even in stationary settings, NS-DPO matches the performance of stationary algorithms. This motivates the usefulness of our approach when the existence of preference drift in a dataset is unknown, as applying NS-DPO will not hurt performance even if the preference drift is too small to matter. Our approach can be further extended to the online setting where data is sequentially provided as time passes. NS-DPO can also be adapted to learn at a time step that is not the present by discounting both past and future preference as a function of their distance from the time step of interest. We leave these ideas to future work.

## Compute Resources Uses

To run the LLM experiments, we used A100 GPUs with 40GB VRAM. The synthetic experiments were run locally on a laptop without using GPUs.

## Acknowledgements

IB was supported by the EPSRC New Investigator Award EP/X03917X/1; the Engineering and Physical Sciences Research Council EP/S021566/1; and Google Research Scholar award. WB was supported by the Engineering and Physical Sciences Research Council EP/S021566/1.

## Appendix A Appendix Contents

In Appendix B, we explain the details of experiments conducted, including the creation of non-stationary datasets for LLM experiments and the behaviour of NS-DPO and SW-DPO in the synthetic setting. We provide proofs of our theoretical analysis in Appendix C step by step. Some of the in-depth derivations necessary for the theoretical analysis are separately presented in Section C.3 and Section C.4.

## Appendix B Further Experiment Details

### B.1 The Two Countries (2C) Non-Stationary Global Opinions Dataset

To test NSDPO, we create a synthetic non-stationary dataset in which the temporal trends are known. To do this, we use the GlobalOpinionsQA dataset (Durmus et al., ). We preprocess the dataset in three major ways.

##### Binary Preferences.

We convert the dataset to a dataset of binary preferences. For each set of prompt and responses, we create a row for each possible combination of prompt and binary response pairs. We calculate the preference probability for these response pairs as follows. Assuming the non-binary responses follow a Plackett-Luce preference framework, we can find the reward associated with responses (up to an additive constant) by taking the log of the preference probability. We can then take the sigmoid of these responses to find a normalised binary preference.

##### Country Filter.

We filter the dataset down to the following countries: Nigeria, Egypt, India, China, Japan, Germany, France, Spain, United States, Canada, Brazil, Argentina, Australia and New Zealand.

##### Country Level Prompts.

We filter the dataset such that each row of the dataset is the prompt, response, preference probability of a single country.

After the preprocessing, we copy the dataset and assign a different timestep to each unique instance of (prompt, response, preference). We simulate the drift in preferences by using preference probabilities of two countries, shifting from one to another over time. Out of $100$ time steps in the training dataset, the first 33 time steps consisted of preference probabilities from the US. Preference labels sampled from the last 33 time steps are from probabilities of the target country. We use Germany, Japan and Brazil as target countries, creating three different datasets. In the intermediate 33 time steps, preference labels are sampled from interpolated probabilities between these two countries. To introduce sufficient shift in preferences, we selected responses in which probabilities for the same response from two countries differed at least by $0.2$. We subsampled prompt-response pairs down to 10,000 datapoints, allowing each time step to consist of different prompts and responses. For evaluation, we used prompts and response candidates that are not present in the training data.

### B.2 Synthetic Experiments

Figure: Figure 9: [Left] Performance of NS-DPO with values of $\gamma>0.9$. NS-DPO shows robust performance with respect to the value of $\gamma$, while it starts resembling the performance of stationary DPO as the value approaches very close to 1, $\gamma>0.97$. [Right] Expected RLHF objective gap of SW-DPO in the same experiments. The performance of SW-DPO improves as the value of $w$ gets closer to 33, when the algorithm is only learning from datapoints where the preference distribution stays stationary in the given setting. The setting with $w=10$ also shows final performance similar to the case of $w=33$, but it shows slower training because of the reduced amount of data used for training.
Refer to caption: x16.png

In this section, we present the experiment results of NS-DPO and SW-DPO on the synthetic dataset with varied values of hyperparameters $\gamma$ and $w$. As shown in Figure 9, The performance of NS-DPO is robust across varied values of $\gamma$, maintaining its reward accuracy over 80% when $0.5\leq\gamma\leq 0.97$. In the case of SW-DPO, the performance is more sensitive to the change of the window size $w$. When $w=10$, it shows similar test performance in the later stage of the training, while the process is visibly slowed down due to the reduced amount of datapoints actually being used. On the other hand, as the window size gets bigger and starts including datapoints where parameter shift introduces conflicting preferences, SW-DPO also shows degrading performance. These results provide further support the advantages of using NS-DPO over SW-DPO, as it shows faster training and less sensitivity to the hyperparameter.

## Appendix C Offline Learning Analysis

In this section, we provide the remaining details of the analysis on the offline learning of non-stationary dataset.

##### Non-Linearity Coefficients.

Following the analysis from Filippi et al. (); Faury et al. (), we capture the non-linearity of the sigmoid function in the NS-DPO loss. We use the coefficients $k_{\sigma,\tau},c_{\sigma,\tau}$, which are the supremum and infimum of $\dot{\sigma}(\tau\langle\phi(x,a)-\phi(x,a^{\prime}),\theta\rangle)$ over $x\in\mathcal{X},(a,a^{\prime})\in\mathcal{A}^{2},\theta\in\Theta$ respectively:

$$ $\displaystyle k_{\sigma,\tau}=\sup_{x\in\mathcal{X},(a,a^{\prime})\in\mathcal{ A}^{2},\theta\in\Theta}\dot{\sigma}(\tau\langle\phi(x,a)-\phi(x,a^{\prime}), \theta\rangle),$ (22) $\displaystyle c_{\sigma,\tau}=\inf_{x\in\mathcal{X},(a,a^{\prime})\in\mathcal{ A}^{2},\theta\in\Theta}\dot{\sigma}(\tau\langle\phi(x,a)-\phi(x,a^{\prime}), \theta\rangle),$ (23) $$

while we use $R_{\sigma,\tau}=k_{\sigma,\tau}/c_{\sigma,\tau}$ to denote the ratio between $k_{\sigma,\tau}$ and $c_{\sigma,\tau}.$

##### Loss and gradient.

For the sake of clarity in our analysis, we draw parallels between the NS-DPO objective in Equation 10 and the logistic regression objective used in the generalised linear bandit setting of (Faury et al., ). We re-write the NS-DPO loss with a preference label $o_{i}\in\{0,1\}$ and a $\ell_{2}$ regularisation term $\frac{\lambda c_{\sigma,\tau}\tau^{2}}{2}\|\theta\|^{2}$:

$$ $\displaystyle\mathcal{L}^{\mathrm{NS}}(\theta)$ $\displaystyle=-\frac{1}{n}\sum_{i=1}^{n}\Big{[}\gamma^{T-t_{i}-1}\big{\{}o_{i} \log\sigma(h_{\theta}(x_{i},a_{i},a^{\prime}_{i}))+(1-o_{i})\log\sigma(h_{ \theta}(x_{i},a^{\prime}_{i},a_{i}))\big{\}}\Big{]}$ $\displaystyle+\frac{\lambda c_{\sigma,\tau}\tau^{2}}{2}\|\theta\|^{2},$ (24) $$

where $h_{\theta}(s,a,a^{\prime})=\tau\log\left(\tfrac{\pi_{\theta}(x,a)}{{\pi_{
\mathrm{ref}}}(x,a)}\right)-\tau\log\left(\tfrac{\pi_{\theta}(x,a^{\prime})}{{
\pi_{\mathrm{ref}}}(x,a^{\prime})}\right)$ is used for brevity.

Here $o_{i}=1$ for $a_{i}\succ a_{i}^{\prime}$ and $o_{i}=0$ when $a_{i}^{\prime}\succ a_{i}$. We assume the preference label $o_{i}$ is sampled from a Dynamic Bradley-Terry model with the true unknown environment parameter $\theta^{*}_{t_{i}}$. Under this assumption, the mean of the preference label is $\mathbb{E}[o_{i}|\{x_{i},a_{i},a_{i}^{\prime},t_{i}\}]=\sigma(h_{\theta_{t_{i}
}^{*}}(x_{i},a_{i},a^{\prime}_{i}))$. When there is only a unilateral preference sampled for a given prompt-response pairs, the sigmoid function forces the implicit rewards of DPO to have infinitely large scale, driving $p(a\succ a^{\prime})$ to either 1 or 0 (Azar et al., ). The $\ell_{2}$ regularisation term in our analysis mitigates this problem, by controlling the parameter norm.
Differentiating Equation 24 with respect to the parameter $\theta$ results in

$$ $\displaystyle\nabla_{\theta}\mathcal{L}^{\mathrm{NS}}(\theta)$ $\displaystyle=-\frac{1}{n}\sum_{i=1}^{n}\tau\gamma^{T-t_{i}-1}o_{i}\hat{\phi}_ {i}+\underbrace{\frac{1}{n}\sum_{i=1}^{n}\left[\tau\gamma^{T-t_{i}-1}\sigma(h_ {\theta}(x_{i},a_{i},a^{\prime}_{i}))\hat{\phi}_{i}\right]+\lambda c_{\sigma, \tau}\tau^{2}\theta}_{:=g^{\tau}(\theta)},$ (25) $$

where $\hat{\phi}_{i}=\phi(x_{i},a_{i})-\phi(x_{i},a^{\prime}_{i})$ is also introduced for brevity. We denote the parameter-dependent part of the gradient as $g^{\tau}(\theta)=\frac{1}{n}\sum_{i=1}^{n}\left[\tau\gamma^{T-t_{i}-1}\sigma(h
_{\theta}(x_{i},a_{i},a^{\prime}_{i}))\hat{\phi}_{i}\right]+\lambda c_{\sigma,
\tau}\tau^{2}\theta$ which we will use to analyse the parameter estimation error.

##### Parameter Projection.

Let ${\hat{\theta}}_{T}$ denote the parameter minimising the NS-DPO loss defined in Equation 24, ${\hat{\theta}}_{T}=\operatorname*{arg\,min}_{\theta\in\mathbb{R}^{d}}\mathcal{
L}^{\mathrm{NS}}(\theta)$. Due to both learning and tracking aspects of the estimation error, we cannot guarantee that ${\hat{\theta}}_{T}$ is within the boundary of the parameter presented in Assumption 4.1, ${\hat{\theta}}_{T}\in\Theta$. This motivates a parameter projection method, which enables finding an admissible parameter ${\tilde{\theta}}_{T}\in\Theta$ while minimising its deviation from ${\hat{\theta}}_{T}$ (Faury et al., ; Wang et al., ). Using ${\tilde{\theta}}_{T}$ in the performance analysis of NS-DPO allows preventing the potential violation of Assumption 4.1 when ${\hat{\theta}}_{T}$ is used. We perform parameter projection by calculating ${\hat{\theta}}_{T}$ by

$$ ${\tilde{\theta}}_{T}=\operatorname*{arg\,min}_{\theta\in\Theta}\|g^{\tau}({ \hat{\theta}}_{T})-g^{\tau}(\theta)\|_{(\hat{\Sigma}+\lambda I)^{-1}},$ (26) $$

using $\hat{\Sigma}$ defined in Equation 17 and $g^{\tau}(\theta)$ defined in Equation 25.

##### Covariance matrices.

In addition to $\hat{\Sigma}$ defined in Equation 17 we also define $\tilde{\Sigma}$, to which squared discount weights are applied:

$$ $\displaystyle\tilde{\Sigma}=\frac{1}{n}\sum_{i=1}^{n}\gamma^{2T-2t_{i}-2}(\phi (x_{i},a_{i})-\phi(x_{i},a^{\prime}_{i}))(\phi(x_{i},a_{i})-\phi(x_{i},a^{ \prime}_{i}))^{\intercal}.$ (27) $$

Due to its squared application of the exponential weighting, $\hat{\Sigma}\succ\tilde{\Sigma}$.

### C.1 Estimation Error

###### Theorem C.1 .

(Estimation error of ${\tilde{\theta}}_{T}$.) Let $\delta\in(0,1],\lambda>0,\tau>0$. Let ${\hat{\theta}}_{T}$ denote the minimiser of the NS-DPO loss defined in Equation 24 on an offline dataset. Let ${\tilde{\theta}}_{T}$ denote the parameter obtained by performing the parameter projection procedure on ${\hat{\theta}}_{T}$. Then with probability at least $1-\delta$:

$$ $\displaystyle\|{\tilde{\theta}}_{T}-\theta^{*}_{T}\|_{\hat{\Sigma}+\lambda I}$ $\displaystyle\leq\underbrace{2\sqrt{\lambda}W+\frac{2C_{1}}{\tau c_{\sigma, \tau}}\sqrt{\frac{d+\log(1/\delta)}{n}}}_{\text{learning}}+\underbrace{\frac{1 6LR_{\sigma,\tau}\bar{m}}{T(1-\gamma)^{\tfrac{3}{2}}}\sqrt{\frac{d\bar{m}}{n}} B_{T}}_{\text{tracking}}$ (28) $$

where $C_{1}>0$ is a constant.

Estimation errors in typical stationary settings can be considered as *learning* errors, which are caused by having finite data sampled stochastically. In time-varying settings, the parameter estimation suffers from *tracking* error as well, which is caused by the drift of the underlying true parameter along the time steps (Faury et al., ; Wang et al., ). In this section, we show how these errors can be disentangled and bounded separately. To do this, we apply the approach of (Wang et al., ) in contextual bandit setting to our setting of offline preference learning.

###### Theorem C.1 .

#### C.1.1 Bound Decomposition

We begin with the deviation between the optimal parameter $\theta^{*}_{T}$ and ${\tilde{\theta}}_{T}$, the projected parameter of the NS-DPO estimator ${\hat{\theta}}_{T}$:

$$ $\displaystyle g^{\tau}({\tilde{\theta}}_{T})-g^{\tau}(\theta^{*}_{T})$ $\displaystyle=\frac{1}{n}\sum_{i=1}^{n}\tau\gamma^{T-1-t_{i}}\left[\sigma(h_{{ \tilde{\theta}}_{T}}(x_{i},a_{i},a^{\prime}_{i}))-\sigma(h_{\theta^{*}_{T}}(x_ {i},a_{i},a^{\prime}_{i}))\right]\hat{\phi}_{i}+\lambda c_{\sigma,\tau}\tau^{2 }({\tilde{\theta}}_{T}-\theta^{*}_{T}).$ (29) $$

Applying the mean value theorem to the difference of sigmoid functions in Equation 29 we get

$$ $\displaystyle g^{\tau}({\tilde{\theta}}_{T})-g^{\tau}(\theta^{*}_{T})$ $\displaystyle=\frac{1}{n}\sum_{i=1}^{n}\tau^{2}\gamma^{T-1-t_{i}}\left[\int_{v =0}^{1}\dot{\sigma}(\tau\langle\hat{\phi}_{i},(1-v)\theta^{*}_{T}+v{\tilde{ \theta}}_{T}\rangle)dv\right]\hat{\phi}_{i}\hat{\phi}_{i}^{\intercal}({\tilde{ \theta}}_{T}-\theta^{*}_{T})$ $\displaystyle\quad+\lambda c_{\sigma,\tau}\tau^{2}({\tilde{\theta}}_{T}-\theta ^{*}_{T}).$ $$

We can now define a matrix ${\mathbf{G}_{T}}$ to define the relation between $g^{\tau}({\tilde{\theta}}_{T})-g^{\tau}(\theta^{*}_{T})$ and ${\tilde{\theta}}_{T}-\theta^{*}_{T}$:

$$ $\displaystyle{\mathbf{G}_{T}}$ $\displaystyle:=\frac{1}{n}\sum_{i=1}^{n}\gamma^{T-1-t_{i}}\underbrace{\left[ \int_{v=0}^{1}\dot{\sigma}(\tau\langle\hat{\phi}_{i},(1-v)\theta^{*}_{T}+v{ \tilde{\theta}}_{T}\rangle)dv\right]}_{\alpha(i,\theta^{*}_{T},{\tilde{\theta} }_{T})}\hat{\phi}_{i}\hat{\phi}_{i}^{\intercal}+\lambda c_{\sigma,\tau}I,$ (30) $\displaystyle g^{\tau}({\tilde{\theta}}_{T})-g^{\tau}(\theta^{*}_{T})=\tau^{2} \cdot{\mathbf{G}_{T}}\cdot({\tilde{\theta}}_{T}-\theta^{*}_{T}).$ (31) $$

We make a brief aside to show ${\mathbf{G}_{T}}\succeq c_{\sigma,\tau}(\hat{\Sigma}+\lambda I)\succeq 0$ (Faury et al., ; Filippi et al., ), as this is an important property of ${\mathbf{G}_{T}}$ and one we will use later in the main proof.
To prove this, we first show that $\alpha(i,\theta^{*}_{T},{\tilde{\theta}}_{T})>c_{\sigma,\tau}$. $\alpha(i,\theta_{1},\theta_{2})$ is the mean value of $\dot{\sigma}$ along the path between some points $\langle\hat{\phi},\theta_{1}\rangle$ and $\langle\hat{\phi},\theta_{2}\rangle$. This is greater than the infimum of $\dot{\sigma}$ at a point along that path, which is in turn greater than the infimum of $\dot{\sigma}$ in the space of parameters $\theta\in\Theta$. The last infimum is the definition of $c_{\sigma,\tau}$ Equation 23. Then

$$ $\displaystyle\alpha(i,\theta_{1},\theta_{2})=\int_{v=0}^{v=1}\dot{\sigma}(\tau (v\phi_{i}^{\intercal}\theta_{1}-(1-v)\phi_{i}^{\intercal}\theta_{2}))dv$ $\displaystyle\geq\mathrm{inf}_{c\in[\phi_{i}^{\intercal}\theta_{1},\phi_{i}^{ \intercal}\theta_{2}]}[\dot{\sigma}(c)]$ $\displaystyle\geq\mathrm{inf}_{\phi\in\Phi,\theta\in\Theta}[\dot{\sigma}(\tau \phi^{\intercal}\theta)]=c_{\sigma,\tau}>0.$ (32) $$

$\alpha(i,\theta_{1},\theta_{2})>0$ comes from the fact that the logistic sigmoid function is strictly increasing and has a gradient greater than zero at every point. Because of this inequality, each element of ${\mathbf{G}_{T}}$ denoted by $[{\mathbf{G}_{T}}]_{lk}\forall l,k\in[d]$, is strictly larger than each element of $c_{\sigma,\tau}[\hat{\Sigma}]_{lk}$. We use this to prove that ${\mathbf{G}_{T}}\succeq c_{\sigma,\tau}(\hat{\Sigma}+\lambda I)$ for any $v=\theta_{1}-\theta_{2}$. We first remind the reader of the definition of $\hat{\Sigma}$:

$$ $\hat{\Sigma}=\frac{1}{n}\sum_{i=1}^{n}\gamma^{T-t_{i}-1}(\phi(x_{i},a_{i})- \phi(x_{i},a^{\prime}_{i}))(\phi(x_{i},a_{i})-\phi(x_{i},a^{\prime}_{i}))^{ \intercal}.$ $$

We then prove the inequality, using the fact that $\alpha$ and $\gamma$ do not depend upon the indices $l,k$ of the vector $v$ to move the sum across indices within the sum over the datapoints

$$ $\displaystyle v^{\intercal}{\mathbf{G}_{T}}v$ $\displaystyle=\sum_{(l,k)\in[d]^{2}}\Big{[}\frac{1}{n}\sum_{i=1}^{n}\gamma^{T- 1-t_{i}}\alpha(i,\theta_{1},\theta_{2})\hat{\phi}_{i}\hat{\phi}_{i}^{\intercal }+\lambda c_{\sigma,\tau}I\Big{]}_{lk}v_{l}v_{k}$ $\displaystyle=\left(\frac{1}{n}\sum_{i=1}^{n}\gamma^{T-1-t_{i}}\alpha(i,\theta _{1},\theta_{2})\sum_{(l,k)\in[d]^{2}}\Big{[}\hat{\phi}_{i}\hat{\phi}_{i}^{ \intercal}\Big{]}_{lk}v_{l}v_{k}\right)+\lambda c_{\sigma,\tau}\sum_{l\in[d]}v _{l}^{2}$ $\displaystyle\geq\left(\frac{1}{n}\sum_{i=1}^{n}\gamma^{T-1-t_{i}}c_{\sigma, \tau}\sum_{(l,k)\in[d]^{2}}\Big{[}\hat{\phi}_{i}\hat{\phi}_{i}^{\intercal}\Big {]}_{lk}v_{l}v_{k}\right)+\lambda c_{\sigma,\tau}\sum_{l\in[d]}v_{l}^{2}$ (33) $\displaystyle=c_{\sigma,\tau}\sum_{(l,k)\in[d]^{2}}\Big{[}\underbrace{\frac{1} {n}\sum_{i=1}^{n}\gamma^{T-1-t_{i}}\hat{\phi}_{i}\hat{\phi}_{i}^{\intercal}+ \lambda I}_{\hat{\Sigma}+\lambda I}\Big{]}_{lk}v_{l}v_{k}=c_{\sigma,\tau}v^{ \intercal}(\hat{\Sigma}+\lambda I)v.$ (34) $$

We now continue applying Equation 31 to bound the estimation error term:

$$ $\displaystyle\|{\tilde{\theta}}_{T}-\theta^{*}_{T}\|_{\hat{\Sigma}+\lambda I}$ $\displaystyle=\frac{1}{\tau^{2}}\|{\mathbf{G}_{T}^{-1}}(g^{\tau}({\tilde{ \theta}}_{T})-g^{\tau}(\theta^{*}_{T}))\|_{\hat{\Sigma}+\lambda I}.$ (35) $$

We use Equation 34 to apply ${\mathbf{G}_{T}}^{-1}\prec\frac{1}{c_{\sigma,\tau}}(\hat{\Sigma}+\lambda I)^{-1}$:

$$ $\displaystyle\frac{1}{\tau^{2}}\|{\mathbf{G}_{T}^{-1}}(g^{\tau}({\tilde{\theta }}_{T})-g^{\tau}(\theta^{*}_{T}))\|_{\hat{\Sigma}+\lambda I}$ $\displaystyle\prec\frac{1}{\tau^{2}c_{\sigma,\tau}}\|g^{\tau}({\tilde{\theta}} _{T})-g^{\tau}(\theta^{*}_{T})\|_{(\hat{\Sigma}+\lambda I)^{-1}}.$ (36) $$

We add and subtract $g^{\tau}({\hat{\theta}}_{T})$ inside Equation 36, and apply triangle inequality to derive

$$ $\displaystyle\frac{1}{\tau^{2}c_{\sigma,\tau}}\|g^{\tau}({\tilde{\theta}}_{T})$ $\displaystyle-g^{\tau}(\theta^{*}_{T})\|_{(\hat{\Sigma}+\lambda I)^{-1}}$ $\displaystyle=\frac{1}{\tau^{2}c_{\sigma,\tau}}\|g^{\tau}({\tilde{\theta}}_{T} )-g^{\tau}({\hat{\theta}}_{T})+g^{\tau}({\hat{\theta}}_{T})-g^{\tau}(\theta^{* }_{T})\|_{(\hat{\Sigma}+\lambda I)^{-1}}$ $\displaystyle\leq\frac{1}{\tau^{2}c_{\sigma,\tau}}\left(\|g^{\tau}({\tilde{ \theta}}_{T})-g^{\tau}({\hat{\theta}}_{T})\|_{(\hat{\Sigma}+\lambda I)^{-1}}+ \|g^{\tau}({\hat{\theta}}_{T})-g^{\tau}(\theta^{*}_{T})\|_{(\hat{\Sigma}+ \lambda I)^{-1}}\right).$ (37) $$

We use the definition of ${\tilde{\theta}}_{T}$ from Equation 26 to derive $\|g^{\tau}({\tilde{\theta}}_{T})-g^{\tau}({\hat{\theta}}_{T})\|_{(\hat{\Sigma}
+\lambda I)^{-1}}\leq\|g^{\tau}({\hat{\theta}}_{T})-g^{\tau}(\theta^{*}_{T})\|
_{(\hat{\Sigma}+\lambda I)^{-1}}$ and get

$$ $\displaystyle\frac{1}{\tau^{2}c_{\sigma,\tau}}$ $\displaystyle\left(\|g^{\tau}({\tilde{\theta}}_{T})-g^{\tau}({\hat{\theta}}_{T })\|_{(\hat{\Sigma}+\lambda I)^{-1}}+\|g^{\tau}({\hat{\theta}}_{T})-g^{\tau}( \theta^{*}_{T})\|_{(\hat{\Sigma}+\lambda I)^{-1}}\right)$ $\displaystyle\leq\frac{2}{\tau^{2}c_{\sigma,\tau}}\|g^{\tau}({\hat{\theta}}_{T })-g^{\tau}(\theta^{*}_{T})\|_{(\hat{\Sigma}+\lambda I)^{-1}}.$ (38) $$

We remind the definition of ${\hat{\theta}}_{T}$, which minimises the gradient of the loss defined in Equation 25, making $\nabla\mathcal{L}^{\mathrm{NS}}({\hat{\theta}}_{T})=0$:

$$ $\displaystyle\nabla\mathcal{L}^{\mathrm{NS}}({\hat{\theta}}_{T})=\frac{1}{n} \sum_{i=1}^{n}\tau\gamma^{T-1-t_{i}}\Big{[}\sigma(\tau\langle\hat{\phi}_{i},{ \hat{\theta}}_{T}-{\theta_{\mathrm{ref}}}\rangle)-o_{i}\Big{]}\hat{\phi}_{i}+ \lambda c_{\sigma,\tau}\tau^{2}{\hat{\theta}}_{T}=0.$ (39) $$

We rearrange the terms in Equation 39 to derive $g^{\tau}({\hat{\theta}}_{T})$ on one side of the equation:

$$ $\displaystyle\underbrace{\frac{1}{n}\sum_{i=1}^{n}\tau\gamma^{T-1-t_{i}}\sigma (\tau\langle\hat{\phi}_{i},{\hat{\theta}}_{T}-{\theta_{\mathrm{ref}}}\rangle) \hat{\phi}_{i}+\lambda c_{\sigma,\tau}\tau^{2}{\hat{\theta}}_{T}}_{=g^{\tau}({ \hat{\theta}}_{T})}=\frac{1}{n}\sum_{i=1}^{n}\tau\gamma^{T-1-t_{i}}o_{i}\hat{ \phi}_{i}.$ (40) $$

We apply the result of Equation 40 to obtain

$$ $\displaystyle g^{\tau}({\hat{\theta}}_{T})-g^{\tau}(\theta^{*}_{T})$ $\displaystyle=\frac{1}{n}\sum_{i=1}^{n}\tau\gamma^{T-1-t_{i}}[o_{i}-\sigma(h_{ \theta^{*}_{T}}(x_{i},a_{i},a^{\prime}_{i}))]\hat{\phi}_{i}-\lambda c_{\sigma, \tau}\tau^{2}\theta^{*}_{T}.$ (41) $$

Using the fact that the preference label $o_{i}$ is obtained from the optimal parameter at time step $t_{i}$, we define $\epsilon_{i}=o_{i}-\sigma(\tau\langle\hat{\phi}_{i},\theta^{*}_{t_{i}}-{\theta
_{\mathrm{ref}}}\rangle)$, and use $o_{i}=\epsilon_{i}+\sigma(\tau\langle\hat{\phi}_{i},\theta^{*}_{t_{i}}-{\theta
_{\mathrm{ref}}}\rangle)$ to get

$$ $\displaystyle\frac{1}{n}\sum_{i=1}^{n}$ $\displaystyle\tau\gamma^{T-1-t_{i}}[o_{i}-\sigma(h_{\theta^{*}_{T}}(x_{i},a_{i },a^{\prime}_{i}))]\hat{\phi}_{i}-\lambda c_{\sigma,\tau}\tau^{2}\theta^{*}_{T}$ $\displaystyle=\frac{1}{n}\sum_{i=1}^{n}\tau\gamma^{T-1-t_{i}}[\epsilon_{i}+ \sigma(\tau\langle\hat{\phi}_{i},\theta^{*}_{t_{i}}-{\theta_{\mathrm{ref}}} \rangle)-\sigma(h_{\theta^{*}_{T}}(x_{i},a_{i},a^{\prime}_{i}))]\hat{\phi}_{i} -\lambda c_{\sigma,\tau}\tau^{2}\theta^{*}_{T}$ $\displaystyle=\underbrace{\frac{1}{n}\sum_{i=1}^{n}\tau\gamma^{T-1-t_{i}}[ \sigma(\tau\langle\hat{\phi}_{i},\theta^{*}_{t_{i}}-{\theta_{\mathrm{ref}}} \rangle)-\sigma(h_{\theta^{*}_{T}}(x_{i},a_{i},a^{\prime}_{i}))]\hat{\phi}_{i} }_{\text{tracking}}$ $\displaystyle\quad+\underbrace{\frac{1}{n}\sum_{i=1}^{n}\tau\gamma^{T-1-t_{i}} \epsilon_{i}\hat{\phi}_{i}-\lambda c_{\sigma,\tau}\tau^{2}\theta^{*}_{T}}_{ \text{learning}}.$ (42) $$

We use terms in Equation 42 with Equation 38 to define learning error and tracking error:

$$ $\displaystyle\xi^{\mathrm{learn}}$ $\displaystyle=\frac{2}{\tau^{2}c_{\sigma,\tau}}\|\frac{1}{n}\sum_{i=1}^{n}\tau \gamma^{T-1-t_{i}}\epsilon_{i}\hat{\phi}_{i}-\lambda c_{\sigma,\tau}\tau^{2} \theta^{*}_{T}\|_{(\hat{\Sigma}+\lambda I)^{-1}}$ (43) $\displaystyle\xi^{\mathrm{track}}$ $\displaystyle=\frac{2}{\tau^{2}c_{\sigma,\tau}}\|\frac{1}{n}\sum_{i=1}^{n}\tau \gamma^{T-1-t_{i}}[\sigma(\tau\langle\hat{\phi}_{i},\theta^{*}_{t_{i}}-{\theta _{\mathrm{ref}}}\rangle)-\sigma(h_{\theta^{*}_{T}}(x_{i},a_{i},a^{\prime}_{i}) )]\hat{\phi}_{i}\|_{(\hat{\Sigma}+\lambda I)^{-1}}.$ (44) $$

Bounding each of Equation 43 and Equation 44 results in Theorem C.1. The detailed bounds for the tracking and learning terms are provided in Section C.1.2 and Section C.1.3 respectively.

#### C.1.2 Confidence Sets: Learning

We begin with the definition of the learning error:

$$ $\displaystyle\xi^{\mathrm{learn}}$ $\displaystyle=\frac{2}{\tau^{2}c_{\sigma,\tau}}\|\frac{1}{n}\sum_{i=1}^{n}\tau \gamma^{T-1-t_{i}}\epsilon_{i}\hat{\phi}_{i}-\lambda c_{\sigma,\tau}\tau^{2} \theta^{*}_{T}\|_{(\hat{\Sigma}+\lambda I)^{-1}}.$ (45) $$

We bound the norm of Equation 45 with respect to $\tilde{\Sigma}+\lambda I$, using the fact that $\hat{\Sigma}\succ\tilde{\Sigma}$ and $\tilde{\Sigma}+\lambda I\succeq\lambda I$:

$$ $\displaystyle\Big{\|}\frac{1}{n}\sum_{i=1}^{n}\tau\gamma^{T-1-t_{i}}\epsilon_{ i}\hat{\phi}_{i}$ $\displaystyle-\lambda c_{\sigma,\tau}\tau^{2}\theta^{*}_{T}\Big{\|}_{(\hat{ \Sigma}+\lambda I)^{-1}}$ $\displaystyle\leq\Big{\|}\frac{1}{n}\sum_{i=1}^{n}\tau\gamma^{T-1-t_{i}} \epsilon_{i}\hat{\phi}_{i}-\lambda c_{\sigma,\tau}\tau^{2}\theta^{*}_{T}\Big{ \|}_{(\tilde{\Sigma}+\lambda I)^{-1}}$ $\displaystyle\leq\|\lambda c_{\sigma,\tau}\tau^{2}\theta^{*}_{T}\|_{(\lambda I )^{-1}}+\Big{\|}\frac{1}{n}\sum_{i=1}^{n}\tau\gamma^{T-1-t_{i}}\epsilon_{i} \hat{\phi}_{i}\Big{\|}_{(\tilde{\Sigma}+\lambda I)^{-1}}$ $\displaystyle\leq\tau^{2}\sqrt{\lambda}c_{\sigma,\tau}W+\Big{\|}\frac{1}{n} \sum_{i=1}^{n}\tau\gamma^{T-1-t_{i}}\epsilon_{i}\hat{\phi}_{i}\Big{\|}_{( \tilde{\Sigma}+\lambda I)^{-1}}.$ (46) $$

We can use the $\epsilon_{i}$’s property of being a sub-Gaussian random variable, sampled i.i.d. during the creation of the dataset. We apply Theorem 2.1 of (Hsu et al., ) to Equation 46, resulting in a bound holding with probability at least $1-\delta$:

$$ $\displaystyle\Big{\|}\frac{1}{n}\sum_{i=1}^{n}\tau\gamma^{T-1-t_{i}}\epsilon_{ i}\hat{\phi}_{i}\Big{\|}_{(\tilde{\Sigma}+\lambda I)^{-1}}$ $\displaystyle\leq\tau C_{1}\sqrt{\frac{d+\log(1/\delta)}{n}}=\beta_{T}(\delta),$ (47) $$

where $C_{1}$ denotes a constant introduced for bounding purpose. We provide the details of applying (Hsu et al., )’s theorem in Section C.3.

We now go back to the original definition of learning error term $\xi^{\mathrm{learn}}$ and bound it. We use the result in Equation 46 and Equation 47 to derive

$$ $\displaystyle\xi^{\mathrm{learn}}$ $\displaystyle=\frac{2}{\tau^{2}c_{\sigma,\tau}}\|\frac{1}{n}\sum_{i=1}^{n}\tau \gamma^{T-1-t_{i}}\epsilon_{i}\hat{\phi}_{i}-\lambda c_{\sigma,\tau}\tau^{2} \theta^{*}_{T}\|_{(\hat{\Sigma}+\lambda I)^{-1}}$ $\displaystyle=\frac{2}{\tau^{2}c_{\sigma,\tau}}\left(\tau^{2}\sqrt{\lambda}c_{ \sigma,\tau}W+\tau C_{1}\sqrt{\frac{d+\log(1/\delta)}{n}}\right)$ $\displaystyle=2\sqrt{\lambda}W+\frac{2C_{1}}{\tau c_{\sigma,\tau}}\sqrt{\frac{ d+\log(1/\delta)}{n}},$ (48) $$

which finishes the bounding of the learning error.

#### C.1.3 Estimation Error: Tracking

We begin with the definition of the tracking error:

$$ $\displaystyle\xi^{\mathrm{track}}$ $\displaystyle=\frac{2}{\tau^{2}c_{\sigma,\tau}}\Big{\|}\frac{1}{n}\sum_{i=1}^{ n}\tau\gamma^{T-1-t_{i}}[\sigma(\tau\langle\hat{\phi}_{i},\theta^{*}_{t_{i}}-{ \theta_{\mathrm{ref}}}\rangle)-\sigma(h_{\theta^{*}_{T}}(x_{i},a_{i},a^{\prime }_{i}))]\hat{\phi}_{i}\Big{\|}_{(\hat{\Sigma}+\lambda I)^{-1}}$ $\displaystyle=\frac{2}{\tau^{2}c_{\sigma,\tau}}\Big{\|}\frac{1}{n}\sum_{i=1}^{ n}\tau\gamma^{T-1-t_{i}}[\sigma(\tau\langle\hat{\phi}_{i},\theta^{*}_{t_{i}}-{ \theta_{\mathrm{ref}}}\rangle)-\sigma(\tau\langle\hat{\phi}_{i},\theta^{*}_{T} -{\theta_{\mathrm{ref}}}\rangle)]\hat{\phi}_{i}\Big{\|}_{(\hat{\Sigma}+\lambda I )^{-1}}.$ (49) $$

We remind that using Equation 32, $\alpha(i,\theta^{*}_{t_{i}},\theta^{*}_{T})$ is

$$ $\displaystyle\alpha(i,\theta^{*}_{t_{i}},\theta^{*}_{T})$ $\displaystyle:=\int_{v=0}^{1}\dot{\sigma}(\tau\langle\hat{\phi}_{i},(1-v) \theta^{*}_{T}+v\theta^{*}_{t_{i}}\rangle)dv.$ (50) $$

Applying the man value theorem to Equation 49, we obtain

$$ $\displaystyle\frac{2}{\tau^{2}c_{\sigma,\tau}}\Big{\|}\frac{1}{n}\sum_{i=1}^{n}$ $\displaystyle\tau\gamma^{T-1-t_{i}}[\sigma(\tau\langle\hat{\phi}_{i},\theta^{* }_{t_{i}}-{\theta_{\mathrm{ref}}}\rangle)-\sigma(\tau\langle\hat{\phi}_{i}, \theta^{*}_{T}-{\theta_{\mathrm{ref}}}\rangle)]\hat{\phi}_{i}\Big{\|}_{(\hat{ \Sigma}+\lambda I)^{-1}}$ $\displaystyle=\frac{2}{\tau^{2}c_{\sigma,\tau}}\Big{\|}\frac{1}{n}\sum_{i=1}^{ n}\tau^{2}\gamma^{T-1-t_{i}}\alpha(i,\theta^{*}_{t_{i}},\theta^{*}_{T})\hat{ \phi}_{i}\hat{\phi}_{i}^{\intercal}(\theta^{*}_{t_{i}}-\theta^{*}_{T})\Big{\|} _{(\hat{\Sigma}+\lambda I)^{-1}}.$ (51) $$

We apply telescopic sum, which separates $\theta^{*}_{t_{i}}-\theta^{*}_{T}$ into differences of the optimal parameters between each datapoint:

$$ $\displaystyle\Big{\|}\frac{1}{n}\sum_{i=1}^{n}\tau^{2}\gamma^{T-1-t_{i}}\alpha (i,\theta^{*}_{t_{i}},\theta^{*}_{T})$ $\displaystyle\hat{\phi}_{i}\hat{\phi}_{i}^{\intercal}(\theta^{*}_{t_{i}}- \theta^{*}_{T})\Big{\|}_{(\hat{\Sigma}+\lambda I)^{-1}}$ $\displaystyle=\Big{\|}\frac{1}{n}\sum_{i=1}^{n}\tau^{2}\gamma^{T-1-t_{i}} \alpha(i,\theta^{*}_{t_{i}},\theta^{*}_{T})\hat{\phi}_{i}\hat{\phi}_{i}^{ \intercal}\Big{(}\sum_{p=i}^{n}(\theta^{*}_{t_{p}}-\theta^{*}_{t_{p+1}})\Big{) }\Big{\|}_{(\hat{\Sigma}+\lambda I)^{-1}},$ (52) $$

where we use $t_{n+1}$ to denote $T$.

Then we use $\sum_{i=k}^{n}\sum_{j=i}^{n}a_{i,j}=\sum_{j=k}^{n}\sum_{i=k}^{j}a_{i,j}$ to rearrange the terms inside the summation:

$$ $\displaystyle\Big{\|}\frac{1}{n}\sum_{i=1}^{n}$ $\displaystyle\tau^{2}\gamma^{T-1-t_{i}}\alpha(i,\theta^{*}_{t_{i}},\theta^{*}_ {T})\hat{\phi}_{i}\hat{\phi}_{i}^{\intercal}\Big{(}\sum_{p=i}^{n}(\theta^{*}_{ t_{p}}-\theta^{*}_{t_{p+1}})\Big{)}\Big{\|}_{(\hat{\Sigma}+\lambda I)^{-1}}$ $\displaystyle=\Big{\|}\sum_{p=1}^{n}\frac{1}{n}\sum_{i=1}^{p}\tau^{2}\gamma^{T -1-t_{i}}\alpha(i,\theta^{*}_{t_{i}},\theta^{*}_{T})\hat{\phi}_{i}\hat{\phi}_{ i}^{\intercal}(\theta^{*}_{t_{p}}-\theta^{*}_{t_{p+1}})\Big{\|}_{(\hat{\Sigma} +\lambda I)^{-1}}.$ (53) $$

We use $\alpha(i,\theta^{*}_{t_{i}},\theta^{*}_{T})\leq k_{\sigma,\tau}$ using the definition of $\alpha_{i}$ in Equation 32 to get

$$ $\displaystyle\Big{\|}\sum_{p=1}^{n}$ $\displaystyle\frac{1}{n}\sum_{i=1}^{p}\tau^{2}\gamma^{T-1-t_{i}}\alpha(i, \theta^{*}_{t_{i}},\theta^{*}_{T})\hat{\phi}_{i}\hat{\phi}_{i}^{\intercal}( \theta^{*}_{t_{p}}-\theta^{*}_{t_{p+1}})\Big{\|}_{(\hat{\Sigma}+\lambda I)^{-1}}$ $\displaystyle\leq\tau^{2}k_{\sigma,\tau}\Big{\|}\sum_{p=1}^{n}\frac{1}{n}\sum_ {i=1}^{p}\gamma^{T-1-t_{i}}\hat{\phi}_{i}\hat{\phi}_{i}^{\intercal}(\theta^{*} _{t_{p}}-\theta^{*}_{t_{p+1}})\Big{\|}_{(\hat{\Sigma}+\lambda I)^{-1}}.$ (54) $$

We then apply triangle inequality and Cauchy-Schwarz inequality to get

$$ $\displaystyle\tau^{2}k_{\sigma,\tau}$ $\displaystyle\Big{\|}\sum_{p=1}^{n}\frac{1}{n}\sum_{i=1}^{p}\gamma^{T-1-t_{i}} \hat{\phi}_{i}\hat{\phi}_{i}^{\intercal}(\theta^{*}_{t_{p}}-\theta^{*}_{t_{p+1 }})\Big{\|}_{(\hat{\Sigma}+\lambda I)^{-1}}$ $\displaystyle\leq\tau^{2}k_{\sigma,\tau}\sum_{p=1}^{n}\Big{\|}\frac{1}{n}\sum_ {i=1}^{p}\gamma^{T-1-t_{i}}\hat{\phi}_{i}\|\hat{\phi}_{i}^{\intercal}\|_{2}\| \theta^{*}_{t_{p}}-\theta^{*}_{t_{p+1}}\|_{2}\Big{\|}_{(\hat{\Sigma}+\lambda I )^{-1}}.$ (55) $$

We use $\|\hat{\phi}\|\leq 2L$ and arrange terms to obtain

$$ $\displaystyle\tau^{2}k_{\sigma,\tau}$ $\displaystyle\sum_{p=1}^{n}\Big{\|}\frac{1}{n}\sum_{i=1}^{p}\gamma^{T-1-t_{i}} \hat{\phi}_{i}\|\hat{\phi}_{i}^{\intercal}\|_{2}\|\theta^{*}_{t_{p}}-\theta^{* }_{t_{p+1}}\|_{2}\Big{\|}_{(\hat{\Sigma}+\lambda I)^{-1}}$ $\displaystyle\leq 2L\tau^{2}k_{\sigma,\tau}\sum_{p=1}^{n}\underbrace{\frac{1}{ n}\sum_{i=1}^{p}\gamma^{T-1-t_{i}}\|\hat{\phi}_{i}\|_{(\hat{\Sigma}+\lambda I) ^{-1}}}_{=v_{1}}\|\theta^{*}_{t_{p}}-\theta^{*}_{t_{p+1}}\|_{2}.$ (56) $$

Here we bound the term $v_{1}$. We first apply Jensen’s inequality to derive

$$ $\displaystyle v_{1}$ $\displaystyle\leq\sqrt{\frac{1}{n}\sum_{i=1}^{p}\gamma^{T-1-t_{i}}}\sqrt{\frac {1}{n}\sum_{i=1}^{p}\gamma^{T-1-t_{i}}\|\hat{\phi}_{i}\|^{2}_{(\hat{\Sigma}+ \lambda I)^{-1}}}$ $\displaystyle=\gamma^{\frac{T-1}{2}}\sqrt{\frac{1}{n}\sum_{i=1}^{p}\gamma^{-t_ {i}}}\sqrt{\frac{1}{n}\sum_{i=1}^{p}\gamma^{T-1-t_{i}}\|\hat{\phi}_{i}\|^{2}_{ (\hat{\Sigma}+\lambda I)^{-1}}}.$ (57) $$

We then use the property of trace operation and $\hat{\Sigma}\succ\sum_{i=1}^{p}\gamma^{T-1-t_{i}}\hat{\phi}_{i}\hat{\phi}_{i}^
{\intercal}$ from Equation 17 to get

$$ $\displaystyle\frac{1}{n}\sum_{i=1}^{p}\gamma^{T-1-t_{i}}\|\hat{\phi}_{i}\|^{2} _{(\hat{\Sigma}+\lambda I)^{-1}}$ $\displaystyle=\frac{1}{n}\sum_{i=1}^{p}\gamma^{T-1-t_{i}}\mathrm{tr}\left(\hat {\phi}_{i}^{\intercal}(\hat{\Sigma}+\lambda I)^{-1}\hat{\phi}_{i}\right)$ $\displaystyle=\mathrm{tr}\left((\hat{\Sigma}+\lambda I)^{-1}\frac{1}{n}\sum_{i =1}^{p}\gamma^{T-1-t_{i}}\hat{\phi}_{i}\hat{\phi}_{i}^{\intercal}\right)$ $\displaystyle\leq\mathrm{tr}\left(I_{d}\right)=d.$ (58) $$

We apply Assumption 4.5 here. Because each time step can have at maximum $\bar{m}$ datapoints, we can upper bound $\frac{1}{n}\sum_{i=1}^{p}\gamma^{-t_{i}}$ with

$$ $\displaystyle\frac{1}{n}\sum_{i=1}^{p}\gamma^{-t_{i}}$ $\displaystyle\leq\frac{\bar{m}}{n}\sum_{k=1}^{t}\gamma^{-k}=\frac{\bar{m} \gamma(\gamma^{-(t+1)}-1)}{n(1-\gamma)},$ (59) $$

where $t=\left\lceil\frac{|[p]|}{\bar{m}}\right\rceil$.
We combine Equation 58 and Equation 59 to obtain

$$ $\displaystyle 2L\tau^{2}k_{\sigma,\tau}$ $\displaystyle\sum_{p=1}^{n}\frac{1}{n}\sum_{i=1}^{p}\gamma^{T-1-t_{i}}\|\hat{ \phi}_{i}\|_{(\hat{\Sigma}+\lambda I)^{-1}}\|\theta^{*}_{t_{p}}-\theta^{*}_{t_ {p+1}}\|_{2}$ $\displaystyle\leq 2L\tau^{2}k_{\sigma,\tau}\sum_{p=1}^{n}\gamma^{\frac{T-1}{2} }\sqrt{\frac{d\bar{m}\gamma(\gamma^{-(t+1)}-1)}{n(1-\gamma)}}\|\theta^{*}_{t_{ p}}-\theta^{*}_{t_{p+1}}\|_{2}.$ (60) $$

We apply Assumption 4.5 again to upper bound the summation as $\sum_{p=1}^{n}v_{p}\leq\bar{m}\sum_{t=1}^{T-1}v_{t}$, getting

$$ $\displaystyle 2L\tau^{2}k_{\sigma,\tau}$ $\displaystyle\sum_{p=1}^{n}\gamma^{\frac{T-1}{2}}\sqrt{\frac{d\bar{m}\gamma( \gamma^{-(t+1)}-1)}{n(1-\gamma)}}\|\theta^{*}_{t_{p}}-\theta^{*}_{t_{p+1}}\|_{2}$ $\displaystyle\leq 2L\tau^{2}k_{\sigma,\tau}\bar{m}\sum_{t=1}^{T-1}\gamma^{ \frac{T-1}{2}}\sqrt{\frac{d\bar{m}\gamma(\gamma^{-(t+1)}-1)}{n(1-\gamma)}}\| \theta^{*}_{t}-\theta^{*}_{t+1}\|_{2}.$ (61) $$

We apply $v=\frac{1}{T}\sum_{k=1}^{T}v$ to introduce another summation:

$$ $\displaystyle 2L\tau^{2}k_{\sigma,\tau}\bar{m}$ $\displaystyle\sum_{t=1}^{T-1}\gamma^{\frac{T-1}{2}}\sqrt{\frac{d\bar{m}\gamma( \gamma^{-(t+1)}-1)}{n(1-\gamma)}}\|\theta^{*}_{t}-\theta^{*}_{t+1}\|_{2}$ $\displaystyle=\frac{2L\tau^{2}k_{\sigma,\tau}\bar{m}}{T}\sum_{k=1}^{T}\sum_{t= 1}^{T-1}\gamma^{\frac{T-1}{2}}\sqrt{\frac{d\bar{m}\gamma(\gamma^{-(t+1)}-1)}{n (1-\gamma)}}\|\theta^{*}_{t}-\theta^{*}_{t+1}\|_{2}.$ (62) $$

Because $\gamma<1$, we can bound

$$ $\sum_{k=1}^{T}\sum_{t=1}^{T-1}\gamma^{\frac{T-1}{2}}\sqrt{\frac{d\bar{m}\gamma (\gamma^{-(t+1)}-1)}{n(1-\gamma)}}\leq 2\sum_{t=1}^{T-1}\sum_{k=t+1}^{T}\gamma ^{\frac{k-1}{2}}\sqrt{\frac{d\bar{m}\gamma(\gamma^{-(t+1)}-1)}{n(1-\gamma)}}$ (63) $$

and apply geometric sum to obtain

$$ $2\sum_{t=1}^{T-1}\sum_{k=t+1}^{T}\gamma^{\frac{k-1}{2}}\sqrt{\frac{d\bar{m} \gamma(\gamma^{-(t+1)}-1)}{n(1-\gamma)}}=2\sum_{t=1}^{T-1}\frac{\gamma^{\tfrac {t}{2}}-\gamma^{\tfrac{T}{2}}}{1-\gamma^{\tfrac{1}{2}}}\sqrt{\frac{d\bar{m} \gamma(\gamma^{-(t+1)}-1)}{n(1-\gamma)}}.$ (64) $$

We use $\gamma<1$ again to derive $\frac{1+\gamma^{\tfrac{1}{2}}}{2}<1$, and get

$$ $\displaystyle 2\sum_{t=1}^{T-1}\frac{\gamma^{\tfrac{t}{2}}-\gamma^{\tfrac{T}{2 }}}{1-\gamma^{\tfrac{1}{2}}}\sqrt{\frac{d\bar{m}\gamma(\gamma^{-(t+1)}-1)}{n(1 -\gamma)}}$ $\displaystyle\leq 2\sum_{t=1}^{T-1}\frac{\gamma^{\tfrac{t}{2}}-\gamma^{\tfrac{ T}{2}}}{1-\gamma^{\tfrac{1}{2}}\frac{1+\gamma^{\tfrac{1}{2}}}{2}}\sqrt{\frac{d \bar{m}\gamma(\gamma^{-(t+1)}-1)}{n(1-\gamma)}}$ $\displaystyle=4\sum_{t=1}^{T-1}\frac{\gamma^{\tfrac{t}{2}}-\gamma^{\tfrac{T}{2 }}}{1-\gamma}\sqrt{\frac{d\bar{m}\gamma(\gamma^{-(t+1)}-1)}{n(1-\gamma)}}.$ (65) $$

We then use $\left(\gamma^{\tfrac{t}{2}}-\gamma^{\tfrac{T}{2}}\right)\sqrt{\gamma(\gamma^{-
(t+1)}-1)}\leq\gamma^{\tfrac{t}{2}}\gamma^{-\tfrac{t}{2}}=1$ to derive

$$ $4\sum_{t=1}^{T-1}\frac{\gamma^{\tfrac{t}{2}}-\gamma^{\tfrac{T}{2}}}{1-\gamma} \sqrt{\frac{d\bar{m}\gamma(\gamma^{-(t+1)}-1)}{n(1-\gamma)}}\leq 4\sqrt{\frac{ d\bar{m}}{n}}\sum_{t=1}^{T-1}\frac{1}{(1-\gamma)^{\tfrac{3}{2}}}.$ (66) $$

We use the result from Equation 66 to Equation 62, and use the definition of variation budget $B_{T}$ from Assumption 4.3 to get

$$ $\displaystyle\frac{2L\tau^{2}k_{\sigma,\tau}\bar{m}}{T}$ $\displaystyle\sum_{k=1}^{T}\sum_{t=1}^{T-1}\gamma^{\frac{T-1}{2}}\sqrt{\frac{d \bar{m}\gamma(\gamma^{-(t+1)}-1)}{n(1-\gamma)}}\|\theta^{*}_{t}-\theta^{*}_{t+ 1}\|_{2}$ $\displaystyle\leq\frac{8L\tau^{2}k_{\sigma,\tau}\bar{m}}{T}\sqrt{\frac{d\bar{m }}{n}}\sum_{t=1}^{T-1}\frac{1}{(1-\gamma)^{\tfrac{3}{2}}}\|\theta^{*}_{t}- \theta^{*}_{t+1}\|_{2}$ $\displaystyle\leq\frac{8L\tau^{2}k_{\sigma,\tau}\bar{m}}{T(1-\gamma)^{\tfrac{3 }{2}}}\sqrt{\frac{d\bar{m}}{n}}B_{T}.$ (67) $$

We now combine Equation 67 with Equation 44 to derive the full bound of the tracking error:

$$ $\displaystyle\xi^{\mathrm{track}}=\frac{16LR_{\sigma,\tau}\bar{m}}{T(1-\gamma) ^{\tfrac{3}{2}}}\sqrt{\frac{d\bar{m}}{n}}B_{T}.$ (68) $$

We now use Equation 68 with Equation 48 to obtain the full estimation error:

$$ $\displaystyle\|{\hat{\theta}}_{T}-{\hat{\theta}}^{*}_{T}\|_{\hat{\Sigma}+ \lambda I}$ $\displaystyle\leq\xi^{\mathrm{learn}}+\xi^{\mathrm{track}}$ $\displaystyle\leq 2\sqrt{\lambda}W+\frac{2C_{1}}{\tau c_{\sigma,\tau}}\sqrt{ \frac{d+\log(1/\delta)}{n}}+\frac{16LR_{\sigma,\tau}\bar{m}}{T(1-\gamma)^{ \tfrac{3}{2}}}\sqrt{\frac{d\bar{m}}{n}}B_{T},$ (69) $$

which concludes the analysis for Theorem C.1.

### C.2 Regret Bound

###### Theorem 4.1 .

(Regret bound of ${\tilde{\theta}}_{T}$) Let $\delta\in(0,\tfrac{1}{2}],\tau>0$ and $r^{*}_{T}(x,a)<r^{\mathrm{max}}\ \forall x\in\mathcal{X},a\in\mathcal{A}$.
Let ${\tilde{\theta}}_{T}$ denote the parameter in $\Theta$ which minimises the NS-DPO loss (Equation 24) on an offline dataset. When $\gamma=1-\left(\tfrac{B_{T}}{dT}\right)^{1/2}$, the following bound holds with probability at least $1-2\delta$:

$$ $\displaystyle R^{\mathrm{off}}_{T}\leq\frac{r^{\mathrm{max}}\sqrt{\bar{m}T(1- \gamma)\kappa}}{C_{2}\sqrt{2\macc@depth\char 1\relax\frozen@everymath{ \macc@group}\macc@set@skewchar\macc@nested@a 111{m}(1-\gamma^{T-1})}}$ $\displaystyle\Bigg{(}2\sqrt{\lambda}W+\frac{2C_{1}}{\tau c_{\sigma,\tau}}\sqrt {\frac{d+\log(1/\delta)}{n}}+\frac{16LR_{\sigma,\tau}\bar{m}}{T(1-\gamma)^{ \tfrac{3}{2}}}\sqrt{\frac{d\bar{m}}{n}}B_{T}\Bigg{)},$ $$

where $C_{1}>0$ and $0<C_{2}<1$ denote constants. In other words, when $\lambda=O\left(\frac{d}{n}\right)$, $R^{\mathrm{off}}_{T}$ satisfies:

$$ $\displaystyle R^{\mathrm{off}}_{T}=\tilde{O}\left(d\ B_{T}^{1/2}n^{-1/4}\right).$ $$

###### Theorem 4.1 .

#### C.2.1 Population Covariance of Feature Differences

Let $\Sigma_{{\pi_{\mathrm{ref}}},\mathrm{diff}}$ define the population covariance matrix of the feature differences:

$$ $\Sigma_{{\pi_{\mathrm{ref}}},\mathrm{diff}}=\mathbb{E}[\hat{\phi}\hat{\phi}^{ \intercal}],$ (70) $$

where $\hat{\phi}=\phi(x,a)-\phi(x,a^{\prime})$ denotes the feature difference vector, and the expectation is computed with respect to ${x\sim\mathcal{X},t\sim\mathcal{T},a,a^{\prime}\sim{\pi_{\mathrm{ref}}}(\cdot|
x)}$. We also define the discounted population covariance matrix $\Sigma^{\gamma}_{{\pi_{\mathrm{ref}}},\mathrm{diff}}$:

$$ $\Sigma^{\gamma}_{{\pi_{\mathrm{ref}}},\mathrm{diff}}=\mathbb{E}[\gamma^{T-1-t} \hat{\phi}\hat{\phi}^{\intercal}],$ (71) $$

where the expectation is computed with respect to the same distributions as $\Sigma_{{\pi_{\mathrm{ref}}},\mathrm{diff}}$.

We then define $\omega^{\mathrm{upp}}(T,\gamma)$:

$$ $\displaystyle\omega^{\mathrm{upp}}(T,\gamma)=\sup_{v\in\mathbb{R}^{d}}\frac{v^ {\intercal}\Sigma_{{\pi_{\mathrm{ref}}},\mathrm{diff}}v}{v^{\intercal}\Sigma^{ \gamma}_{{\pi_{\mathrm{ref}}},\mathrm{diff}}v},$ (72) $$

Without any assumptions on the time distribution, $\omega^{\mathrm{upp}}(T,\gamma)\leq\gamma^{-(T-1)}$, which happens when all the datapoints come from the oldest time step.
We use Assumption 4.5 to obtain a tighter upper bound of $\omega^{\mathrm{upp}}$. Using $\macc@depth\char 1\relax\frozen@everymath{\macc@group}\macc@set@skewchar
\macc@nested@a 111{m}(T-1)\leq n\leq\bar{m}(T-1)$, we can get

$$ $\displaystyle\frac{1}{n}\sum_{i=1}^{n}\gamma^{T-1-t_{i}}\geq\frac{\macc@depth \char 1\relax\frozen@everymath{\macc@group}\macc@set@skewchar\macc@nested@a 11 1{m}}{n}\cdot\sum_{t=1}^{T-1}\gamma^{T-1-t}\geq\frac{\macc@depth\char 1\relax \frozen@everymath{\macc@group}\macc@set@skewchar\macc@nested@a 111{m}}{\bar{m} (T-1)}\cdot\sum_{t=1}^{T-1}\gamma^{T-1-t}.$ (73) $$

We note that the prompt distribution $\mathcal{X}$ and the reference policy ${\pi_{\mathrm{ref}}}$ are independent from the time step distribution $\mathcal{T}$. Using Equation 73, we obtain

$$ $\displaystyle v^{\intercal}\Sigma^{\gamma}_{{\pi_{\mathrm{ref}}},\mathrm{diff}}v$ $\displaystyle\geq\left(\frac{\macc@depth\char 1\relax\frozen@everymath{ \macc@group}\macc@set@skewchar\macc@nested@a 111{m}}{\bar{m}(T-1)}\sum_{i=0}^{ T-2}\gamma^{i}\right)\cdot(v^{\intercal}\Sigma_{{\pi_{\mathrm{ref}}},\mathrm{ diff}}v)=\frac{\macc@depth\char 1\relax\frozen@everymath{\macc@group} \macc@set@skewchar\macc@nested@a 111{m}(1-\gamma^{T-1})}{\bar{m}(T-1)(1-\gamma )}\cdot(v^{\intercal}\Sigma_{{\pi_{\mathrm{ref}}},\mathrm{diff}}v),$ (74) $$

which implies $\omega^{\mathrm{upp}}(T,\gamma)\leq\frac{\bar{m}(T-1)(1-\gamma)}{\macc@depth
\char 1\relax\frozen@everymath{\macc@group}\macc@set@skewchar\macc@nested@a 11
1{m}(1-\gamma^{T-1})}$.

#### C.2.2 Decomposing Regret Bound

In order to decompose and bound the detailed elements of the regret bound, we first show the relation between the regret and the estimation error of the model parameters.

###### Theorem C.2 .

Let $\delta\in[0,1]$ and $r^{*}_{T}(x,a)<r^{\mathrm{max}}\ \forall x\in\mathcal{X},a\in\mathcal{A}$. Let ${\tilde{\theta}}_{T}$ denote the parameter obtained by performing the parameter projection in Appendix C, after training with the NS-DPO loss defined in Equation 24 on an offline dataset. When $\gamma=1-\left(\tfrac{B_{T}}{dT}\right)^{1/2}$, with probability at least $1-\delta$:

$$ $R^{\mathrm{off}}_{T}\leq\frac{r^{\mathrm{max}}\sqrt{\bar{m}T(1-\gamma)\kappa}} {C_{2}\sqrt{2\macc@depth\char 1\relax\frozen@everymath{\macc@group} \macc@set@skewchar\macc@nested@a 111{m}(1-\gamma^{T-1})}}\|{\tilde{\theta}}_{T }-\theta^{*}_{T}\|_{\hat{\Sigma}+\lambda I},$ (75) $$

where $0<C_{2}<1$ is a constant.

Let $\pi_{{\tilde{\theta}}_{T}}$ denote the policy we obtained by training with NS-DPO and performing parameter projection. We use $\Sigma_{\pi_{{\tilde{\theta}}}}$ to denote the population covariance matrix, whose expectation taken with respect to $\pi_{{\tilde{\theta}}}$. The initial part of the proof follows the derivation presented in the regret analysis of (Chowdhury et al., ), so we skip the intermediate steps and directly present Equation 76:

$$ $\displaystyle R^{\mathrm{off}}_{T}$ $\displaystyle\leq r^{\mathrm{max}}\|{\tilde{\theta}}_{T}-\theta^{*}_{T}\|_{ \Sigma_{\pi_{{\tilde{\theta}}_{T}}}}$ $\displaystyle(\text{Section A.5. of \cite[citep]{(\@@bibref{AuthorsPhrase1Year }{chowdhury2024provably}{\@@citephrase{, }}{})}}),$ (76) $$

where $r^{\mathrm{max}}$ refers to the maximum value of the reward.
We then convert the parameter difference norm into one using $\hat{\Sigma}+\lambda I$ defined in Equation 17:

$$ $\displaystyle r^{\mathrm{max}}\|{\tilde{\theta}}_{T}$ $\displaystyle-\theta^{*}_{T}\|_{\Sigma_{\pi_{{\tilde{\theta}}_{T}}}}\leq r^{ \mathrm{max}}\|{\tilde{\theta}}_{T}-\theta^{*}_{T}\|_{(\hat{\Sigma}+\lambda I) }\sqrt{\frac{({\tilde{\theta}}_{T}-\theta^{*}_{T})^{\intercal}\Sigma_{\pi_{{ \tilde{\theta}}_{T}}}({\tilde{\theta}}_{T}-\theta^{*}_{T})}{({\tilde{\theta}}_ {T}-\theta^{*}_{T})^{\intercal}(\hat{\Sigma}+\lambda I)({\tilde{\theta}}_{T}- \theta^{*}_{T})}}.$ (77) $$

We now use the following lemma from (Chowdhury et al., ), which relies on the matrix concentration inequality to explain the difference between $\hat{\Sigma}$ and $\Sigma^{\gamma}_{{\pi_{\mathrm{ref}}},\mathrm{diff}}$.

###### Lemma C.1 .

(Lemma A.1. of (Chowdhury et al., )) With probability at least $1-\delta$, for some universal constant C, we have

$$ $\|\hat{\Sigma}-\Sigma^{\gamma}_{{\pi_{\mathrm{ref}}},\mathrm{diff}}\|_{2}\leq C \sqrt{d\log(4d/\delta)/n}.$ (78) $$

We use the result of Lemma C.2 proved in Section C.4 with Lemma C.1 to obtain

$$ $\hat{\Sigma}\succeq C_{2}\Sigma^{\gamma}_{{\pi_{\mathrm{ref}}},\mathrm{diff}}$ (79) $$

for a constant $0<C_{2}<1$ and the discount weight $\gamma$ set to

$$ $\displaystyle\gamma$ $\displaystyle=1-\left(\frac{B_{T}}{dT}\right)^{1/2}.$ (80) $$

We use Equation 79 to derive

$$ $\displaystyle r^{\mathrm{max}}\|{\tilde{\theta}}_{T}-\theta^{*}_{T}\|_{(\hat{ \Sigma}+\lambda I)}$ $\displaystyle\sqrt{\frac{({\tilde{\theta}}_{T}-\theta^{*}_{T})^{\intercal} \Sigma_{\pi_{{\tilde{\theta}}_{T}}}({\tilde{\theta}}_{T}-\theta^{*}_{T})}{({ \tilde{\theta}}_{T}-\theta^{*}_{T})^{\intercal}(\hat{\Sigma}+\lambda I)({ \tilde{\theta}}_{T}-\theta^{*}_{T})}}$ $\displaystyle\leq\frac{r^{\mathrm{max}}}{C_{2}}\|{\tilde{\theta}}_{T}-\theta^{ *}_{T}\|_{(\hat{\Sigma}+\lambda I)}\sqrt{\frac{({\tilde{\theta}}_{T}-\theta^{* }_{T})^{\intercal}\Sigma_{\pi_{{\tilde{\theta}}_{T}}}({\tilde{\theta}}_{T}- \theta^{*}_{T})}{({\tilde{\theta}}_{T}-\theta^{*}_{T})^{\intercal}(\Sigma^{ \gamma}_{{\pi_{\mathrm{ref}}},\mathrm{diff}})({\tilde{\theta}}_{T}-\theta^{*}_ {T})}}.$ (81) $$

We then apply the result from Equation 72 which implies $(\|v\|_{\Sigma^{\gamma}_{{\pi_{\mathrm{ref}}},\mathrm{diff}}})^{-1}\leq\sqrt{
\omega^{\mathrm{upp}}(T,\gamma)}(\|v\|_{\Sigma_{{\pi_{\mathrm{ref}}},\mathrm{
diff}}})^{-1}$:

$$ $\displaystyle\frac{r^{\mathrm{max}}}{C_{2}}\|{\tilde{\theta}}_{T}-\theta^{*}_{ T}\|_{(\hat{\Sigma}+\lambda I)}$ $\displaystyle\sqrt{\frac{({\tilde{\theta}}_{T}-\theta^{*}_{T})^{\intercal} \Sigma_{\pi_{{\tilde{\theta}}_{T}}}({\tilde{\theta}}_{T}-\theta^{*}_{T})}{({ \tilde{\theta}}_{T}-\theta^{*}_{T})^{\intercal}(\Sigma^{\gamma}_{{\pi_{\mathrm {ref}}},\mathrm{diff}})({\tilde{\theta}}_{T}-\theta^{*}_{T})}}$ $\displaystyle\leq\frac{r^{\mathrm{max}}\sqrt{\omega^{\mathrm{upp}}(T,\gamma)}} {C_{2}}\|{\tilde{\theta}}_{T}-\theta^{*}_{T}\|_{(\hat{\Sigma}+\lambda I)}\sqrt {\frac{({\tilde{\theta}}_{T}-\theta^{*}_{T})^{\intercal}\Sigma_{\pi_{{\tilde{ \theta}}_{T}}}({\tilde{\theta}}_{T}-\theta^{*}_{T})}{({\tilde{\theta}}_{T}- \theta^{*}_{T})^{\intercal}(\Sigma_{{\pi_{\mathrm{ref}}},\mathrm{diff}})({ \tilde{\theta}}_{T}-\theta^{*}_{T})}}.$ (82) $$

From the definition of $\Sigma_{{\pi_{\mathrm{ref}}},\mathrm{diff}}$ in Equation 70, $a,a^{\prime}$ are independently sampled. We combine this fact with the population covariance matrix $\Sigma_{{\pi_{\mathrm{ref}}}}$, deriving $\Sigma_{{\pi_{\mathrm{ref}}},\mathrm{diff}}=2\Sigma_{{\pi_{\mathrm{ref}}}}$. We use this to get

$$ $\displaystyle\frac{r^{\mathrm{max}}\sqrt{\omega^{\mathrm{upp}}(T,\gamma)}}{C_{ 2}}\|{\tilde{\theta}}_{T}-\theta^{*}_{T}\|_{(\hat{\Sigma}+\lambda I)}$ $\displaystyle\sqrt{\frac{({\tilde{\theta}}_{T}-\theta^{*}_{T})^{\intercal} \Sigma_{\pi_{{\tilde{\theta}}_{T}}}({\tilde{\theta}}_{T}-\theta^{*}_{T})}{({ \tilde{\theta}}_{T}-\theta^{*}_{T})^{\intercal}(\Sigma_{{\pi_{\mathrm{ref}}}, \mathrm{diff}})({\tilde{\theta}}_{T}-\theta^{*}_{T})}}$ $\displaystyle\leq\frac{r^{\mathrm{max}}\sqrt{\omega^{\mathrm{upp}}(T,\gamma)}} {C_{2}\sqrt{2}}\|{\tilde{\theta}}_{T}-\theta^{*}_{T}\|_{(\hat{\Sigma}+\lambda I )}\sqrt{\frac{({\tilde{\theta}}_{T}-\theta^{*}_{T})^{\intercal}\Sigma_{\pi_{{ \tilde{\theta}}_{T}}}({\tilde{\theta}}_{T}-\theta^{*}_{T})}{({\tilde{\theta}}_ {T}-\theta^{*}_{T})^{\intercal}\Sigma_{{\pi_{\mathrm{ref}}}}({\tilde{\theta}}_ {T}-\theta^{*}_{T})}}.$ (83) $$

We use $\kappa=\max_{\pi\in\Pi}\kappa_{\pi}$ with the definition of $\kappa_{\pi}$ in Equation 16, along with the result obtained in Equation 74 to use $\omega^{\mathrm{upp}}(T,\gamma)=\frac{(T-1)(1-\gamma)}{1-\gamma^{T-1}}\leq
\frac{T(1-\gamma)}{1-\gamma^{T-1}}$:

$$ $\displaystyle\frac{r^{\mathrm{max}}\sqrt{\omega^{\mathrm{upp}}(T,\gamma)}}{C_{ 2}\sqrt{2}}$ $\displaystyle\|{\tilde{\theta}}_{T}-\theta^{*}_{T}\|_{(\hat{\Sigma}+\lambda I) }\sqrt{\frac{({\tilde{\theta}}_{T}-\theta^{*}_{T})^{\intercal}\Sigma_{\pi_{{ \tilde{\theta}}_{T}}}({\tilde{\theta}}_{T}-\theta^{*}_{T})}{({\tilde{\theta}}_ {T}-\theta^{*}_{T})^{\intercal}\Sigma_{{\pi_{\mathrm{ref}}}}({\tilde{\theta}}_ {T}-\theta^{*}_{T})}}$ $\displaystyle\leq\frac{r^{\mathrm{max}}\sqrt{\omega^{\mathrm{upp}}(T,\gamma) \kappa}}{C_{2}\sqrt{2}}\|{\tilde{\theta}}_{T}-\theta^{*}_{T}\|_{(\hat{\Sigma}+ \lambda I)}$ $\displaystyle\leq\frac{r^{\mathrm{max}}\sqrt{\bar{m}T(1-\gamma)\kappa}}{C_{2} \sqrt{2\macc@depth\char 1\relax\frozen@everymath{\macc@group} \macc@set@skewchar\macc@nested@a 111{m}(1-\gamma^{T-1})}}\|{\tilde{\theta}}_{T }-\theta^{*}_{T}\|_{(\hat{\Sigma}+\lambda I)}.$ (84) $$

###### Theorem C.2 .

###### Lemma C.1 .

#### C.2.3 Complexity Analysis

In order to investigate the complexity of the regret bound, we set the value of $\gamma$ using $d,T,B_{T}$. We first set $\gamma$ as

$$ $\displaystyle\gamma$ $\displaystyle=1-\left(\frac{B_{T}}{dT}\right)^{1/2}.$ $$

We apply $(1-\gamma)$ to each term in the estimation error, with assumption of $\lambda=O\left(\frac{d}{n}\right)$ from Lemma C.1, while ignoring the logarithmic factor:

$$ $\displaystyle 2\sqrt{\lambda}W$ $\displaystyle(=d^{\tfrac{1}{2}}\ n^{-\tfrac{1}{2}})$ $\displaystyle\frac{2C_{1}}{\tau c_{\sigma,\tau}}\sqrt{\frac{d+\log(1/\delta)}{ n}}$ $\displaystyle(=d^{\tfrac{1}{2}}\ n^{-\tfrac{1}{2}})$ $\displaystyle\frac{16LR_{\sigma,\tau}\bar{m}}{T(1-\gamma)^{\tfrac{3}{2}}}\sqrt {\frac{d\bar{m}}{n}}B_{T}$ $\displaystyle(=d^{\tfrac{5}{4}}\ B_{T}^{\tfrac{1}{4}}\ T^{-\tfrac{3}{4}})$ (85) $$

Here, we note that from Assumption 4.5, $n=\Theta(T)$. This allows us to consider the complexity with respect to the dataset size $n$ and $T$ together. We can conclude from Equation 85 that the complexity bound of the entire estimation error is $O(d^{\tfrac{5}{4}}\ B_{T}^{\tfrac{1}{4}}\ T^{-\tfrac{1}{2}})$.
By setting the value of $T$ to a sufficiently large one, making $1-\gamma^{T-1}\geq\tfrac{1}{2}$, then the complexity bound of $\sqrt{\omega^{\mathrm{upp}}(T,\gamma)}$ is

$$ $\displaystyle\sqrt{T(1-\gamma)}$ $\displaystyle(=d^{-\tfrac{1}{4}}\ B_{T}^{\tfrac{1}{4}}\ T^{\tfrac{1}{4}}).$ (86) $$

Finally we present the total complexity bound of the algorithm, by applying the complexity of $\sqrt{\omega^{\mathrm{upp}}(T,\gamma)}$ in Equation 86 to each of the estimation error term:

$$ $\displaystyle R^{\mathrm{off}}_{T}=O(d\ B_{T}^{\tfrac{1}{2}}\ T^{-\tfrac{1}{4}})$ $\displaystyle=O(d\ B_{T}^{\tfrac{1}{2}}\ n^{-\tfrac{1}{4}}).$ (87) $$

### C.3 Details of applying Bernstein’s inequality

We restate the norm to investigate:

$$ $\|\frac{1}{n}\sum_{i=1}^{n}\tau\gamma^{T-1-t_{i}}\epsilon_{i}\hat{\phi}_{i}\|_ {(\tilde{\Sigma}+\lambda I)^{-1}}.$ (88) $$

We then define two vectors $V$ and $Z$, followed by a matrix $M$:

$$ $\displaystyle V$ $\displaystyle=[\epsilon_{1},\ldots,\epsilon_{n}],$ (89) $\displaystyle Z$ $\displaystyle=[\gamma^{T-1-t_{1}}\hat{\phi}_{1},\ldots,\gamma^{T-1-t_{n}}\hat{ \phi}_{n}],$ (90) $\displaystyle M$ $\displaystyle=\frac{1}{n^{2}}Z(\tilde{\Sigma}+\lambda I)^{-1}Z^{\intercal}.$ (91) $$

We then express Equation 88 using $V,Z,M$:

$$ $\displaystyle\|\frac{1}{n}\sum_{i=1}^{n}\tau\gamma^{T-1-t_{i}}\epsilon_{i}\hat {\phi}_{i}\|_{(\tilde{\Sigma}+\lambda I)^{-1}}$ $\displaystyle=\sqrt{\tau^{2}V^{\intercal}MV}.$ (92) $$

We here recall the definition of $\epsilon_{i}$, which is a 1-sub-Gaussian random variable:

$$ $\displaystyle\epsilon_{i}$ $\displaystyle=o_{i}-\sigma(\tau\langle\hat{\phi}_{i},\theta^{*}_{t_{i}}-{ \theta_{\mathrm{ref}}}\rangle),$ $\displaystyle\mathbb{E}_{o_{i}\sim p_{t_{i}}(a_{i}\succ a^{\prime}_{i}|x_{i})} [\epsilon_{i}]$ $\displaystyle=0,$ (93) $\displaystyle\mathrm{Var}_{o_{i}\sim p_{t_{i}}(a_{i}\succ a^{\prime}_{i}|x_{i} )}[\epsilon_{i}]$ $\displaystyle=\mathbb{E}_{o_{i}\sim p_{t_{i}}(a_{i}\succ a^{\prime}_{i}|x_{i}) }[\epsilon_{i}^{2}]-(\mathbb{E}_{o_{i}\sim p_{t_{i}}(a_{i}\succ a^{\prime}_{i} |x_{i})}[\epsilon_{i}])^{2}\leq 1.$ (94) $$

As stated in (Hsu et al., ), the Bernstein’s inequality for sub-Gaussian random variables in quadratic form implies

$$ $\displaystyle\tau^{2}V^{\intercal}MV$ $\displaystyle\leq\tau^{2}\left(\text{tr}(M)+2\sqrt{\text{tr}(M^{\intercal}M) \log(1/\delta)}+2\|M\|\log(1/\delta)\right)$ $\displaystyle\leq\tau^{2}\cdot C_{1}\cdot\frac{d+\log(1/\delta)}{n},$ (95) $$

for some $C_{1}>0$, while $\|M\|=\lambda_{\mathrm{max}}(M)$. Here we used the definition of $\tilde{\Sigma}$ in Equation 17 to show $\tilde{\Sigma}=\frac{1}{n}Z^{\intercal}Z$, and derive for $\lambda>0$

$$ $\displaystyle M$ $\displaystyle\prec\frac{1}{n^{2}}Z(\tilde{\Sigma})^{-1}Z^{\intercal}=\frac{1}{ n}I,$ (96) $\displaystyle\text{tr}(M)$ $\displaystyle\leq d/n,$ (97) $\displaystyle\text{tr}(M^{\intercal}M)$ $\displaystyle\leq d/n^{2},$ (98) $\displaystyle\|M\|$ $\displaystyle\leq 1/n.$ (99) $$

### C.4 Setting Discount Weight γ 𝛾 \gamma italic_γ

In this section, we prove the following lemma which poses a condition on the structure of discount weight $\gamma$.

###### Lemma C.2 .

(Setting $\gamma$) Under Assumption 4.5, there exists a constant $0<C_{2}<1$ which satisfies

$$ $\Sigma^{\gamma}_{{\pi_{\mathrm{ref}}},\mathrm{diff}}-C\sqrt{d\log(4d/\delta)/n }\succeq C_{2}\Sigma^{\gamma}_{{\pi_{\mathrm{ref}}},\mathrm{diff}},$ (100) $$

when $\gamma=1-\left(\frac{B_{T}}{dT}\right)^{1/2}$.

We rearrange terms in Equation 100 to get

$$ $(1-C_{2})\Sigma^{\gamma}_{{\pi_{\mathrm{ref}}},\mathrm{diff}}\succeq C\sqrt{d \log(4d/\delta)/n},$ (101) $$

which implies that $\lambda_{\mathrm{min}}(\Sigma^{\gamma}_{{\pi_{\mathrm{ref}}},\mathrm{diff}})
\geq C\sqrt{d\log(4d/\delta)/n}$. Because prompt distribution $\mathcal{X}$ and the behaviour of the reference policy ${\pi_{\mathrm{ref}}}$ is independent from the time distribution $\mathcal{T}$, combined with Assumption 4.4, $\lambda_{\mathrm{min}}(\Sigma^{\gamma}_{{\pi_{\mathrm{ref}}},\mathrm{diff}})>0$ is guaranteed.

Because $\omega^{\mathrm{upp}}(T,\gamma)^{-1}\lambda_{\mathrm{max}}(\Sigma_{{\pi_{
\mathrm{ref}}},\mathrm{diff}})\preceq\lambda_{\mathrm{min}}(\Sigma^{\gamma}_{{
\pi_{\mathrm{ref}}},\mathrm{diff}})$ based on Equation 72, we derive

$$ $\displaystyle\lambda_{\mathrm{min}}(\Sigma^{\gamma}_{{\pi_{\mathrm{ref}}}, \mathrm{diff}})$ $\displaystyle\succeq\omega^{\mathrm{upp}}(T,\gamma)^{-1}\lambda_{\mathrm{max}} (\Sigma_{{\pi_{\mathrm{ref}}},\mathrm{diff}})$ $\displaystyle\succeq C\sqrt{d\log(4d/\delta)/n}.$ (102) $$

We apply Assumption 4.5 to use $\omega^{\mathrm{upp}}(T,\gamma)\leq\frac{\bar{m}(T-1)(1-\gamma)}{\macc@depth
\char 1\relax\frozen@everymath{\macc@group}\macc@set@skewchar\macc@nested@a 11
1{m}(1-\gamma^{T-1})}$ obtained in Equation 74, and get

$$ $\displaystyle\frac{2}{T(1-\gamma)}\geq\frac{1-\gamma^{T-1}}{(T-1)(1-\gamma)} \geq\frac{\bar{m}C\sqrt{d\log(4d/\delta)/n}}{\macc@depth\char 1\relax \frozen@everymath{\macc@group}\macc@set@skewchar\macc@nested@a 111{m}\lambda_{ \mathrm{max}}(\Sigma_{{\pi_{\mathrm{ref}}},\mathrm{diff}})}.$ (103) $$

By setting $\gamma=1-\left(\frac{B_{T}}{dT}\right)^{1/2}$, combined with $n=\Theta(T)$ from Assumption 4.5, we show that

$$ $\frac{2}{T(1-\gamma)}=T^{-1/2}d^{1/2}B_{T}^{-1/2}\geq\frac{\bar{m}C\sqrt{d\log (4d/\delta)/n}}{\macc@depth\char 1\relax\frozen@everymath{\macc@group} \macc@set@skewchar\macc@nested@a 111{m}\lambda_{\mathrm{max}}(\Sigma_{{\pi_{ \mathrm{ref}}},\mathrm{diff}})},$ (104) $$

which concludes the proof.

###### Lemma C.2 .

## Peer Reviews

confidence: 3
contribution: 2
initial_rating: 3
presentation: 3
questions: Please refer to weakness part.
soundness: 2
strengths: - Addressing temporal preference drift is an important and interesting problem.
- The paper is well written.
- The work provides both theoretical and experimental results.
summary: This paper addresses temporal preference drift - a phenomenon where preferences in datasets collected over long periods undergo gradual or sudden changes. They also proposed Non-Stationary Direct Preference Optimization (NS-DPO) algorithm to  handle this preference drift.
weaknesses: - While temporal preference drift is important, NS-DPO makes a strong assumption: that older data has a higher probability of changed preference labels, regardless of topic. However, this assumption may not hold in reality. For example, preferences for factual topics (like "What is the capital of France?") remain constant over time.

- The experiments are conducted only on synthetic setups.

- What are the benefits of the algorithm compared to this alternative approach: first training the model on the newest data, then using this trained model to generate new preference annotations for older data, and finally training on the combined dataset?

---

confidence: 3
contribution: 2
initial_rating: 5
presentation: 4
questions: 1. As noted in the weaknesses section, is all older data— even the valuable data—significantly discounted?
2. In the results presented, $\rho_{diff}$ values are above 0.7. This may or may not be true given real-world preference data. What would the results look like for much smaller values of $\rho_{diff}$?
soundness: 3
strengths: 1. The paper is well-presented, highly readable, and organized effectively.
2. The theoretical analysis is comprehensive, and the resulting bound, expressed in terms of a drift measure, is particularly insightful.
summary: This paper introduces a new algorithm, NS-DPO (Non-Stationary Direct Preference Optimization), which extends DPO to address the temporal drift of preferences. The authors provide both theoretical and empirical support for this algorithm. The theoretical analysis derives a regret bound for the algorithm’s convergence in the offline setting. Empirically, NS-DPO is tested on both synthetic and LLM experiments under conditions where preference data shifts over time.
weaknesses: 1. The study lacks strong motivation. Are there any advantages to incorporating older preference data instead of relying solely on the most recent data, which is more relevant for the model? Considering that RLHF uses much less data compared to pre-training or SFT and that binary preference data is relatively inexpensive to collect, would it be more effective to gather fresh data for model training? Or alternatively, could we focus on collecting only the updated opinions to align the model?
2. It appears that all older data is discounted. How would the algorithm handle a mixture of drifting and fixed preference data, especially if some of the fixed data—though collected long ago—still holds true? Would this data be overly discounted? Is there a mechanism to ensure that genuinely stable preferences aren't unfairly penalized over time?

---

confidence: 4
contribution: 2
initial_rating: 5
presentation: 3
questions: See Weaknesses.
soundness: 3
strengths: 1. **Method Simplicity and Clarity**: The proposed NS-DPO method is straightforward and easy to follow, making it accessible for implementation.
2. **Theoretical Support**: Rigorous theoretical analysis provides bounds on estimation errors, ensuring the method's reliability.
3. **Robust Experimental Design**: The experiments are well-designed and comprehensive, effectively demonstrating the method's robustness and effectiveness.
summary: This paper introduces Non-Stationary Direct Preference Optimization (NS-DPO), addressing the issue of time-varying preferences in Large Language Models (LLMs). Unlike existing methods, NS-DPO accounts for preference drift by incorporating a Dynamic Bradley-Terry model and exponential weighting in the loss function. Theoretical analysis provides bounds on estimation errors and regret due to non-stationary preferences. Empirical results demonstrate that NS-DPO effectively maintains robustness under preference drift, outperforming baseline algorithms while preserving performance in stationary settings.
weaknesses: 1. **Baseline Considerations**: The paper could benefit from a more comprehensive comparison with alternative methods. Specifically, the most straightforward approach to handling non-stationary preferences would be to re-finetune the model on new data. Adjusting the $\beta$ parameter to control the model update speed or using a retrieval-based system (e.g. RAG) to update memory could also address the issues illustrated in Figure 1. Incorporating these methods as baselines would provide a more robust evaluation of NS-DPO's advantages.

2. **Reward Accuracy Metric**: While reward accuracy is used as the primary evaluation metric, it is important to note that recent study [1] have shown that reward accuracy does not always correlate directly with model performance. Win rate, which measures the proportion of times the model outperforms a baseline, is often a more meaningful metric in practice. Including win rate alongside reward accuracy would provide a more comprehensive assessment of the model's effectiveness.

3. **Model Fine-Tuning Approach**: The paper uses Llama-2-7b-chat-hf as the base model, which is large enough to support full fine-tuning. However, the experiments only explore LoRA fine-tuning. Conducting experiments with full fine-tuning would offer deeper insights into the performance gains and potential limitations of NS-DPO. This could help determine whether the benefits of NS-DPO are consistent across different fine-tuning strategies.

[1] Preference Learning Algorithms Do Not Learn Preference Rankings. CoRR abs/2405.19534 (2024)

Meta-review: This paper introduces NS-DPO, an algorithm addressing temporal preference drift in LLM fine-tuning by using exponential weighting in the loss function. Several key points were raised during the thorough discussion between authors and reviewers:

Strengths: 1) The problem is well-motivated. 2) The paper presents a theoretically sound approach with regret bounds. 3) The method is simple and empirically performs well. 4) The presentation is clear and well-organized.

Weaknesses: 1) The reviewers share the concern that experiments are semi-synthetic: real-world data (prompts and responses) and synthetic reward/preference drifts. The reviewers believe that directly testing and evaluating on real-world data would be more convincing. 2) Questions about whether a single discount factor can adequately handle different types of preference changes. IMO, this is partially addressed by the assumption and theoretical result: knowing $B_T$ (variation budget bound) allows the algorithm to use optimal discount factor $\gamma$ which solves the issue. But this might be a concern in practice. 3) Questions about whether older data is less reliable than recent data and should be all discounted and the reliability of older data can vary. IMO, this question is addressed by theoretical results and experiments on varying the portion of changed preference. 4) Question about evaluation metric (reward accuracy vs. win rate), which is addressed in response.

After discussion among reviewers, all reviewers agree to reject the submission. Given the scores and the discussion, I recommend rejection.

Decision: Reject