Skip to main content

Class: CorrectnessEvaluator

Correctness Evaluator

Extends

Implements

  • BaseEvaluator

Constructors

new CorrectnessEvaluator()

new CorrectnessEvaluator(params?): CorrectnessEvaluator

Parameters

params?: CorrectnessParams

Returns

CorrectnessEvaluator

Overrides

PromptMixin.constructor

Defined in

packages/llamaindex/src/evaluation/Correctness.ts:35

Methods

_getPromptModules()

protected _getPromptModules(): object

Return a dictionary of sub-modules within the current module that also implement PromptMixin (so that their prompts can also be get/set).

Can be blank if no sub-modules.

Returns

object

Overrides

PromptMixin._getPromptModules

Defined in

packages/llamaindex/src/evaluation/Correctness.ts:49


_getPrompts()

protected _getPrompts(): object

Returns

object

correctnessPrompt

correctnessPrompt: CorrectnessSystemPrompt

Overrides

PromptMixin._getPrompts

Defined in

packages/llamaindex/src/evaluation/Correctness.ts:44


_updatePrompts()

protected _updatePrompts(prompts): void

Parameters

prompts

prompts.correctnessPrompt: CorrectnessSystemPrompt

Returns

void

Overrides

PromptMixin._updatePrompts

Defined in

packages/llamaindex/src/evaluation/Correctness.ts:53


evaluate()

evaluate(__namedParameters): Promise<EvaluationResult>

Parameters

__namedParameters: EvaluatorParams

Returns

Promise<EvaluationResult>

Implementation of

BaseEvaluator.evaluate

Defined in

packages/llamaindex/src/evaluation/Correctness.ts:68


evaluateResponse()

evaluateResponse(__namedParameters): Promise<EvaluationResult>

Parameters

__namedParameters: EvaluatorResponseParams

Returns

Promise<EvaluationResult>

Implementation of

BaseEvaluator.evaluateResponse

Defined in

packages/llamaindex/src/evaluation/Correctness.ts:114


getPrompts()

getPrompts(): PromptsRecord

Returns

PromptsRecord

Inherited from

PromptMixin.getPrompts

Defined in

packages/core/dist/prompts/index.d.ts:58


updatePrompts()

updatePrompts(prompts): void

Parameters

prompts: PromptsRecord

Returns

void

Inherited from

PromptMixin.updatePrompts

Defined in

packages/core/dist/prompts/index.d.ts:59


validatePrompts()

validatePrompts(promptsDict, moduleDict): void

Parameters

promptsDict: PromptsRecord

moduleDict: ModuleRecord

Returns

void

Inherited from

PromptMixin.validatePrompts

Defined in

packages/core/dist/prompts/index.d.ts:57