File tree Expand file tree Collapse file tree 2 files changed +27
-12
lines changed Expand file tree Collapse file tree 2 files changed +27
-12
lines changed Original file line number Diff line number Diff line change 76
76
from .cli_eval import EvalMetricResult
77
77
from .cli_eval import EvalSetResult
78
78
from .cli_eval import EvalStatus
79
+ from .utils import common
79
80
from .utils import create_empty_state
80
81
from .utils import envs
81
82
from .utils import evals
@@ -119,27 +120,18 @@ class AgentRunRequest(BaseModel):
119
120
streaming : bool = False
120
121
121
122
122
- class AddSessionToEvalSetRequest (BaseModel ):
123
+ class AddSessionToEvalSetRequest (common . BaseModel ):
123
124
eval_id : str
124
125
session_id : str
125
126
user_id : str
126
127
127
128
128
- class RunEvalRequest (BaseModel ):
129
- model_config = ConfigDict (
130
- alias_generator = alias_generators .to_camel ,
131
- )
132
-
129
+ class RunEvalRequest (common .BaseModel ):
133
130
eval_ids : list [str ] # if empty, then all evals in the eval set are run.
134
131
eval_metrics : list [EvalMetric ]
135
132
136
133
137
- class RunEvalResult (BaseModel ):
138
- model_config = ConfigDict (
139
- alias_generator = alias_generators .to_camel ,
140
- populate_by_name = True ,
141
- )
142
-
134
+ class RunEvalResult (common .BaseModel ):
143
135
eval_set_file : str
144
136
eval_set_id : str
145
137
eval_id : str
Original file line number Diff line number Diff line change
1
+ # Copyright 2025 Google LLC
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # http://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing, software
10
+ # distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+
15
+ import pydantic
16
+ from pydantic import alias_generators
17
+
18
+
19
+ class BaseModel (pydantic .BaseModel ):
20
+ model_config = pydantic .ConfigDict (
21
+ alias_generator = alias_generators .to_camel ,
22
+ populate_by_name = True ,
23
+ )
You can’t perform that action at this time.
0 commit comments