Major package refractor amongst other changes