Skip to content

Commit 4b214a9

Browse files
committed
fix(test): move ReasoningEffort to ModelScore in classification test
Update generic_category_mapping_test.go to use the new structure where reasoning_effort is a field of ModelScore instead of Category. Signed-off-by: Xunzhuo <[email protected]> Signed-off-by: bitliu <[email protected]>
1 parent a5e89bd commit 4b214a9

File tree

1 file changed

+18
-6
lines changed

1 file changed

+18
-6
lines changed

src/semantic-router/pkg/utils/classification/generic_category_mapping_test.go

Lines changed: 18 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,20 +27,32 @@ var _ = Describe("generic category mapping (MMLU-Pro -> generic)", func() {
2727
// Define generic categories with MMLU-Pro mappings
2828
cfg.Categories = []config.Category{
2929
{
30-
Name: "tech",
31-
MMLUCategories: []string{"computer science", "engineering"},
32-
ModelScores: []config.ModelScore{{Model: "phi4", Score: 0.9, UseReasoning: config.BoolPtr(false)}},
33-
ReasoningEffort: "low",
30+
Name: "tech",
31+
MMLUCategories: []string{"computer science", "engineering"},
32+
ModelScores: []config.ModelScore{{
33+
Model: "phi4",
34+
Score: 0.9,
35+
UseReasoning: config.BoolPtr(false),
36+
ReasoningEffort: "low",
37+
}},
3438
},
3539
{
3640
Name: "finance",
3741
MMLUCategories: []string{"economics"},
38-
ModelScores: []config.ModelScore{{Model: "gemma3:27b", Score: 0.8, UseReasoning: config.BoolPtr(true)}},
42+
ModelScores: []config.ModelScore{{
43+
Model: "gemma3:27b",
44+
Score: 0.8,
45+
UseReasoning: config.BoolPtr(true),
46+
}},
3947
},
4048
{
4149
Name: "politics",
4250
// No explicit mmlu_categories -> identity fallback when label exists in mapping
43-
ModelScores: []config.ModelScore{{Model: "gemma3:27b", Score: 0.6, UseReasoning: config.BoolPtr(false)}},
51+
ModelScores: []config.ModelScore{{
52+
Model: "gemma3:27b",
53+
Score: 0.6,
54+
UseReasoning: config.BoolPtr(false),
55+
}},
4456
},
4557
}
4658

0 commit comments

Comments
 (0)