Skip to content

Commit 467f36a

Browse files
add model name for metrics
Signed-off-by: Jintao Zhang <[email protected]>
1 parent dca5149 commit 467f36a

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

src/semantic-router/pkg/extproc/request_handler.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -339,7 +339,7 @@ func (r *OpenAIRouter) handleModelRouting(openAIRequest *openai.ChatCompletionNe
339339
log.Printf("Reasoning mode decision for this query: %v on [%s] model", useReasoning, matchedModel)
340340
// Record reasoning decision metric with the effort that will be applied if enabled
341341
effortForMetrics := r.getReasoningEffort(categoryName)
342-
metrics.RecordReasoningDecision(categoryName, useReasoning, effortForMetrics)
342+
metrics.RecordReasoningDecision(categoryName, matchedModel, useReasoning, effortForMetrics)
343343

344344
// Track the model load for the selected model
345345
r.Classifier.IncrementModelLoad(matchedModel)

src/semantic-router/pkg/metrics/metrics.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -489,6 +489,8 @@ func InitializeBatchMetrics(config BatchMetricsConfig) {
489489
[]string{"processing_type"},
490490
)
491491
})
492+
}
493+
492494
// RecordReasoningDecision records a reasoning-mode decision for a category, model and effort
493495
func RecordReasoningDecision(category, model string, enabled bool, effort string) {
494496
status := "false"

0 commit comments

Comments
 (0)