class_docstr: Class for loading text data with batches 
class_docstr_tok: ["Class","for","loading","text","data","with","batches"]
code: def __init__(self, path: str):
      if os.path.isfile(path):
          raise ValueError("Expected directory path but got file")
      super().__init__(path)
  
imports: import glob
  import json
  import os
  from abc import ABC, abstractmethod
  import pandas
label_desc: Use image node_id 1 to create a new TextBatchLoader object from inherited base classes: BatchLoader with example: obj = TextBatchLoader(path)