code: def _is_trajectory_like(value):
      """Helper to identify values that are trajectory like."""
      if isinstance(value, trajectory.Trajectory):
          return True
  
      fields = getattr(value, "_fields", None)
      if fields and trajectory.Trajectory._fields == fields:
          return True
  
      return False
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import typing
  import tensorflow
  from tf_agents.specs import tensor_spec
  from tf_agents.trajectories import policy_step
  from tf_agents.trajectories import time_step
  from tf_agents.trajectories import trajectory
  from tf_agents.typing import types
  from tf_agents.utils import composite
  from tf_agents.utils import nest_utils
  import typing_extensions
label_desc: Use image node_id 2 for calling a global function with example usage: _is_trajectory_like(value) and returns: False, True, True