For convenience we work with commutative rings instead of commutative algebras.




---


Fix a commutative ring $R$. Consider the functor $\mathsf{Mod}\longrightarrow \mathsf{CRing}$ defined by taking an $R$-module $M$ to $R\ltimes M$ (with dual number multiplication). Following the [nlab](https://ncatlab.org/nlab/show/Mod#TangentsAndDeformationTheory), the module of Kähler differentials of $R$ is defined as the universal arrow from $R$ to this functor.


There's also the equivalence between the category of *split* zero-square extensions and the category of modules. These result in the natural isomorphisms ($\operatorname{dom}$ takes an arrow to its domain).


$$\begin{aligned}\mathsf{CRing}(R,\operatorname{dom}(A^{\prime}\twoheadrightarrow A)) & \cong{\substack{\text{split square-zero}\\
\text{extensions}
}
}(R\ltimes\Omega\_{R}\twoheadrightarrow R,A^{\prime}\twoheadrightarrow A)\\
 & \cong \mathsf{Mod}(\Omega\_{R},\operatorname{Ker}(A^{\prime}\twoheadrightarrow A)).
\end{aligned}$$


So $\Omega \_R\cong \bf 0$ iff $R$ has exactly one arrow to the domain of every 
*split* square-zero extension.




---


On the other hand, we say $R$ is unramified if given a zero-square extension $A^\prime \twoheadrightarrow A$, the induced post-composition $$\mathsf{CRing}(R,A^\prime)\longrightarrow \mathsf{CRing}(R,A)$$ is injective. The diagrams of interest are below.


$$\require{AMScd} \begin{CD} A^\prime /I @<<< R\\ @AAA \\ A^\prime & \end{CD}
\; \; \; \begin{CD} A^\prime /I @<<< R\\ @AAA @VVV\\ A^\prime @<<< I \end{CD}$$




---


Now, if $\Omega \_R\cong \bf 0$ then there *exists and is unique* a diagonal arrow $R\to A^\prime $, which seems to easily give "unramified w.r.t *split* square-zero extensions". However, I see no way to deduce anything about the non-split ones.




---


The thing is, I feel a proof is very close: suppose $g,h$ are diagonal fillers $R\to A^\prime$ on the left below. Viewing them as module arrows this is equivalent to saying $g-h$ lands in $I$, i.e factors through $I\vartriangleleft A^\prime $. Finally $g=h$ iff this factorization $R\to I$ of $g-h$ must be zero. If only this could be given by the universal property...


Perhaps the correct way to proceed is using some universal property of the diagonal? (Not that it realizes the Kähler differentials.)



"Formally unramified iff trivial Kähler differentials" using only universal properties?
Your question can be rephrased as follows: I know something about split square-zero extensions. How can I (categorically) conclude something about all square-zero extensions? The key observation is that square-zero extensions are the *torsors* for the split square-zero extensions. I first learned about this general idea from section 7.4.1 of Lurie's [Higher algebra](http://people.math.harvard.edu/%7Elurie/papers/HA.pdf) and I formulated this idea more precisely [here](https://arxiv.org/abs/2006.04230).


Let $\varphi: B\to A$ be a square-zero extension. Then $\ker(\varphi)$ is an $A$-module and $A\oplus \ker(\varphi)\to A$ is an abelian group object in $\text{CRing}/A$. We have a natural group action $\tau: (A\oplus \ker(\varphi))\times\_A B\to B$ which is a torsor in the sense that $$(\tau, \pi\_B): (A\oplus \ker(\varphi))\times\_A B\to B\times\_A B$$ is an isomorphism.


Now we'll relate this to your question. Let $C$ be such that $\Omega\_C = 0$. Let $\varphi: B\to A$ be a square-zero extension. We want to show that the canonical map $\text{Hom}(C, B)\to\text{Hom}(C, A)$ is injective. Let $\alpha, \beta\in\text{Hom}(C, B) $ be such that $\varphi\circ\alpha = \varphi\circ\beta$. Thus $$(\alpha, \beta)\in \text{Hom}(C, B)\times\_{\text{Hom}(C,A)} \text{Hom}(C, B).$$ As you already showed, $\Omega\_C = 0$ implies $\text{Hom}(C, A\oplus\ker(\varphi))\approx\text{Hom}(C, A)$. Thus $$\begin{split} \text{Hom}(C, B)\times\_{\text{Hom}(C,A)} \text{Hom}(C, B) &\approx \text{Hom}(C, B\times\_A B) \\ &\approx \text{Hom}(C, (A\oplus \ker(\varphi))\times\_A B) \\ &\approx \text{Hom}(C, A\oplus \ker(\varphi))\times\_{\text{Hom}(C, A)} \text{Hom}(C, B)\\&\approx \text{Hom}(C, A)\times\_{\text{Hom}(C, A)} \text{Hom}(C, B)\\&\approx \text{Hom}(C, A\times\_A B)\\&\approx \text{Hom}(C, B)\end{split}$$ and this final bijection maps $(\alpha, \beta)$ to $\beta$. This establishes that there can be at most one lift for a general square-zero extension.


This same argument works in any category with a notion of Kähler differentials, as I show [here](https://arxiv.org/abs/2104.08999).


