code: def forward(
      model: Model[SeqT, SeqT], Xseq: SeqT, is_train: bool
  ) -> Tuple[SeqT, Callable]:
      layer: Model[List2d, List2d] = model.layers[0]
      if isinstance(Xseq, Padded):
          return _padded_forward(layer, Xseq, is_train)
      elif isinstance(Xseq, Ragged):
          return _ragged_forward(layer, Xseq, is_train)
      else:
          return cast(
              Tuple[SeqT, Callable], layer(cast(List2d, Xseq), is_train)
          )
  
file_path: thinc/thinc/layers/with_list.py
imports: from typing import Callable, List, Optional, Tuple, TypeVar, Union, cast
  from ..config import registry
  from ..model import Model
  from ..types import Array2d, Floats2d, Ints2d, List2d, Padded, Ragged
label_desc: Use image node_id 2 for calling a global function with example usage: forward(model, Xseq, is_train) and returns: _padded_forward, _ragged_forward, cast