Predicting halo occupation and galaxy assembly bias with machine learning