added first bits of duplicate manager