Solution (source code)

= Solution

For each mode, the right side of
$$
\Delta_{\mathcal R}^2(k)=\frac1{2\epsilon M_{\rm Pl}^2}
\left(\frac H{2\pi}\right)^2
$$
is evaluated at <cosmological horizon exit>, $k=aH$. Since
$$
\frac{d\log H}{dN}=-\epsilon,
\qquad
\frac{d\log\epsilon}{dN}=\eta,
\qquad
\frac{d\log k}{dN}=1-\epsilon,
$$
first order in the <Hubble slow-roll parameters> gives
$$
\boxed{n_s-1=\frac{d\log\Delta_{\mathcal R}^2}{d\log k}
=-2\epsilon-\eta}.
$$