Generate sequential identifiers using a template