import re


def capitalize_acronyms(name):
  """Capitalize acronyms."""
  known_acronyms = [
      'Cc',
      'Cl',
      'Cpu',
      'Db',
      'Gce',
      'Gcs',
      'Html',
      'Http',
      'Id',
      'Os',
      'Tls',
      'Url',
  ]

  for acronym in known_acronyms:
    # Match occurrences either at end of string, or before the start of another
    # word, or 's' (plural).
    pattern = acronym + '([A-Zs]|$)'
    name = re.sub(pattern, acronym.upper() + r'\1', name)

  return name