Skip to content

Commit fe0f74e

Browse files
committed
update types
1 parent 71766c3 commit fe0f74e

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/cleanlab_codex/project.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
from typing import Dict, Optional, Union, cast
88

99
from codex import AuthenticationError
10-
from codex.types.project_validate_params import Response
10+
from codex.types.project_validate_params import Response, Tool
1111

1212
from cleanlab_codex.internal.analytics import _AnalyticsMetadata
1313
from 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

0 commit comments

Comments
 (0)