code: def _parse_spans_row_as_example(row):
      """Parse elements to TF Example for toxic spans mode."""
      example = _parse_common(row)
      example["spans"] = np.array(
          ast.literal_eval(row["spans"]), dtype=np.int32
      )
      return example
  
file_path: datasets/tensorflow_datasets/text/civil_comments.py
imports: from __future__ import annotations
  import ast
  import csv
  import os
  from etils import epath
  import numpy
  import tensorflow_datasets.public_api
label_desc: Use image node_id 4 for calling a global function with example usage: _parse_spans_row_as_example(row) and returns: example