code: def normalize_compiler_output(compiler_output: Dict[str, Any]) -> Dict[str, Any]:
      
      paths_and_names = [
          (path, contract_name)
          for path in compiler_output
          for contract_name in compiler_output[path].keys()
      ]
      paths, names = zip(*paths_and_names)
      if len(names) != len(set(names)):
          raise ManifestBuildingError(
              "Duplicate contract names were found in the compiler output."
          )
      return {
          name: normalize_contract_type(compiler_output[path][name])
          for path, name in paths_and_names
      }
docs: Return compiler output with normalized fields for each contract type,
      as specified in `normalize_contract_type`.