Capitalization in tag replacement