code: def select_continuation_from_batch_left_padding(
      generations: Union[List[List[int]], torch.Tensor],
      max_context_size: int,
  ):
      """Select the continuation from the batch, removing prompts of different lengths.
      Args:
          generations (Union[List[List[int]], torch.Tensor]):
              A tensor or list-of-lists of shape [batch_size, sequence length].
          max_context_size (int):
              The size of the biggest context; generations will proceed from that
              index.
      Example:
          PAD     PAD Continue : The dog chased the cat  [every       day of the week]
          Riddle  me    this   : The  dog chased the  cat [yesterday] PAD PAD PAD PAD
      Output:
          [every day of the week]
          [yesterday]  PAD PAD PAD PAD
      """
      return generations[:, max_context_size:]
  
imports: import os
  import pathlib
  import re
  import collections
  import functools
  import inspect
  import sys
  from typing import List, Union
  import torch
  from omegaconf import OmegaConf
  import sacrebleu
  from rouge_score import rouge_scorer, scoring
label_desc: Use image node_id 9 for calling a global function with example usage: select_continuation_from_batch_left_padding(generations, max_context_size) and returns: generations