I think what you literally need is the function f such that y = f(x, t) where y is the outcome, t is the treatment and x is the covariates (or features of an infant), because with that function you can compare f(x, 1) and f(x, 0) and see which gives you a better y.
In this case, my answer is, the given example does not have that function and so you cannot achieve that. It requires you to create that function f. You will see the extra work you need to do in the discussion below.
step 1 of the example makes a model assumption that all covariates (i.e. all the 26 x's) are the common causes, and because of that, all the 26 x's should be inside the function f you want to create.
then you need to think about how y is depending on the x's. step 3 actually required this as well, but because this is case-by-case, there is no one single answer, and so step 3 actually demonstrated 4 different simple ways. Take step 3.1 as an example, it uses linear regression, which should be effectively modeling f as:
f(x, t) = at + bx
However, can we use this model for your goal - calculate difference in outcomes of the two treatment for a new infant ?
yes, but because f(x, 1) - f(x, 0) = a, and this difference is independent of x, which means that you always get the same result for any new infant, which means you will always have to pick the same treatment.
Now I hope you see that you actually need to find the best function f to model the relationship between y, x and t. You may carefully examine the relation between y and each x given a t, and apply the best model or combination of model from your machine learning toolbox. If you finally justify that the above linear model is the perfect model assumption, then I would just say, ok, assign all new infants to that same treatment then.