Skip to content

Commit f90d736

Browse files
author
jariy17
committed
fix(eval): lowercase 'builtin' in list --type filter
1 parent b6318d9 commit f90d736

3 files changed

Lines changed: 4 additions & 4 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ agentcore eval evaluator code-based create \
143143
--lambda-arn arn:aws:lambda:us-west-2:123456789012:function:refund-policy \
144144
--json
145145

146-
# Get, list, delete. --type filters the returned page (Builtin | code-based | llm-as-a-judge).
146+
# Get, list, delete. --type filters the returned page (builtin | code-based | llm-as-a-judge).
147147
agentcore eval evaluator get --id <evaluatorId> --json
148148
agentcore eval evaluator list --type llm-as-a-judge --max-results 20 --json
149149
agentcore eval evaluator delete --id <evaluatorId> --yes --json

src/handlers/eval/evaluator/evaluator.test.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -320,7 +320,7 @@ describe("list filtering", () => {
320320
] as unknown as EvaluatorSummary[];
321321

322322
test.each([
323-
["Builtin", ["b1"]],
323+
["builtin", ["b1"]],
324324
["code-based", ["c1"]],
325325
["llm-as-a-judge", ["l1"]],
326326
] as const)("filters the returned page by --type %s", async (type, expectedIds) => {

src/handlers/eval/evaluator/list/index.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,13 @@ import { JsonRendererKey } from "../../../../tui";
55
import type { Core } from "../../../types";
66
import { coreOptsFromCtx } from "../../../utils";
77

8-
const TYPE_FILTERS = ["Builtin", "code-based", "llm-as-a-judge"] as const;
8+
const TYPE_FILTERS = ["builtin", "code-based", "llm-as-a-judge"] as const;
99

1010
// The AgentCore ListEvaluators API only paginates (nextToken/maxResults); it does
1111
// not filter by type. `--type` is therefore applied client-side to the returned
1212
// page, so combining it with --max-results can under-fill a page.
1313
const TYPE_TO_SDK: Record<(typeof TYPE_FILTERS)[number], string> = {
14-
Builtin: EvaluatorType.BUILTIN,
14+
builtin: EvaluatorType.BUILTIN,
1515
"code-based": EvaluatorType.CODE,
1616
"llm-as-a-judge": EvaluatorType.CUSTOM,
1717
};

0 commit comments

Comments
 (0)