convert factorizer to bolt