refactor the packages so that local implementations are stored in a single package