Skip to content

Commit c0f5c86

Browse files
m7md7sienvizhur
andauthored
Relevance Evaluator: Support Conversational Format in specs (#4571)
Updated the dataMappingSchema to allow 'query' and 'response' to be either a string or an array of objects in Relevance Evaluator specs Co-authored-by: vizhur <[email protected]>
1 parent 9750409 commit c0f5c86

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed

assets/evaluators/builtin/relevance/spec.yaml

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
type: "evaluator"
22
name: "builtin.relevance"
3-
version: 3
3+
version: 4
44
displayName: "Relevance-Evaluator"
55
description: "Assesses how well the response matches the user’s intent or question. Higher scores mean better alignment with the prompt. It’s best used for generative business writing such as summarizing meeting notes, creating marketing materials, and drafting email."
66
evaluatorType: "builtin"
@@ -23,14 +23,22 @@ dataMappingSchema:
2323
type: "object"
2424
properties:
2525
query:
26-
type: "string"
26+
anyOf:
27+
- type: "string"
28+
- type: "array"
29+
items:
30+
type: "object"
2731
response:
28-
type: "string"
32+
anyOf:
33+
- type: "string"
34+
- type: "array"
35+
items:
36+
type: "object"
2937
required: ["query", "response"]
3038
outputSchema:
3139
relevance:
3240
type: "ordinal"
3341
desirable_direction: "increase"
3442
min_value: 1
3543
max_value: 5
36-
path: ./evaluator
44+
path: ./evaluator

0 commit comments

Comments
 (0)