Application of Tensor Neural Networks to Pricing Bermudan Swaptions
The Cheyette model is a quasi-Gaussian volatility interest rate model widely
used to price interest rate derivatives such as European and Bermudan Swaptions
for which Monte Carlo simulation has become the industry standard. In low
dimensions, these approaches provide accurate and robust prices for European
Swaptions but, even in this computationally simple setting, they are known to
underestimate the value of Bermudan Swaptions when using the state variables as
regressors. This is mainly due to the use of a finite number of predetermined
basis functions in the regression. Moreover, in high-dimensional settings,
these approaches succumb to the Curse of Dimensionality. To address these
issues, Deep-learning techniques have been used to solve the backward
Stochastic Differential Equation associated with the value process for European
and Bermudan Swaptions; however, these methods are constrained by training time
and memory. To overcome these limitations, we propose leveraging Tensor Neural
Networks as they can provide significant parameter savings while attaining the
same accuracy as classical Dense Neural Networks. In this paper we rigorously
benchmark the performance of Tensor Neural Networks and Dense Neural Networks
for pricing European and Bermudan Swaptions, and we show that Tensor Neural
Networks can be trained faster than Dense Neural Networks and provide more
accurate and robust prices than their Dense counterparts.
Raj G. Patel, Tomas Dominguez, Mohammad Dib, Samuel Palmer, Andrea Cadarso, Fernando De Lope Contreras, Abdelkader Ratnani, Francisco Gomez Casanova, Senaida Hernández-Santana, Álvaro Díaz-Fernández, Eva Andrés, Jorge Luis-Hita, Escolástico Sánchez-Martínez, Samuel Mugel, Roman Orus
# Application of Tensor Neural Networks to Pricing Bermudan Swaptions

###### Abstract

The Cheyette model is a quasi-Gaussian volatility interest rate model widely used to price interest rate derivatives such as European and Bermudan Swaptions for which Monte Carlo simulation has become the industry standard. In low dimensions, these approaches provide accurate and robust prices for European Swaptions but, even in this computationally simple setting, they are known to underestimate the value of Bermudan Swaptions when using the state variables as regressors. This is mainly due to the use of a finite number of pre-determined basis functions in the regression. Moreover, in high-dimensional settings, these approaches succumb to the Curse of Dimensionality. To address these issues, Deep-learning techniques have been used to solve the backward Stochastic Differential Equation associated with the value process for European and Bermudan Swaptions; however, these methods are constrained by training time and memory. To overcome these limitations, we propose leveraging Tensor Neural Networks as they can provide significant parameter savings while attaining the same accuracy as classical Dense Neural Networks. In this paper we rigorously benchmark the performance of Tensor Neural Networks and Dense Neural Networks for pricing European and Bermudan Swaptions, and we show that Tensor Neural Networks can be trained faster than Dense Neural Networks and provide more accurate and robust prices than their Dense counterparts.

## 1 Introduction

Partial Differential Equations (PDE) are a crucial tool for modeling a variety of problems in Quantitative Finance. Many of these problems, such as the option pricing problem, can be recast as solving a parabolic PDE. Classical methods for solving such PDE involve mesh-based or Monte-Carlo approaches. Unfortunately, these techniques fail to scale to high-dimensional settings due to their dependence on spatio-temporal grids and an exorbitant number of sample paths. Recent advances in the field of Deep Learning [1] have made it possible to address these issues by approximating the unknown solution to a PDE using a Dense Neural Network (DNN) [2, 3, 4, 5, 6, 7]. This breakthrough has had deep implications for the field of Quantitative Finance, where it has made it possible to consider models with a previously computationally intractable number of assets or agents without making any provisional assumptions on their correlation or interaction structure. The flexibility and omnipresence of PDE makes these advances equally relevant for the domains of high-dimensional Stochastic Optimal Control and Forward-Backward Stochastic Differential Equations, both of which can be recast in the language of PDE [8]. In particular, these Deep Learning techniques can
be leveraged to address problems such as option pricing, optimal liquidation, portfolio optimization and systemic risk in quantitative finance [9, 10], but they can also be extended to industries as diverse as energy management or supply chain and inventory control.

This paper explores the problem of pricing European and Bermudan Swaptions [11, 12, 13] in the Cheyette model [14], a Markovian quasi-Gaussian volatility interest model. The importance of this problem stems from the considerable trading volume of interest rate derivatives, including European and Bermudan Swaptions, and the wide-spread use of the Cheyette model in industry. Classically, these interest rate derivatives are priced by Monte-Carlo methods. In the case of Bermudan Swaptions, these Monte-Carlo approaches rely on the regression-based Longstaff-Schwartz method [15] which becomes computationally intractable in high dimensions when taking the factors as the state variables in the regression. In addition to suffering from the Curse of Dimensionality, this regression-based method is widely known to under-estimate the true price of the option [16]. There have been attempts industrially to leverage Principal Component Analysis to first extract relevant factors, and then solve their associated PDE; however, with five or more factors, the PDE cannot be solved by traditional approaches such as finite difference or finite element methods. To circumvent these problems, in this paper, the problem of pricing European and Bermudan Swaptions is recast as the problem of solving a system of forward-backward Stochastic Differential Equations (SDE) [8]. Efficient methods for approximating the solutions to forward-backward SDE using Dense Neural Networks have recently been proposed [17, 18, 19]; however, in spite of their apparent success, Dense Neural Network approaches are computationally expensive and limited by memory [20, 21, 22]. Furthermore, there have been recent attempts to address the problem of solving PDE using the advances in Quantum Computing [23, 24, 25]. While promising, given the current limitations of quantum algorithms such as the limited number of qubits and high error rates, these approaches require important hardware advances before becoming a viable tool to solve high-dimensional PDE. In this paper we take a quantum-inspired approach by combining Tensor Networks with Dense Neural Networks to obtain Tensor Neural Networks (TNN).

Originally developed in the field of physics to describe strongly-correlated structures, Tensor Networks [26, 27, 28] have gained popularity in Machine Learning due to their efficiency in describing high-dimensional vectors and operators. Tensor Networks have been successfully applied to various Machine Learning tasks [29, 30] such as classification [31, 32, 33, 34, 35, 36, 37], generative modeling [38, 39, 40], sequence modeling [41], quantum chemistry [42], dimensionality reduction [43] and subspace learning [44] to mention just a few. Inspired by recent works, we propose this transformation from a Dense Neural Network into a Tensor Neural Network for the case of Swaptions, resulting in improved training performance as compared to the classical approaches and reduced memory consumption. To back this claim, a detailed comparison of Tensor Neural Networks against the best performing Dense Neural Network with the same number of parameters is performed. This is supported by contrasting a given Tensor Neural Network with the Dense Neural Network with the same number of neurons, and therefore considerably more parameters [7, 29].

It should be noted that the strategy proposed to price European Swaptions differs from that put forth to price Bermudan Swaptions. In the European setting, a forward methodology leveraging a single Neural Network to solve the SDE associated with the Swaption value is used. On the other hand, in the Bermudan setting, a stacked sequence of Neural Networks, one for each exercise time, is exploited. This requires a careful handling of the early-exercise nature of the option which is done by starting at the terminal time and recursively propagating the terminal condition backwards in time while simultaneously learning the optimal decision boundary. Despite these deep and fundamental strategic differences, both of these problems benefit from the computational speed-up associated with Tensor Neural Networks.

This paper is organized as follows. In Section 2, the concept of European and Bermudan Swaptions is briefly reviewed. Following this, the Cheyette Model is defined, and then the pricing of European and Bermudan Swaptions in the Cheyette Model is discussed. Section 3 focuses on the Neural Network setup required to price European and Bermudan Swaptions in the Cheyette model. The notion of tensorizing a Neural Network is then briefly reviewed in Section 4. The results of numerical experiments using the methods introduced in this paper to price European and Bermudan Swaptions are presented and discussed in Section 5, where it is shown that Tensor Neural Networks outperform Dense Neural Networks. Finally, in Section 6, conclusions and further areas of investigation are put forth.
## 2 Problem Formulation and Mathematical Framework

In this section we define the two financial instruments, the _European Swaption_ and the _Bermudan Swaption_, whose no-arbitrage price we determine in this paper. We also introduce the stochastic interest rate model that will drive the evolution of these financial derivatives, and discuss how to price these instruments under said model.

### European and Bermudan Swaptions

A _European Swaption_ is a financial contract that gives the holder the right, but not the obligation, to enter the _payer leg_ of an _interest rate swap_ with a pre-determined _tenor structure_\(0<T_{0}<T_{1}<\ldots<T_{n}\) and fixed rate \(K\geq 0\) at the future time \(T_{0}\). A _Bermudan Swaption_ is a financial contract that gives the holder the right, but not the obligation, to enter the _payer leg_ of an _interest rate swap_ with a pre-determined _tenor structure_\(0<T_{0}<T_{1}<\ldots<T_{n}\) and fixed rate \(K\geq 0\) at any future tenor date \(T_{m}\) with \(0\leq m\leq n\) An analogous discussion to what follows can be developed in the case that the holder of the Swaption enters the _receiver leg_ of the interest rate swap, but, for brevity, we focus exclusively on payer Swaptions. An _interest rate swap_ with tenor structure \(0<T_{0}<T_{1}<\ldots<T_{n}\) and fixed rate \(K\geq 0\) is a financial contract in which one party, the _payer_, pays another party, the _receiver_, the fixed cash-flow \(K\) in exchange of a floating cash flow \(\ell_{m}\) at each future time \(T_{m}\) in the tenor structure. The floating rate \(\ell_{m}\) between times \(T_{m-1}\) and \(T_{m}\) can be expressed in terms of the over-night risk-free-rate at \(T_{m}\) and the value \(P(T_{m-1},T_{m})\) of a _zero-coupon bond_ with maturity \(T_{m}\) at time \(T_{m-1}\). Recall that a _zero-coupon bond_ with maturity \(T>0\) is a contract which guarantees the holder one dollar to be paid at time \(T>0\), and its price is the stochastic process denoted by \((P(t,T))_{t\in[0,T]}\). Zero-coupon bonds are the building blocks of any interest rate theory, and their stochastic evolution will be the driver for the value of the European and Bermudan Swaptions that we price.

### The Cheyette model

Throughout this paper we will place ourselves in the context of the _Cheyette model_[14]. The Cheyette model is a special case of the _Heath-Jarrow-Morton_ (HIM) stochastic interest rate model, so, instead of directly modeling the evolution of zero-coupon bonds, we model the evolution of the forward curve

\[f(t,T):=-\frac{\partial}{\partial T}\log P(t,T). \tag{1}\]

More specifically, we assume that the _initial forward curve_\(T\mapsto f(0,T)\) is known and evolves according to the real-world dynamics

\[\mathrm{d}f(t,T)=\mu(t,T)\,\mathrm{d}t+\sigma(t,T)\cdot\,\mathrm{d}W(t) \tag{2}\]

for some drift \(\mu:\mathbb{R}_{\geq 0}\times\mathbb{R}_{\geq 0}\to\mathbb{R}\), some volatility \(\sigma:\mathbb{R}_{\geq 0}\times\mathbb{R}_{\geq 0}\to\mathbb{R}^{d}\) and some \(d\)-dimensional Brownian motion \(W\). Notice that the evolution of zero-coupon bonds may be recovered from the evolution of the forward curve,

\[P(t,T)=\exp\bigg{(}-\int_{t}^{T}f(t,s)\,\mathrm{d}s\bigg{)}. \tag{3}\]

Combining Ito's lemma with the Girsanov theorem, under appropriate regularity assumptions, it is possible to find a unique risk-neutral measure \(\mathbb{Q}\) under which all discounted zero-coupon bonds are martingales. Here the discounting is done relative to the _short rate_

\[r(t):=f(t,t). \tag{4}\]

Under this risk-neutral measure, the initial forward curve evolves according to the stochastic dynamics

\[\mathrm{d}f(t,T)=\sigma(t,T)\cdot\sigma^{*}(t,T)\,\mathrm{d}t+\sigma(t,T)\cdot \,\mathrm{d}W^{\mathbb{Q}}(t) \tag{5}\]

for some \(d\)-dimensional \(\mathbb{Q}\)-Brownian motion \(W^{\mathbb{Q}}\) and the functions

\[\mu^{*}(t,T):=\int_{t}^{T}\mu(t,s)\,\mathrm{d}s\quad\text{and}\quad\sigma^{*}( t,T):=\int_{t}^{T}\sigma(t,s)\,\mathrm{d}s. \tag{6}\]

Since we are concerned with the _pricing_ of financial derivatives, by the HJM model we will mean the stochastic evolution (5) of the forward curve under the risk-neutral measure \(\mathbb{Q}\).

One of the main difficulties in analyzing the HJM model is the path dependence of the process \(\sigma^{*}\) in (6) which makes the forward curve non-Markovian. A classical way to overcome this difficulty is to impose that the volatility process \(\sigma=(\sigma_{i})_{i\leq d}\) be separable,

\[\sigma_{i}(t,T):=h_{i}(t,X_{i}(t))g_{i}(T) \tag{7}\]
for some deterministic functions \(h=(h_{i})_{i\leq d}\) and \(g=(g_{i})_{i\leq d}\) and some adapted process \(X=(X_{i})_{i\leq d}\). A direct calculation reveals that under this assumption the forward curve is Markovian,

\[f(t,T)=f(0,T)+\sum_{i\leq d}\frac{g_{i}(T)}{g_{i}(t)}\bigg{(}X_{i}(t)+Y_{i}(t) \int_{t}^{T}\frac{g_{i}(v)}{g_{i}(t)}\,\mathrm{d}v\bigg{)} \tag{8}\]

for the stochastic processes \(X=(X_{i})_{i\leq d}\) and \(Y=(Y_{i})_{i\leq d}\) defined by

\[X_{i}(t) :=g_{i}(t)\int_{0}^{t}h_{i}^{2}(s,X_{i}(s))\int_{s}^{t}g_{i}(v)\, \mathrm{d}v\,\mathrm{d}s+g_{i}(t)\int_{0}^{t}h_{i}(s,X_{i}(s))\,\mathrm{d}W_{i }^{\mathbb{Q}}(s), \tag{9}\] \[Y_{i}(t) :=g_{i}(t)^{2}\int_{0}^{t}h_{i}^{2}(s,X_{i}(s))\,\mathrm{d}s. \tag{10}\]

Writing \(\odot\) for the Hadamard product on the space of matrices and applying Ito's lemma shows that the factor processes \(X\) and \(Y\) evolve according to the system of SDE

\[\left\{\begin{aligned} \mathrm{d}X(t)&=\big{(}Y(t)- \kappa(t)\odot X(t)\big{)}\,\mathrm{d}t+\eta(t,X(t))\odot\,\mathrm{d}W^{ \mathbb{Q}}(t)\\ \mathrm{d}Y(t)&=\big{(}\eta^{\odot 2}(t,X(t))-2 \kappa(t)\odot Y(t)\big{)}\,\mathrm{d}t\end{aligned}\right. \tag{11}\]

subject to the initial conditions \(X_{0}=Y_{0}=0\), where we have introduced the quantities \(\kappa,\eta\in\mathbb{R}^{d}\) defined by

\[\kappa_{i}(t):=-\frac{g_{i}^{\prime}(t)}{g_{i}(t)}\quad\text{and}\quad\eta_{i} (t,X_{i}(t)):=h_{i}(t,X_{i}(t))g_{i}(t). \tag{12}\]

The following result, whose proof is a direct computation leveraging (3) and (8) shows that modeling the factor processes \(X\) and \(Y\) is equivalent to modeling zero-coupon bonds. By the _Cheyette model_ we will therefore mean the stochastic evolution (11) of the factor processes \(X\) and \(Y\).

**Proposition 1**.: _The value of a zero-coupon bond with maturity \(T\) at time \(t\) in the Cheyette model is given by_

\[P(t,T)=\frac{P(0,T)}{P(0,t)}\exp\bigg{(}-X(t)\cdot G(t,T)-\frac{1}{2}Y(t)\cdot G ^{\odot 2}(t,T)\bigg{)} \tag{13}\]

_for the deterministic vector-valued function \(G(t,T)=(G_{i}(t,T))_{i\leq d}\) defined by_

\[G_{i}(t,T)=\int_{t}^{T}\exp\bigg{(}-\int_{t}^{s}\kappa_{i}(u)\,\mathrm{d}u \bigg{)}\,\mathrm{d}s. \tag{14}\]

We now discuss how this result can be leveraged to price European and Bermudan Swaptions in the Cheyette model.

### Pricing European Swaptions in the Cheyette model

A straightforward no-arbitrage argument reveals that a European Swaption with tenor structure \(T_{0}<T_{1}<\ldots<T_{n}\) and fixed rate \(K\) is a contingent claim with payoff at the first tenor date \(T_{0}\) given by

\[\phi^{\mathrm{EUR}}(X(T_{0}),Y(T_{0})):=\big{(}1-P(T_{0},T_{n})-A_{T_{0}}K \big{)}_{+}\quad\text{where}\quad A_{T_{0}}:=\sum_{m=1}^{n}P(T_{0},T_{m}) \Delta T_{k} \tag{15}\]

is the _annuity process_ evaluated at the maturity \(T_{0}\) of the Swaption. On the other hand, a direct application of the Feynmann-Kac theorem shows that, in the context of the Cheyette model, the value process

\[V_{t}:=V(t,X(t),Y(t)) \tag{16}\]

of a contingent claim with payoff \(V_{T}:=\phi(X(T),Y(T))\) at its maturity \(T>0\) evolves according to the stochastic dynamics

\[\mathrm{d}V_{t}=r_{t}V_{t}\,\mathrm{d}t+\nabla_{x}V(t,X(t),Y(t))\eta(t,X(t)) \odot\,\mathrm{d}W^{\mathbb{Q}}(t) \tag{17}\]

subject to the terminal condition \(V_{T}:=\phi(X(T),Y(T))\). Together with Proposition 1 and the observation from (8) that

\[r_{t}=f(0,t)+\sum_{i\leq d}X_{i}(t), \tag{18}\]

this insight will allow us to determine the value of a European Swaption using Neural Networks. More details will be provided in Section 3.1.
### Pricing Bermudan Swaptions in the Cheyette model

Pricing a Bermudan Swaption requires more care. A no-arbitrage argument analogous to that for a European Swaption shows that the _exercise value_, or the immediate profit, made by exercising the Bermudan Swaption at exercise time \(T_{m}\) is

\[\phi^{\mathrm{BER},m}(X(T_{m}),Y(T_{m})):=\big{(}1-P(T_{m},T_{n})-A_{T_{m}}K \big{)}_{+}\quad\text{where}\quad A_{T_{m}}:=\sum_{\ell=m+1}^{n}P(T_{m},T_{\ell })\Delta T_{\ell} \tag{19}\]

is the annuity process evaluated at the exercise date \(T_{m}\). To deduce from this the value \(V_{T_{m}}\) of the Swaption at each exercise date \(T_{m}\), and hence determine its initial value \(V_{0}\), the idea will be to proceed iteratively and backwards in time. More specifically, the strategy will be to compare the exercise value of the Swaption to its _continuation value_ at each exercise date \(T_{m}\); the larger of the two being the value of the Swaption at that time. To begin with, notice that the terminal value of the Bermudan Swaption is

\[V_{T_{n}}:=\phi^{\mathrm{BER},n}(X(T_{n}),Y(T_{n})), \tag{20}\]

and observe that the continuation value \(C^{m}=(C^{m}_{t})_{t\in[T_{m-1},T_{m})}\) of the Bermudan Swaption between exercise times \(T_{m-1}\) and \(T_{m}\) coincides with the value of a contingent claim having payoff \(V_{T_{m}}\) at time \(T_{m}\). It therefore evolves according to the stochastic dynamics

\[\mathrm{d}C^{m}_{t}=r_{t}C^{m}_{t}\,\mathrm{d}t+\nabla_{x}C^{m}_{t}(t,X(t),Y(t ))\eta(t,X(t))\odot\,\mathrm{d}W^{\mathbb{Q}}(t)\quad\text{for }t\in[T_{m-1},T_{m}) \tag{21}\]

subject to the terminal condition \(C^{m}_{T_{m}}:=V_{T_{n}}\). With the continuation value \(C^{m}_{T_{m-1}}\) at hand, the value \(V_{T_{m-1}}\) of the Bermudan Swaption at exercise time \(T_{m-1}\) becomes

\[V_{T_{m-1}}:=\max\big{(}C^{m}_{T_{m-1}},\phi^{\mathrm{BER},m-1}\big{)}. \tag{22}\]

This well-defined backwards iterative procedure yields the value of the Bermudan Swaption at each tenor date \(T_{m}\). The initial value \(V_{0}\) of the Bermudan Swaption is now the continuation value \(C^{0}_{0}\) obtained by evolving the SDE (21) backwards in time from \(T_{0}\) to \(0\) subject to the terminal condition \(C^{0}_{T_{0}}:=V_{T_{0}}\). This backward iterative procedure will be implemented using a sequence of Neural Networks as detailed in Section 3.2.

## 3 Neural Networks for Swaption Pricing

In this section we describe a Neural Network approach to price European and Bermudan Swaptions in the Cheyette stochastic interest rate model. The strategy will be to define Neural Networks that learn the solution to the SDE (17) with an appropriate terminal condition at all points along a partition of the relevant time interval. We also discuss how these Neural Networks can be tensorized using quantum-inspired ideas to yield Tensor Neural Networks.

### A Neural Network for the European Swaption

To price a European Swaption with tenor structure \(T_{0}<T_{1}<\ldots<T_{n}\) and fixed rate \(K\geq 0\), we will use a single Neural Network that learns the solution \(V\) to the SDE (17) along a partition of the interval \([0,T_{0}]\) subject to the terminal condition \(\phi^{\mathrm{EUR}}\) defined in (15). To be more specific, we partition the interval \([0,T_{n}]\) into \(N\) sub-intervals of width \(\Delta t=T_{n}/N\) with endpoints at \(0=:t_{0}<t_{1}<\ldots<t_{N}:=T_{n}\), and we strive to learn the value \(V_{t_{k}}\) of the solution to (17) at each of the partition points \(t_{k}\) in the interval \([0,T_{0}]\). For simplicity, we will assume that \(N\) is chosen in such a way that \(T_{0}=t_{k_{0}}\) for some \(0\leq k_{0}\leq N\); otherwise, in everything that follows, \(T_{0}\) would have to be replaced by its nearest neighbor \(t_{k_{0}}\) in the partition of \([0,T_{n}]\). Writing \(M\) for the batch size, we proceed in \(3\) steps.

#### 3.1.1 The forward simulation

To begin with, we discretize the system of SDE (11) describing the evolution of the factor processes \(X\) and \(Y\) using an Euler scheme. This yields \(M\) simulated paths \((X^{j})_{j\leq M}\) and \((Y^{j})_{j\leq M}\) of each factor process. The \(k^{\mathrm{th}}\) coordinate in the vectors \(X^{j}=(X^{j,k})_{k\leq N}\) and \(Y^{j}=(Y^{j,k})_{k\leq N}\) is found from the system of discrete differences

\[\begin{cases}X^{j,k+1}&:=X^{j,k}+\big{(}Y^{j,k}-\kappa(t_{k})\odot X^{j,k} \big{)}\Delta t+\eta(t_{k},X^{j,k})\odot\Delta W^{j,k}\\ Y^{j,k+1}&:=Y^{j,k}+\big{(}\eta^{\odot 2}(t_{k},X^{j,k})-2\kappa(t_{k})\odot Y^{j,k} \big{)}\Delta t\end{cases} \tag{23}\]

subject to the initial condition \(X^{j,0}=Y^{j,0}=0\), and it corresponds to a sample of the random variable \(X_{t_{k}}\) or \(Y_{t_{k}}\). Here \(\Delta W^{j,k}:=\sqrt{\Delta t}Z^{j,k}\) for a family of independent and identically distributed standard Gaussian random variables \((Z^{j,k})\). Notice that the vectors \(Y^{j}\) are all identical since \(Y\) is deterministic; nonetheless, we artificially take \(M\) of them as this will lighten the notation required to describe the Neural Network.
#### 3.1.2 The European terminal condition

The forward simulation yields \(NM\) vectors of triples \((X^{j,k},Y^{j,k},t_{k})\) which may be combined with Proposition 1 to estimate the zero-coupon bond prices \(P(T_{0},T_{m})\) required to determine the terminal condition \(\phi^{\mathrm{EUR}}\) defined in (15). The \(m^{\mathrm{th}}\) coordinate in the vector \(P^{j}=(P^{j,m})_{1\leq m\leq n}\) estimates the zero-coupon bond price \(P(T_{0},T_{m})\), and is defined by

\[P^{j,m}:=\frac{P(0,T_{m})}{P(0,T_{0})}\exp\bigg{(}-X^{j,k_{0}}\cdot G(T_{0},T_{ m})-\frac{1}{2}Y^{j,k_{0}}\cdot G^{\odot 2}(T_{0},T_{m})\bigg{)}, \tag{24}\]

where the deterministic function \(G\) is given by (14) and \(k_{0}\) is the unique index with \(T_{0}=t_{k_{0}}\). From these zero-coupon bond estimates, it is possible to approximate the \(M\) terminal conditions

\[\phi^{\mathrm{EUR},j}:=\bigg{(}1-P^{j,n}-\sum_{m=1}^{n}KP^{j,m}\Delta T_{m} \bigg{)}_{+} \tag{25}\]

required to price the European Swaption.

#### 3.1.3 The European Neural Network

The \(NM\) vectors of triples \((X^{j,k},Y^{j,k},t_{k})\) and the \(M\) terminal conditions \((\phi^{\mathrm{EUR},j})\) now become the inputs of the Neural Network tasked with learning the solution to the SDE (17) subject to the terminal condition \(\phi^{\mathrm{EUR}}\) at the points \(t_{k}\) in the interval \([0,T_{0}]\). The output of this Neural Network are \(M\) paths

\[\widehat{V}^{j}(\theta)=\big{(}\widehat{V}^{j,k}(\theta)\big{)}_{k\leq k_{0}} \tag{26}\]

with \(\widehat{V}^{j,k}(\theta)\) being an estimator for \(V_{t_{k}}\). This output vector can be used to estimate the gradient \(\widehat{\nabla}_{X}V^{j,k}\) by means of automatic differentiation, and this estimated gradient can be leveraged to obtain another approximation of \(V_{t_{k}}\) through an Euler discretization of the backward SDE (17),

\[\widetilde{V}^{j,k+1}(\theta):=\widehat{V}^{j,k}(\theta)+r^{j,k}\widehat{V}^{ j,k}(\theta)\Delta t+\widehat{\nabla}_{X}V^{j,k}\eta(t_{k},X^{j,k})\odot \Delta W^{j,k}, \tag{27}\]

where

\[r^{j,k}:=f(0,t_{k})+\sum_{i\leq d}X^{j,k} \tag{28}\]

is an approximation of the short rate (18) at \(t_{k}\). The Neural Network is now trained by minimizing the square difference between the estimators \(\widehat{V}^{j}\) and \(\widetilde{V}^{j}\) while matching the terminal conditions \(\phi^{\mathrm{EUR},j}\) across batches. In other words, its associated loss function is defined by

\[\mathcal{L}(\theta):=\sum_{j=1}^{M}\sum_{k=1}^{N}\big{(}\widehat{V}^{j,k}( \theta)-\widetilde{V}^{j,k}(\theta)\big{)}^{2}+\sum_{j=1}^{M}\big{(}\widehat{ V}^{j,k_{0}}(\theta)-\phi^{\mathrm{EUR},j}\big{)}^{2} \tag{29}\]

Notice that we could have included a term comparing \(\widetilde{V}^{j,k_{0}}_{N}(\theta)\) and \(\phi^{\mathrm{EUR},j}\), but this is not necessary as the triangle inequality already takes care of it.

Figure 1: Learning pipeline for the European Swaption Neural Network.
### A Sequence of Neural Networks for the Bermudian Swaption

To price a Bermudan Swaption with tenor structure \(T_{0}<T_{1}<\ldots<T_{n}\) and fixed rate \(K\geq 0\), we will use a backward sequence of \(n+1\) Neural Networks. The \(m^{\rm th}\) of these Neural Networks will learn the solution \(C^{m}\) to the SDE (21) along a partition of the interval \([T_{m-1},T_{m}]\) subject to a terminal condition depending on the payoff \(\phi^{\rm BER,m}\) defined in (19) and the ouput of the previous Neural Network. Here and henceforth we adopt the convention that \(T_{-1}:=0\). Just like we did for European Swaptions, we partition the interval \([0,T_{n}]\) into \(N\) sub-intervals of width \(\Delta t=T_{n}/N\) with endpoints at \(0=:t_{0}<t_{1}<\ldots<t_{N}:=T_{n}\), and we assume that \(N\) is chosen in such a way that for every \(0\leq m\leq n\), we have \(T_{m}=t_{k_{m}}\) for some \(0\leq k_{m}\leq N\); otherwise, in everything that follows, \(T_{m}\) would have to be replaced by its nearest neighbour \(t_{k_{m}}\) in the partition of \([0,T_{n}]\). Moving forward we adopt the convention that \(t_{k_{-1}}:=0\). Writing \(M\) for the batch size we once again proceed in \(3\) steps.

#### 3.2.1 The forward simulation

The forward simulation is identical to that described in Section 3.1.1 for European Swaptions, and again yields \(NM\) vectors of triples \((X^{j,k},Y^{j,k},t_{k})\).

#### 3.2.2 The Bermudan payoffs

To price a Bermudan Swaption, we need to estimate the \(n+1\) payoffs \(\phi^{\rm BER,m}\) defined in (19). To do this we require approximations \(P^{j,m,\ell}\) to the zero-coupon bond prices \(P(T_{m},T_{\ell})\) for \(0\leq m<n\) and \(m<\ell\leq n\). These may be obtained from Proposition 1 by setting

\[P^{j,m,\ell}:=\frac{P(0,T_{\ell})}{P(0,T_{m})}\exp\bigg{(}-X^{j,k_{m}}\cdot G (T_{m},T_{\ell})-\frac{1}{2}Y^{j,k_{m}}\cdot G^{\odot 2}(T_{m},T_{\ell}) \bigg{)}, \tag{30}\]

where the deterministic function \(G\) is given by (14) and \(k_{m}\) is the unique index with \(T_{m}=t_{k_{m}}\). From these zero-coupon bond estimates, for each of the \(M\) batches, it is possible to approximate the \(m^{\rm th}\) payoff

\[\phi^{\rm BER,j,m}:=\bigg{(}1-P^{j,m,n}-\sum_{\ell=m+1}^{n}KP^{j,m,\ell}\Delta T _{\ell}\bigg{)}_{+} \tag{31}\]

required to price the Bermudan Swaption.

#### 3.2.3 The sequence of Bermudan Neural Networks

The \(NM\) vectors of triples \((X^{j,k},Y^{j,k},t_{k})\) with \(k_{n-1}\leq k\leq k_{n}\) and the \(M\) payoffs \((\phi^{\rm BER,j,n})\) now become the inputs of the \(n^{\rm th}\) Neural Network tasked with learning the solution to the SDE (21) subject to the terminal condition \(\phi^{\rm BER,n}\) at the points \(t_{k}\) in the interval \([T_{n-1},T_{n}]\). The output of this Neural Network are \(M\) continuation values

\[\widehat{C}^{j,n}(\theta_{n})=\big{(}\widehat{C}^{j,n,k}(\theta_{n})\big{)}_{ k_{n-1}\leq k\leq k_{n}} \tag{32}\]

with \(\widehat{C}^{j,n,k}(\theta_{n})\) being an estimator for \(C^{n}_{t_{k}}\). Before discussing how the \(m^{\rm th}\) Neural Network learns, let us describe the inputs and outputs of the \(m^{\rm th}\) Neural Network in this stacked sequence of Neural Networks for \(0\leq m<n\). The \(NM\) vectors of triples \((X^{j,k},Y^{j,k},t_{k})\) with \(k_{m-1}\leq k\leq k_{m}\) and the \(M\) terminal conditions

\[V^{j,m}:=\max\big{(}\phi^{\rm BER,j,m},\widehat{C}^{j,m+1,k_{m}}(\theta_{m+1}) \big{)} \tag{33}\]

are the inputs of the \(m^{\rm th}\) Neural Network tasked with learning the solution to the SDE (21) subject to the terminal condition \(V_{T_{m}}\) defined in (22) at the points \(t_{k}\) in the interval \([T_{m-1},T_{m}]\). The output of the \(m^{\rm th}\) Neural Network are the \(M\) continuation values

\[\widehat{C}^{j,m}(\theta_{m})=\big{(}\widehat{C}^{j,m,k}(\theta_{m})\big{)}_{ k_{m-1}\leq k\leq k_{m}} \tag{34}\]

with \(\widehat{C}^{j,m,k}(\theta_{m})\) being an estimator for \(C^{m}_{t_{k}}\). The value of the Bermudan swaption is then obtained from the continuation values \(V^{j}_{0}:=\widehat{C}^{j,0,0}(\theta_{0})\).

Having described the stacked Neural Network structure, let us delve into the learning procedure for the \(m^{\rm th}\) Neural Network. This will be identical for \(0\leq m\leq n\) and will very closely resemble the procedure described for the European Neural Network in Section 3.1.3. The output \(\widehat{C}^{j,m,k}(\theta_{m})\) of the \(m^{\rm th}\) Neural Network can be used to estimate the gradient \(\widehat{\nabla}_{X}C^{j,m,k}\) by means of automatic differentiation, and this estimated gradient can be leveraged to obtain another approximation of the continuation value \(C^{m}_{t_{k}}\) through the Euler discretization of the backward SDE (21),

\[\widehat{C}^{j,m,k+1}(\theta_{m})=\widehat{C}^{j,m,k}(\theta_{m})+r^{j,k} \widehat{C}^{j,m,k}(\theta_{m})\Delta t+\widehat{\nabla}_{X}C^{j,m,k}\eta(t_{k },X^{j,k})\odot\Delta W^{j,k}, \tag{35}\]
where \(r^{j,k}\) is an approximation of the short rate (18) at \(t_{k}\). The \(m^{\rm th}\) Neural Network is now trained by minimizing the loss function

\[\mathcal{L}_{m}(\theta_{m}):=\sum_{j=1}^{M}\sum_{k=k_{m-1}}^{k_{m}} \left(\widehat{C}^{j,m,k}(\theta_{m})-\widetilde{C}^{j,m,k}(\theta_{m})\right) ^{2}+\sum_{j=1}^{M}\left(\widehat{C}^{j,m,k_{m}}(\theta_{m})-V^{j,m}\right)^{2} \tag{36}\]

which strives to match the estimators \(\widehat{C}^{j,m}\) and \(\widetilde{C}^{j,m}\) as well as the terminal conditions \(V^{j,m}\) across batches.

## 4 Tensorizing the Neural Networks

To address the shortcomings of dense architectures, we transform classical fully-connected Dense Neural Networks into what we call Tensor Neural Networks. This has the purpose of enhancing training performance and reducing memory consumption [7, 29]. The way we tensorize the Neural Networks is to replace the weight matrix of a dense layer by a Tensor Network [26]. In particular, we choose a Matrix Product Operator (MPO) representation [26] of the weight matrix that is analogous to the Tensor-Train format [20], and we call this layer a _TN layer_. This representation, however, is not unique, and is determined by two additional parameters: the MPO bond dimension, and the number of tensors in the MPO. In the simplest case, the MPO may consist of only two tensors, \(\mathbf{W_{1}}\) and \(\mathbf{W_{2}}\), as shown in Figure 3. The MPO in the figure has bond dimension \(\chi\) and physical dimension \(d\) as the input and output dimension. The TN layer with such an MPO can be initialized in the same manner as a weight matrix of a dense layer.

In the forward pass of the TN layer, we first contract the MPO along the bond index and then reshape the resulting rank-4 tensor into a matrix as shown in Figure 3. This matrix is the corresponding weight matrix of a TN layer. The weight matrix can then be multiplied with the input vector. We apply an activation function to the resulting output vector, thereby finishing the forward pass. The weight matrix takes the form

\[\mathbf{W}=\sum_{\alpha=1}^{\chi}(\mathbf{A}_{\alpha}\otimes\mathbf{B}_{ \alpha}),\ \ \ \mathbf{W}\in\mathbb{R}^{d^{2}\times d^{2}}, \tag{37}\]

where \(\mathbf{W}_{1}=[\mathbf{A}_{1},\mathbf{A}_{2},\cdots,\mathbf{A}_{\chi}], \mathbf{A}_{\alpha}\in\mathbb{R}^{d\times d}\) and \(\mathbf{W}_{2}=[\mathbf{B}_{1},\mathbf{B}_{2},\cdots,\mathbf{B}_{\chi}], \mathbf{B}_{\alpha}\in\mathbb{R}^{d\times d}\) are the two rank-3 weight tensors connected by a virtual bond \(\alpha\) of dimension \(\chi\). The resulting weight matrix \(\mathbf{W}\) is of dimension \(d^{2}\times d^{2}\), so it contains \(d^{4}\) elements. Notice that these elements _are not independent_ due to the Kronecker product in (37). Indeed, the weights come from the TN structure with \(2\chi d^{2}\) trainable parameters, and they are a sum of products of elements of the tensors \(\mathbf{A}\) and \(\mathbf{B}\), thus leading to a correlation structure. It is worth noting that the parameters to be trained

Figure 3: The process of contracting a 2-node MPO and reshaping it into the weight matrix \(\mathbf{W}\) in each forward pass.

Figure 2: Learning pipeline for the Bermudan Swaption stacked Neural Network.
are not the matrix elements of the weight matrix, but the elements of the individual tensors of the MPO. This can lead to interesting training behaviour and can result in faster convergence of the loss function. Moreover, any choice of \(\chi<d^{2}/2\) will result in \(d^{4}-2\chi d^{2}\) fewer trainable parameters than an equivalent dense layer, thus allowing for potential parameter savings. In principle, when \(\chi=d^{2}\), we have sufficient degrees of freedom to be able to construct an arbitrary \(d^{2}\times d^{2}\) matrix. By increasing the bond dimension, we therefore expect the TN layer to behave increasingly like a dense layer [29].

## 5 Swaption Pricing Results

We now apply the methodology described in Sections 3.1, 3.2 and 4 to benchmark the performance of Dense Neural Networks and Tensor Neural Networks in pricing European and Bermudan Swaptions. For benchmarking, we consider the Cheyette model with constant parameters and identity correlation matrix. Under this parametrization, the Cheyette model is equivalent to a one-factor Hull and White model. It is worth noting, however, that our approach and code can be extended to the generalized version of the Cheyette model.

### European Swaptions

To price European Swaptions we place ourselves in the context of the 3-factor Cheyette model with \(X_{i}(0)=Y_{i}(0)=0\) for \(1\leq i\leq 3\), we use the base parameters \(\kappa=-0.02\) and \(\eta=0.0065\), the tenor structure \((T_{0},T_{1},T_{2},T_{3},T_{4})=(1,2,3,4,5)\), the fixed rates \(K=0.00\) or \(K=0.01\), and the initial forward curve \(T\mapsto f(0,T)\) implied from (1) and the zero-coupon bond prices \(P(0,T)\) given in Table 1. Moreover, we partition the time interval \([0,T_{4}]\) into \(N=500\) sub-intervals of width \(\Delta t=0.01\). For our use-case we only use Neural Networks with a 2-hidden layer architecture.

Furthermore, for Tensor Neural Networks, we only construct TN layers that are symmetric in each input and each output dimension. As a result, we choose the first layer in our Tensor Neural Network to be a dense layer with neurons that match the input shape of the second TN layer. For convenience of notation, we will write \(\text{DNN}(x,y)\) to mean a two-layer Dense Neural Network with \(x\) neurons in the first layer and \(y\) neurons in the second layer. Similarly, we will write \(\text{TNN}(x,y)\) to mean a two-layer Tensor Neural Network with a dense first layer having \(x\) neurons and a TN second layer having \(y\) neurons, where we must have \(x=y\). To optimize the Neural Network weights, we use the Adam Optimizer with batch of size 100 and a piece-wise learning rate of \([10^{-2},10^{-3},10^{-4},10^{-5}]\). This means that for the \(i\)'th quarter of epochs, we use a learning rate of \(10^{-(i+1)}\) in the Adam Optimizer.

Having described the model and Neural Network specifications for our numerical experiments, we now turn our attention to the numerical results for the initial price and loss evolution of European Swaptions with fixed rate \(K=0.00\) and \(K=0.01\). We focus on three architectures, TNN(64, 64), DNN(64, 64) and DNN(24,27), and we compare and contrast them to the Monte-Carlo (MC) price obtained by approximating the discounted payoff

\[\mathbb{E}\bigg{[}\exp\bigg{(}-\int_{0}^{T_{0}}r_{s}\,\mathrm{d}s \bigg{)}\phi^{\text{EUR}}(X(T_{0}),Y(T_{0}))\bigg{]} \tag{38}\]

by its sample average. In the context of European Swaptions, we will assume this MC price to be the "true" option price. We start with DNN(64, 64) as it is the smallest Dense Neural Network that agrees with the MC price for one of the two fixed rates \(K\) that we consider. To compare a Tensor Neural Network with this DNN(64, 64), we select the architecture TNN(64, 64) as it has a comparable number of neurons. However, it is worth noting that TNN(64, 64) does not have the same number of parameters as DNN(64, 64). In our experiments, we use a bond-dimension \(\chi\)= 2, so, as discussed in Section 4, the architecture TNN(64,64) would have \(d^{4}-2\chi d^{2}=(8)^{4}-2*2*(8^{2})=3840\) fewer parameters than DNN(64,64). Notice that \(d=8\) as \(64=8^{2}\) (see Figure 3). In this particular case, DNN(64, 64) has \(4737\) parameters whereas TNN(64, 64) has \(897\) parameters. Moreover, to have a fair comparison, we also contrast TNN(64, 64) to DNN(24, 27) as it is the best performing Dense Neural Network architecture with a comparable number of parameters as TNN(64,64).

\begin{table}
\begin{tabular}{|c|c||c|c||c|c|} \hline Maturity & Bond price & Maturity & Bond price & Maturity & Bond price \\ \hline
0 & 1.00000 & 5 & 0.88232 & 18 & 0.60911 \\
1 & 0.99005 & 6 & 0.83500 & 23 & 0.53693 \\
2 & 0.97528 & 7 & 0.78240 & 28 & 0.49611 \\
3 & 0.95596 & 8 & 0.77064 & 33 & 0.47940 \\
4 & 0.91376 & 13 & 0.67661 & 38 & 0.46721 \\ \hline \end{tabular}
\end{table}
Table 1: Zero-coupon bond prices \(T\mapsto P(0,T)\) used to determine the initial forward curve \(T\mapsto f(0,T)\).
The results in Figure 4 show that the Tensor Neural Network (64, 64) outperforms the best performing Dense Neural Network with similar parameter count for both fixed rates \(K\) considered. This is evident from the option price evolution, with the Tensor Neural Network approaching the MC price faster and to a much greater extent while exhibiting a significantly smaller confidence interval than the DNN(24, 27) architecture which doesn't even converge to the MC price. This is supported by the loss function evolution, with the Tensor Neural Network loss function becoming considerably smaller than the DNN(24,27) loss function. Upon comparing the TNN(64, 64) architecture to a dense architecture with similar neuron count but significantly higher parameter count, we see that the Tensor Neural Network again outperforms its dense counterpart despite an \(81\%\) compression in parameter count. It is worth pointing out that while the DNN(64,64) architecture does result in convergence to the MC price for the fixed rate \(K=0.01\), it fails to converge to this benchmark price for the fixed rate \(K=0.00\). On the other hand, the Tensor Neural Network readily converges to this "true" price for both fixed rates. In summary, the Tensor Neural Network outperforms both the best Dense Neural Network with comparable number of parameters and the Dense Neural Network with similar neuron count but considerably more parameters.

In light of the fact that the two layer Dense Neural Networks in Figure 4 fail to converge, to compare the convergence time of Tensor Neural Networks and Dense Neural Networks we consider four layer architectures. The three four layer architectures shown in Figure 5 all converge to the true price with the Tensor Neural Network doing so considerably faster than its dense counterparts with comparable number of neurons or parameters.

Figure 4: **(top panel)** Initial option price evolution for fixed rate \(K=0.00\) (left) and fixed rate \(K=0.01\) (right) for TNN(64, 64) with a bond dimension 2 (red), the corresponding DNN(64,64) with similar neuron count (green) and the best DNN(24,27) with equivalent parameter count (blue). The plots display the mean and \(95\%\) confidence interval for the runs. To benchmark the results, the dotted line (black) indicates the MC price from \(10^{5}\) runs while the grey shaded region indicates its associated \(95\%\) confidence interval. (**bottom panel**) Training loss evolution for fixed rate \(K=0.00\) (left) and fixed rate \(K=0.01\) (right) for TNN(64, 64) with a bond dimension 2 (red), the corresponding DNN(64,64) with similar neuron count (green) and the best DNN(24,27) with equivalent parameter count (blue). The plots display the mean and \(95\%\) confidence interval for the runs.
### Bermudan Swaptions

To price Bermudan Swaptions we consider the 3-factor Cheyette model with \(X_{i}(0)=Y_{i}(0)=0\) for \(1\leq i\leq 3\), we use the base parameters \(\kappa=-0.02\) and \(\eta=0.0065\), the tenor structure \((T_{0},T_{1},T_{2},T_{3},T_{4})=(1,2,3,4,5)\), the fixed rates \(K=0.00\) or \(K=0.01\), and the initial forward curve \(T\mapsto f(0,T)\) implied from (1) and the zero-coupon bond prices \(P(0,T)\) given in Table 1. Moreover, we partition the time interval \([0,T_{4}]\) into \(N=500\) sub-intervals of width \(\Delta t=0.01\), and we assume that the exercise dates of the Bermudan Swaption coincide with its tenor structure.

The plot in Figure 6 gives the Bermudan Swaption price for a collection of different Neural Network architectures both for Tensor Neural Networks and Dense Neural Networks. We have chosen to compare a given Tensor Neural Network architecture to the Dense Neural Network architecture with the same number of neurons, and therefore a considerably higher parameter count. The differences in parameter count between comparable Tensor Neural Networks and Dense Neural Networks is summarized in Table 2.

\begin{table}
\begin{tabular}{|c|c|c|c|} \hline Layers & Neurons & Dense Neural Networks & Tensor Neural Networks \\ \hline
2 & 16 & 417 & 225 \\
2 & 64 & 4,737 & 897 \\
4 & 64 & 13,057 & 1,537 \\
10 & 64 & 38,017 & 3,457 \\
20 & 256 & 1,252,353 & 26,625 \\ \hline \end{tabular}
\end{table}
Table 2: Parameter Count for Dense Neural Networks and Tense Neural Networks compared in Figure 6.

Figure 5: European Swaption Price for different architectures in 3-factor Cheyette Model with fixed rate \(K=0.00\).

Figure 6: Bermudan Swaption Price for different architectures in 3-factor Cheyette Model with fixed rate \(K=0.00\).
To benchmark the Bermudan Swaption prices given by Tensor Neural Networks and Dense Neural Networks, Figure 6 also displays the Bermudan Swaption price provided by the classical Longstaff-Schwartz (LS) approach. We have included the LS price when the regressors are of degree 1, which turned out to be $0.1090, and also the price when the regressors are of degree 2, which turned out to be $0.1096. It is well-known that the LS approach leads to an under-estimate of the option price [16] and that the LS price approaches the "true" option price when the degree of the regressors tends to infinity [15]. The first of these heuristics is supported by our numerical results, and the second suggests that the "true" option price should be higher than the $0.1096 given by the LS with regressors of degree 2. It is worth noting that such a price will also be higher than the "true" price of $0.1079 for the European Swaption with the same parameters displayed in Figure 4. This is in accordance with the fact that the price of a Bermudan Swaption should always be lower bounded by the price of its European counterpart.

Having understood how we will benchmark the Tensor Neural Network and Dense Neural Network prices, and emphasising that this benchmark is not as reliable as it was in the setting of European Swaptions, let us turn our attention to the Neural Network prices for various architectures. To begin with we used a 2-layer architecture with 16 neurons in each layer for each of the 5 Neural Networks (one for each exercise date), and trained each Neural Network for 500 epochs. The prices for such a Tensor Neural Network and Dense Neural Network are displayed on the far right of Figure 6. It is clear that these prices are underestimates resulting from the Neural Networks under-fitting the data. This led us to consider the same configuration of Neural Networks with 64 neurons instead of just 16 in each of the 2 layers. We observe a marked improvement in both the price and the stability (the bars around the estimate indicate a 95% confidence interval for 10 runs under the same configuration) of the resulting Bermudan Swaption prices, particularly in the Tensor Neural Network setting where the price goes above the LS price as expected of the "true" option price. Upon increasing the complexity of the architecture to a 4-layer Neural Network with 64 neurons in each layer, the improvements are evident with both the Tensor Neural Network and the Dense Neural Network above the LS price, thereby making the Neural Network advantage evident. This phenomenon of Neural Networks outperforming classical regression should come as no surprise. Indeed, the finite number of regressors chosen in the classical LS approach cannot fully represent the conditional payoff they strive to approximate. This limitation could be mitigated by increasing the degree of the regressors but this quickly becomes infeasible from an accuracy and time perspective, leading both to over-fitting and a lack of convergence. The advantage of Neural Networks is that they allow us to learn the relevant regressors instead of selecting them a priori, thus being more amenable to high-dimensional settings. Once the Tensor Neural Networks and Dense Neural Networks both start to outperform the LS approach, in the sense that they yield higher prices, we increase the number of layers to 10 and see a further increment in price to $0.1230. Upon increasing the number of layers to 20, we observe that the Tensor Neural Network price is almost identical to that given in the 10 layer setting. On the other hand, the Dense Neural Network price for 20 layers falls subject to over-fitting and is considerably worse than the price observed in the 10 layer setting both in terms of accuracy and stability. Besides exhibiting overfitting, as shown in Figure 7, Dense Neural Networks also require a larger number of parameters than Tensor Neural Networks to converge above the threshold prices of $0.110 and $0.120 which appear to be lower bounds for the true price. This suggests that Tensor Neural Networks provide better and more scalable prices than both LS and Dense Neural Networks which are more prone to overfitting if not properly fine-tuned.

Figure 7: DNN and TNN parameter comparison for Bermudan Swaption price in \(3\)-factor Cheyette model with \(K=0.00\) to cross $0.110 and $0.120 price threshold.
Before closing this section we would like to delve deeper into the 150bps difference between the degree 2 LS price and the 20 layer Tensor Neural Network price shown in Figure 6 as this might seem overly large. We hypothesise that this difference is a consequence of using low degree regressors in the LS approach, and that the LS price would approach the Tensor Neural Network price if we increased the degree of the regressors. Due to computational limitations, instead of increasing the degree of the regressors, we decrease the complexity of the model by considering the 1-factor Cheyette model as opposed to the 3-factor model.

The hypothesis that the 150bps difference is being driven by an under-fitting of the regressors is supported by Figure 8 which shows a smaller 30bps difference between the degree 2 LS price and the 4 layer Tensor Neural Network price. Furthermore, in this simpler setting the Tensor Neural Network and the Dense Neural Network price both tend to the same value with almost no standard error. To further display the advantage provided by Tensor Neural Networks, let us compare the loss plots, parameter count and time to convergence for Tensor Neural Networks and Dense Neural Networks.

From the premise that smaller losses imply better results, Figure 9 shows that the Tensor Neural Network outperforms the Dense Neural Network with similar neuron count and also the best Dense Neural Network with comparable parameter count. This corroborates the observation from Figures 6 and 8 that Tensor Neural Networks provide more reliable prices than Dense Neural Networks.

Figure 8: Bermudan Swaption Price for different architectures in 1-factor Cheyette Model with fixed rate \(K=0.00\).

Figure 9: Bermudan Swaption loss evolution in \(3\)-factor Cheyette model with fixed rates \(K=0.00\) and \(K=0.01\).
## 6 Conclusions and Outlook

In this paper we have shown how Tensor Neural Networks can be leveraged to price European Swaptions in the multi-factor Cheyette model. We have also extended this approach to price early-exercise Swaptions under this stochastic interest rate model by stacking \(n\) feed-forward Neural Networks to price a Bermudan Swaption with \(n\) exercise dates. To quantify the considerable advantages of Tensor Neural Networks we have performed rigorous empirical benchmarking. In doing so, we have demonstrated that Tensor Neural Networks provide significant parameter savings relative to Dense Neural Networks with comparable number of neurons or parameter count while attaining more reliable prices having smaller variance. We have further shown that Tensor Neural Networks achieve a computational speed-up in training when contrasted with Dense Neural Networks having comparable number of neurons or parameter count. Although we have performed numerical experiments in the 3-factor setting, unlike the traditional Monte-Carlo based methods which succumb to the Curse of Dimensionality, our approach can be scaled to a significantly higher number of factors. Despite an absence of theoretical bounds, which can be an area of further investigation, the Tensor Neural Network approach described in this paper can be used to improve training from a memory and speed perspective for a wide variety of problems in Machine Learning. Extending this approach to yield a parametric Tensor Neural Network, able to instantaneously derive prices for a wide variety of different model parameters without having to retrain the Neural Network, would be an interesting and fruitful avenue of further investigation.

**Acknowledgements -** We acknowledge the regular fruitful discussions with the technical teams both at BBVA and Multiverse Computing.

**Disclaimer -** This paper is purely scientific and informative in nature and is not a product of BBVA SA or any of its subsidiaries. Neither BBVA nor such subsidiaries are aware of or necessarily share the premises, conclusions or contents in general of this document. Consequently, the responsibility for its originality, accuracy, reliability or for any other reason lies exclusively with the authors. This document is not intended as investment research or investment advice, or a recommendation, offer or solicitation for the purchase or sale of any security, financial instrument, financial product or service, or to be used in any way for evaluating the merits of participating in any transaction.
