In the course of a proof, I need some version of Castelnuovo and Artin's contractibility criteria for a family of surfaces. Say I have a family (flat is probably needed, in order to compare intersection products as varying fibers) of surfaces $(\mathcal{X},\mathcal{B}) \rightarrow T$, where $\mathcal{B}_t \subset \mathcal{X}_t$ cuts either a $(-1)$-curve or some configuration of curves admitted by Artin's criterion for every fiber $t$. Assume that the configuration is independent of $t$. Then, I think some version of the contractibility criteria should hold. In particular, there should be an open subset $U \subset T$ such that I can perform Castelnuovo or Artin's contractions in family.

Just looking at the proof of the criteria for one fixed surface, it seems one can mimic the proofs to get a contraction in family (up to shrinking the base). My question are then the following.

Is this proved somewhere? If so, what is a reference?

If it is not proved, does it seems plausible? Are there some assumptions on the setup I should require in order for it to work?

If everything works as I expect, what is the obstruction (if any) to extend the contraction over the whole base $T$?