code: def backend_factory(
      *, backend_name, api_token=None, proxies=None
  ) -> BackendApiClient:
      if backend_name == "offline":
          return OfflineBackendApiClient()
  
      elif backend_name is None:
          return HostedNeptuneBackendApiClient(api_token, proxies)
  
      else:
          raise InvalidNeptuneBackend(backend_name)
  
imports: from neptune.legacy.backend import BackendApiClient
  from neptune.legacy.exceptions import InvalidNeptuneBackend
  from neptune.legacy.internal.api_clients import HostedNeptuneBackendApiClient, OfflineBackendApiClient
label_desc: Use image node_id 1 for calling a global function with example usage: backend_factory() and returns: OfflineBackendApiClient, HostedNeptuneBackendApiClient