nlptest.testrunner.BaseRunner#

class BaseRunner(load_testcases: List[Sample], model_handler: ModelFactory, data: List[Sample])#

Bases: object

Base class for running tests on models.

__init__(load_testcases: List[Sample], model_handler: ModelFactory, data: List[Sample]) None#

Initialize the BaseRunner class.

Parameters:
  • load_testcases (List) – List containing the testcases to be evaluated.

  • model_handler (spark, spacy, transformer) – Object representing the model handler, either spaCy, SparkNLP or transformer.

Methods

__init__(load_testcases, model_handler, data)

Initialize the BaseRunner class.

evaluate()

Abstract method to evaluate the testcases.

evaluate() Tuple[List[Sample], DataFrame]#

Abstract method to evaluate the testcases.

Returns:

Tuple[List[Sample], pd.DataFrame]