# Dynamical Casimir cooling in circuit QED systems

Sadeq S. Kadijani  Department of Physics and Materials Science, University of
Luxembourg, L-1511 Luxembourg, Luxembourg  Nicolás Del Grosso  Universidad de
Buenos Aires, Facultad de Ciencias Exactas y Naturales, Departamento de
Física. Buenos Aires, Argentina.  CONICET - Universidad de Buenos Aires,
Instituto de Física de Buenos Aires (IFIBA). Buenos Aires, Argentina.  Thomas
L. Schmidt  Department of Physics and Materials Science, University of
Luxembourg, L-1511 Luxembourg, Luxembourg  M. Belén Farias  Department of
Physics and Materials Science, University of Luxembourg, L-1511 Luxembourg,
Luxembourg

###### Abstract

A transmission line coupled to an externally driven superconducting quantum
interference device (SQUID) can exhibit the Dynamical Casimir Effect (DCE).
Employing this setup, we quantize the SQUID degrees of freedom and show that
it gives rise to a three-body interaction Hamiltonian with the cavity modes.
By considering only two interacting modes from the cavities we show that the
device can function as an autonomous cooler where the SQUID can be used as a
work source to cool down the cavity modes. Moreover, this setup allows for
coupling to all modes existing inside the cavities, and we show that by adding
two other extra modes to the interaction with the SQUID the cooling effect can
be enhanced.

##  I Introduction

Among the different platforms that allow for an experimental study of quantum
phenomena, one that has attracted much interest over the past years is quantum
electrical circuits [1, 2, 3, 4, 5]. These systems, which consist of quantized
lumped elements such as inductors and capacitors, exhibit a wide range of
applications, ranging from performing quantum information and computation
tasks [6, 7] to the field of quantum thermodynamics [8, 9, 10].

Figure 1: The schematics of the system consisting of a transmission line
interrupted by a SQUID. Each transmission line element consists of a
capacitance $\mathcal{C}_{0}^{\pm}$ and an inductance $\ell_{0}^{\pm}$. The
SQUID itself consists of two Josephson junctions with Josephson energy $E_{J}$
in parallel to a capacitance $C_{J}$. The SQUID is threaded by a flux $f$. The
quantities $\Phi_{j}^{\pm}$ denotes the fluxes at the nodes of the system.

Within the framework of thermodynamics, it is of particular interest to
explore desirable ways to transform energy. Quantum engines have been broadly
studied [11, 12, 13, 14, 15, 16, 17], and it was found that in those settings
work can either be extracted from thermal baths, or used to transfer heat from
a cold source to a warmer one, thus working as a small-scale refrigerator.
However, quantum engines in general require measurements and external control
over the parameters and interactions. This makes them more energetically
costly than their classical counterparts when realizing them in practice.
Therefore, autonomous quantum engines [18, 19, 20], which avoid the necessity
of external control and are thus less demanding in terms of energy resources,
are desirable. In that respect, circuit QED has emerged as a promising
platform for their study, since they allow a precise control over several
parameters. For instance, Hofer et al. propose to use a Josephson junction
(JC) to create an interaction among three harmonic oscillators [21] such that
a three-body interaction Hamiltonian can be built, which creates an absorption
refrigerator [22, 23].

Another important success of circuit QED was the first experimental
realization of the Dynamical Casimir Effect (DCE) [24]. The DCE is a
phenomenon in which real photons are created out of the vacuum by the presence
of time-dependent boundary conditions of the electromagnetic (EM) field [25].
Given the difficulty of reaching the required frequencies using mechanical
setups (e.g., in the conventional configuration consisting of one perfectly
conducting cavity with one moving wall), the experimental circuit QED setup
consisted of a cavity interrupted by a superconducting quantum interference
device (SQUID) [26]. SQUIDs are superconducting loops consisting of two
Josephson junctions and are used to obtain precise measurements of magnetic
fields. By providing an external driving field to the SQUID, it can mimic the
boundary conditions that would be imposed by a fast oscillating mirror on the
EM field, which creates pairs of photons inside the cavity [27]. Building on
this, similar setups have been proposed to exploit the effects of vacuum
fluctuations, in particular to use the DCE as a resource to create
entanglement between superconducting qubits [28]. The crucial element in these
scenarios is the externally driven SQUID that creates an interaction between
pairs of modes of the cavity. However, the degrees of freedom of the SQUID
will be absent in the interaction and it only acts as a time-dependent phase
in the Hamiltonian of the system.

In the present work, we extend the previous studies by investigating the
effect of including the internal degrees of freedom of the SQUID on the modes
of the cavity with which it interacts. Our proposed setup, shown in Fig. 1,
consists of two cavities connected by a SQUID in the middle. This can be
interpreted as a transmission line interrupted by a SQUID [6, 7, 25, 2, 29,
30]. By quantizing the SQUID and the cavity field, we find that the SQUID
degrees of freedom will generate a three-body interaction Hamiltonian with the
cavity modes. We show that, by truncating the cavity to only two interacting
modes, the DCE setup will reduce to an absorption refrigerator. Therefore, by
assigning temperatures to the cavity and SQUID modes, one can use the SQUID as
a work source to cool down the coldest mode of the cavity. Furthermore, since
the SQUID couples to all the modes of the cavity, we investigate the effect of
the interplay of more than one pair of modes on the performance of the cooling
process. We observe that, depending on the temperature of the extra modes of
the cavity, they can have a positive or a negative effect on the cooling.

This paper is structured as follows. In Sec. II we present our setup by
explaining the Lagrangian of the system. In Sec. III, following Ref. [31], we
derive the quantized Hamiltonian of the SQUID and the cavity. Employing this
Hamiltonian, we show in Sec. IV that this setup can be reduced to an
absorption refrigerator Hamiltonian. Finally, in Sec. V, we study the effect
of adding more modes of the cavity on the cooling performance. We present our
conclusions in Sec. VI.

##  II The system

The main object of study of this paper will be a system consisting of a
transmission line with a SQUID in the middle, as illustrated in Fig. 1. This
system is analogous to an optical cavity divided by a wall, which can in turn
impose a time-dependent boundary condition on the EM field [28].

In our system, the cavities are represented by a large but finite number of LC
circuits, each of them consisting of identical inductors and capacitors per
unit length denoted by $\ell_{0}^{\pm}$ and $\mathcal{C}_{0}^{\pm}$,
respectively. The primary variables used to describe the transmission lines
are the node flux variables $\Phi^{\pm}_{j}(t)$ associated with each node in
the cavity. The SQUID, which plays the role of the wall in the optical analog,
consists of two parallel Josephson junctions (JJ) with identical Josephson
energies $E_{J}$ and capacitances $C_{J}$. It is represented by the node flux
at $x=0$, referred to as $\Phi_{0}$, and the phase difference $2f$, which is
associated with the SQUID self-inductance $L$. Additionally, this phase
difference can be affected by an external flux.

We begin our analysis by first writing the Lagrangian of the cavities and the
SQUID. The total Lagrangian of the system shown in Fig. 1 can be written as

$\displaystyle\mathcal{L}$
$\displaystyle=\mathcal{L}_{c}+\mathcal{L}_{s}+\mathcal{L}_{f}.$ (1)

The Lagrangian $\mathcal{L}_{c}$ describes the bare cavity and is obtained by
summing over the Lagrangians of each LC circuit element of the two cavities on
the right ($\alpha=+$) and left ($\alpha=-$) side of the SQUID,

$\displaystyle\mathcal{L}_{c}$
$\displaystyle=\frac{1}{2}\left(\frac{\hbar}{2e}\right)^{2}\sum_{\alpha=\pm}\bigg{[}\sum_{j=1}^{N}\Delta
x\mathcal{C}^{\alpha}_{0}(\dot{\Phi}_{j}^{\alpha})^{2}$
$\displaystyle-\sum_{j=0}^{N-1}\frac{\left(\Phi^{\alpha}_{j+1}-\Phi^{\alpha}_{j}\right)^{2}}{\ell_{0}^{\alpha}\Delta
x}\bigg{]},$ (2)

where $\dot{\Phi}_{j}^{\alpha}\equiv\partial_{t}\Phi^{\alpha}_{j}$,
$\Phi_{0}^{+}=\Phi_{0}^{-}\equiv\Phi_{0}$, and we have introduced $\Delta x$,
the length of each circuit element. Next, the Lagrangian $\mathcal{L}_{s}$
pertains to the SQUID part of the system,

$\displaystyle\mathcal{L}_{s}$
$\displaystyle=\left(\frac{\hbar}{2e}\right)^{2}C_{J}\left(\dot{\Phi}^{2}_{0}+\dot{f}^{2}\right)+E_{J}\sum_{\alpha=\pm}\cos(\Phi_{0}+\alpha
f).$ (3)

We can identify the first term as the sum of the Coulomb energies in the
SQUID. The second term denotes the Josephson energies which are obtained by
assuming that the SQUID inductance $L$ is split into two equal parts $L/2$
shared between the two JJs, with a phase drop of $f$ over each part.
Therefore, the phase difference on one of the JJs is $\Phi_{0}-f$ while it is
$\Phi_{0}+f$ on the other one.

Finally, the kinetic energy of the SQUID ring inductance $L$ corresponds to
the term

$\displaystyle\mathcal{L}_{f}$
$\displaystyle=-\left(\frac{\hbar}{2e}\right)^{2}\frac{1}{2L}\left(4f^{2}+8\frac{M}{L_{\rm
ext}}ff_{\rm ext}\right),$ (4)

where the first term inside the bracket is the kinetic energy produced by the
inductance $L$. In the second term we have accounted for the presence of an
external circuit with inductance $L_{\rm ext}$ which is magnetically coupled
to the SQUID by a mutual inductance $M$, which can be modulated by the
external flux $f_{\rm ext}$.

Next, we perform a continuum limit by introducing the field,

$\displaystyle\Phi(\alpha j\Delta x)\equiv\Phi^{\alpha}_{j}$ (5)

for $j\in\\{0,\ldots,N\\}$ and $\alpha=\pm$, and by taking the limit $\Delta
x\to 0$. The Lagrangian of the SQUID coupled to the cavity becomes in the
continuum limit,

$\displaystyle\mathcal{L}_{\rm cav}=\mathcal{L}_{c}+\mathcal{L}_{s}=$
$\displaystyle\left(\frac{\hbar}{2e}\right)^{2}\frac{\mathcal{C}_{0}}{2}\int_{-d/2}^{d/2}dx\left\\{\left[1+\frac{2C_{J}}{\mathcal{C}_{0}}\delta(x)\right]\dot{\Phi}^{2}-v^{2}\Phi^{\prime
2}\right\\}$
$\displaystyle+E_{J}\int_{-d/2}^{d/2}dx\delta(x)\cos(\Phi)\cos(f).$ (6)

where $\Phi^{\prime}\equiv\partial_{x}\Phi$, $d=2N\Delta x$ denotes the
lengths of the side cavities, and $v=1/\sqrt{\ell_{0}\mathcal{C}_{0}}$ is the
cavity field propagation velocity. Note that for simplicity we assumed
identical cavities to the left and right, i.e., $\ell_{0}=\ell_{0}^{\alpha}$
and $\mathcal{C}_{0}=\mathcal{C}_{0}^{\alpha}$.

Next, we can employ the full Lagrangian to derive the equations of motion.
Defining $E_{L}=\hbar^{2}/(8e^{2}L)$, we obtain the Euler-Lagrange equations
for the variables $\Phi(x)$, $\Phi_{0}=\Phi(0)$ and $f$,

$\displaystyle\ddot{\Phi}-v^{2}\Phi{{}^{\prime\prime}}=0$ (7) $\displaystyle
2\left(\frac{\hbar}{2e}\right)^{2}\\!\\!\left[C_{J}\ddot{\Phi}_{0}-\mathcal{C}_{0}v^{2}(\Phi_{0+}^{\prime}-\Phi_{0-}^{\prime})\right]\\!\\!+\\!2E_{J}\cos(f)\Phi_{0}=0$
(8)
$\displaystyle\left(\frac{\hbar}{2e}\right)^{2}C_{J}\ddot{f}+E_{J}\cos\Phi_{0}\sin
f+E_{L}\left(f+\frac{M}{L_{ext}}f_{ext}\right)=0.$ (9)

These equations describe two coupled nonlinear oscillators, so the solution
will in general feature chaotic behavior. With this in mind, we will restrict
our analysis to the case in which the flux variable $\Phi_{0}\ll 1$ and this
is satisfied in the phase regime of superconducting qubits where
$E_{J}\gg(2e)^{2}/(2C_{J})$ [3]. In this case, Eqs. (8) and (9) will decouple,
and the equation of motion for $f$ will read

$\left(\frac{\hbar}{2e}\right)^{2}C_{J}\ddot{f}+E_{J}\sin
f+E_{L}\left(f+\frac{M}{L_{ext}}f_{ext}\right)=0,$ (10)

and for small values of $f$ it will describe a shifted harmonic oscillator.

Before further discussing the dynamics of $f$, we will focus on the equation
of motion (7) for $\Phi(x,t)$. It can be solved by introducing a time-
dependent basis [7] such that

$\Phi(x,t)=\sum_{n}\phi_{n}(t)\psi_{n}(x,t),$ (11)

where the summation runs over all the modes of the cavity and $\phi_{n}(t)$ is
the time-dependent flux variable, while $\psi_{n}(x,t)$ represents the
instantaneous eigenmodes of the cavity and obeys the equations

$\displaystyle\psi_{n}^{\prime\prime}(x,t)+k^{2}_{n}(t)\psi_{n}(x,t)=0,$
$\displaystyle\psi^{\prime}_{n}(-d/2,t)=\psi^{\prime}_{n}(d/2,t)=0,$ (12)
$\displaystyle\psi_{n}^{\prime}(0^{+},t)-\psi_{n}^{\prime}(0^{-},t)=$
$\displaystyle\frac{2}{v^{2}}\left(-\frac{C_{J}v^{2}k_{n}^{2}(t)}{\mathcal{C}_{0}}+\frac{E_{J}\cos
f(t)}{\left(\frac{\hbar}{2e}\right)^{2}\mathcal{C}_{0}}\right)\psi_{n}(0,t),$

where $k_{n}(t)=\omega_{n}(t)/v$ is the wave vector and
${\omega_{n}(t)\equiv\omega(f(t))}$ is the time-dependent frequency of the
$n$th oscillator which can be obtained by solving Eq. (12) (see Ref. [32] for
more details). It is important here to remark that the time-dependence in the
functions $\psi_{n}(x,t)$ is a result of the time-dependence of the
frequencies of the cavity modes $\omega_{n}(t)$, which is in turn caused by
the time-dependent SQUID flux variable $f(t)$. Using Eq. (11) and the given
boundary conditions one can obtain the Lagrangian of the cavity
$\mathcal{L}_{\rm cav}$ in terms of $\phi_{n}(t)$ and $\psi_{n}(x,t)$ in the
following form (see App. A for more details),

$\displaystyle\mathcal{L}_{\rm cav}$
$\displaystyle=\frac{\hbar^{2}}{4E_{C}}\sum_{n}\left(\dot{\phi}_{n}^{2}-\omega_{n}^{2}(t)\phi_{n}^{2}\right)+\frac{\hbar^{2}\dot{f}}{2E_{C}}\sum_{nm}M_{nm}\dot{\phi}_{n}\phi_{m}$
$\displaystyle+\frac{\hbar^{2}}{4E_{C}}\frac{\dot{f}^{2}}{2}\sum_{nmk}M_{nk}M_{mk}\phi_{n}\phi_{m}.$
(13)

In the above Lagrangian we defined $E_{C}=(2e)^{2}/(2C)$ as the charging
energy corresponding to the capacitance $C$ of the cavity mode, and we have
defined

$M_{nm}=\frac{1}{d}\int_{-d/2}^{d/2}dx[1+2C_{J}/\mathcal{C}_{0}\delta(x)]\psi_{m}\frac{d\psi_{n}}{df}\,,$
(14)

where the time-dependence of the $\psi_{n}$ functions is related to the field
$f$. The Lagrangian (13) indicates that the time-dependence in $f$ causes an
interaction among the modes of the cavity. We can interpret such an
interaction as a manifestation of the Dynamical Casimir effect (DCE). In the
standard DCE setting, the SQUID flux $f$ is externally driven, thus inducing
an interaction among the cavity modes (two-mode squeezing) [28, 27, 33]. In
contrast, we are aiming at considering $f$ as an interacting mode rather than
a time-dependent phase. To do so, we will consider the full Lagrangian of the
system $\mathcal{L}=\mathcal{L}_{\rm cav}+\mathcal{L}_{f}$ to find the total
Hamiltonian. Following a procedure analogous to Ref. [31], we will find the
quantized Hamiltonian of the cavity and the SQUID in the next section.

##  III Quantized Hamiltonian

We can write the full Lagrangian $\mathcal{L}$ of the system by combining Eq.
(13) with $\mathcal{L}_{f}$ from the SQUID Lagrangian,

$\displaystyle\mathcal{L}$
$\displaystyle=\frac{\hbar^{2}}{4E_{C}}\sum_{n}\left(\dot{\phi}_{n}^{2}-\omega_{n}^{2}(t)\phi_{n}^{2}\right)+\frac{\hbar^{2}}{2E_{C}}\dot{f}\sum_{nm}M_{nm}\dot{\phi_{n}}\phi_{m}$
$\displaystyle+\frac{\hbar^{2}}{4E_{C}}\frac{\dot{f}^{2}}{2}\sum_{n,m,k}M_{nk}M_{mk}\phi_{n}\phi_{m}+\frac{\hbar^{2}}{2E_{C_{J}}}\frac{\dot{f}^{2}}{2}-V(f),$
(15)

where we have defined the energy of the Josephson capacitance as
$E_{C_{J}}=(2e)^{2}/2C_{J}$, and

$V(f)=-E_{J}\cos
f+\left(\frac{\hbar}{2e}\right)^{2}\frac{1}{L}\left(f^{2}+\frac{M}{L_{ext}}ff_{ext}\right)$
(16)

is the potential term.

From this Lagrangian one obtains the momentum variables conjugate to the SQUID
flux $f$ and the cavity fluxes $\phi_{n}$,

$\displaystyle q_{n}$
$\displaystyle=\frac{1}{\hbar}\frac{\partial\mathcal{L}}{\partial\dot{\phi}_{n}}=\frac{\hbar}{2E_{C}}\left(\dot{\phi}_{n}+\dot{f}\sum_{m}M_{nm}\phi_{m}\right),$
(17) $\displaystyle p_{f}$
$\displaystyle=\frac{1}{\hbar}\frac{\partial\mathcal{L}}{\partial\dot{f}}=\frac{\hbar}{2E_{C_{J}}}\dot{f}$
(18)
$\displaystyle+\frac{\hbar}{2E_{C}}\left(\dot{f}\sum_{nmk}M_{nk}M_{mk}\phi_{n}\phi_{m}+\sum_{nm}M_{nm}\dot{\phi_{n}}\phi_{m}\right)\,.$

Here, $q_{n}$ denotes the charge variable of the $n$th oscillator of the
cavity and $p_{f}$ is the momentum variable of the SQUID. Note that the
fraction $1/\hbar$ is added to make the momenta dimensionless. By performing a
Legendre transformation of the Lagrangian we can find the Hamiltonian of the
total system in terms of the flux and charge variables. Moreover, we promote
the momentum and position variables to quantum operators by imposing the
commutation relation $[\phi_{n},q_{n}]=i$. In this way we can substitute

$\displaystyle\phi_{n}$
$\displaystyle=\sqrt{\frac{\hbar\omega_{n}(t)}{2E_{C}}}\left(a_{n}+a_{n}^{\dagger}\right),$
(19) $\displaystyle q_{n}$
$\displaystyle=-i\sqrt{\frac{E_{C}}{2\hbar\omega_{n}(t)}}\left(a_{n}-a_{n}^{\dagger}\right).$
(20)

Hence, the Hamiltonian will take the following form,

$\displaystyle
H=\sum_{n}\hbar\omega_{n}(t)a_{n}^{\dagger}a_{n}+\frac{\left(2e\right)^{2}}{2C_{J}}\left[p_{f}+\Gamma(f)\right]^{2}+V(f)\,,$
(21)

where
$\Gamma(f)\equiv(i/2)\sum_{nm}M_{nm}\left(a_{n}-a_{n}^{\dagger}\right)\left(a_{n}+a_{n}^{\dagger}\right)$.
This Hamiltonian indicates that the SQUID momentum will interact with the
cavity modes through the term $\Gamma$. The $f$ dependence of $\Gamma$ comes
from the fact that the operators $a_{n}$ and $a^{\dagger}_{n}$ in (20) depend
on $f$ through the time-dependent frequency $\omega_{n}(t)$.

At this point we are in a position to perform a first linear approximation of
the Hamiltonian. This can be done by assuming that the position variable $f$
of the SQUID undergoes only small oscillations about its rest position
$f_{0}$, i.e., $f(t)\approx f_{0}+\delta f(t)$ where $\delta f(t)\ll 1$. In
this case, the frequency can be expanded to first order in $\delta f$ as
$\omega_{n}(f)\approx\omega_{n}(f_{0})+\delta f\omega_{n}^{\prime}(f_{0})$.
Replacing this into Eq. (20) we find, to first order in $\delta f$,

$a_{n}\approx a_{n}(f_{0})-\frac{1}{2}\delta
f\frac{\omega_{n}^{\prime}(f_{0})}{\omega_{n}(f_{0})}a_{n}^{\dagger}(f_{0})\,.$
(22)

Moreover, we should also do the same expansion for the other $f$-dependent
parameters of the system, i.e., $M_{nm}$ and $\Gamma(f)$. Therefore, we write
${M_{nm}=M_{nm0}+\delta fM^{\prime}_{nm}}$ with
${M^{\prime}_{mn0}=\sum_{k}M_{nk0}M_{mk0}}$ and

$M_{nm0}=\frac{1}{d}\int_{-d/2}^{d/2}dx[1+2C_{J}/\mathcal{C}_{0}\delta(x)]\psi_{m}(f_{0})\frac{d\psi_{n}(f_{0})}{df_{0}}.$
(23)

Using this we can also write $\Gamma(f)\approx\Gamma(f_{0})+\delta
f\Gamma^{\prime}(f_{0})$ such that

$\displaystyle\Gamma^{\prime}(f_{0})=\sqrt{\frac{\omega_{m}(f_{0})}{\omega_{n}(f_{0})}}M_{nm}^{\prime}\left(a_{m}+a_{m}^{\dagger}\right)\left(a_{n}-a_{n}^{\dagger}\right)$
$\displaystyle+\sqrt{\frac{\omega_{m}(f_{0})}{\omega_{n}(f_{0})}}M_{nm}\frac{\omega_{n}^{\prime}(f_{0})}{\omega_{n}(f_{0})}\left(a_{m}+a_{m}^{\dagger}\right)\left(a_{n}-a_{n}^{\dagger}\right),$
(24)

where we have dropped the $f_{0}$ dependence of the ladder operators. Now we
can insert the above expansions into Eq. (21) and find the Hamiltonian in
terms of $\delta f$. Dropping the $f_{0}$ dependence of $\omega^{\prime}_{n}$
and $\omega_{n}$ we find

$\displaystyle H=\hbar\sum_{n}\left(\omega_{n}+\omega_{n}^{\prime}\delta
f\right)\left(\\!\\!a_{n}^{\dagger}\\!-\delta
f\frac{\omega_{n}^{\prime}}{2\omega_{n}}a_{n}\\!\\!\right)\left(\\!\\!a_{n}\\!-\delta
f\frac{\omega_{n}^{\prime}}{2\omega_{n}}a_{n}^{\dagger}\\!\\!\right)$
$\displaystyle+E_{C_{J}}\left(p_{f}+\Gamma_{0}+\delta
f\Gamma^{\prime}_{0}\right)^{2}+V(\delta f)\,.$ (25)

Equation (25) evidently denotes the nonlinear interaction between the modes
and $\delta f$. To find the first linear order of the interaction Hamiltonian
in terms of $\delta f$, we perform a unitary transformation
$H^{\prime}=T^{\dagger}HT$ where

$T=\exp\left\\{i\delta f(\Gamma_{0}+\frac{1}{2}\delta
f\Gamma^{\prime}_{0})\right\\}.$ (26)

Applying this on the square term in Eq. (25) we see that
$T^{\dagger}\left(p_{f}+\Gamma_{0}+\delta
f\Gamma^{\prime}_{0}\right)^{2}T=p_{f}^{2}$, so the transformation effectively
shifts the momentum $p_{f}$ by $\Gamma_{0}+\delta\Gamma^{\prime}_{0}$. The
effect of the translation on the other parts of the Hamiltonian gives rise to
interaction terms in powers of $\delta f$ (see App. B for details). To keep
the linear interaction terms, we proceed to a rotating wave approximation
(RWA) in order to eliminate fast oscillating terms in the Hamiltonian. To do
so, we first promote $p_{f}$ and $\delta_{f}$ to quantum operators, as was
done for the cavity variables, by defining their commutation relation $[\delta
f,p_{f}]=i$. Thus, we can write

$\displaystyle\delta
f=\sqrt{\frac{E_{C_{J}}}{\hbar\omega_{f}}}\left(a_{f}+a_{f}^{\dagger}\right)\,,$
(27) $\displaystyle
p_{f}=-i\frac{1}{2}\sqrt{\frac{\hbar\omega_{f}}{E_{C_{J}}}}\left(a_{f}-a_{f}^{\dagger}\right)\,,$
(28)

where

$\displaystyle\omega_{f}^{2}=\frac{E_{J}E_{C_{J}}}{\hbar^{2}}\left(\cos
f_{0}+\left(\frac{\hbar}{2e}\right)^{2}\frac{2}{LE_{J}}\right)$ (29)

is the frequency of the oscillations in $\delta f$ (see App. B for details).
To perform the RWA, we have to transform the Hamiltonian (25) into the
rotating frame by the application of the unitary operator

$U=\exp\left(\frac{it}{\hbar}\sum_{n}\hbar\omega_{n}a_{n}^{\dagger}a_{n}+\hbar\omega_{f}a_{f}^{\dagger}a_{f}\right).$
(30)

Afterwards we only keep the terms that satisfy the resonance condition
$\omega_{f}=\omega_{n}+\omega_{m}$ for $m\neq n$. Going back to the
Schrödinger picture, the Hamiltonian of the system becomes

$\displaystyle
H_{\text{RWA}}=\hbar\sum_{n}\omega_{n}a_{n}^{\dagger}a_{n}+\hbar\omega_{f}a_{f}^{\dagger}a_{f}$
(31)
$\displaystyle-\frac{\hbar}{2}\sqrt{\frac{E_{C_{J}}}{\hbar\omega_{f}}}\sum_{n,m}M_{nm0}\sqrt{\frac{\omega_{m}}{\omega_{n}}}\\!\omega_{f}\\!\left(\\!a_{f}^{\dagger}a_{m}a_{n}+a_{f}a_{m}^{\dagger}a_{n}^{\dagger}\\!\right),$

where the summation runs over all the frequencies that satisfy the resonance
condition. The Hamiltonian in Eq. (31) reflects the three-body interaction
among the modes of the cavity and the SQUID mode. One interesting feature of
this Hamiltonian is that by choosing only two interacting modes from the
cavity, one can show that the system can behave as a quantum autonomous
refrigerator.

##  IV absorption refrigerator

At this point, we proceed by simplifying the Hamiltonian (31) further by only
considering two modes of the cavity, i.e., $n,m\in\\{1,2\\}$, so that the only
interaction term contains $a_{f}^{\dagger}a_{2}a_{1}+\text{h.c.}$. The
Hamiltonian then describes an absorption refrigerator [21, 23, 22].

In this setup, the interaction term $a_{f}^{\dagger}a_{2}a_{1}$ entails that
one photon is created in the SQUID while two photons are annihilated in the
two modes of the cavity. This lowers the energy stored in the two modes and
increases the energy of the SQUID, so that one can achieve autonomous cooling
of one mode by utilizing the other two modes.

On the other hand, the hermitian conjugate term
$a_{f}a_{2}^{\dagger}a_{1}^{\dagger}$ describes a reverse process, i.e., one
photon being annihilated in the SQUID while one photon is created at each
cavity mode. However, one can favor the cooling term by conveniently choosing
the energy levels of each oscillator. One possibility is to connect each
cavity to a heat bath, allowing them to reach a thermal equilibrium state with
temperatures $T_{i}$ for $i\in\\{f,1,2\\}$. By adjusting these temperatures,
the occupation probabilities of the oscillators can be tuned. The initial
occupation number $n_{i}$ of the $i$th oscillator can be expressed as

$n_{i}=\operatorname{Tr}[\rho_{T_{i}}a^{\dagger}_{i}a_{i}]\,,$ (32)

where

$\rho_{T_{i}}=\frac{\exp\left(-\frac{\hbar\omega_{i}}{k_{B}T_{i}}a^{\dagger}_{i}a_{i}\right)}{\operatorname{Tr}\left[\exp\left(-\frac{\hbar\omega_{i}}{k_{B}T_{i}}a^{\dagger}_{i}a_{i}\right)\right]}$
(33)

is the thermal initial state of the $i$th oscillator $i\in\\{f,1,2\\}$.

In general, the system can operate both as a refrigerator and as a heat
engine. By applying the resonance condition
$\omega_{f}=\omega_{1}+\omega_{2}$, one can adjust the temperatures of the
three modes (corresponding to the initial occupation probabilities) in a way
that allows the SQUID to cool down the other two cavities. This occurs when
the temperature of the SQUID is higher than or equal to the cold mode
($T_{2}$) while still being smaller than the hot mode ($T_{1}$), i.e.,
$T_{2}\leq T_{f}<T_{1}$. In this temperature regime, the state of SQUID will
have a lower occupation probability than to the other modes, so the final
average energy of the SQUID,
$E_{f}(t)=\mathrm{Tr}[\omega_{f}a_{f}^{\dagger}a_{f}\rho(t)]$, exceeds its
initial energy obtained from the thermal state
$E_{f}(t)=\mathrm{Tr}[\omega_{f}a_{f}^{\dagger}a_{f}\rho_{T_{f}}(0)]$.

Figure 2: Averaged energies of each mode after time t, showing the increase in
energy of the SQUID and the decrease in energy of the cold mode ($n_{2}$) and
the hot mode ($n_{1}$). The solid lines show the average energy of each
oscillator at time $t$. Dashed lines indicate the average energy at the
initial time. This plot is depicted for frequencies are
$\omega_{f}=3\omega_{0}$, $\omega_{2}=2\omega_{0}$ and $\omega_{1}=\omega_{0}$
where $\omega_{0}=1$GHz and the temperatures are
$T_{f}=65(\hbar\omega_{0}/k_{B})$, $T_{2}=T_{f}$ and
$T_{1}=100(\hbar\omega_{0}/k_{B})$.

Moreover, the setup in Fig. 1 offers the freedom to select the modes that are
located on the left or right side of the SQUID. Therefore, it is possible to
cool one half of the cavity by choosing parameters that localize the field
modes [32]. There are two options to ensure that the system will indeed work
as a refrigerator. The first approach involves connecting each mode to
separate heat baths initially, allowing them to reach their respective
temperatures. Subsequently, the modes interact with each other while still
being influenced by the baths. In this scenario, the dynamics at time $t$ can
be obtained by solving a master equation as demonstrated in Ref. [21]. An
alternative approach is to disconnect the modes from the heat baths once they
have reached their respective temperatures. Afterwards, the modes interact
with each other without the influence of the baths [23]. In this case, the
dynamics are determined by the unitary time evolution. Since both cases lead
to similar results, for simplicity and the sole purpose of demonstrating the
behavior of the cooling system in our setup, we will consider the latter
scenario from this point on.

To obtain numerical results, we use the QuTip library [34] to solve the
unitary dynamics caused by the rotated Hamiltonian (31). In Fig. 2, we show
the resulting average energy of each mode as a function of time $t$. The
comparison with their initial values clearly indicates that the energy of the
SQUID increases while the other two modes become colder. This confirms that
this configuration operates as a refrigerator, consistent with the findings in
Ref. [23, 22]. As a matter of fact, a better indication that this setup can
work as a cooler can be achieved by monitoring the temperature of the cold
mode while it remains in contact with a heat bath as shown in Ref. [21]. This
involves solving a quantum master equation to find the dynamics of each mode.
In contrast, here we limited ourselves to a closed system case as it still
captures the essential dynamical behaviour of the cooler similarly to the open
dynamics [23].

##  V Enhanced cooling

In the previous section, we show that by keeping only two interacting modes of
the cavity, the system can act as an absorption refrigerator. However, one of
the advantages of the proposed setup is that it gives us the freedom to retain
more modes as long as they fulfill the resonance condition
$\omega_{f}=\omega_{n}+\omega_{m}$. In this section we will study the effect
on the refrigeration process of two extra modes from the cavity.

Figure 3: Average energy of the cold mode ($n_{2}$) as a function of time $t$.
The blue line indicates the energy of the cold mode when the SQUID is
interacting only with the hot and cold modes (two modes) of the cavity. The
red line denotes the energy of the cold mode when two extra modes are added.
The frequencies are $\omega_{f}=3\omega_{0}$, $\omega_{3}=1.8\omega_{0}$ and
$\omega_{4}=1.2\omega_{0}$ and the temperatures are
$T_{f}=65(\hbar\omega_{0}/k_{B})$, $T_{3}=T_{4}=92(\hbar\omega_{0}/k_{B})$.

We now consider the Hamiltonian (31) with four modes $\omega_{1,2,3,4}$, such
that they satisfy $\omega_{f}=\omega_{3}+\omega_{4}=\omega_{1}+\omega_{2}$.
The resulting Hamiltonian will take the form

$\displaystyle H_{\rm
ref}=\hbar\sum_{n=1,2}\omega_{n}a_{n}^{\dagger}a_{n}+\hbar\omega_{f}a_{f}^{\dagger}a_{f}$
(34)
$\displaystyle-\frac{1}{2}\sqrt{\hbar\omega_{f}E_{C_{J}}}\sum_{n,m=1,2}\\!\\!M_{nm0}\sqrt{\frac{\omega_{m}}{\omega_{n}}}\left(a_{f}^{\dagger}a_{2}a_{1}+a_{f}a_{2}^{\dagger}a_{1}^{\dagger}\right)$
$\displaystyle-\frac{1}{2}\sqrt{\hbar\omega_{f}E_{C_{J}}}\sum_{n,m=3,4}\\!\\!M_{nm0}\sqrt{\frac{\omega_{m}}{\omega_{n}}}\left(a_{f}^{\dagger}a_{3}a_{4}+a_{f}a_{3}^{\dagger}a_{4}^{\dagger}\right).$

Figure 4: Averaged energy of all the modes after time $\omega_{0}t$. The cold
mode ($n_{2}$) cools down and the cooling period is longer compared to the
case of only two interacting modes (see Fig. 2).

The modes 1 and 2 are the hot and cold modes of the refrigerators, and they
will not interact directly with the extra modes 3 and 4. To study the impact
of these modes on the refrigeration process, we assign thermal states to the
two modes with temperatures $T_{3}$ and $T_{4}$.

It turns out that the refrigeration process will depend strongly on the
temperatures of those modes. If we set their temperatures to be higher than
the temperature of the cold mode ($T_{2}$) and the SQUID mode ($T_{f}$), the
energy of the cold mode will be higher compared to the two-mode case. The
reason lies behind the fact that when the SQUID mode interacts with the extra
modes, due to their higher temperature, the SQUID mode will become hotter and
its state population will grow. Therefore, since the SQUID is simultaneously
in contact with the cold mode, due to its higher energy, it will not be able
to decrease the energy of the cold mode as it did before. The result of this
process is sketched in Fig. 3. We notice, as expected, that when the
temperatures of the two extra modes are higher than that of the SQUID and the
cold mode, the cooling process is less effective.

Figure 5: Averaged energy of the cold mode. When the SQUID is interacting with
the two extra modes which have the same temperature of the cold mode, the
cooling process is enhanced (red line). The frequencies are
$\omega_{f}=3\omega_{0}$, $\omega_{3}=1.8\omega_{0}$ and
$\omega_{4}=1.2\omega_{0}$, and the temperatures are
$T_{f}=65(\hbar\omega_{f}/k_{B})$ and $T_{3}=T_{4}=T_{f}$.  Figure 6: Averaged
energy of the cold mode. By decreasing the temperature of the extra modes, one
can further enhance the cooling of the cold mode ($n_{2}$). We compare the
cooling in the case of two modes (blue line) to the case of cooling in the
presence of four modes for $T_{3}=T_{4}=65\hbar\omega_{0}$ (red line),
$T_{3}=T_{4}=40\hbar\omega_{0}$ (yellow line), and
$T_{3}=T_{4}=\hbar\omega_{0}$ (black line).

On the other hand, if we choose the temperatures of the extra modes to be
equal to the temperatures of the SQUID and the cold mode, we observe enhanced
cooling (see Fig. 4). When the SQUID interacts with the cold mode, its energy
will increase. Therefore, during the interaction with the extra modes, it will
release its energy to those modes. Thus, when it comes back to interact with
the cold mode again, it has a lower population than before and therefore it
can lower the cold mode energy. This results in an enhancement in the
refrigeration process, and the two extra modes are acting like heat sinks that
decrease the energy of the SQUID during the interaction. Figure 5 shows the
behavior of the cold mode when the temperatures of the extra modes are equal
to that of the SQUID and the cold mode. We notice that this not only improves
the cooling process but also that the cold mode keeps its minimum energy for a
longer period of time before moving into the oscillatory dynamics.

The effect of decreasing the temperatures of the extra modes below the
temperature of the SQUID and cold mode is also depicted in Fig. 6. We observe
that if we decrease the temperature of the extra modes to below the
temperature of the cold and SQUID modes, we can improve the cooling effect
even further. Nevertheless, this cooling will stop at some point which can be
related to the fundamental limit of cooling [35]. This effect can be observed
in externally driven systems and we do not have drive in our Hamiltonian due
to quantizing the SQUID degrees of freedom. However, since the original setup
stems from the dynamical Casimir effect, we can argue that this cooling limit
should still exist because we are considering the quantized version of the
driven SQUID. This means that a time-dependent classical phase in the
Hamiltonian is now treated quantum mechanically to create a three body
Hamiltonian instead of two body interaction.

##  VI Conclusions

We investigated cooling in a setup consisting of a finite transmission line
interrupted by a SQUID, a system that has been used to experimentally realize
the Dynamical Casimir effect [27]. By quantizing the SQUID degrees of freedom,
we obtained the Lagrangian of the quantized system in terms of the modes
inside the cavity. After switching to the Hamiltonian representation, we
obtained a three-body interaction term consisting of the cavity modes
operators and the SQUID. By keeping only two interacting modes of the cavity
we reduced the Hamiltonian into the form of the absorption refrigerator
interaction. Therefore, we showed that in some temperature regime, by
increasing the energy of the SQUID mode, one can cool down the two modes of
the cavity.

To study the effect of the other existing modes of the cavity on the cooling
process, we explored the influence of including two extra modes in the
interaction with the SQUID. In this way we observed that, if the initial
temperature of the extra modes are equal to the cold mode and the SQUID, one
can cool the cold mode even further than the previous case. This result is
significant as it demonstrates the versatility of the architecture depicted in
Fig. 1 where the system offers the flexibility to work with multiple cavity
modes and their interactions with the SQUID.

Since the Hamiltonian (31) contains a squeezing interaction term which stems
from the DCE, we expect that this interaction among the cavity modes and the
SQUID can create entanglement among the involved modes which may play a role
in the cooling effect. Analyzing the role of entanglement for cooling is
beyond the scope of the present work but would be interesting to study in
future work.

##  VII Acknowledgements

The authors would like to thank J. N. Freitas for helpful discussions, and
acknowledge financial support from the National Research Fund Luxembourg under
Grants C20/MS/14757511/OpenTop and C18/MS/12704391/QUTHERM, the Agencia
Nacional de Promoción Científica y Tecnológica (ANPCyT), Consejo Nacional de
Investigaciones Científicas y Técnicas (CONICET), and Universidad de Buenos
Aires (UBA).

## References

  * Devoret  _et al._ [1995] M. H. Devoret _et al._ , Les Houches, Session LXIII 7, 133 (1995).
  * [2] S. M. Girvin, in  _Quantum Machines: Measurement and Control of Engineered Quantum Systems_, edited by M. Devoret, B. Huard, R. Schoelkopf, and L. F. Cugliandolo (Oxford University PressOxford) 1st ed., pp. 113–256.
  * Devoret  _et al._ [2004] M. H. Devoret, A. Wallraff, and J. M. Martinis, arXiv preprint cond-mat/0411174 https://arxiv.org/abs/cond-mat/0411174 (2004).
  * Beaudoin  _et al._ [2011] F. Beaudoin, J. M. Gambetta, and A. Blais, Physical Review A 84, 043832 (2011).
  * Majer  _et al._ [2007] J. Majer, J. Chow, J. Gambetta, J. Koch, B. Johnson, J. Schreier, L. Frunzio, D. Schuster, A. A. Houck, A. Wallraff, _et al._ , Nature 449, 443 (2007).
  * [6] W. Wustmann and V. Shumeiko, Parametric resonance in tunable superconducting cavities, 1302.3484 [cond-mat, physics:quant-ph] .
  * [7] C. D. Fosco, F. C. Lombardo, and F. D. Mazzitelli, Physical Review D 87, 105008.
  * Senior  _et al._ [2020] J. Senior, A. Gubaydullin, B. Karimi, J. T. Peltonen, J. Ankerhold, and J. P. Pekola, Communications Physics 3, 40 (2020).
  * Karimi and Pekola [2016] B. Karimi and J. Pekola, Physical Review B 94, 184503 (2016).
  * Kadijani  _et al._ [2020] S. S. Kadijani, T. L. Schmidt, M. Esposito, and N. Freitas, Physical Review B 102, 235422 (2020).
  * Uzdin  _et al._ [2015] R. Uzdin, A. Levy, and R. Kosloff, Physical Review X 5, 031044 (2015).
  * Zhang  _et al._ [2014] K. Zhang, F. Bariani, and P. Meystre, Physical review letters 112, 150602 (2014).
  * Roßnagel  _et al._ [2014] J. Roßnagel, O. Abah, F. Schmidt-Kaler, K. Singer, and E. Lutz, Physical review letters 112, 030602 (2014).
  * Chand and Biswas [2017] S. Chand and A. Biswas, Physical Review E 95, 032111 (2017).
  * Klaers  _et al._ [2017] J. Klaers, S. Faelt, A. Imamoglu, and E. Togan, Physical Review X 7, 031044 (2017).
  * Camati  _et al._ [2019] P. A. Camati, J. F. Santos, and R. M. Serra, Physical Review A 99, 062103 (2019).
  * Roßnagel  _et al._ [2016] J. Roßnagel, S. T. Dawkins, K. N. Tolazzi, O. Abah, E. Lutz, F. Schmidt-Kaler, and K. Singer, Science 352, 325 (2016).
  * Levy and Kosloff [2012] A. Levy and R. Kosloff, Physical review letters 108, 070604 (2012).
  * Palao  _et al._ [2001] J. P. Palao, R. Kosloff, and J. M. Gordon, Physical Review E 64, 056130 (2001).
  * Linden  _et al._ [2010] N. Linden, S. Popescu, and P. Skrzypczyk, Physical review letters 105, 130401 (2010).
  * [21] P. P. Hofer, M. Perarnau-Llobet, J. B. Brask, R. Silva, M. Huber, and N. Brunner, Physical Review B 94, 235420.
  * [22] G. Maslennikov, S. Ding, R. Hablützel, J. Gan, A. Roulet, S. Nimmrichter, J. Dai, V. Scarani, and D. Matsukevich, Nature Communications 10, 202, number: 1 Publisher: Nature Publishing Group.
  * [23] S. Nimmrichter, J. Dai, A. Roulet, and V. Scarani, Quantum 1, 37, 1709.08353 [quant-ph] .
  * Dodonov [2020] V. Dodonov, Physics 2, 67 (2020).
  * [25] A. Lupascu, C. J. P. M. Harmans, and J. E. Mooij, Physical Review B 71, 184506, cond-mat/0410730 .
  * [26] The SQUID handbook, OCLC: ocm52746892.
  * [27] C. M. Wilson, G. Johansson, A. Pourkabirian, M. Simoen, J. R. Johansson, T. Duty, F. Nori, and P. Delsing, Nature 479, 376.
  * [28] S. Felicetti, M. Sanz, L. Lamata, G. Romero, G. Johansson, P. Delsing, and E. Solano, Physical Review Letters 113, 093602, 1402.4451 [cond-mat, physics:quant-ph] .
  * [29] M. Wallquist, V. S. Shumeiko, and G. Wendin, Physical Review B 74, 224506, cond-mat/0608209 .
  * [30] J. Bourassa, F. Beaudoin, J. M. Gambetta, and A. Blais, Physical Review A 86, 013814, 1204.2237 [cond-mat, physics:quant-ph] .
  * [31] C. K. Law, Physical Review A 51, 2537.
  * Velasco  _et al._ [2022] C. I. Velasco, N. F. Del Grosso, F. C. Lombardo, A. Soba, and P. I. Villar, Physical Review A 106, 043701 (2022).
  * Drechsler  _et al._ [2020] M. Drechsler, M. B. Farías, N. Freitas, C. T. Schmiegelow, and J. P. Paz, Physical Review A 101, 052331 (2020).
  * Johansson  _et al._ [2012] J. R. Johansson, P. D. Nation, and F. Nori, Computer Physics Communications 183, 1760 (2012).
  * Freitas and Paz [2017] N. Freitas and J. P. Paz, Physical Review E 95, 012146 (2017).

##  Appendix A Lagrangian of the cavity modes

To obtain the Lagrangian of the cavity $L_{cav}$ we first need to find

$\displaystyle\dot{\Phi}=\sum_{n}\dot{\phi}_{n}\psi_{n}+\phi_{n}\dot{\psi}$
(35)
$\displaystyle\Phi^{\prime}(x,t)=\sum_{n}\phi_{n}(t)\psi^{\prime}_{n}(x,t)$
(36)

and consequently

$\displaystyle\dot{\Phi}^{2}=\sum_{n,m}\dot{\phi}_{n}\dot{\phi}_{m}\psi_{n}\psi_{m}+\sum_{n,m}\phi_{n}\phi_{m}\dot{\psi}_{n}\dot{\psi}_{m}+2\sum_{n,m}\dot{\phi}_{n}\phi_{m}\psi_{n}\dot{\psi}_{m}$
(37) $\displaystyle\Phi^{\prime
2}(x,t)=\sum_{mn}\phi_{n}(t)\phi_{m}(t)\psi^{\prime}_{n}(x,t)\psi^{\prime}_{m}(x,t).$
(38)

We then replace these terms inside the Lagrangian (II) and from the first term
we will have

$\displaystyle\left(\frac{\hbar}{2e}\right)^{2}\mathcal{C}_{0}\int_{-d/2}^{d/2}(1+2C_{J}/\mathcal{C}_{0}\delta(x))\dot{\Phi}^{2}=\left(\frac{\hbar}{2e}\right)^{2}\mathcal{C}_{0}\sum_{n,m}\dot{\phi}_{n}\dot{\phi}_{m}\int_{-d/2}^{d/2}(1+2C_{J}/\mathcal{C}_{0}\delta(x))\psi_{n}\psi_{m}$
$\displaystyle+\left(\frac{\hbar}{2e}\right)^{2}\mathcal{C}_{0}\sum_{n,m}\phi_{n}\phi_{m}\int_{-d/2}^{d/2}(1+2C_{J}/\mathcal{C}_{0}\delta(x))\dot{\psi}_{n}\dot{\psi}_{m}+2\left(\frac{\hbar}{2e}\right)^{2}\mathcal{C}_{0}\sum_{n,m}\dot{\phi}_{n}\phi_{m}\int_{-d/2}^{d/2}(1+2C_{J}/\mathcal{C}_{0}\delta(x))\psi_{n}\dot{\psi}_{m}.$
(39)

We define the inner product as

$\displaystyle\frac{1}{d}\int_{-d/2}^{d/2}(1+2C_{J}/\mathcal{C}_{0}\delta(x))\psi_{n}\psi_{m}=\delta_{mn},$
(40)

and using this we obtain

$\left(\frac{\hbar}{2e}\right)^{2}\mathcal{C}_{0}\int_{-d/2}^{d/2}(1+2C_{J}/\mathcal{C}_{0}\delta(x))\dot{\Phi}^{2}=\left(\frac{\hbar}{2e}\right)^{2}C\sum_{n}\dot{\phi}_{n}^{2}+2\left(\frac{\hbar}{2e}\right)^{2}C\sum_{n,m}A_{mn}\dot{\phi}_{n}\phi_{m}+\left(\frac{\hbar}{2e}\right)^{2}C\sum_{n,m}B_{mn}\phi_{n}\phi_{m}$
(41)

where we defined $\mathcal{C}_{0}=C/d$ and

$\displaystyle
A_{mn}=\frac{1}{d}\int_{-d/2}^{d/2}dx(1+2C_{J}/\mathcal{C}_{0}\delta(x))\psi_{n}\dot{\psi}_{m}$
(42) $\displaystyle
B_{mn}=\frac{1}{d}\int_{-d/2}^{d/2}dx(1+2C_{J}/\mathcal{C}_{0}\delta(x))\dot{\psi}_{n}\dot{\psi}_{m}=\sum_{k}A_{mk}A_{nk}=\sum_{k}A_{mk}A_{nk}.$
(43)

The next term in the Lagrangian will give rise to

$\displaystyle-\int_{-d/2}^{d/2}dxv^{2}\Phi^{\prime
2}=-v^{2}\sum_{mn}\phi_{n}(t)\phi_{m}(t)\int_{-d/2}^{d/2}dx\psi^{\prime}_{n}(x,t)\psi^{\prime}_{m}(x,t)=-v^{2}\sum_{mn}k_{n}^{2}\phi_{n}^{2}(t)+E_{J}\cos
f\Phi_{0},$ (44)

where to obtain the last equality we have used the boundary condition (12)
together with the inner product. Therefore the Lagrangian will be written as

##  Appendix B Hamiltonian of the system

After doing the Legendre transformation of the Lagrangian in Eq. (15) we will
find the Hamiltonian such that

$\displaystyle
H=\frac{1}{2}\left(\frac{\hbar}{2e}\right)^{2}C\sum_{n}\left(\dot{\phi_{n}}^{2}+\omega_{n}^{2}\phi_{n}^{2}\right)+\hbar\left(\frac{1}{2e}\right)^{2}C\dot{f}\sum_{n,m}M_{nm}\dot{\phi_{n}}\phi_{m}$
$\displaystyle+\left(\frac{\hbar}{2e}\right)^{2}C_{J}\frac{\dot{f}^{2}}{2}+\left(\frac{\hbar}{2e}\right)^{2}C\frac{\dot{f}^{2}}{2}\sum_{n,m,k}M_{nk}M_{mk}\phi_{n}\phi_{m}+V(f).$
(45)

Now we need to replace the momentum variables above. We notice that

$\displaystyle\dot{\phi}_{n}=\frac{1}{\hbar\left(\frac{1}{2e}\right)^{2}C}q_{n}-\dot{f}M_{nm}\phi_{m},$
(46)

thus, using this we can write

$p_{f}=\sum_{n,m}M_{nm}q_{n}\phi_{m}+\hbar\left(\frac{1}{2e}\right)^{2}C_{J}\dot{f},$
(47)

and hence

$\dot{f}=\frac{1}{\hbar\left(\frac{1}{2e}\right)^{2}C_{J}}p_{f}-\frac{1}{\hbar\left(\frac{1}{2e}\right)^{2}C_{J}}\sum_{n,m}M_{nm}q_{n}\phi_{m}.$
(48)

Replacing $\dot{\phi}_{n}$ in the Hamiltonian (45) we find

$\displaystyle
H=\sum_{n}\left[\frac{\left(2e\right)^{2}}{2C}q_{n}^{2}+\frac{1}{2}\left(\frac{\hbar}{2e}\right)^{2}C\omega_{n}^{2}\phi_{n}^{2}\right]+\left(\frac{\hbar}{2e}\right)^{2}C_{J}\frac{\dot{f}^{2}}{2}+V(f).$
(49)

Therefore the final Hamiltonian after replacing $\dot{\delta f}$ as well will
take the following form

$H=\sum_{n}\left[\frac{\left(2e\right)^{2}}{2C}q_{n}^{2}+\frac{1}{2}\left(\frac{\hbar}{2e}\right)^{2}C\omega_{n}^{2}\phi_{n}^{2}\right]+\frac{\left(2e\right)^{2}}{2C_{J}}\left(p_{f}-\sum_{n,m}M_{nm}q_{n}\phi_{m}\right)^{2}+V(f).$
(50)

To go further we first quantize the full Hamiltonian by assuming the usual
commutation reation among the operators. Therefore we write

$\displaystyle\phi_{n}=\sqrt{\frac{\hbar\omega_{n}}{2E_{C}}}\left(a_{n}+a_{n}^{\dagger}\right)$
(51) $\displaystyle
q_{n}=-i\sqrt{\frac{E_{C}}{2\hbar\omega_{n}}}\left(a_{n}-a_{n}^{\dagger}\right).$
(52)

Thus the Hamiltonian will become

$\displaystyle
H=\sum_{n}\hbar\omega_{n}a_{n}^{\dagger}a_{n}+\frac{\left(2e\right)^{2}}{2C_{J}}\left(p_{f}+\Gamma(f)\right)^{2}+V(f),$
(53)

where
$\Gamma(f)=\frac{i}{2}\sum_{n,m}M_{nm}\left(a_{n}-a_{n}^{\dagger}\right)\left(a_{n}+a_{n}^{\dagger}\right)$.
We notice that the operators $a_{n}$ and $a^{\dagger}_{n}$ depend on $\delta
f$ through $\omega_{n}$. Therefore, there exists an interaction among the
cavity fields and the SQUID degrees of freedom $f$. This said, we can now do
the first linear approximation of the Hamiltonian. This can be done by
assuming that the position of the SQUID, $f$, has small oscillations around
its rest position, $f_{0}$.

Explicitly, we can write for $f(t)\approx f_{0}+\delta f(t)$ where $\delta
f(t)\ll 1$;

$\omega_{n}(f)\approx\omega_{n}(f_{0})+\delta f\omega_{n}^{\prime}(f_{0}).$
(54)

Therefore

$a_{n}\approx\sqrt{\frac{E_{C}}{2\hbar\omega_{n}(f_{0})}}\phi_{n}+i\sqrt{\frac{\hbar\omega_{n}(f_{0})}{2E_{C}}}q_{n}-\frac{1}{2}\delta
f\frac{\omega_{n}^{\prime}(f_{0})}{\omega_{n}(f_{0})}\left(\sqrt{\frac{E_{C}}{2\hbar\omega_{n}(f_{0})}}\phi_{n}-i\sqrt{\frac{\hbar\omega_{n}(f_{0})}{2E_{C}}}q_{n}\right)$
(55)

which can be written as

$a_{n}\approx a_{n}(f_{0})-\frac{1}{2}\delta
f\frac{\omega_{n}^{\prime}(f_{0})}{\omega_{n}(f_{0})}a_{n}^{\dagger}(f_{0}).$
(56)

Moreover, we notice that in this limit using Eq. (14) we have

$M_{nm}=M_{nm0}+\delta fM^{\prime}_{nm0},$ (57)

with $M^{\prime}_{mn0}=\sum_{k}M_{nk0}M_{mk0}$ and

$M_{nm0}=\frac{1}{d}\int_{-d/2}^{d/2}dx(1+2C_{J}/\mathcal{C}_{0}\delta(x))\psi_{m}(f_{0})\frac{dk_{n}}{df_{0}}\frac{d\psi_{n}(f_{0})}{dk_{n}}.$
(58)

Now we should replace all these terms back into the bare Hamiltonian and
$\Gamma(f)$. In this way, these terms give nonlinear contributions to the
interaction Hamiltonian. Therefore, using the fact that $\delta f\ll 1$, we
can do a linear approximation. To do so we write
$\Gamma(f)\approx\Gamma(f_{0})+\delta f\Gamma^{\prime}(f_{0})$ where
$\Gamma^{\prime}$ can be found by replacing the above expansions of creation
and annihilation operators and $M_{n}m$ in $\Gamma(f)$ and only keeping the
first order in $\delta f$;

$\Gamma^{\prime}(f_{0})=\sqrt{\frac{\omega_{m}(f_{0})}{\omega_{n}(f_{0})}}\left[M_{nm}^{\prime}+M_{nm}\frac{\omega_{n}^{\prime}(f_{0})}{\omega_{n}(f_{0})}\right]\left(a_{m}(f_{0})+a_{m}^{\dagger}(f_{0})\right)\left(a_{n}(f_{0})-a_{n}^{\dagger}(f_{0})\right).$
(59)

Replacing this into the Hamiltonian we will have

$\displaystyle H=\hbar\sum_{n}\left(\omega_{n}+\omega_{n}^{\prime}\delta
f\right)\left(a_{n}^{\dagger}-\delta
f\frac{\omega_{n}^{\prime}}{2\omega_{n}}a_{n}\right)\left(a_{n}-\delta
f\frac{\omega_{n}^{\prime}}{2\omega_{n}}a_{n}^{\dagger}\right)+\frac{\left(2e\right)^{2}}{2C_{J}}\left(p_{f}+\Gamma_{0}+\delta
f\Gamma^{\prime}_{0}\right)^{2}+V(\delta f),$ (60)

where we just for simplicity replaced $\Gamma(f_{0})$ with $\Gamma_{0}$ and
the same for $\Gamma^{\prime}$. Moreover

$V(\delta
f)=\left(\frac{\hbar}{2e}\right)^{2}\frac{1}{2}C_{J}\omega_{f}^{2}\delta
f^{2}+\left(\frac{\hbar}{2e}\right)^{2}\frac{2M}{LL_{\rm ext}}\delta ff_{\rm
ext}.$ (61)

In the above Hamiltonian, the ladder operators are independent of $f$. To find
the form of the interaction, we perform a unitary transformation
$H^{\prime}=T^{\dagger}HT$ where

$T=\exp\left\\{i\delta f(\Gamma_{0}+\frac{1}{2}\delta
f\Gamma^{\prime}_{0})\right\\}.$ (62)

We first apply this on the second term of the Hamiltonain and the result will
be

$T^{\dagger}\left(p_{f}+\Gamma_{0}+\delta
f\Gamma^{\prime}_{0}\right)^{2}T=p_{f}^{2},$ (63)

so we are shifting the momentum by $\Gamma_{0}+\delta f\Gamma^{\prime}_{0}$.
Next we need to transform the first term in the Hamiltonian,

$\displaystyle
T^{\dagger}\hbar\sum_{n}\left(\omega_{n}+\omega_{n}^{\prime}\delta
f\right)\left(a_{n}^{\dagger}-\delta
f\frac{\omega_{n}^{\prime}}{2\omega_{n}}a_{n}\right)\left(a_{n}-\delta
f\frac{\omega_{n}^{\prime}}{2\omega_{n}}a_{n}^{\dagger}\right)T\approx$
$\displaystyle\hbar\sum_{n}\omega_{n}\left(a_{n}^{\dagger}a_{n}-\delta
f\frac{\omega_{n}^{\prime}}{2\omega_{n}}(a_{n}^{\dagger 2}+a_{n}^{2})+\delta
f^{2}\left(\frac{\omega_{n}^{\prime}}{2\omega_{n}}\right)^{2}a_{n}a_{n}^{\dagger}\right)+\hbar\sum_{n}\omega_{n}^{\prime}\left(\delta
fa_{n}^{\dagger}a_{n}-\delta
f^{2}\frac{\omega_{n}^{\prime}}{2\omega_{n}}(a_{n}^{\dagger
2}+a_{n}^{2})\right)$ $\displaystyle\frac{-\hbar}{2}\delta
f\sum_{n,m}M_{nm}\sqrt{\frac{\omega_{m}}{\omega_{n}}}\left[\omega_{m}\left(a_{m}-a_{m}^{\dagger}\right)\left(a_{n}-a_{n}^{\dagger}\right)+\omega_{n}\left(a_{m}+a_{m}^{\dagger}\right)\left(a_{n}+a_{n}^{\dagger}\right)\right]$
$\displaystyle-\frac{-\hbar}{4}\delta
f^{2}\sum_{n,m}\tilde{M}_{nm}\sqrt{\frac{\omega_{m}}{\omega_{n}}}\left[\omega_{m}\left(a_{m}-a_{m}^{\dagger}\right)\left(a_{n}-a_{n}^{\dagger}\right)+\omega_{n}\left(a_{m}+a_{m}^{\dagger}\right)\left(a_{n}+a_{n}^{\dagger}\right)\right]$
$\displaystyle-\frac{\hbar}{2}\delta
f^{2}\sum_{mn}M_{nm}\sqrt{\frac{\omega_{m}}{\omega_{n}}}\left[\omega_{n}\frac{\omega_{n}^{\prime}}{\omega_{n}}\left(a_{m}+a_{m}^{\dagger}\right)\left(a_{n}^{\dagger}+a_{n}\right)+\omega_{m}\frac{\omega_{m}^{\prime}}{\omega_{m}}\left(a_{m}^{\dagger}-a_{m}\right)\left(a_{n}-a_{n}^{\dagger}\right)\right]$
$\displaystyle-\frac{\hbar}{2}\delta
f^{2}\sum_{n,m}M_{nm}\sqrt{\frac{\omega_{m}}{\omega_{n}}}\left[\omega^{\prime}_{m}\left(a_{m}-a_{m}^{\dagger}\right)\left(a_{n}-a_{n}^{\dagger}\right)+\omega^{\prime}_{n}\left(a_{m}+a_{m}^{\dagger}\right)\left(a_{n}+a_{n}^{\dagger}\right)\right]+O(\delta
f^{3}),$ (64)

where
$\tilde{M}_{nm}=M_{nm}^{\prime}+M_{nm}\frac{\omega_{n}^{\prime}}{\omega_{n}}$.
Now these terms are denoting the interaction between the cavities and the
squid in powers of $\delta f$ and we only kept terms up to the second order in
$\delta f$. We can further simplify this Hamiltonian in two ways. First, since
$\delta f$ is very small, we can neglect all second order terms in $\delta f$.
Note that there exists a second order term in $V(\delta_{f})$ which is written
as $\left(\frac{\hbar}{2e}\right)^{2}\frac{1}{2}C_{J}\omega_{f}^{2}\delta
f^{2}$. However, the prefactor of this term,
$\left(\frac{\hbar}{2e}\right)^{2}\frac{1}{2}C_{J}=\hbar^{2}\omega_{f}^{2}/4E_{C_{J}}\propto
E_{J}$ is large. The second simplification is the rotating wave approximation
(RWA). One can show that all the terms of second order in $\delta f$ will be
eliminated by the approximation. To sketch the RWA, we first write

$\displaystyle\delta f$
$\displaystyle=\sqrt{\frac{E_{C_{J}}}{\hbar\omega_{f}}}\left(a_{f}+a_{f}^{\dagger}\right)$
(65) $\displaystyle p_{f}$
$\displaystyle=-i\frac{1}{2}\sqrt{\frac{\hbar\omega_{f}}{E_{C_{J}}}}\left(a_{f}-a_{f}^{\dagger}\right).$
(66)

Replacing them in the Hamiltonian will result in a bare Hamiltonian of the
form,

$H_{0}=\hbar\sum_{n}\omega_{n}a^{\dagger}_{n}a_{n}+\hbar\omega_{f}a^{\dagger}_{f}a_{f}.$
(67)

Therefore we can use the above Hamiltonian and move to the rotating frame by
applying the unitary transformation

$U=\exp\left\\{\frac{it}{\hbar}\left[\sum_{n}\hbar\omega_{n}a_{n}^{\dagger}a_{n}+\hbar\omega_{f}a_{f}^{\dagger}a_{f}\right]\right\\}$
(68)

on the interaction Hamiltonian (64). Therefore, after doing the RWA, using the
resonance condition $\omega_{f}=\omega_{n}+\omega_{m}$ for $m\neq n$, and
going back to the Schrödinger picture, we obtain

$\displaystyle H_{\rm
RWA}=\hbar\sum_{n}\omega_{n}a_{n}^{\dagger}a_{n}+\hbar\omega_{f}a_{f}^{\dagger}a_{f}+\hbar\sum_{n}\omega_{n}\frac{E_{C_{J}}}{\hbar\omega_{f}}\left(\frac{\omega_{n}^{\prime}}{2\omega_{n}}\right)^{2}a_{n}a_{n}^{\dagger}a_{f}a_{f}^{\dagger}$
$\displaystyle-\frac{\hbar}{2}\sqrt{\frac{E_{C_{J}}}{\hbar\omega_{f}}}\sum_{n,m}M_{nm}\sqrt{\frac{\omega_{m}}{\omega_{n}}}\left(\omega_{m}+\omega_{n}\right)\left(a_{f}^{\dagger}a_{m}a_{n}+a_{f}a_{m}^{\dagger}a_{n}^{\dagger}\right).$
(69)

Moreover, we can neglect the third term of the first line by reasoning that
$E_{C_{J}}/\hbar\omega_{f}\propto\sqrt{E_{C_{J}}/E_{J}}\ll 1$. Therefore that
term is negligible and we can write the final Hamiltonian as

$\displaystyle
H_{rwa}=\hbar\sum_{n}\omega_{n}a_{n}^{\dagger}a_{n}+\hbar\omega_{f}a_{f}^{\dagger}a_{f}-\frac{\hbar}{2}\sqrt{\frac{E_{C_{J}}}{\hbar\omega_{f}}}\sum_{n,m}M_{nm}\sqrt{\frac{\omega_{m}}{\omega_{n}}}\left(\omega_{m}+\omega_{n}\right)\left(a_{f}^{\dagger}a_{m}a_{n}+a_{f}a_{m}^{\dagger}a_{n}^{\dagger}\right).$
(70)

##  Appendix C the SQUID Lagrangian

The phase drop of the SQUID over its inductance $L$ follows

$\left(\frac{\hbar}{2e}\right)^{2}C_{J}\ddot{f}+E_{J}\sin
f+\left(\frac{\hbar}{2e}\right)^{2}\frac{2}{L}\left(f+\frac{M}{L_{\rm
ext}}f_{\rm ext}\right)=0.$ (71)

Therefore its Lagrangian can be written as

$\mathcal{L}=\left(\frac{\hbar}{2e}\right)^{2}\frac{C_{J}}{2}\dot{f}^{2}-V(f)$
(72)

where

$V(f)=-E_{J}\cos
f+\left(\frac{\hbar}{2e}\right)^{2}\frac{1}{L}\left(f^{2}+\frac{M}{L_{\rm
ext}}ff_{\rm ext}\right).$ (73)

This Lagrangian is exact up to the assumption that $\Phi_{0}\ll 1$. However,
we can also look at the limit of small displacement of $f$ around $f_{0}$
namely assuming

$\displaystyle f=f_{0}+\delta f(t)$ $\displaystyle f_{\rm xt}=F_{\rm
ext}+\delta f_{\rm ext}(t)$ (74)

where $\delta f\ll 1$ and $\delta f_{\rm ext}\ll 1$. This limit will be useful
once we write the full Hamiltonian and we need to make the linear interaction
approximation.

Therefore the equation of motion for $f$ can be rewritten as

$\left(\frac{\hbar}{2e}\right)^{2}C_{J}\ddot{\delta f}+\left(E_{J}\cos
f_{0}+\left(\frac{\hbar}{2e}\right)^{2}\frac{2}{L}\right)\delta f+E_{J}\sin
f_{0}+\left(\frac{\hbar}{2e}\right)^{2}\frac{2}{L}f_{0}=-\left(\frac{\hbar}{2e}\right)^{2}\frac{2M}{LL_{\rm
ext}}\delta f_{\rm ext}-\left(\frac{\hbar}{2e}\right)^{2}\frac{2M}{LL_{\rm
ext}}F_{\rm ext}$ (75)

The stationary solution where we set $\delta f=0$ and $\delta f_{\rm ext}=0$
gives

$E_{J}\sin
f_{0}+\left(\frac{\hbar}{2e}\right)^{2}\frac{2}{L}\left(f_{0}+\frac{M}{L_{\rm
ext}}F_{\rm ext}\right)=0.$ (76)

This indicates the relation between $f_{0}$ and $F_{\rm ext}$. Using it we get

$\left(\frac{\hbar}{2e}\right)^{2}C_{J}\ddot{\delta f}+\left(E_{J}\cos
f_{0}+\left(\frac{\hbar}{2e}\right)^{2}\frac{2}{L}\right)\delta
f=-\left(\frac{\hbar}{2e}\right)^{2}\frac{2M}{LL_{\rm ext}}\delta f_{\rm
ext},$ (77)

which is basically a forced oscillator. To quantize $f$, we first write the
Hamiltonian using the above equation of motion. Since assuming $\Phi_{0}$ to
be small will effectively decouple $f$ from the rest of the system, we can
quantize its Hamiltonian independently. One can rewrite the Lagrangian of $f$
according to its equation of motion 71, which will lead to

$L_{f}=\left(\frac{\hbar}{2e}\right)^{2}C_{J}\frac{\dot{\delta
f}^{2}}{2}-\left(\frac{\hbar}{2e}\right)^{2}\frac{1}{2}C_{J}\omega_{f}^{2}\delta
f^{2}-\left(\frac{\hbar}{2e}\right)^{2}\frac{2M}{LL_{\rm ext}}\delta f\delta
f_{\rm ext}$ (78)

where

$\omega_{f}^{2}=\frac{1}{\left(\frac{\hbar}{2e}\right)^{2}C_{J}}\left(E_{J}\cos
f_{0}+\left(\frac{\hbar}{2e}\right)^{2}\frac{2}{L}\right).$ (79)


# Answer Generation for Questions With Multiple Information Sources in
E-Commerce

Anand A. Rajasekar  FlipkartBengaluruIndia<EMAIL_ADDRESS>and  Nikesh
Garera  FlipkartBengaluruIndia<EMAIL_ADDRESS>
(2021)

###### Abstract.

Automatic question answering is an important yet challenging task in
E-commerce given the millions of questions posted by users about the product
that they are interested in purchasing. Hence, there is a great demand for
automatic answer generation systems that provide quick responses using related
information about the product. There are three sources of knowledge available
for answering a user posted query, they are reviews, duplicate or similar
questions, and specifications. Effectively utilizing these information sources
will greatly aid us in answering complex questions. However, there are two
main challenges present in exploiting these sources: (i) The presence of
irrelevant information and (ii) the presence of ambiguity of sentiment present
in reviews and similar questions. Through this work we propose a novel
pipeline (MSQAP) that utilizes the rich information present in the
aforementioned sources by separately performing relevancy and ambiguity
prediction before generating a response.
Experimental results show that our relevancy prediction model (BERT-QA)
outperforms all other variants and has an improvement of 12.36% in F1 score
compared to the BERT-base baseline. Our generation model (T5-QA) outperforms
the baselines in all content preservation metrics such as BLEU, ROUGE and has
an average improvement of 35.02% in ROUGE and 198.75% in BLEU compared to the
highest performing baseline (HSSC-q). Human evaluation of our pipeline shows
us that our method has an overall improvement in accuracy of 30.7% over the
generation model (T5-QA), resulting in our full pipeline-based approach
(MSQAP) providing more accurate answers. To the best of our knowledge, this is
the first work in the e-commerce domain that automatically generates natural
language answers combining the information present in diverse sources such as
specifications, similar questions, and reviews data.

Natural language generation, Question answering, Transformers, Next sentence
prediction

††copyright: acmcopyright††journalyear: 2021††conference: SIGIR : The 2021
SIGIR Workshop On eCommerce; July 15, 2021; Online††ccs: Computing
methodologies Natural language generation

##  1\. Introduction

Automatic question answering systems that respond to product related questions
has gained a lot of attention in recent years due to their extensive
application in E-commerce. Customers usually post a number of questions before
purchasing a product. Unless these questions are answered by an user who
purchased the product, they go unanswered. In such cases, we can utilize the
information present in various sources of the product such as reviews,
specifications and duplicate questions to aid us in automatically creating a
response. This rapidly led to variety of works in review and other sources
driven answer generation (Deng et al., 2020; Chen et al., 2019; Gao et al.,
2019).

Table 1. Example of answer generation dataset with candidates |  Example 1 |  Example 2
---|---|---
Question |  display are very slow in ABC? |  does phn have theatre sound quality?
Reference Answer |  my mobile display slow |  Yes, the audio quality of this phone is too good
Duplicate Q&A (Partial) |  1) At present now on words which is better XYZ or ABC And mainly display which is better? ABC. |  1) How is the sound quality? Is the sound better than MNO? PQR best sound quality
Reviews |  1) ABC mobile overall good but display quality poor |  1) sound quality is very low class
|  2) but the display of ABC are not good |  2) Sound quality is not good
Specifications |  1) Other Display Features: …Narrow Frame: 2.05mm, Screen Ratio: |  1) Sound Enhancements: …Noise Reduction: Dual-microphone Noise
|  2) Display Colors: 16.7M |
|  3) Display Size: 15.8 cm (6.22 inch) |

One of the primary challenges present in building a real world answer
generation system for E-commerce is the noise present in the dataset. The
dataset used for training and evaluating the models consists of user posted
questions and answers which has spelling errors, grammatical inconsistencies
and sometimes code switching. Another common problem is the presence of
irrevelant information and ambiguity in users’ opinions present in reviews and
similar questions. Question, answer pairs along with their information
candidates are tabulated in Table 1. We solve for some of the above mentioned
challenges through our work.
Ever since their introduction, Transformer (Vaswani et al., 2017) has gained
extensive popularity due to their top performance in variety of Natural
Language Processing tasks. They have surpassed other neural network models
such as Recurrent Neural Networks and Convolutional neural networks in natural
language understanding and generation. The transformer architecture scales
well with larger training data and size of the model and allows efficient
parallel training. In recent years, it is becoming common to pretrain the
transformer on a data rich task. This pretraining allows the model to learn
general knowledge about the language that can be transferred to downstream
tasks with few steps of fine tuning. The initial pretraining step is often
done in an unsupervised fashion on unlabelled data and has resulted in state
of the art results in many NLP benchmarks (Devlin et al., 2018; Yang et al.,
2019; Lan et al., 2019). The main advantage of this way of pretraining is due
to the availability of large volumes of text data. We use pretrained
transformers as our models that are further finetuned for the task at hand.
Through this work, we propose Multi Source Question Answering Pipeline (MSQAP)
consisting of three components, (i) relevancy prediction using a transformer
fine tuned on Next Sentence Prediction task, (ii) Ambiguity prediction using a
pretrained model and (iii) answer generation using a text to text transformer
fine tuned on a large Question Answer dataset to generate accurate and precise
response.
The main contributions of our paper can be summarized as follows:

  * •

We propose an answer generation system utilizing three sources of knowledge,
namely, reviews, similar questions and specifications.

  * •

We show how to handle the two main challenges when incorporating information
from all the sources(i) The presence of irrelevant information and (ii) the
presence of ambiguity of answer sentiment.

  * •

We propose a novel pipeline (MSQAP) that utilizes the rich information present
in the above sources by separately performing relevance and ambiguity
prediction before generating a response to address the above challenges.

  * •

We compute content preservation metrics such as BLEU and ROUGE for generation
and benchmark results for all the models.

  * •

Experimental analyses show that our approach outperform the baselines in the
above metrics and generate answers with an overall accuracy of 77.88% in human
evaluations.

The reminder of the paper is organized as follows. Section 2 describes the
related work in answer generation and relevancy prediction. The problem
statement is formally defined in Section 3 and our proposed approach is
explained in Section 4. All experimental details along with results are
available in Section 5 and conclusion is discussed in Section 6.

##  2\. Related work

We detail recent work on large language models, relevancy prediction and
answer generation. BERT (Devlin et al., 2018) is a bidirectional transformer
encoder pretrained on large amounts of data to perform masked language
modelling and Next Sentence Prediction task. RoBERTa (Liu et al., 2019)
removes NSP task from BERT’s pretraining and introduce dynamic masking so that
tokens can be changed during training. T5 (Raffel et al., 2019) is an encoder-
decoder transformer architecture trained on a variety of tasks using transfer
learning strategies. We employ all the above transformers in our study.

###  2.1. Relevancy prediction

Recent studies (Moghaddam and Ester, 2011; Yu et al., 2017) employ ranking
strategies to pick an answer from a set of candidate answers while
incorporating review information. Yu et al. (Yu et al., 2017) proposed a model
to retrieve the most similar question from a list of QA pairs and used the
corresponding answer as the response. Cui et al. (Cui et al., 2017) built a
chatbot called SuperAgent which utilizes all three sources of information and
selects the best answer from them. In general, there has been a lot of work in
ranking the candidates that are relevant to a question and picking the best
answer as the final result. One of the recent works using transformer based
models is done by Mittal et al. (Mittal et al., 2021) where questions answer
pairs are retrieved based on their relevance to the question. We use a similar
approach to relevancy prediction for selecting the top $k$ candidates and
further add on a key component called ambiguity filtering given the
inconsistency in answers from e-commerce user data. These are then used as
context for our natural language generation model.

###  2.2. Answer generation

In recent years, there has been a variety of RNN based (Sutskever et al.,
2014) and transformer based (Lewis et al., 2019; Raffel et al., 2019) sequence
to sequence models proposed for text generation. Most of the successful
implementation of these methods involved attention mechanism (Bahdanau et al.,
2016) and/or self attention (Vaswani et al., 2017). However, answer generation
in E-commerce generally uses a RNN based model (Deng et al., 2020; Chen et
al., 2019) with source information obtained from reviews. In one of the
earlier works, McAuley et al. (McAuley and Yang, 2016) use a Mixture Of
Expert(MOE) model with review as the source to predict the answer, where they
classify them to binary answers i.e ”Yes” or ”No”. Chen et al. (Chen et al.,
2019) utilize the attention mechanism (Chen et al., 2019) to alleviate the
noise present in review snippets to aid in answer generation. Dzendzik et al.
(Dzendzik et al., 2019) use BERT (Devlin et al., 2018) on reviews to answer
binary questions. Deng et al. (Deng et al., 2020) learn a multi task model
that performs answer generation and opinion mining while utilizing review
ratings. They make use of pointer generator network (See et al., 2017) with
fusion of review information to generate answers. Gao et al. (Gao et al.,
2019) encode reviews and product specifications using two separate encoders.
The generated answer is passed through a consistency discriminator to check if
the generated answer matches the facts. However, our focus in this work is to
build a comprehensive answer generation pipeline utilising information from
various e-commerce sources such as specifications, similar questions and
reviews, and combining them to generate a natural language answer. To the best
of our knowledge, this is the first work in e-commerce domain to utilize all
the above three sources of information for natural language generation.
Furthermore, we show how this can be built at scale by utilising noisy user
submitted answers for answer generation component and hence reducing the need
for clean supervised data present in most of the prior work settings.

##  3\. Problem Definition

Given a question $Q$ and a set of information candidates
$\\{x_{1},\dots,x_{k}\\}$ related to a product, the goal is to generate a
natural language answer $y$ as the response using relevant information.

Specifically, we use dataset $D$ which consists of N samples where data point,
$d^{i}$ consists of the question $Q^{i}$, a set of reviews
$\\{r^{i}_{1},\dots,r^{i}_{k}\\}$, a set of duplicate questions and answers
$\\{(q^{i}_{1},a^{i}_{1}),\dots,(q^{i}_{l},a^{i}_{l})\\}$, and a set of
specifications $\\{s^{i}_{1},\dots,s^{i}_{m}\\}$ and the ground truth answer
$y^{i}$. The dataset $D$ is represented by,

(1)
$D=\big{(}Q^{i},\\{r^{i}_{1},\dots,r^{i}_{k}\\},\\{(q^{i}_{1},a^{i}_{1}),\dots,\\\
(q^{i}_{l},a^{i}_{l})\\},\\{s^{i}_{1},\dots,s^{i}_{m}\\},y^{i}\big{)}_{i=1}^{N}$

The goal is to generate the answer $\hat{y}^{i}$ using appropriate information
in a coherent and precise way.

##  4\. Proposed approach

Figure 1. Multi Source Question Answering Pipeline

We introduce Mutli Source Question Answering Pipeline (MSQAP) to generate the
answer to a product related question by removing irrelevant information and
ambiguity present in the information candidates. Figure 1 depicts the overview
of the MSQA Pipeline which can be split into three components. $(1)$ Relevancy
prediction uses relational information between the question and information
candidates to rank their importance in answering a question. $(2)$ Ambiguity
prediction helps in removing ambiguous opinions present in the candidates.
$(3)$ Answer generator helps in generating the response to the question with
important and less ambiguous context information. The models used in this
pipeline are trained and evaluated separately.

###  4.1. Relevancy prediction

The candidates available in the dataset are quite high in number for common
questions and fewer in number for unique/rare questions. Also, these
candidates are sometimes repetitive or irrelevant in their ability to answer
the query. Using many candidates for generation will increase computation time
and will make it difficult for the model to give attention to the right
information. Hence, it is important to rank them with respect to their
relevance with the question and their importance in answering it. We propose
to model the relevancy prediction task as a Next Sentence Prediction approach
with the question as the first sentence and each candidate as the potential
second sentence. The intuition behind this modelling strategy is that any
candidate that is relevant for answering a question will be the sentence
immediately following it in a paragraph. Any other sentence that is irrelevant
will be a random sentence. Thus, a well trained NSP model should be able to
identify an important and relevant candidate from a random one.
Let $n^{i}$ be the number of candidates available for question $Q^{i}$. The
question $Q^{i}$ and a candidate $x^{i}_{k}$ are concatenated, tokenized, and
passed to an embedding layer. The word embeddings along with their positional
signals are passed to a transformer encoder whose head predicts the Next
Sentence label.

(2)
$w^{i}_{k}=tokenizer([Q^{i};x^{i}_{k}])\;\;\;\;\hat{y}^{i}_{k}=transformer(w^{i}_{k})$

$";"$ denote the appropriate concatenation of input sentences as required by
the pretrained transformer in use. The relevancy prediction task is trained to
minimize the cross entropy loss,

(3)
$L_{nsp}=-\frac{1}{N_{1}}\sum_{i=1}^{N_{1}}\frac{1}{n^{i}}\sum_{k=1}^{n^{i}}y^{i}_{k}log\hat{y}^{i}_{k}$

where $y^{i}_{k}$ is the ground truth label indicating the relevancy of the
candidate.

###  4.2. Ambiguity prediction

Apart from irrelevancy, one other reason for unnecessary information being fed
into the generation model while answering a question is the ambiguity present
in the candidates due to the subjective nature of the question. When both
positive and negative sentiments together are passed as inputs to the
generation model during training with a ground truth label containing any of
the two sentiment, it will hinder the model from learning to generate a
response with the right sentiment. For eg., two data points with the same
question and candidates but using conflicting answers given by two users as
ground truth labels will confuse the model whereas filtering the candidates to
match the sentiment of the label will help the model to generate a response
with sentiment present in the input. Hence, we have to remove candidates with
opposite sentiments to that of the label and the advantage of removing this
ambiguity is two fold. First, the number of input candidates decreases
improving the computation time and second, the model gets trained to generate
the answer with the sentiment which is given as input. During evaluation, we
can choose the sentiment of the candidates to be given as input using any
heuristic and the generated answer will contain the chosen sentiment. However,
this task is carried out only for dichotomous (yes/no) questions. The
candidates of WH questions are usually less subjective and hence, they are
left untouched.

###  4.3. Answer generation

Once the candidates that are relevant to answering a question are collected,
they are concatenated and passed along with the question into a transformer
with encoder decoder architecture to generate the response. The encoder-
decoder implementation follows the original proposed form (Vaswani et al.,
2017). The encoder consists of a stack of layers each with a self attention
layer and a feed forward network. Layer normalization is applied to input of
every layer and a skip connection is applied which connects the layer’s input
with its output. The decoder consists of similar setup except that it also has
a attention layer that attends to output of the encoder. The self attention
layer in decoder follows a causal attention strategy (i.e) paying attention to
past inputs only.
Let $k$ be the number of candidates available for question $Q^{i}$. The
question $Q^{i}$ and its candidates are concatenated, tokenized, and passed to
an embedding layer. The word embeddings along with their positional signals
are passed to a transformer encoder which helps the decoder in generating the
answers in an auto regressive fashion.

(4) $\displaystyle w^{i}=tokenizer([Q^{i};(x^{i}_{1}:\dots:x^{i}_{k}])$
$\displaystyle\hat{h}^{i}=Encoder(w^{i})\;\;\;\;\hat{y}^{i}_{t}=Decoder(h^{i},y^{i}_{t-1})$

$":"$ denote the regular string concatenation and $\hat{y}^{i}_{t}$ is the
generated token at position $t$. The answer generation task is trained to
minimize the cross entropy loss,

(5) $L_{gen}=-\frac{1}{N_{2}}\sum_{i=1}^{N_{2}}logP(\hat{y}^{i}_{*})$

where $P(\hat{y}^{i}_{*})$ is the probability of the token corresponding to
ground truth.

###  4.4. Auto answering pipeline

The MSQA Pipeline brings together all the three components in aiding answer
generation. First, all the provided candidates from reviews, similar questions
and answers, and specifications are passed as inputs to relevancy prediction
task. The scores obtained from the NSP model are used to rank the candidates
in decreasing order of their relevancy. The top $k$ candidates are chosen and
passed to ambiguity prediction task depending on the type of question. The
trimmed candidates along with the question are passed as input to the answer
generation model to produce the response.

##  5\. Experiments

The aim of the analysis is to answer the following questions

  * •

Does the pipeline outperform the results of the baselines?

  * •

Are the generated answers precise and coherent?

  * •

How does each variant of the pipeline generate answers?

###  5.1. Dataset

Table 2. Relevancy prediction dataset | Train dataset | Val dataset
---|---|---
No. of questions | 1638 | 362
Total candidates | 15122 | 3268
Total relevant candidates | 8670 | 1736
Avg. specs relevancy | 0.308 | 0.253
Avg. qa relevancy | 0.668 | 0.634
Avg. reviews relevancy | 0.626 | 0.573
Table 3. Answer generation dataset | Train dataset | Val dataset
---|---|---
Total No. of questions | 217086 | 11153
No. of WH questions | 66075 | 3459
Avg. candidates per question | 9.750 | 9.486
Avg. specs per question | 2.381 | 2.381
Avg. reviews per question | 2.637 | 2.344
Avg. dup. questions per question | 4.732 | 4.762
Table 4. Datasets used for training models Dataset | Model
---|---
D1 | RoBERTa-A
BERT-A
RoBERTa-QA
BERT-QA
D2 | Seq2Seq
HSSC-q
T5-QA

We train and evaluate the relevancy prediction model using our inhouse dataset
$D1$ of mobiles. This dataset is made up of questions collected randomly from
a list of accepted user posted questions. The number of questions present in
the dataset is 2000. Every question is matched with a set of candidates from
three sources of information, reviews, similar questions and answers, and
specifications. We manually labelled this dataset to indicate whether each
candidate has relevant information to answer the question 111Note that the one
of the main challenges for relevancy is coverage since the relevant
information may not available in the source for retrieval. Specifically
dataset $D1$ is represented by,

$\displaystyle
D1=\big{(}Q^{i},\\{(r^{i}_{1},yr^{i}_{1}),\dots,(r^{i}_{k},yr^{i}_{k})\\},\\{(q^{i}_{1},a^{i}_{1},ya^{i}_{1}),\dots,$
$\displaystyle(q^{i}_{l},a^{i}_{l},ya^{i}_{l})\\},\\{(s^{i}_{1},ys^{i}_{1}),\dots,(s^{i}_{m},ys^{i}_{m})\\}\big{)}_{i=1}^{N}$

where $yr^{i}_{j}$, $ys^{i}_{j}$, and $ya^{i}_{j}$ denote the relevancy of
each of the sources for $j^{th}$ candidate of $i^{th}$ question. Every
question with any one of the candidate make up a datapoint for Next Sentence
Prediction task. The statistics of the table are presented in Table 2. The
dataset is well balanced with an average of 0.573 and 0.531 relevant
candidates in train dataset and validation dataset respectively.
We train and evaluate the answer generation model using our inhouse dataset
$D2$ of mobiles consisting of 200K questions collected randomly from user
posted questions along with their answers. The ground truth labels of this
dataset are noisy since they represent the individual opinion of a single
user. We also collect candidates from all three sources for each question.
However, these candidates are filtered by relevancy and ambiguity prediction
models resulting in seven or less candidates per question. Specifically,
dataset $D2$ is represented by,

$\displaystyle D2=\big{(}Q^{i},\\{x^{i}_{1},\dots,x^{i}_{\leq
7}\\},y^{i}\big{)}_{i=1}^{N}$

The statistics of the dataset before filtering are presented in Table 3.
Though the duplicate question and answers are more relevant in answering a
question as evident from Table 2, they are also more in number per question on
average. The datasets used for training our models are tabulated in Table 4.
We employ weak candidates retrieval models for each source inorder to
eliminate the most unlikely candidates before constructing our datasets.

###  5.2. Baselines & Evaluation metrics

T5-QA model denotes answer generation component only, while MSQAP (rel.)
denotes our generation model with relevancy prediction and MSQAP (full)
denotes the entire pipeline. We compare our approach on both relevancy
prediction and answer generation baselines. We have adopted two generation
based methods along with the pre trained base transformer in use for answer
generation task.

  * •

Seq2Seq (Bahdanau et al., 2016) \- We implement the standard sequence to
sequence RNN model with attention. The question and the candidates are
concatenated and fed as input to the model.

  * •

HSSC-q \- We utilize the multi task model HSSC (Ma et al., 2018) that jointly
performs summarization and sentiment classification. However, we implement a
slightly modified variant HSSC-q that utilizes question with candidates and
sentiment of the label to perform answer generation and sentiment
classification.

  * •

T5 (Raffel et al., 2019) \- We use the pretrained text-to-text transformer
(T5) trained on a wide variety of tasks to do answer generation. The question
concatenated with candidates appropriately are fed as input to the model.

We use a pretrained transformer as a baseline for our relevancy prediction
task.

  * •

BERT (Devlin et al., 2018) \- We compare our model with different
architectural variants with the pretrained BERT model on Next Sentence
Prediction task.

We use ROUGE (R1, R2, RL) and BLEU (B1) to automatically evaluate the
performance of our answer generation pipeline. We also employ human evaluation
of our dataset and measure correctness w.r.t candidates (CC) and correctness
w.r.t ground truth label (CL) inorder to quantify the performance of our
pipeline. We use Accuracy (Acc), Precision (Pre), Recall (Rec) and F1-score
(F1) to evaluate the variants of our relevancy prediction model.

###  5.3. Implementation details

We use Transformers (Wolf et al., 2020) package for training our transformers
and loading pretrained models. All our models are implemented in Pytorch
(Paszke et al., 2017).

####  5.3.1. Relevancy prediction

We finetune BERT (Devlin et al., 2018) model on dataset $D1$. We also train
RoBERTa (Liu et al., 2019) model on dataset $D1$ pretrained on Flipkart
reviews data on mobiles vertical to perform relevancy prediction. We try two
variants of these models by changing the input. The first variant utilizes
only the duplicate answer as second sentence for prediction and is denoted by
BERT-A and RoBERTa-A while the second variant uses both duplicate question and
answer for prediction and is denoted by BERT-QA and RoBERTa-QA. The remaining
two sources remain the same across variants. Every sentence in a review is
considered as an individual candidate and key value pair present in
specifications is utilized directly(not converted into a sentence). All four
models are trained for 5 epochs with a batch size of 32.

####  5.3.2. Ambiguity prediction

We use pretrained T5 (Raffel et al., 2019) model for ambiguity prediction.
During training, we filter out the sentiments that are in contrast with the
label and during evaluation, we keep the sentiment that is expressed in most
of the candidates (i.e) minority sentiments are eliminated. Around one third
of the dataset contains WH questions as reported in Table 3 and sentiment
filtering is not performed on those points.

####  5.3.3. Answer generation

We train Seq2Seq model with pretrained Glove embeddings (Pennington et al.,
2014) with 300 dimensions and with a vocabulary size of 400k. We train HSSC-q
(Ma et al., 2018) using the details provided in the paper. We finetune
pretrained T5 (Raffel et al., 2019) model. We concatenate all the relevant
candidates from reviews, specifications and duplicate question & answer pairs
to a single sentence. Every duplicate question is followed by its
corresponding answer and unnecessary punctuation are removed from
specifications. We train all the models with a batch size of 32. We set a
learning rate of $5\times 10^{-5}$. We train all the models for 25 epochs.

###  5.4. Results

####  5.4.1. Relevancy prediction

Table 5. Methods comparison on relevancy prediction Model | Acc | Pre | Rec | F1
---|---|---|---|---
BERT-base | 0.635 | 0.637 | 0.996 | 0.777
RoBERTa-A | 0.708 | 0.767 | 0.7778 | 0.772
BERT-A | 0.749 | 0.806 | 0.797 | 0.802
RoBERTa-QA | 0.764 | 0.832 | 0.789 | 0.810
BERT-QA | 0.838 | 0.873 | 0.872 | 0.873
Table 6. Evaluation of methods on answer generation | Dichot. questions | WH questions
---|---|---
| R1 | R2 | RL | B1 | R1 | R2 | RL | B1
T5-Base | 9.74 | 1.89 | 9.18 | 0.22 | 8.14 | 2.20 | 7.80 | 0.77
Seq2Seq | 22.87 | 6.57 | 22.09 | 1.50 | 14.50 | 3.74 | 13.77 | 0.10
HSSC-q | 24.19 | 8.65 | 23.46 | 1.91 | 15.43 | 4.85 | 14.68 | 0.90
T5-QA | 31.27 | 12.85 | 29.65 | 5.48 | 22.69 | 8.77 | 20.71 | 3.21
MSQAP (rel. only) | 31.17 | 12.79 | 29.58 | 5.41 | 22.48 | 8.47 | 20.60 | 3.18
MSQAP (full) | 30.47 | 12.16 | 28.88 | 5.18 | 22.64 | 8.73 | 20.85 | 3.28
Table 7. Case study of generated answers Question:  is this gorilla glass in
this device….??
---
Reference Answer:  no you have to protect at your own
T5-base:  Has it gorilla glass?
Seq2Seq:  no , it has gorilla glass
HSSC-q:  yes gorilla glass 3
T5-QA:  No, it’s not gorilla glass.
MSQAP(rel.):  No, it has no gorilla glass.
MSQAP(full):  No, it is not gorilla glass.
Question:  how to handle ABC game. graphics and game performance?
Reference Answer:  you can play it in HD mode with quite decent fps but hdr
mode is too much for this device in ABC mobile
T5-base:  bad
Seq2Seq:  it can play ABC in settings settings
HSSC-q:  you can play ABC in hd graphics
T5-QA:  ABC game is very smooth and graphics are very good.
MSQAP(rel.):  ABC is a high end game. It runs smoothly on high graphics
settings.
MSQAP(full):  ABC is a high end game. It runs smoothly on HD graphics.
Question: sound quality and heating problem?
Reference Answer: no issue at all and sound is great
T5-base: Hang
Seq2Seq: sound quality is good
HSSC-q: sound quality is good
T5-QA: sound quality is good but heating problem is there
MSQAP(rel.): sound quality is good but heating problem is there
MSQAP(full): sound quality is good and no heating problem

The relevancy prediction results are reported in Table 5. Though relevancy
prediction is not directly related to answer generation, ranking the
candidates based on their importance and picking the top $k$ candidates aids
in the performance of generation. Our baseline model, BERT predicts almost all
candidates as relevant and hence has a high recall. However, precision of the
baseline model is quite low proving that its ability to pick the relevant
candidates is lower. Both the variants finetuned from BERT perform better than
their counterparts owing to BERT being pretrained on NSP task. Our models,
BERT-A and RoBERTa-A have a moderate performance compared to QA variants due
to the lack of duplicate question information. BERT-QA has the best
performance because it combines best of both worlds; NSP pretraining and QA
information. We choose BERT-QA as the relevancy prediction model in MSQA
Pipeline.

####  5.4.2. Answer generation pipeline

The performance of our approach compared with the baselines are reported in
Table 6 which shows that our variants report the highest performance in
content preservation metrics such as ROGUE and BLEU. The generated answers
from each of these models are reported in Table 6. The pretrained T5 (Raffel
et al., 2019) model almost always generates answers with a couple of words.
The Seq2Seq model mostly doesn’t generate proper answers to the posted
question, rather a general sequence of words. The multi task HSSC model
modified for answer generation (HSSC-q) shows a slight improvement due to
being trained to pay attention to sentiment of the candidates. However, the
generated answers are still not as coherent. Our MSQA Pipeline and its
variants generate coherent answers handling most spelling mistakes. Also, it
is easier to generate answers for dichotomous questions compared to WH
questions, hence all models show a huge performance gain on dichotomous
questions present in validation data. One important point to be noted is that
the generation model (T5-QA) without the other two components show the best
performance in most of the metrics.

Table 8. Differences in generated answers Question:  will u give headphone in
the mobile box inside?
---
Reference Answer:  yes it includes earphone also
T5-QA:  No, you have to buy it separately.
MSQAP(rel.):  yes, earphones are there
MSQAP(full):  yes, earphones are there
Question:  How can used to 2nd back camera?
Reference Answer:  In portrait mode, both cameras work simultaneously
T5-QA:  it’s a portrait mode..
MSQAP(rel.):  Open the camera app and click on the left side of the camera
icon. Then click on
MSQAP(full):  Open the camera app and click on the portrait mode.
Question: is there 3gb ram version avilable?
Reference Answer: no never .4GB ram please
T5-QA: No, 4gb ram variant is not available.
MSQAP(rel.): No, 4gb ram variant is not available.
MSQAP(full): No, it’s 4gb ram

####  5.4.3. Human Evaluation

Table 9. Human evaluation of our methods | Dichot. questions | WH questions
---|---|---
| CC | CL | CC | CL
T5-QA | 0.919 | 0.628 | 0.833 | 0.537
MSQAP (full) | 0.943 | 0.845 | 0.869 | 0.656

Though the generation model (T5-QA) mostly possess the highest ROUGE and BLEU
scores among all the other methods, the generated answers are not as precise
as the MSQA Pipeline. We believe the absence of grammatical consistency and
presence of spelling mistakes in the dataset render BLEU and ROUGE scores to
be only an approximate measure of overall generation performance. Some of the
generated answers that are different and sometimes incorrect in generation
model are reported in Table 8. Hence, we performed human evaluation of
generated answers and the results are tabulated in Table 9. Human annotators
were asked to label a generated answer correct w.r.t candidates if the
information present in the them is accurately reflected in the generated
response. The aim of this task is to make sure that the model pays attention
to information present in the candidates while generating the answers instead
of memorizing the responses from the training data. Correctness w.r.t label is
measured by checking if the generated response matches with the ground truth
answer. Also, annotators were asked to evaluate if a question can be answered
with the information present in the candidates. This measure is called
answerability. Out of 11183 data points present in the validation dataset, we
labelled 8207 points for evaluation. Around 5389 points were answerable with
the given information making the answerability of the dataset to be 65.66%.
There is slight improvement in correctness w.r.t context in MSQAP when
compared to generation model (T5-QA) which we attribute to relevancy
prediction. However, the huge improvement in correctness w.r.t label can be
attributed to both the components. As discussed before, generating answers for
dichotomous questions is an easier task and hence, the performance is
relatively high.

##  6\. Conclusion

Automatically answering questions is an important area of interest in
E-commerce because it helps users in deciding if the product matches their
requirement in order to make a purchase decision. To the best of our
knowledge, this is the first work in e-commerce domain that automatically
generates natural language answers given the information about the product
from different sources such as specifications, similar questions and reviews.
We describe the challenges with respect to noisy and inconsistent user data,
and propose a novel question answering pipeline (MSQAP) that utilizes
information from these sources in-order to generate coherent and accurate
answers. Our relevancy prediction model (BERT-QA) outperforms all other
variants and has an improvement of 12.36% in F1 score compared to the
baseline. We also show how to solve for ambiguity in user data by using a
pretrained ambiguity prediction model taking into account the sentiments of
the answer candidates. One key challenge in building Question Answering
systems is the need for supervised training data for passage retrieval tasks.
We show how we can use noisy answers submitted from users and reduce the need
for supervised annotations of text spans required in training Question
Answering models. Our generation model outperforms the baselines in all
content preservation metrics such as BLEU, ROUGE and has an average
improvement of 35.02% in ROUGE and 198.75% in BLEU compared to the highest
performing baseline (HSSC-q). Human evaluation of our pipeline shows us that
our method has an overall improvement in accuracy of 30.7% over the generation
model (T5-QA), resulting in our generation approach (MSQAP) providing more
accurate answers from the full pipeline. Our future work in this area is to
train an end to end model to incorporate both answer generation and ambiguity
prediction as part of the training process as compared to separate modules
presented in the current approach. We also plan to extend this natural
language generation approach to other e-commerce use-cases such as answering
questions about offers, delivery, etc. in addition to product information.

## References

  * (1)
  * Bahdanau et al. (2016) Dzmitry Bahdanau, Kyunghyun Cho, and Yoshua Bengio. 2016\.  Neural Machine Translation by Jointly Learning to Align and Translate.  arXiv:1409.0473 [cs.CL]
  * Chen et al. (2019) Shiqian Chen, Chenliang Li, Feng Ji, Wei Zhou, and Haiqing Chen. 2019.  Review-Driven Answer Generation for Product-Related Questions in E-Commerce _(WSDM ’19)_. Association for Computing Machinery, New York, NY, USA, 411–419.  https://doi.org/10.1145/3289600.3290971
  * Cui et al. (2017) Lei Cui, Shaohan Huang, Furu Wei, Chuanqi Tan, Chaoqun Duan, and Ming Zhou. 2017\.  SuperAgent: A Customer Service Chatbot for E-commerce Websites. In _Proceedings of ACL 2017, System Demonstrations_. Association for Computational Linguistics, Vancouver, Canada, 97–102.  https://www.aclweb.org/anthology/P17-4017
  * Deng et al. (2020) Yang Deng, Wenxuan Zhang, and Wai Lam. 2020.  Opinion-aware Answer Generation for Review-driven Question Answering in E-Commerce.  arXiv:2008.11972 [cs.CL]
  * Devlin et al. (2018) Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2018.  BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding.  _CoRR_ abs/1810.04805 (2018).  arXiv:1810.04805 http://arxiv.org/abs/1810.04805
  * Dzendzik et al. (2019) Daria Dzendzik, Carl Vogel, and Jennifer Foster. 2019\.  Is It Dish Washer Safe? Automatically Answering “Yes/No” Questions Using Customer Reviews. In _Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Student Research Workshop_. Association for Computational Linguistics, Minneapolis, Minnesota, 1–6.  https://doi.org/10.18653/v1/N19-3001
  * Gao et al. (2019) Shen Gao, Zhaochun Ren, Yihong Eric Zhao, Dongyan Zhao, Dawei Yin, and Rui Yan. 2019\.  Product-Aware Answer Generation in E-Commerce Question-Answering.  _CoRR_ abs/1901.07696 (2019).  arXiv:1901.07696 http://arxiv.org/abs/1901.07696
  * Lan et al. (2019) Zhenzhong Lan, Mingda Chen, Sebastian Goodman, Kevin Gimpel, Piyush Sharma, and Radu Soricut. 2019\.  ALBERT: A Lite BERT for Self-supervised Learning of Language Representations.  _CoRR_ abs/1909.11942 (2019).  arXiv:1909.11942 http://arxiv.org/abs/1909.11942
  * Lewis et al. (2019) Mike Lewis, Yinhan Liu, Naman Goyal, Marjan Ghazvininejad, Abdelrahman Mohamed, Omer Levy, Veselin Stoyanov, and Luke Zettlemoyer. 2019.  BART: Denoising Sequence-to-Sequence Pre-training for Natural Language Generation, Translation, and Comprehension.  _CoRR_ abs/1910.13461 (2019).  arXiv:1910.13461 http://arxiv.org/abs/1910.13461
  * Liu et al. (2019) Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019.  RoBERTa: A Robustly Optimized BERT Pretraining Approach.  _CoRR_ abs/1907.11692 (2019).  arXiv:1907.11692 http://arxiv.org/abs/1907.11692
  * Ma et al. (2018) Shuming Ma, Xu Sun, Junyang Lin, and Xuancheng Ren. 2018\.  A Hierarchical End-to-End Model for Jointly Improving Text Summarization and Sentiment Classification.  _CoRR_ abs/1805.01089 (2018).  arXiv:1805.01089 http://arxiv.org/abs/1805.01089
  * McAuley and Yang (2016) Julian McAuley and Alex Yang. 2016.  Addressing Complex and Subjective Product-Related Queries with Customer Reviews. In _Proceedings of the 25th International Conference on World Wide Web_ (Montréal, Québec, Canada) _(WWW ’16)_. International World Wide Web Conferences Steering Committee, Republic and Canton of Geneva, CHE, 625–635.  https://doi.org/10.1145/2872427.2883044
  * Mittal et al. (2021) Happy Mittal, Aniket Chakrabarti, Belhassen Bayar, Animesh Anant Sharma, and Nikhil Rasiwasia. 2021.  Distantly Supervised Transformers For E-Commerce Product QA.  arXiv:2104.02947 [cs.LG]
  * Moghaddam and Ester (2011) Samaneh Moghaddam and Martin Ester. 2011.  AQA: Aspect-based Opinion Question Answering. 89–96.  https://doi.org/10.1109/ICDMW.2011.34
  * Paszke et al. (2017) Adam Paszke, Sam Gross, Soumith Chintala, Gregory Chanan, Edward Yang, Zachary DeVito, Zeming Lin, Alban Desmaison, Luca Antiga, and Adam Lerer. 2017\.  Automatic differentiation in PyTorch.  (2017).
  * Pennington et al. (2014) Jeffrey Pennington, Richard Socher, and Christopher D. Manning. 2014.  GloVe: Global Vectors for Word Representation. In _Empirical Methods in Natural Language Processing (EMNLP)_. 1532–1543.  http://www.aclweb.org/anthology/D14-1162
  * Raffel et al. (2019) Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J. Liu. 2019.  Exploring the Limits of Transfer Learning with a Unified Text-to-Text Transformer.  _CoRR_ abs/1910.10683 (2019).  arXiv:1910.10683 http://arxiv.org/abs/1910.10683
  * See et al. (2017) Abigail See, Peter J. Liu, and Christopher D. Manning. 2017\.  Get To The Point: Summarization with Pointer-Generator Networks.  _CoRR_ abs/1704.04368 (2017).  arXiv:1704.04368 http://arxiv.org/abs/1704.04368
  * Sutskever et al. (2014) Ilya Sutskever, Oriol Vinyals, and Quoc V. Le. 2014\.  Sequence to Sequence Learning with Neural Networks.  _CoRR_ abs/1409.3215 (2014).  arXiv:1409.3215 http://arxiv.org/abs/1409.3215
  * Vaswani et al. (2017) Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017\.  Attention Is All You Need.  _CoRR_ abs/1706.03762 (2017).  arXiv:1706.03762 http://arxiv.org/abs/1706.03762
  * Wolf et al. (2020) Thomas Wolf, Lysandre Debut, Victor Sanh, Julien Chaumond, Clement Delangue, Anthony Moi, Pierric Cistac, Tim Rault, Rémi Louf, Morgan Funtowicz, Joe Davison, Sam Shleifer, Patrick von Platen, Clara Ma, Yacine Jernite, Julien Plu, Canwen Xu, Teven Le Scao, Sylvain Gugger, Mariama Drame, Quentin Lhoest, and Alexander M. Rush. 2020\.  HuggingFace’s Transformers: State-of-the-art Natural Language Processing.  arXiv:1910.03771 [cs.CL]
  * Yang et al. (2019) Zhilin Yang, Zihang Dai, Yiming Yang, Jaime G. Carbonell, Ruslan Salakhutdinov, and Quoc V. Le. 2019\.  XLNet: Generalized Autoregressive Pretraining for Language Understanding.  _CoRR_ abs/1906.08237 (2019).  arXiv:1906.08237 http://arxiv.org/abs/1906.08237
  * Yu et al. (2017) Jianfei Yu, Minghui Qiu, Jing Jiang, Jun Huang, Shuangyong Song, Wei Chu, and Haiqing Chen. 2017.  Modelling Domain Relationships for Transfer Learning on Retrieval-based Question Answering Systems in E-commerce.  _CoRR_ abs/1711.08726 (2017).  arXiv:1711.08726 http://arxiv.org/abs/1711.08726