docs: def shelf_from_config(config, **default_init):
      """Get a `Shelf` instance dynamically based on config.
  
      `config` is a dictionary containing ``shelf_*`` keys as defined in
      :mod:`birding.config`.
      """
      shelf_cls = import_name(config['shelf_class'], default_ns='birding.shelf')
      init = {}
      init.update(default_init)
      init.update(config['shelf_init'])
      shelf = shelf_cls(**init)
      if hasattr(shelf, 'set_expiration') and 'shelf_expiration' in config:
          shelf.set_expiration(config['shelf_expiration'])
      return shelf