code: def _dependency(self, name, fn):
      dependencies = list(inspect.signature(fn).parameters)
      for dependency in dependencies:
          assert self._already_declared(dependency), (
              f"`{name}` depends on `{dependency}`, which has not been"
              " declared yet."
          )
  
      self._dependencies[name] = Dependency(fn, dependencies)
  
imports: import functools
  import inspect
  import itertools
  from operator import attrgetter
  from typing import Any
  from gluonts.pydantic import pydantic, deep_update
label_desc: Use image node_id 6 for calling the Settings obj's underlying member method code with example usage: obj._dependency(name, fn) without return types