changed models to account for duplicates