added replacing primitive generators