Started poking at this myself.
You can't do this because CookingRecipeSerializer.IFactory is not visible (and is required for the lambda syntax to function correctly). I had to clone my own copy of CookingRecipeSerializer and AbstractCookingRecipe as well as all of the register methods vanilla uses.
This is probably an ideal solution anyway, as AbstractCookingRecipe is a class that implements IRecipe<IInventory>, which should probably be changed for mod machines anyway, but we can't because of the definition of IRecipe....
I did find this comment, but it still depends on IInventory:
https://gist.github.com/williewillus/353c872bcf1a6ace9921189f6100d09a#gistcomment-2939062