Bayesian optimization of metastable nickel formation during the spontaneous crystallization under extreme conditions