GeezerVison is showing github.com — feat(api): api update · cleanlab/codex-python@7ccf252
File treeExpand file treeCollapse file tree Open diff view settings tests/api_resources/projects
Expand file treeCollapse file tree Open diff view settings Collapse file Copy file name to clipboard +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
| 1 | 1 | configured_endpoints: 56 | 2 | | -openapi_spec_hash: 12260ab88069ff15d254606e041debfb | | 2 | +openapi_spec_hash: 3edbb8139be919b07598ed85ebea9878 | 3 | 3 | config_hash: 6c3ad84d97bf1d0989ad2ec0cae64078 |
Collapse file Copy file name to clipboardExpand all lines: src/codex/resources/projects/query_logs.py +70-4Lines changed: 70 additions & 4 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -147,6 +147,17 @@ def list( | 147 | 147 |
| 148 | 148 | primary_eval_issue: Filter logs that have ANY of these primary evaluation issues (OR operation) | 149 | 149 |
| | 150 | + sort: Field or score to sort by. | | 151 | +
| | 152 | + Available fields: 'created_at', 'primary_eval_issue_score'. | | 153 | +
| | 154 | + For eval scores, use '.eval.' prefix followed by the eval name. | | 155 | +
| | 156 | + Default eval scores: '.eval.trustworthiness', '.eval.context_sufficiency', | | 157 | + '.eval.response_helpfulness', '.eval.query_ease', '.eval.response_groundedness'. | | 158 | +
| | 159 | + Custom eval scores: '.eval.custom_eval_1', '.eval.custom_eval_2', etc. | | 160 | +
| 150 | 161 | tool_call_names: Filter by names of tools called in the assistant response | 151 | 162 |
| 152 | 163 | was_cache_hit: Filter by cache hit status | @@ -286,6 +297,17 @@ def list_by_group( | 286 | 297 |
| 287 | 298 | remediation_ids: List of groups to list child logs for | 288 | 299 |
| | 300 | + sort: Field or score to sort by. | | 301 | +
| | 302 | + Available fields: 'created_at', 'primary_eval_issue_score'. | | 303 | +
| | 304 | + For eval scores, use '.eval.' prefix followed by the eval name. | | 305 | +
| | 306 | + Default eval scores: '.eval.trustworthiness', '.eval.context_sufficiency', | | 307 | + '.eval.response_helpfulness', '.eval.query_ease', '.eval.response_groundedness'. | | 308 | +
| | 309 | + Custom eval scores: '.eval.custom_eval_1', '.eval.custom_eval_2', etc. | | 310 | +
| 289 | 311 | tool_call_names: Filter by names of tools called in the assistant response | 290 | 312 |
| 291 | 313 | was_cache_hit: Filter by cache hit status | @@ -351,8 +373,7 @@ def list_groups( | 351 | 373 | List[Literal["hallucination", "search_failure", "unhelpful", "difficult_query", "ungrounded"]] | 352 | 374 | ] | 353 | 375 | | NotGiven = NOT_GIVEN, | 354 | | - sort: Optional[Literal["created_at", "primary_eval_issue_score", "total_count", "custom_rank", "impact_score"]] | 355 | | - | NotGiven = NOT_GIVEN, | | 376 | + sort: Optional[str] | NotGiven = NOT_GIVEN, | 356 | 377 | tool_call_names: Optional[SequenceNotStr[str]] | NotGiven = NOT_GIVEN, | 357 | 378 | was_cache_hit: Optional[bool] | NotGiven = NOT_GIVEN, | 358 | 379 | # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs. | @@ -384,6 +405,18 @@ def list_groups( | 384 | 405 |
| 385 | 406 | primary_eval_issue: Filter logs that have ANY of these primary evaluation issues (OR operation) | 386 | 407 |
| | 408 | + sort: Field or score to sort by. | | 409 | +
| | 410 | + Available fields: 'created_at', 'custom_rank', 'impact_score', | | 411 | + 'primary_eval_issue_score', 'total_count'. | | 412 | +
| | 413 | + For eval scores, use '.eval.' prefix followed by the eval name. | | 414 | +
| | 415 | + Default eval scores: '.eval.trustworthiness', '.eval.context_sufficiency', | | 416 | + '.eval.response_helpfulness', '.eval.query_ease', '.eval.response_groundedness'. | | 417 | +
| | 418 | + Custom eval scores: '.eval.custom_eval_1', '.eval.custom_eval_2', etc. | | 419 | +
| 387 | 420 | tool_call_names: Filter by names of tools called in the assistant response | 388 | 421 |
| 389 | 422 | was_cache_hit: Filter by cache hit status | @@ -609,6 +642,17 @@ def list( | 609 | 642 |
| 610 | 643 | primary_eval_issue: Filter logs that have ANY of these primary evaluation issues (OR operation) | 611 | 644 |
| | 645 | + sort: Field or score to sort by. | | 646 | +
| | 647 | + Available fields: 'created_at', 'primary_eval_issue_score'. | | 648 | +
| | 649 | + For eval scores, use '.eval.' prefix followed by the eval name. | | 650 | +
| | 651 | + Default eval scores: '.eval.trustworthiness', '.eval.context_sufficiency', | | 652 | + '.eval.response_helpfulness', '.eval.query_ease', '.eval.response_groundedness'. | | 653 | +
| | 654 | + Custom eval scores: '.eval.custom_eval_1', '.eval.custom_eval_2', etc. | | 655 | +
| 612 | 656 | tool_call_names: Filter by names of tools called in the assistant response | 613 | 657 |
| 614 | 658 | was_cache_hit: Filter by cache hit status | @@ -750,6 +794,17 @@ async def list_by_group( | 750 | 794 |
| 751 | 795 | remediation_ids: List of groups to list child logs for | 752 | 796 |
| | 797 | + sort: Field or score to sort by. | | 798 | +
| | 799 | + Available fields: 'created_at', 'primary_eval_issue_score'. | | 800 | +
| | 801 | + For eval scores, use '.eval.' prefix followed by the eval name. | | 802 | +
| | 803 | + Default eval scores: '.eval.trustworthiness', '.eval.context_sufficiency', | | 804 | + '.eval.response_helpfulness', '.eval.query_ease', '.eval.response_groundedness'. | | 805 | +
| | 806 | + Custom eval scores: '.eval.custom_eval_1', '.eval.custom_eval_2', etc. | | 807 | +
| 753 | 808 | tool_call_names: Filter by names of tools called in the assistant response | 754 | 809 |
| 755 | 810 | was_cache_hit: Filter by cache hit status | @@ -815,8 +870,7 @@ def list_groups( | 815 | 870 | List[Literal["hallucination", "search_failure", "unhelpful", "difficult_query", "ungrounded"]] | 816 | 871 | ] | 817 | 872 | | NotGiven = NOT_GIVEN, | 818 | | - sort: Optional[Literal["created_at", "primary_eval_issue_score", "total_count", "custom_rank", "impact_score"]] | 819 | | - | NotGiven = NOT_GIVEN, | | 873 | + sort: Optional[str] | NotGiven = NOT_GIVEN, | 820 | 874 | tool_call_names: Optional[SequenceNotStr[str]] | NotGiven = NOT_GIVEN, | 821 | 875 | was_cache_hit: Optional[bool] | NotGiven = NOT_GIVEN, | 822 | 876 | # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs. | @@ -848,6 +902,18 @@ def list_groups( | 848 | 902 |
| 849 | 903 | primary_eval_issue: Filter logs that have ANY of these primary evaluation issues (OR operation) | 850 | 904 |
| | 905 | + sort: Field or score to sort by. | | 906 | +
| | 907 | + Available fields: 'created_at', 'custom_rank', 'impact_score', | | 908 | + 'primary_eval_issue_score', 'total_count'. | | 909 | +
| | 910 | + For eval scores, use '.eval.' prefix followed by the eval name. | | 911 | +
| | 912 | + Default eval scores: '.eval.trustworthiness', '.eval.context_sufficiency', | | 913 | + '.eval.response_helpfulness', '.eval.query_ease', '.eval.response_groundedness'. | | 914 | +
| | 915 | + Custom eval scores: '.eval.custom_eval_1', '.eval.custom_eval_2', etc. | | 916 | +
| 851 | 917 | tool_call_names: Filter by names of tools called in the assistant response | 852 | 918 |
| 853 | 919 | was_cache_hit: Filter by cache hit status | |
Collapse file Copy file name to clipboardExpand all lines: src/codex/types/projects/query_log_list_by_group_params.py +11Lines changed: 11 additions & 0 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -52,6 +52,17 @@ class QueryLogListByGroupParams(TypedDict, total=False): | 52 | 52 | """List of groups to list child logs for""" | 53 | 53 |
| 54 | 54 | sort: Optional[str] | | 55 | + """Field or score to sort by. | | 56 | +
| | 57 | + Available fields: 'created_at', 'primary_eval_issue_score'. | | 58 | +
| | 59 | + For eval scores, use '.eval.' prefix followed by the eval name. | | 60 | +
| | 61 | + Default eval scores: '.eval.trustworthiness', '.eval.context_sufficiency', | | 62 | + '.eval.response_helpfulness', '.eval.query_ease', '.eval.response_groundedness'. | | 63 | +
| | 64 | + Custom eval scores: '.eval.custom_eval_1', '.eval.custom_eval_2', etc. | | 65 | + """ | 55 | 66 |
| 56 | 67 | tool_call_names: Optional[SequenceNotStr[str]] | 57 | 68 | """Filter by names of tools called in the assistant response""" | |
Collapse file Copy file name to clipboardExpand all lines: src/codex/types/projects/query_log_list_groups_params.py +13-1Lines changed: 13 additions & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
@@ -48,7 +48,19 @@ class QueryLogListGroupsParams(TypedDict, total=False): | 48 | 48 | ] | 49 | 49 | """Filter logs that have ANY of these primary evaluation issues (OR operation)""" | 50 | 50 |
| 51 | | - sort: Optional[Literal["created_at", "primary_eval_issue_score", "total_count", "custom_rank", "impact_score"]] | | 51 | + sort: Optional[str] | | 52 | + """Field or score to sort by. | | 53 | +
| | 54 | + Available fields: 'created_at', 'custom_rank', 'impact_score', | | 55 | + 'primary_eval_issue_score', 'total_count'. | | 56 | +
| | 57 | + For eval scores, use '.eval.' prefix followed by the eval name. | | 58 | +
| | 59 | + Default eval scores: '.eval.trustworthiness', '.eval.context_sufficiency', | | 60 | + '.eval.response_helpfulness', '.eval.query_ease', '.eval.response_groundedness'. | | 61 | +
| | 62 | + Custom eval scores: '.eval.custom_eval_1', '.eval.custom_eval_2', etc. | | 63 | + """ | 52 | 64 |
| 53 | 65 | tool_call_names: Optional[SequenceNotStr[str]] | 54 | 66 | """Filter by names of tools called in the assistant response""" | |
Collapse file Copy file name to clipboardExpand all lines: src/codex/types/projects/query_log_list_params.py +11Lines changed: 11 additions & 0 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -46,6 +46,17 @@ class QueryLogListParams(TypedDict, total=False): | 46 | 46 | """Filter logs that have ANY of these primary evaluation issues (OR operation)""" | 47 | 47 |
| 48 | 48 | sort: Optional[str] | | 49 | + """Field or score to sort by. | | 50 | +
| | 51 | + Available fields: 'created_at', 'primary_eval_issue_score'. | | 52 | +
| | 53 | + For eval scores, use '.eval.' prefix followed by the eval name. | | 54 | +
| | 55 | + Default eval scores: '.eval.trustworthiness', '.eval.context_sufficiency', | | 56 | + '.eval.response_helpfulness', '.eval.query_ease', '.eval.response_groundedness'. | | 57 | +
| | 58 | + Custom eval scores: '.eval.custom_eval_1', '.eval.custom_eval_2', etc. | | 59 | + """ | 49 | 60 |
| 50 | 61 | tool_call_names: Optional[SequenceNotStr[str]] | 51 | 62 | """Filter by names of tools called in the assistant response""" | |
Collapse file Copy file name to clipboardExpand all lines: tests/api_resources/projects/test_query_logs.py +4-4Lines changed: 4 additions & 4 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -108,7 +108,7 @@ def test_method_list_with_all_params(self, client: Codex) -> None: | 108 | 108 | order="asc", | 109 | 109 | passed_evals=["string"], | 110 | 110 | primary_eval_issue=["hallucination"], | 111 | | - sort="sort", | | 111 | + sort="created_at", | 112 | 112 | tool_call_names=["string"], | 113 | 113 | was_cache_hit=True, | 114 | 114 | ) | @@ -231,7 +231,7 @@ def test_method_list_by_group_with_all_params(self, client: Codex) -> None: | 231 | 231 | passed_evals=["string"], | 232 | 232 | primary_eval_issue=["hallucination"], | 233 | 233 | remediation_ids=["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], | 234 | | - sort="sort", | | 234 | + sort="created_at", | 235 | 235 | tool_call_names=["string"], | 236 | 236 | was_cache_hit=True, | 237 | 237 | ) | @@ -527,7 +527,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncCodex) -> No | 527 | 527 | order="asc", | 528 | 528 | passed_evals=["string"], | 529 | 529 | primary_eval_issue=["hallucination"], | 530 | | - sort="sort", | | 530 | + sort="created_at", | 531 | 531 | tool_call_names=["string"], | 532 | 532 | was_cache_hit=True, | 533 | 533 | ) | @@ -650,7 +650,7 @@ async def test_method_list_by_group_with_all_params(self, async_client: AsyncCod | 650 | 650 | passed_evals=["string"], | 651 | 651 | primary_eval_issue=["hallucination"], | 652 | 652 | remediation_ids=["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], | 653 | | - sort="sort", | | 653 | + sort="created_at", | 654 | 654 | tool_call_names=["string"], | 655 | 655 | was_cache_hit=True, | 656 | 656 | ) | |
|