Refactoring: String ID generation for lists