The equivalence of (1) and (2) follows from Theorem \ref{theorem-regular-fs}. \medskip\noindent Assume (3). By Lemma \ref{lemma-formally-smooth-flat} we see that $A \to B$ is flat. By Lemma \ref{lemma-base-change-fs} we see that $k \to \overline{B}$ is formally smooth in the $\mathfrak m_{\overline{B}}$-adic topology. Thus (2) holds. \medskip\noindent Assume (2). Lemma \ref{lemma-formally-smooth-completion} tells us formal smoothness is preserved under completion. The same is true for flatness by Algebra, Lemma \ref{algebra-lemma-completion-faithfully-flat}. Hence we may replace $A$ and $B$ by their respective completions and assume that $A$ and $B$ are Noetherian complete local rings. In this case choose a diagram $$ \xymatrix{ S \ar[r] & B \\ R \ar[u] \ar[r] & A \ar[u] } $$ as in Lemma \ref{lemma-embed-map-Noetherian-complete-local-rings}. We will use all of the properties of this diagram without further mention. Fix a regular system of parameters $t_1, \ldots, t_d$ of $R$ with $t_1 = p$ in case the characteristic of $k$ is $p > 0$. Set $\overline{S} = S \otimes_R k$. Consider the short exact sequence $$ 0 \to J \to S \to B \to 0 $$ Since $B$ is flat over $A$ we see that $J \otimes_R k$ is the kernel of $\overline{S} \to \overline{B}$. As $\overline{B}$ and $\overline{S}$ are regular we see that $J \otimes_R k$ is generated by elements $\overline{x}_1, \ldots, \overline{x}_r$ which form part of a regular system of parameters of $\overline{S}$, see Algebra, Lemma \ref{algebra-lemma-regular-quotient-regular}. Lift these elements to $x_1, \ldots, x_r \in J$. Then $t_1, \ldots, t_d, x_1, \ldots, x_r$ is part of a regular system of parameters for $S$. Hence $S/(x_1, \ldots, x_r)$ is a power series ring over a field (if the characteristic of $k$ is zero) or a power series ring over a Cohen ring (if the characteristic of $k$ is $p > 0$), see Lemma \ref{lemma-quotient-power-series-ring-over-Cohen}. Moreover, it is still the case that $R \to S/(x_1, \ldots, x_r)$ maps $t_1, \ldots, t_d$ to a part of a regular system of parameters of $S/(x_1, \ldots, x_r)$. In other words, we may replace $S$ by $S/(x_1, \ldots, x_r)$ and assume we have a diagram $$ \xymatrix{ S \ar[r] & B \\ R \ar[u] \ar[r] & A \ar[u] } $$ as in Lemma \ref{lemma-embed-map-Noetherian-complete-local-rings} with moreover $\overline{S} = \overline{B}$. In this case the map $$ S \otimes_R A \longrightarrow B $$ is an isomorphism as it is surjective and an isomorphism on special fibres, see Algebra, Lemma \ref{algebra-lemma-mod-injective}. Thus by Lemma \ref{lemma-base-change-fs} it suffices to show that $R \to S$ is formally smooth in the $\mathfrak m_S$-adic topology. Of course, since $\overline{S} = \overline{B}$, we have that $\overline{S}$ is formally smooth over $k = R/\mathfrak m_R$. \medskip\noindent Choose elements $y_1, \ldots, y_m \in S$ such that $t_1, \ldots, t_d, y_1, \ldots, y_m$ is a regular system of parameters for $S$. If the characteristic of $k$ is zero, choose a coefficient field $K \subset S$ and if the characteristic of $k$ is $p > 0$ choose a Cohen ring $\Lambda \subset S$ with residue field $K$. At this point the map $K[[t_1, \ldots, t_d, y_1, \ldots, y_m]] \to S$ (characteristic zero case) or $\Lambda[[t_2, \ldots, t_d, y_1, \ldots, y_m]] \to S$ (characteristic $p > 0$ case) is an isomorphism, see Lemma \ref{lemma-quotient-power-series-ring-over-Cohen}. From now on we think of $S$ as the above power series ring. \medskip\noindent The rest of the proof is analogous to the argument in the proof of Theorem \ref{theorem-regular-fs}. Choose a solid diagram $$ \xymatrix{ S \ar[r]_{\bar\psi} \ar@{-->}[rd] & N/J \\ R \ar[u]^i \ar[r]^\varphi & N \ar[u]_\pi } $$ as in Definition \ref{definition-formally-smooth}. As $J^2 = 0$ we see that $J$ has a canonical $N/J$ module structure and via $\bar\psi$ a $S$-module structure. As $\bar\psi$ is continuous for the $\mathfrak m_S$-adic topology we see that $\mathfrak m_S^nJ = 0$ for some $n$. Hence we can filter $J$ by $N/J$-submodules $0 \subset J_1 \subset J_2 \subset \ldots \subset J_n = J$ such that each quotient $J_{t + 1}/J_t$ is annihilated by $\mathfrak m_S$. Considering the sequence of ring maps $N \to N/J_1 \to N/J_2 \to \ldots \to N/J$ we see that it suffices to prove the existence of the dotted arrow when $J$ is annihilated by $\mathfrak m_S$, i.e., when $J$ is a $K$-vector space. \medskip\noindent Assume given a diagram as above such that $J$ is annihilated by $\mathfrak m_S$. As $\mathbf{Q} \to S$ (characteristic zero case) or $\mathbf{Z} \to S$ (characteristic $p > 0$ case) is formally smooth in the $\mathfrak m_S$-adic topology (see Lemma \ref{lemma-power-series-ring-over-Cohen-fs}), we can find a ring map $\psi : S \to N$ such that $\pi \circ \psi = \bar \psi$. Since $S$ is a power series ring in $t_1, \ldots, t_d$ (characteristic zero) or $t_2, \ldots, t_d$ (characteristic $p > 0$) over a subring, it follows from the universal property of power series rings that we can change our choice of $\psi$ so that $\psi(t_i)$ equals $\varphi(t_i)$ (automatic for $t_1 = p$ in the characteristic $p$ case). Then $\psi \circ i$ and $\varphi : R \to N$ are two maps whose compositions with $\pi$ are equal and which agree on $t_1, \ldots, t_d$. Hence $D = \psi \circ i - \varphi : R \to J$ is a derivation which annihilates $t_1, \ldots, t_d$. By Algebra, Lemma \ref{algebra-lemma-universal-omega} we can write $D = \xi \circ \text{d}$ for some $R$-linear map $\xi : \Omega_{R/\mathbf{Z}} \to J$ which annihilates $\text{d}t_1, \ldots, \text{d}t_d$ (by construction) and $\mathfrak m_R \Omega_{R/\mathbf{Z}}$ (as $J$ is annihilated by $\mathfrak m_R$). Hence $\xi$ factors as a composition $$ \Omega_{R/\mathbf{Z}} \to \Omega_{k/\mathbf{Z}} \xrightarrow{\xi'} J $$ where $\xi'$ is $k$-linear. Using the $K$-vector space structure on $J$ we extend $\xi'$ to a $K$-linear map $$ \xi'' : \Omega_{k/\mathbf{Z}} \otimes_k K \longrightarrow J. $$ Using that $\overline{S}/k$ is formally smooth we see that $$ \Omega_{k/\mathbf{Z}} \otimes_k K \to \Omega_{\overline{S}/\mathbf{Z}} \otimes_S K $$ is injective by Theorem \ref{theorem-regular-fs} (this is true also in the characteristic zero case as it is even true that $\Omega_{k/\mathbf{Z}} \to \Omega_{K/\mathbf{Z}}$ is injective in characteristic zero, see Algebra, Proposition \ref{algebra-proposition-characterize-separable-field-extensions}). Hence we can find a $K$-linear map $\xi''' : \Omega_{\overline{S}/\mathbf{Z}} \otimes_S K \to J$ whose restriction to $\Omega_{k/\mathbf{Z}} \otimes_k K$ is $\xi''$. Write $$ D' : S \xrightarrow{\text{d}} \Omega_{S/\mathbf{Z}} \to \Omega_{\overline{S}/\mathbf{Z}} \to \Omega_{\overline{S}/\mathbf{Z}} \otimes_S K \xrightarrow{\xi'''} J. $$ Finally, set $\psi' = \psi - D' : S \to N$. The reader verifies that $\psi'$ is a ring map such that $\pi \circ \psi' = \bar \psi$ and such that $\psi' \circ i = \varphi$ as desired.