def create_augmented_examples(orig_examples: Iterable[RawExample],
                              converter: casper_converters.BaseExampleConverter,
                              split: str,
                              log_every: int = 1000) -> List[AugmentedExample]:
  """Creates AugmentedExamples from the raw JSONLs.

  Args:
    orig_examples: An Iterable of deserialzied JSONs.
    converter: A subclass of BaseExampleConverter.
    split: Split name (used only for logging).
    log_every: Logging frequency.

  Returns:
    a list of AugmentedExamples.
  """
  examples = []
  for i, orig_example in enumerate(orig_examples):
    if i % log_every == 0:
      logging.info("[%s:%d] Produced %d examples", split, i, len(examples))
    converter.verify_exemplars(orig_example)
    examples.extend(converter.convert(orig_example))
  logging.info("[%s] Produced %d examples total.", split, len(examples))
  return examples
Creates AugmentedExamples from the raw JSONLs.

  Args:
    orig_examples: An Iterable of deserialzied JSONs.
    converter: A subclass of BaseExampleConverter.
    split: Split name (used only for logging).
    log_every: Logging frequency.

  Returns:
    a list of AugmentedExamples.
  
language/casper/augment/cached_retrieval_to_dataset_lib.py