File tree Expand file tree Collapse file tree 1 file changed +2
-3
lines changed
Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change 77from typing import Dict , Optional , Union , cast
88
99from codex import AuthenticationError
10- from codex .types .project_validate_params import Response
10+ from codex .types .project_validate_params import Response , Tool
1111
1212from cleanlab_codex .internal .analytics import _AnalyticsMetadata
1313from cleanlab_codex .internal .sdk_client import client_from_access_key
@@ -194,7 +194,6 @@ def validate(
194194
195195 When available, consider swapping your AI response with the expert answer before serving the response to your user.
196196 """
197-
198197 return self ._sdk_client .projects .validate (
199198 self ._id ,
200199 messages = messages ,
@@ -203,7 +202,7 @@ def validate(
203202 query = query ,
204203 rewritten_question = rewritten_query ,
205204 custom_metadata = metadata ,
206- tools = tools ,
205+ tools = [ cast ( Tool , tool ) for tool in tools ] if tools else None ,
207206 eval_scores = eval_scores ,
208207 )
209208
You can’t perform that action at this time.
0 commit comments