File tree 2 files changed +7
-0
lines changed
2 files changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ import type {
5
5
AxAIPromptConfig ,
6
6
AxAIService ,
7
7
AxAIServiceActionOptions ,
8
+ AxAIServiceMetrics ,
8
9
AxChatRequest ,
9
10
AxChatResponse ,
10
11
AxEmbedResponse
@@ -32,6 +33,7 @@ class MockService implements AxAIService {
32
33
getModelConfig = ( ) => ( { } ) ;
33
34
getFeatures = ( ) => ( { functions : false , streaming : false } ) ;
34
35
getModelMap = ( ) => undefined ;
36
+ getMetrics = ( ) => ( { } ) as AxAIServiceMetrics ;
35
37
36
38
embed = async ( ) => ( { } ) as AxEmbedResponse ;
37
39
setOptions = ( ) => { } ;
Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ import type {
5
5
AxAIPromptConfig ,
6
6
AxAIService ,
7
7
AxAIServiceActionOptions ,
8
+ AxAIServiceMetrics ,
8
9
AxAIServiceOptions ,
9
10
AxChatRequest ,
10
11
AxChatResponse ,
@@ -105,6 +106,10 @@ export class AxBalancer implements AxAIService {
105
106
return this . currentService . getFeatures ( model ) ;
106
107
}
107
108
109
+ getMetrics ( ) : AxAIServiceMetrics {
110
+ return this . currentService . getMetrics ( ) ;
111
+ }
112
+
108
113
async chat (
109
114
req : Readonly < AxChatRequest > ,
110
115
options ?: Readonly < AxAIPromptConfig & AxAIServiceActionOptions > | undefined
You can’t perform that action at this time.
0 commit comments