Custom Metrics
Evaluate your LLM outputs with easy-to-implement custom metrics
Last updated
Evaluate your LLM outputs with easy-to-implement custom metrics
Last updated
Make sure you have your OpenAI API Key before you begin.
custom_metrics()
Quickly create bespoke metrics to evaluate outputs based on other specific criteria. Implement constraints and automatically check if your LLM outputs meet these constraints. Returns a list of booleans: one for each guideline / constraint you provide.
Param | Type | Description |
---|---|---|
Output Type | Output Definition |
---|---|
output
str
the response from your LLM
constraints
List[str]
List of constraints you want to check your LLM output against
List[str]
a list of booleans: one for each guideline you provide
"True" signifies that the output has violated the constraint