class_docstr: Apply the history best config
  
  Parameters
  ----------
  records : str, list of str, or iterator of (auto_scheduler.measure.MeasureInput,                                                auto_scheduler.measure.MeasureResult)
      Collection of tuning records.
      If is str, then it should be the filename of a records log file.
      Each row of this file is an encoded record pair. If it is an iterator,
      it can either be a set of str filenames which will be applied jointly,
      or a set of (input, result) tuples.
  n_lines: Optional[int]
      if it is not None, only load the first `n_lines` lines of log.
  include_compatible: bool
      When set to True, compatible records will also be considered.
code: def update(self, target, workload_key, state):
      entry, _, workload_args = self.get_workload_entry(
          self._best_user_defined, target.model, workload_key
      )
      entry[workload_args] = (state, 1)
  
      for k in target.keys:
          entry, _, _ = self.get_workload_entry(
              self._best_user_defined, k, workload_key
          )
          entry[workload_args] = (state, 1)
  
imports: import logging
  import pathlib
  from collections.abc import Iterable
  import numpy
  from tvm.contrib.utils import tempdir
  from tvm.tir.expr import FloatImm
  from .cost_model import RandomModel, XGBModel
  from .measure import LocalRPCMeasureContext
  from .measure_record import RecordToFile, load_records
  from .search_policy import PreloadMeasuredStates, SketchPolicy
  from .search_task import SearchTask, TuningOptions
  from .utils import calc_workload_dis_factor, decode_workload_key
label_desc: Use image node_id 5 for calling the ApplyHistoryBest obj's underlying member method code with example usage: obj.update(target, workload_key, state) without return types