filled out AM and SM create_slice functions