class_docstr: A helper for tuners to deduplicate generated parameters.
  
  When the tuner generates an already existing parameter,
  calling this will return a new parameter generated with grid search.
  Otherwise it returns the orignial parameter object.
  
  If all parameters have been generated, raise ``NoMoreTrialError``.
  
  All search space types, including nested choice, are supported.
  
  Resuming and updating search space are not supported for now.
  It will not raise error, but may return duplicate parameters.
  
  See random tuner's source code for example usage.
code: def add_history(
      self, formatted_parameters: FormattedParameters
  ) -> None:
      params = deformat_parameters(formatted_parameters, self._space)
      params_str = typing.cast(str, nni.dump(params, sort_keys=True))
      if params_str not in self._history:
          self._history.add(params_str)
  
file_path: nni/nni/common/hpo_utils/dedup.py
imports: from __future__ import annotations
  import logging
  import typing
  import nni
  from .formatting import FormattedParameters, FormattedSearchSpace, ParameterSpec, deformat_parameters
label_desc: Use image node_id 5 for calling the Deduplicator obj's underlying member method code with example usage: obj.add_history(formatted_parameters) without return types