langfair.metrics.counterfactual.metrics.baseclass.metrics.Metric#

class langfair.metrics.counterfactual.metrics.baseclass.metrics.Metric#

Bases: ABC

Abstract base class of all counterfactual metrics. Serves as a template for creating new metric functions.

__init__()#

Methods

__init__()

evaluate(texts1, texts2)

Abstract method that needs to be implemented by the user when creating a new metric function.

abstract evaluate(texts1, texts2)#

Abstract method that needs to be implemented by the user when creating a new metric function.

Return type:

Union[float, List[float]]