code: def make_attrs(attrs=None, library=None):
      
      default_attrs = {"created_at": datetime.datetime.utcnow().isoformat()}
      if library is not None:
          library_name = library.__name__
          default_attrs["inference_library"] = library_name
          try:
              version = pkg_resources.get_distribution(library_name).version
              default_attrs["inference_library_version"] = version
          except pkg_resources.DistributionNotFound:
              if hasattr(library, "__version__"):
                  version = library.__version__
                  default_attrs["inference_library_version"] = version
  
      if attrs is not None:
          default_attrs.update(attrs)
      return default_attrs
docs: Make standard attributes to attach to xarray datasets.
  
      Parameters
      ----------
      attrs : dict (optional)
          Additional attributes to add or overwrite
  
      Returns
      -------
      dict
          attrs