structifyai 1.158.0__py3-none-any.whl → 1.176.1__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- structify/_base_client.py +140 -11
- structify/_client.py +1116 -253
- structify/_models.py +16 -1
- structify/_streaming.py +12 -10
- structify/_types.py +12 -2
- structify/_version.py +1 -1
- structify/lib/__init__.py +5 -0
- structify/lib/cost_confirmation.py +63 -0
- structify/pagination.py +63 -1
- structify/resources/__init__.py +57 -27
- structify/resources/admin/__init__.py +26 -40
- structify/resources/admin/admin.py +39 -71
- structify/resources/admin/chat_templates.py +382 -0
- structify/resources/admin/jobs.py +76 -3
- structify/resources/admin/sandbox.py +184 -0
- structify/resources/admin/teams.py +88 -0
- structify/resources/admin/users.py +28 -238
- structify/resources/chat.py +232 -0
- structify/resources/connector_catalog/__init__.py +33 -0
- structify/resources/connector_catalog/admin.py +1510 -0
- structify/resources/connector_catalog/connector_catalog.py +394 -0
- structify/resources/connectors/__init__.py +33 -0
- structify/resources/{connectors.py → connectors/connectors.py} +1155 -325
- structify/resources/connectors/type_snippets.py +169 -0
- structify/resources/datasets/datasets.py +0 -4
- structify/resources/documents.py +1 -123
- structify/resources/external.py +35 -2
- structify/resources/jobs.py +19 -336
- structify/resources/nango.py +234 -0
- structify/resources/polars.py +225 -103
- structify/resources/sandbox.py +13 -110
- structify/resources/scrape.py +0 -16
- structify/resources/sessions.py +241 -153
- structify/resources/slack.py +1 -151
- structify/resources/structure.py +120 -48
- structify/resources/teams.py +96 -0
- structify/resources/user/__init__.py +14 -0
- structify/resources/user/api_keys.py +380 -0
- structify/resources/user/user.py +209 -2
- structify/resources/whitelabel.py +294 -187
- structify/resources/whitelabel_service.py +222 -0
- structify/resources/{report.py → wiki.py} +237 -210
- structify/resources/workflow_schedule.py +4 -5
- structify/types/__init__.py +67 -36
- structify/types/add_member_response.py +35 -4
- structify/types/admin/__init__.py +13 -88
- structify/types/admin/admin_dataset_return.py +6 -0
- structify/types/admin/{user_get_credits_response.py → admin_delete_jobs_response.py} +3 -3
- structify/types/admin/admin_list_jobs_response.py +35 -1
- structify/types/admin/admin_sandbox.py +38 -0
- structify/types/admin/chat_template_create_params.py +21 -0
- structify/types/admin/{human_llm_start_next_job_params.py → chat_template_list_params.py} +3 -3
- structify/types/admin/{human_llm_get_jobs_response.py → chat_template_list_response.py} +3 -3
- structify/types/admin/chat_template_update_params.py +22 -0
- structify/types/admin/{user_add_credits_response.py → expire_grants_response.py} +5 -3
- structify/types/admin/impersonate_response.py +17 -0
- structify/types/admin/{next_action_get_batched_training_data_params.py → job_delete_params.py} +2 -2
- structify/types/admin/{user_get_credits_params.py → sandbox_list_params.py} +4 -4
- structify/types/admin/sandbox_type.py +7 -0
- structify/types/admin/{user_set_credits_params.py → team_expire_grants_params.py} +4 -4
- structify/types/admin/user.py +16 -0
- structify/types/admin/user_create_params.py +1 -0
- structify/types/admin/{training_dataset_delete_params.py → user_impersonate_params.py} +3 -3
- structify/types/admin/user_list_response.py +14 -4
- structify/types/admin_grant_access_response.py +2 -0
- structify/types/{slack_user_mapping_response.py → admin_issue_found_response.py} +3 -5
- structify/types/chat_add_git_commit_response.py +2 -0
- structify/types/{admin/human_llm_get_next_step_params.py → chat_admin_issue_found_params.py} +4 -4
- structify/types/chat_create_session_params.py +7 -0
- structify/types/chat_dependency.py +17 -0
- structify/types/chat_event.py +51 -239
- structify/types/chat_get_git_commit_response.py +2 -0
- structify/types/chat_get_session_timeline_response.py +31 -1
- structify/types/{job_get_steps_response.py → chat_list_templates_response.py} +3 -3
- structify/types/chat_prompt.py +2 -0
- structify/types/chat_revert_to_commit_response.py +2 -0
- structify/types/chat_session.py +14 -0
- structify/types/chat_session_with_messages.py +33 -1
- structify/types/chat_template.py +31 -0
- structify/types/chat_update_session_params.py +2 -0
- structify/types/code_generate_code_params.py +7 -0
- structify/types/connector.py +16 -25
- structify/types/connector_auth_method.py +29 -0
- structify/types/connector_auth_method_with_fields.py +15 -0
- structify/types/connector_catalog/__init__.py +32 -0
- structify/types/connector_catalog/admin_batch_create_credential_fields_params.py +14 -0
- structify/types/connector_catalog/admin_batch_create_credential_fields_response.py +10 -0
- structify/types/connector_catalog/admin_batch_create_scopes_params.py +14 -0
- structify/types/connector_catalog/admin_create_auth_method_params.py +22 -0
- structify/types/connector_catalog/admin_create_catalog_params.py +22 -0
- structify/types/connector_catalog/admin_create_credential_field_params.py +28 -0
- structify/types/connector_catalog/admin_create_scope_params.py +19 -0
- structify/types/connector_catalog/admin_list_nango_pending_response.py +10 -0
- structify/types/{admin/training_dataset_get_datum_info_params.py → connector_catalog/admin_list_scopes_params.py} +3 -3
- structify/types/connector_catalog/admin_update_auth_method_params.py +16 -0
- structify/types/connector_catalog/admin_update_catalog_params.py +20 -0
- structify/types/connector_catalog/admin_update_credential_field_params.py +26 -0
- structify/types/connector_catalog/admin_update_scope_params.py +18 -0
- structify/types/connector_catalog/admin_upload_logo_params.py +13 -0
- structify/types/connector_catalog/batch_create_scopes_response.py +12 -0
- structify/types/connector_catalog/connector_auth_method_scope.py +25 -0
- structify/types/connector_catalog/connector_catalog.py +26 -0
- structify/types/connector_catalog/create_credential_field_request_param.py +28 -0
- structify/types/connector_catalog/create_scope_request_param.py +19 -0
- structify/types/connector_catalog/list_scopes_response.py +12 -0
- structify/types/connector_catalog/pending_nango_integration.py +17 -0
- structify/types/{admin/user_set_credits_response.py → connector_catalog/upload_logo_response.py} +3 -3
- structify/types/connector_catalog_list_params.py +20 -0
- structify/types/connector_catalog_list_response.py +22 -0
- structify/types/connector_catalog_with_methods.py +15 -0
- structify/types/connector_category.py +7 -0
- structify/types/connector_create_params.py +11 -25
- structify/types/connector_credential_field.py +34 -0
- structify/types/connector_delete_schema_object_params.py +35 -0
- structify/types/connector_explore_params.py +19 -0
- structify/types/connector_explorer_chat.py +9 -84
- structify/types/connector_get_clarification_requests_response.py +36 -0
- structify/types/connector_get_response.py +2 -0
- structify/types/connector_list_with_snippets_params.py +12 -0
- structify/types/connector_list_with_snippets_response.py +10 -0
- structify/types/connector_search_tables_params.py +15 -0
- structify/types/connector_search_tables_response.py +160 -0
- structify/types/connector_store_response.py +21 -0
- structify/types/connector_summaries_params.py +15 -0
- structify/types/connector_summaries_response.py +10 -0
- structify/types/connector_summary.py +16 -0
- structify/types/connector_table_info.py +15 -0
- structify/types/connector_update_column_params.py +12 -0
- structify/types/connector_update_params.py +4 -25
- structify/types/connector_update_table_params.py +14 -0
- structify/types/connector_with_secrets.py +2 -0
- structify/types/connector_with_snippets.py +11 -0
- structify/types/connectors/__init__.py +6 -0
- structify/types/connectors/snippet.py +20 -0
- structify/types/connectors/type_snippet_upsert_params.py +12 -0
- structify/types/create_chat_session_response.py +2 -0
- structify/types/dataset_create_params.py +0 -2
- structify/types/dataset_descriptor.py +6 -0
- structify/types/dataset_descriptor_param.py +6 -0
- structify/types/dataset_get_response.py +6 -0
- structify/types/dataset_list_response.py +6 -0
- structify/types/dataset_view_table_response.py +3 -1
- structify/types/delete_chat_session_response.py +2 -0
- structify/types/delete_schema_object_request_param.py +35 -0
- structify/types/delete_schema_object_response.py +13 -0
- structify/types/edge_spec_param.py +13 -0
- structify/types/entity_get_source_entities_response.py +0 -2
- structify/types/entity_list_jobs_response.py +3 -3
- structify/types/entity_view_response.py +0 -2
- structify/types/estimate_cost_response.py +9 -0
- structify/types/exploration_phase_id.py +79 -0
- structify/types/finalize_dag_response.py +11 -0
- structify/types/get_chat_session_response.py +14 -6
- structify/types/get_dependencies_response.py +15 -0
- structify/types/get_job_events_response.py +20 -0
- structify/types/get_node_response.py +10 -0
- structify/types/job_cancel_response.py +3 -3
- structify/types/job_event_body.py +108 -1
- structify/types/job_get_source_entities_response.py +0 -2
- structify/types/job_list_params.py +1 -1
- structify/types/job_list_response.py +35 -1
- structify/types/knowledge_graph.py +6 -0
- structify/types/knowledge_graph_param.py +6 -0
- structify/types/list_chat_sessions_response.py +2 -0
- structify/types/list_collaborators_response.py +4 -0
- structify/types/list_tables_response.py +12 -0
- structify/types/llm_information_store.py +62 -28
- structify/types/merge_config.py +2 -0
- structify/types/merge_config_param.py +2 -0
- structify/types/message.py +2 -0
- structify/types/nango_create_session_params.py +21 -0
- structify/types/nango_create_session_response.py +15 -0
- structify/types/nango_list_integrations_response.py +28 -0
- structify/types/{session_create_node_params.py → node_spec_param.py} +4 -4
- structify/types/refresh_session_response.py +15 -0
- structify/types/sandbox.py +8 -2
- structify/types/sandbox_get_params.py +2 -1
- structify/types/scrape_list_params.py +1 -22
- structify/types/scrape_list_response.py +2 -0
- structify/types/scrape_scrape_params.py +1 -14
- structify/types/scrape_scrape_response.py +2 -0
- structify/types/select_team_response.py +3 -1
- structify/types/{connector_approve_version_params.py → session_confirm_node_params.py} +3 -3
- structify/types/session_finalize_dag_params.py +20 -0
- structify/types/session_get_events_response.py +2 -0
- structify/types/session_request_confirmation_params.py +13 -0
- structify/types/session_upload_node_output_data_params.py +3 -0
- structify/types/slack_event_payload_param.py +18 -2
- structify/types/slack_events_params.py +18 -2
- structify/types/source_list_response.py +0 -2
- structify/types/structure_enhance_property_params.py +2 -17
- structify/types/structure_enhance_relationship_params.py +2 -17
- structify/types/structure_find_relationship_params.py +2 -18
- structify/types/structure_pdf_params.py +22 -0
- structify/types/structure_pdf_response.py +11 -0
- structify/types/structure_run_async_params.py +10 -17
- structify/types/table.py +2 -0
- structify/types/table_param.py +2 -0
- structify/types/team.py +14 -0
- structify/types/{admin/training_dataset_remove_datum_params.py → team_create_link_code_params.py} +3 -3
- structify/types/team_update_params.py +10 -0
- structify/types/team_wiki_page.py +28 -0
- structify/types/teams_link_code_response.py +13 -0
- structify/types/token_response.py +6 -2
- structify/types/tool_invocation.py +468 -0
- structify/types/tool_result.py +99 -0
- structify/types/update_table_response.py +46 -0
- structify/types/usage_group_key.py +14 -1
- structify/types/user/__init__.py +4 -0
- structify/types/{admin/training_dataset_size_params.py → user/api_key_create_params.py} +5 -5
- structify/types/user/api_key_info.py +24 -0
- structify/types/user/create_api_key_response.py +12 -0
- structify/types/user/list_api_keys_response.py +12 -0
- structify/types/user_enrich_params.py +11 -0
- structify/types/user_info.py +22 -0
- structify/types/user_refresh_params.py +13 -0
- structify/types/user_transactions_response.py +5 -5
- structify/types/user_update_params.py +32 -12
- structify/types/user_usage_response.py +0 -2
- structify/types/wiki_connector_reference.py +63 -0
- structify/types/wiki_create_params.py +16 -0
- structify/types/{admin/training_dataset_list_response.py → wiki_list_response.py} +4 -2
- structify/types/wiki_page_with_references.py +12 -0
- structify/types/wiki_update_params.py +16 -0
- structify/types/workflow_dag.py +2 -0
- structify/types/workflow_node_execution_status.py +3 -1
- structify/types/workflow_schedule_info.py +2 -2
- structify/types/workflow_session_node.py +10 -0
- {structifyai-1.158.0.dist-info → structifyai-1.176.1.dist-info}/METADATA +67 -4
- structifyai-1.176.1.dist-info/RECORD +496 -0
- {structifyai-1.158.0.dist-info → structifyai-1.176.1.dist-info}/licenses/LICENSE +1 -1
- structify/resources/admin/human_llm.py +0 -819
- structify/resources/admin/next_action.py +0 -656
- structify/resources/admin/training_datasets.py +0 -2028
- structify/resources/external/__init__.py +0 -61
- structify/resources/external/external.py +0 -166
- structify/resources/external/news.py +0 -519
- structify/resources/external/people.py +0 -998
- structify/resources/external/search_api.py +0 -1525
- structify/types/active_version_data.py +0 -21
- structify/types/active_version_response.py +0 -13
- structify/types/admin/action_training_data_entry.py +0 -219
- structify/types/admin/action_training_data_response.py +0 -12
- structify/types/admin/datum_status.py +0 -19
- structify/types/admin/delete_action_training_data_response.py +0 -9
- structify/types/admin/human_llm_add_search_for_job_params.py +0 -13
- structify/types/admin/human_llm_add_to_dataset_params.py +0 -186
- structify/types/admin/human_llm_finish_job_params.py +0 -13
- structify/types/admin/human_llm_get_jobs_params.py +0 -12
- structify/types/admin/human_llm_get_next_step_response.py +0 -196
- structify/types/admin/human_llm_job.py +0 -73
- structify/types/admin/human_llm_prelabel_step_response.py +0 -184
- structify/types/admin/human_llm_update_step_params.py +0 -186
- structify/types/admin/labeling_stats.py +0 -24
- structify/types/admin/next_action_add_training_datum_params.py +0 -203
- structify/types/admin/next_action_delete_training_data_params.py +0 -12
- structify/types/admin/next_action_get_training_data_params.py +0 -25
- structify/types/admin/next_action_get_training_datum_params.py +0 -12
- structify/types/admin/next_action_label_training_datum_params.py +0 -90
- structify/types/admin/step_choices.py +0 -32
- structify/types/admin/training_dataset_add_datum_params.py +0 -13
- structify/types/admin/training_dataset_add_params.py +0 -12
- structify/types/admin/training_dataset_download_datum_params.py +0 -13
- structify/types/admin/training_dataset_get_labeller_stats_params.py +0 -23
- structify/types/admin/training_dataset_get_labeller_stats_response.py +0 -10
- structify/types/admin/training_dataset_get_next_for_labeling_params.py +0 -15
- structify/types/admin/training_dataset_get_next_for_qa_params.py +0 -18
- structify/types/admin/training_dataset_get_next_suspicious_params.py +0 -23
- structify/types/admin/training_dataset_label_datum_params.py +0 -188
- structify/types/admin/training_dataset_list_datums_params.py +0 -17
- structify/types/admin/training_dataset_list_datums_response.py +0 -33
- structify/types/admin/training_dataset_mark_datum_suspicious_params.py +0 -19
- structify/types/admin/training_dataset_size_response.py +0 -37
- structify/types/admin/training_dataset_suspicious_count_params.py +0 -23
- structify/types/admin/training_dataset_suspicious_count_response.py +0 -9
- structify/types/admin/training_dataset_switch_dataset_params.py +0 -13
- structify/types/admin/training_dataset_update_datum_status_params.py +0 -18
- structify/types/admin/training_dataset_upload_labeled_step_params.py +0 -15
- structify/types/admin/training_dataset_verify_datum_params.py +0 -17
- structify/types/admin/training_datum_response.py +0 -405
- structify/types/admin/user_add_credits_params.py +0 -18
- structify/types/chat_prompt_param.py +0 -255
- structify/types/connector_column_descriptor.py +0 -21
- structify/types/connector_relational_database_descriptor.py +0 -13
- structify/types/connector_table_descriptor.py +0 -22
- structify/types/document_structure_params.py +0 -21
- structify/types/document_structure_response.py +0 -8
- structify/types/execution_step.py +0 -198
- structify/types/external/__init__.py +0 -96
- structify/types/external/companies_search_response.py +0 -28
- structify/types/external/company_search_result.py +0 -69
- structify/types/external/enriched_organization.py +0 -69
- structify/types/external/everything_response.py +0 -19
- structify/types/external/google_maps_result.py +0 -38
- structify/types/external/google_search_response.py +0 -19
- structify/types/external/google_search_result.py +0 -21
- structify/types/external/job_posting.py +0 -54
- structify/types/external/job_postings_response.py +0 -19
- structify/types/external/location_coordinates.py +0 -13
- structify/types/external/location_response.py +0 -16
- structify/types/external/location_result.py +0 -24
- structify/types/external/news_article.py +0 -33
- structify/types/external/news_everything_params.py +0 -45
- structify/types/external/news_source.py +0 -15
- structify/types/external/news_source_detail.py +0 -28
- structify/types/external/news_sources_params.py +0 -19
- structify/types/external/news_top_headlines_params.py +0 -28
- structify/types/external/organization_detail.py +0 -87
- structify/types/external/people_match_response.py +0 -18
- structify/types/external/people_search_response.py +0 -28
- structify/types/external/person_companies_search_params.py +0 -63
- structify/types/external/person_match.py +0 -60
- structify/types/external/person_organization_job_postings_params.py +0 -16
- structify/types/external/person_organizations_enrich_params.py +0 -16
- structify/types/external/person_people_match_params.py +0 -49
- structify/types/external/person_people_search_params.py +0 -57
- structify/types/external/person_search_result.py +0 -48
- structify/types/external/search_api_google_flights_calendar_params.py +0 -28
- structify/types/external/search_api_google_flights_calendar_response.py +0 -8
- structify/types/external/search_api_google_flights_location_search_params.py +0 -16
- structify/types/external/search_api_google_flights_location_search_response.py +0 -8
- structify/types/external/search_api_google_flights_search_params.py +0 -43
- structify/types/external/search_api_google_flights_search_response.py +0 -8
- structify/types/external/search_api_google_maps_place_details_params.py +0 -16
- structify/types/external/search_api_google_maps_place_details_response.py +0 -8
- structify/types/external/search_api_google_maps_place_photos_params.py +0 -16
- structify/types/external/search_api_google_maps_place_photos_response.py +0 -8
- structify/types/external/search_api_google_maps_place_reviews_params.py +0 -19
- structify/types/external/search_api_google_maps_place_reviews_response.py +0 -8
- structify/types/external/search_api_google_maps_search_params.py +0 -22
- structify/types/external/search_api_google_maps_search_response.py +0 -10
- structify/types/external/search_api_google_scholar_author_search_params.py +0 -22
- structify/types/external/search_api_google_scholar_author_search_response.py +0 -8
- structify/types/external/search_api_google_scholar_citations_params.py +0 -22
- structify/types/external/search_api_google_scholar_citations_response.py +0 -8
- structify/types/external/search_api_google_scholar_search_params.py +0 -28
- structify/types/external/search_api_google_scholar_search_response.py +0 -8
- structify/types/external/search_api_google_search_params.py +0 -25
- structify/types/external/search_api_location_search_params.py +0 -22
- structify/types/external/sources_response.py +0 -16
- structify/types/external/top_headlines_response.py +0 -19
- structify/types/job_delete_response.py +0 -7
- structify/types/job_get_response.py +0 -62
- structify/types/job_get_step_graph_response.py +0 -233
- structify/types/job_get_step_response.py +0 -196
- structify/types/message_param.py +0 -35
- structify/types/pending_version_response.py +0 -21
- structify/types/report_missing_params.py +0 -18
- structify/types/report_missing_response.py +0 -7
- structify/types/report_relationship_params.py +0 -18
- structify/types/report_relationship_response.py +0 -7
- structify/types/report_step_params.py +0 -15
- structify/types/report_step_response.py +0 -7
- structify/types/report_wrong_params.py +0 -18
- structify/types/report_wrong_response.py +0 -7
- structify/types/sandbox_create_params.py +0 -20
- structify/types/session_create_edge_params.py +0 -13
- structify/types/slack_connection_status.py +0 -15
- structify/types/slack_user_mapping_params.py +0 -18
- structify/types/tool_metadata_param.py +0 -17
- structify/types/user_team.py +0 -35
- structify/types/workflow_schedule_get_response.py +0 -10
- structifyai-1.158.0.dist-info/RECORD +0 -530
- {structifyai-1.158.0.dist-info → structifyai-1.176.1.dist-info}/WHEEL +0 -0
|
@@ -1,656 +0,0 @@
|
|
|
1
|
-
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
-
|
|
3
|
-
from __future__ import annotations
|
|
4
|
-
|
|
5
|
-
from typing import Union, Optional
|
|
6
|
-
from datetime import datetime
|
|
7
|
-
from typing_extensions import Literal
|
|
8
|
-
|
|
9
|
-
import httpx
|
|
10
|
-
|
|
11
|
-
from ..._types import Body, Omit, Query, Headers, NoneType, NotGiven, SequenceNotStr, omit, not_given
|
|
12
|
-
from ..._utils import maybe_transform, async_maybe_transform
|
|
13
|
-
from ..._compat import cached_property
|
|
14
|
-
from ..._resource import SyncAPIResource, AsyncAPIResource
|
|
15
|
-
from ..._response import (
|
|
16
|
-
to_raw_response_wrapper,
|
|
17
|
-
to_streamed_response_wrapper,
|
|
18
|
-
async_to_raw_response_wrapper,
|
|
19
|
-
async_to_streamed_response_wrapper,
|
|
20
|
-
)
|
|
21
|
-
from ...types.admin import (
|
|
22
|
-
next_action_get_training_data_params,
|
|
23
|
-
next_action_add_training_datum_params,
|
|
24
|
-
next_action_get_training_datum_params,
|
|
25
|
-
next_action_delete_training_data_params,
|
|
26
|
-
next_action_label_training_datum_params,
|
|
27
|
-
next_action_get_batched_training_data_params,
|
|
28
|
-
)
|
|
29
|
-
from ..._base_client import make_request_options
|
|
30
|
-
from ...types.admin.action_training_data_entry import ActionTrainingDataEntry
|
|
31
|
-
from ...types.admin.action_training_data_response import ActionTrainingDataResponse
|
|
32
|
-
from ...types.admin.delete_action_training_data_response import DeleteActionTrainingDataResponse
|
|
33
|
-
|
|
34
|
-
__all__ = ["NextActionResource", "AsyncNextActionResource"]
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
class NextActionResource(SyncAPIResource):
|
|
38
|
-
@cached_property
|
|
39
|
-
def with_raw_response(self) -> NextActionResourceWithRawResponse:
|
|
40
|
-
"""
|
|
41
|
-
This property can be used as a prefix for any HTTP method call to return
|
|
42
|
-
the raw response object instead of the parsed content.
|
|
43
|
-
|
|
44
|
-
For more information, see https://www.github.com/StructifyAI/structify-python#accessing-raw-response-data-eg-headers
|
|
45
|
-
"""
|
|
46
|
-
return NextActionResourceWithRawResponse(self)
|
|
47
|
-
|
|
48
|
-
@cached_property
|
|
49
|
-
def with_streaming_response(self) -> NextActionResourceWithStreamingResponse:
|
|
50
|
-
"""
|
|
51
|
-
An alternative to `.with_raw_response` that doesn't eagerly read the response body.
|
|
52
|
-
|
|
53
|
-
For more information, see https://www.github.com/StructifyAI/structify-python#with_streaming_response
|
|
54
|
-
"""
|
|
55
|
-
return NextActionResourceWithStreamingResponse(self)
|
|
56
|
-
|
|
57
|
-
def add_training_datum(
|
|
58
|
-
self,
|
|
59
|
-
*,
|
|
60
|
-
input: next_action_add_training_datum_params.Input,
|
|
61
|
-
label: str,
|
|
62
|
-
output: next_action_add_training_datum_params.Output,
|
|
63
|
-
job_id: Optional[str] | Omit = omit,
|
|
64
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
65
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
66
|
-
extra_headers: Headers | None = None,
|
|
67
|
-
extra_query: Query | None = None,
|
|
68
|
-
extra_body: Body | None = None,
|
|
69
|
-
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
70
|
-
) -> None:
|
|
71
|
-
"""
|
|
72
|
-
Add a new action training datum
|
|
73
|
-
|
|
74
|
-
Args:
|
|
75
|
-
extra_headers: Send extra headers
|
|
76
|
-
|
|
77
|
-
extra_query: Add additional query parameters to the request
|
|
78
|
-
|
|
79
|
-
extra_body: Add additional JSON properties to the request
|
|
80
|
-
|
|
81
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
|
82
|
-
"""
|
|
83
|
-
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
84
|
-
return self._post(
|
|
85
|
-
"/admin/next_action/add_action_training_datum",
|
|
86
|
-
body=maybe_transform(
|
|
87
|
-
{
|
|
88
|
-
"input": input,
|
|
89
|
-
"label": label,
|
|
90
|
-
"output": output,
|
|
91
|
-
"job_id": job_id,
|
|
92
|
-
},
|
|
93
|
-
next_action_add_training_datum_params.NextActionAddTrainingDatumParams,
|
|
94
|
-
),
|
|
95
|
-
options=make_request_options(
|
|
96
|
-
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
97
|
-
),
|
|
98
|
-
cast_to=NoneType,
|
|
99
|
-
)
|
|
100
|
-
|
|
101
|
-
def delete_training_data(
|
|
102
|
-
self,
|
|
103
|
-
*,
|
|
104
|
-
id: str,
|
|
105
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
106
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
107
|
-
extra_headers: Headers | None = None,
|
|
108
|
-
extra_query: Query | None = None,
|
|
109
|
-
extra_body: Body | None = None,
|
|
110
|
-
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
111
|
-
) -> DeleteActionTrainingDataResponse:
|
|
112
|
-
"""
|
|
113
|
-
Args:
|
|
114
|
-
id: ID of the training datum to delete
|
|
115
|
-
|
|
116
|
-
extra_headers: Send extra headers
|
|
117
|
-
|
|
118
|
-
extra_query: Add additional query parameters to the request
|
|
119
|
-
|
|
120
|
-
extra_body: Add additional JSON properties to the request
|
|
121
|
-
|
|
122
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
|
123
|
-
"""
|
|
124
|
-
return self._delete(
|
|
125
|
-
"/admin/next_action/delete_action_training_data",
|
|
126
|
-
options=make_request_options(
|
|
127
|
-
extra_headers=extra_headers,
|
|
128
|
-
extra_query=extra_query,
|
|
129
|
-
extra_body=extra_body,
|
|
130
|
-
timeout=timeout,
|
|
131
|
-
query=maybe_transform(
|
|
132
|
-
{"id": id}, next_action_delete_training_data_params.NextActionDeleteTrainingDataParams
|
|
133
|
-
),
|
|
134
|
-
),
|
|
135
|
-
cast_to=DeleteActionTrainingDataResponse,
|
|
136
|
-
)
|
|
137
|
-
|
|
138
|
-
def get_batched_training_data(
|
|
139
|
-
self,
|
|
140
|
-
*,
|
|
141
|
-
job_ids: SequenceNotStr[str],
|
|
142
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
143
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
144
|
-
extra_headers: Headers | None = None,
|
|
145
|
-
extra_query: Query | None = None,
|
|
146
|
-
extra_body: Body | None = None,
|
|
147
|
-
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
148
|
-
) -> ActionTrainingDataResponse:
|
|
149
|
-
"""
|
|
150
|
-
Args:
|
|
151
|
-
extra_headers: Send extra headers
|
|
152
|
-
|
|
153
|
-
extra_query: Add additional query parameters to the request
|
|
154
|
-
|
|
155
|
-
extra_body: Add additional JSON properties to the request
|
|
156
|
-
|
|
157
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
|
158
|
-
"""
|
|
159
|
-
return self._post(
|
|
160
|
-
"/admin/next_action/get_batched_action_training_data",
|
|
161
|
-
body=maybe_transform(
|
|
162
|
-
{"job_ids": job_ids},
|
|
163
|
-
next_action_get_batched_training_data_params.NextActionGetBatchedTrainingDataParams,
|
|
164
|
-
),
|
|
165
|
-
options=make_request_options(
|
|
166
|
-
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
167
|
-
),
|
|
168
|
-
cast_to=ActionTrainingDataResponse,
|
|
169
|
-
)
|
|
170
|
-
|
|
171
|
-
def get_training_data(
|
|
172
|
-
self,
|
|
173
|
-
*,
|
|
174
|
-
from_date: Union[str, datetime, None] | Omit = omit,
|
|
175
|
-
job_id: Optional[str] | Omit = omit,
|
|
176
|
-
limit: int | Omit = omit,
|
|
177
|
-
offset: int | Omit = omit,
|
|
178
|
-
status: Optional[Literal["HumanLLMLabel", "LLMOutput", "Pending", "Reviewed", "Verified", "Others"]]
|
|
179
|
-
| Omit = omit,
|
|
180
|
-
to_date: Union[str, datetime, None] | Omit = omit,
|
|
181
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
182
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
183
|
-
extra_headers: Headers | None = None,
|
|
184
|
-
extra_query: Query | None = None,
|
|
185
|
-
extra_body: Body | None = None,
|
|
186
|
-
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
187
|
-
) -> ActionTrainingDataResponse:
|
|
188
|
-
"""
|
|
189
|
-
Args:
|
|
190
|
-
extra_headers: Send extra headers
|
|
191
|
-
|
|
192
|
-
extra_query: Add additional query parameters to the request
|
|
193
|
-
|
|
194
|
-
extra_body: Add additional JSON properties to the request
|
|
195
|
-
|
|
196
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
|
197
|
-
"""
|
|
198
|
-
return self._get(
|
|
199
|
-
"/admin/next_action/get_action_training_data",
|
|
200
|
-
options=make_request_options(
|
|
201
|
-
extra_headers=extra_headers,
|
|
202
|
-
extra_query=extra_query,
|
|
203
|
-
extra_body=extra_body,
|
|
204
|
-
timeout=timeout,
|
|
205
|
-
query=maybe_transform(
|
|
206
|
-
{
|
|
207
|
-
"from_date": from_date,
|
|
208
|
-
"job_id": job_id,
|
|
209
|
-
"limit": limit,
|
|
210
|
-
"offset": offset,
|
|
211
|
-
"status": status,
|
|
212
|
-
"to_date": to_date,
|
|
213
|
-
},
|
|
214
|
-
next_action_get_training_data_params.NextActionGetTrainingDataParams,
|
|
215
|
-
),
|
|
216
|
-
),
|
|
217
|
-
cast_to=ActionTrainingDataResponse,
|
|
218
|
-
)
|
|
219
|
-
|
|
220
|
-
def get_training_datum(
|
|
221
|
-
self,
|
|
222
|
-
*,
|
|
223
|
-
id: str,
|
|
224
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
225
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
226
|
-
extra_headers: Headers | None = None,
|
|
227
|
-
extra_query: Query | None = None,
|
|
228
|
-
extra_body: Body | None = None,
|
|
229
|
-
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
230
|
-
) -> ActionTrainingDataEntry:
|
|
231
|
-
"""
|
|
232
|
-
Args:
|
|
233
|
-
id: ID of the training datum to get
|
|
234
|
-
|
|
235
|
-
extra_headers: Send extra headers
|
|
236
|
-
|
|
237
|
-
extra_query: Add additional query parameters to the request
|
|
238
|
-
|
|
239
|
-
extra_body: Add additional JSON properties to the request
|
|
240
|
-
|
|
241
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
|
242
|
-
"""
|
|
243
|
-
return self._get(
|
|
244
|
-
"/admin/next_action/get_action_training_datum",
|
|
245
|
-
options=make_request_options(
|
|
246
|
-
extra_headers=extra_headers,
|
|
247
|
-
extra_query=extra_query,
|
|
248
|
-
extra_body=extra_body,
|
|
249
|
-
timeout=timeout,
|
|
250
|
-
query=maybe_transform(
|
|
251
|
-
{"id": id}, next_action_get_training_datum_params.NextActionGetTrainingDatumParams
|
|
252
|
-
),
|
|
253
|
-
),
|
|
254
|
-
cast_to=ActionTrainingDataEntry,
|
|
255
|
-
)
|
|
256
|
-
|
|
257
|
-
def label_training_datum(
|
|
258
|
-
self,
|
|
259
|
-
*,
|
|
260
|
-
id: str,
|
|
261
|
-
label: str,
|
|
262
|
-
output: next_action_label_training_datum_params.Output,
|
|
263
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
264
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
265
|
-
extra_headers: Headers | None = None,
|
|
266
|
-
extra_query: Query | None = None,
|
|
267
|
-
extra_body: Body | None = None,
|
|
268
|
-
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
269
|
-
) -> None:
|
|
270
|
-
"""
|
|
271
|
-
Label an existing action training datum
|
|
272
|
-
|
|
273
|
-
Args:
|
|
274
|
-
extra_headers: Send extra headers
|
|
275
|
-
|
|
276
|
-
extra_query: Add additional query parameters to the request
|
|
277
|
-
|
|
278
|
-
extra_body: Add additional JSON properties to the request
|
|
279
|
-
|
|
280
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
|
281
|
-
"""
|
|
282
|
-
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
283
|
-
return self._put(
|
|
284
|
-
"/admin/next_action/label_action_training_datum",
|
|
285
|
-
body=maybe_transform(
|
|
286
|
-
{
|
|
287
|
-
"id": id,
|
|
288
|
-
"label": label,
|
|
289
|
-
"output": output,
|
|
290
|
-
},
|
|
291
|
-
next_action_label_training_datum_params.NextActionLabelTrainingDatumParams,
|
|
292
|
-
),
|
|
293
|
-
options=make_request_options(
|
|
294
|
-
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
295
|
-
),
|
|
296
|
-
cast_to=NoneType,
|
|
297
|
-
)
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
class AsyncNextActionResource(AsyncAPIResource):
|
|
301
|
-
@cached_property
|
|
302
|
-
def with_raw_response(self) -> AsyncNextActionResourceWithRawResponse:
|
|
303
|
-
"""
|
|
304
|
-
This property can be used as a prefix for any HTTP method call to return
|
|
305
|
-
the raw response object instead of the parsed content.
|
|
306
|
-
|
|
307
|
-
For more information, see https://www.github.com/StructifyAI/structify-python#accessing-raw-response-data-eg-headers
|
|
308
|
-
"""
|
|
309
|
-
return AsyncNextActionResourceWithRawResponse(self)
|
|
310
|
-
|
|
311
|
-
@cached_property
|
|
312
|
-
def with_streaming_response(self) -> AsyncNextActionResourceWithStreamingResponse:
|
|
313
|
-
"""
|
|
314
|
-
An alternative to `.with_raw_response` that doesn't eagerly read the response body.
|
|
315
|
-
|
|
316
|
-
For more information, see https://www.github.com/StructifyAI/structify-python#with_streaming_response
|
|
317
|
-
"""
|
|
318
|
-
return AsyncNextActionResourceWithStreamingResponse(self)
|
|
319
|
-
|
|
320
|
-
async def add_training_datum(
|
|
321
|
-
self,
|
|
322
|
-
*,
|
|
323
|
-
input: next_action_add_training_datum_params.Input,
|
|
324
|
-
label: str,
|
|
325
|
-
output: next_action_add_training_datum_params.Output,
|
|
326
|
-
job_id: Optional[str] | Omit = omit,
|
|
327
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
328
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
329
|
-
extra_headers: Headers | None = None,
|
|
330
|
-
extra_query: Query | None = None,
|
|
331
|
-
extra_body: Body | None = None,
|
|
332
|
-
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
333
|
-
) -> None:
|
|
334
|
-
"""
|
|
335
|
-
Add a new action training datum
|
|
336
|
-
|
|
337
|
-
Args:
|
|
338
|
-
extra_headers: Send extra headers
|
|
339
|
-
|
|
340
|
-
extra_query: Add additional query parameters to the request
|
|
341
|
-
|
|
342
|
-
extra_body: Add additional JSON properties to the request
|
|
343
|
-
|
|
344
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
|
345
|
-
"""
|
|
346
|
-
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
347
|
-
return await self._post(
|
|
348
|
-
"/admin/next_action/add_action_training_datum",
|
|
349
|
-
body=await async_maybe_transform(
|
|
350
|
-
{
|
|
351
|
-
"input": input,
|
|
352
|
-
"label": label,
|
|
353
|
-
"output": output,
|
|
354
|
-
"job_id": job_id,
|
|
355
|
-
},
|
|
356
|
-
next_action_add_training_datum_params.NextActionAddTrainingDatumParams,
|
|
357
|
-
),
|
|
358
|
-
options=make_request_options(
|
|
359
|
-
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
360
|
-
),
|
|
361
|
-
cast_to=NoneType,
|
|
362
|
-
)
|
|
363
|
-
|
|
364
|
-
async def delete_training_data(
|
|
365
|
-
self,
|
|
366
|
-
*,
|
|
367
|
-
id: str,
|
|
368
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
369
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
370
|
-
extra_headers: Headers | None = None,
|
|
371
|
-
extra_query: Query | None = None,
|
|
372
|
-
extra_body: Body | None = None,
|
|
373
|
-
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
374
|
-
) -> DeleteActionTrainingDataResponse:
|
|
375
|
-
"""
|
|
376
|
-
Args:
|
|
377
|
-
id: ID of the training datum to delete
|
|
378
|
-
|
|
379
|
-
extra_headers: Send extra headers
|
|
380
|
-
|
|
381
|
-
extra_query: Add additional query parameters to the request
|
|
382
|
-
|
|
383
|
-
extra_body: Add additional JSON properties to the request
|
|
384
|
-
|
|
385
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
|
386
|
-
"""
|
|
387
|
-
return await self._delete(
|
|
388
|
-
"/admin/next_action/delete_action_training_data",
|
|
389
|
-
options=make_request_options(
|
|
390
|
-
extra_headers=extra_headers,
|
|
391
|
-
extra_query=extra_query,
|
|
392
|
-
extra_body=extra_body,
|
|
393
|
-
timeout=timeout,
|
|
394
|
-
query=await async_maybe_transform(
|
|
395
|
-
{"id": id}, next_action_delete_training_data_params.NextActionDeleteTrainingDataParams
|
|
396
|
-
),
|
|
397
|
-
),
|
|
398
|
-
cast_to=DeleteActionTrainingDataResponse,
|
|
399
|
-
)
|
|
400
|
-
|
|
401
|
-
async def get_batched_training_data(
|
|
402
|
-
self,
|
|
403
|
-
*,
|
|
404
|
-
job_ids: SequenceNotStr[str],
|
|
405
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
406
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
407
|
-
extra_headers: Headers | None = None,
|
|
408
|
-
extra_query: Query | None = None,
|
|
409
|
-
extra_body: Body | None = None,
|
|
410
|
-
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
411
|
-
) -> ActionTrainingDataResponse:
|
|
412
|
-
"""
|
|
413
|
-
Args:
|
|
414
|
-
extra_headers: Send extra headers
|
|
415
|
-
|
|
416
|
-
extra_query: Add additional query parameters to the request
|
|
417
|
-
|
|
418
|
-
extra_body: Add additional JSON properties to the request
|
|
419
|
-
|
|
420
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
|
421
|
-
"""
|
|
422
|
-
return await self._post(
|
|
423
|
-
"/admin/next_action/get_batched_action_training_data",
|
|
424
|
-
body=await async_maybe_transform(
|
|
425
|
-
{"job_ids": job_ids},
|
|
426
|
-
next_action_get_batched_training_data_params.NextActionGetBatchedTrainingDataParams,
|
|
427
|
-
),
|
|
428
|
-
options=make_request_options(
|
|
429
|
-
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
430
|
-
),
|
|
431
|
-
cast_to=ActionTrainingDataResponse,
|
|
432
|
-
)
|
|
433
|
-
|
|
434
|
-
async def get_training_data(
|
|
435
|
-
self,
|
|
436
|
-
*,
|
|
437
|
-
from_date: Union[str, datetime, None] | Omit = omit,
|
|
438
|
-
job_id: Optional[str] | Omit = omit,
|
|
439
|
-
limit: int | Omit = omit,
|
|
440
|
-
offset: int | Omit = omit,
|
|
441
|
-
status: Optional[Literal["HumanLLMLabel", "LLMOutput", "Pending", "Reviewed", "Verified", "Others"]]
|
|
442
|
-
| Omit = omit,
|
|
443
|
-
to_date: Union[str, datetime, None] | Omit = omit,
|
|
444
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
445
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
446
|
-
extra_headers: Headers | None = None,
|
|
447
|
-
extra_query: Query | None = None,
|
|
448
|
-
extra_body: Body | None = None,
|
|
449
|
-
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
450
|
-
) -> ActionTrainingDataResponse:
|
|
451
|
-
"""
|
|
452
|
-
Args:
|
|
453
|
-
extra_headers: Send extra headers
|
|
454
|
-
|
|
455
|
-
extra_query: Add additional query parameters to the request
|
|
456
|
-
|
|
457
|
-
extra_body: Add additional JSON properties to the request
|
|
458
|
-
|
|
459
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
|
460
|
-
"""
|
|
461
|
-
return await self._get(
|
|
462
|
-
"/admin/next_action/get_action_training_data",
|
|
463
|
-
options=make_request_options(
|
|
464
|
-
extra_headers=extra_headers,
|
|
465
|
-
extra_query=extra_query,
|
|
466
|
-
extra_body=extra_body,
|
|
467
|
-
timeout=timeout,
|
|
468
|
-
query=await async_maybe_transform(
|
|
469
|
-
{
|
|
470
|
-
"from_date": from_date,
|
|
471
|
-
"job_id": job_id,
|
|
472
|
-
"limit": limit,
|
|
473
|
-
"offset": offset,
|
|
474
|
-
"status": status,
|
|
475
|
-
"to_date": to_date,
|
|
476
|
-
},
|
|
477
|
-
next_action_get_training_data_params.NextActionGetTrainingDataParams,
|
|
478
|
-
),
|
|
479
|
-
),
|
|
480
|
-
cast_to=ActionTrainingDataResponse,
|
|
481
|
-
)
|
|
482
|
-
|
|
483
|
-
async def get_training_datum(
|
|
484
|
-
self,
|
|
485
|
-
*,
|
|
486
|
-
id: str,
|
|
487
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
488
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
489
|
-
extra_headers: Headers | None = None,
|
|
490
|
-
extra_query: Query | None = None,
|
|
491
|
-
extra_body: Body | None = None,
|
|
492
|
-
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
493
|
-
) -> ActionTrainingDataEntry:
|
|
494
|
-
"""
|
|
495
|
-
Args:
|
|
496
|
-
id: ID of the training datum to get
|
|
497
|
-
|
|
498
|
-
extra_headers: Send extra headers
|
|
499
|
-
|
|
500
|
-
extra_query: Add additional query parameters to the request
|
|
501
|
-
|
|
502
|
-
extra_body: Add additional JSON properties to the request
|
|
503
|
-
|
|
504
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
|
505
|
-
"""
|
|
506
|
-
return await self._get(
|
|
507
|
-
"/admin/next_action/get_action_training_datum",
|
|
508
|
-
options=make_request_options(
|
|
509
|
-
extra_headers=extra_headers,
|
|
510
|
-
extra_query=extra_query,
|
|
511
|
-
extra_body=extra_body,
|
|
512
|
-
timeout=timeout,
|
|
513
|
-
query=await async_maybe_transform(
|
|
514
|
-
{"id": id}, next_action_get_training_datum_params.NextActionGetTrainingDatumParams
|
|
515
|
-
),
|
|
516
|
-
),
|
|
517
|
-
cast_to=ActionTrainingDataEntry,
|
|
518
|
-
)
|
|
519
|
-
|
|
520
|
-
async def label_training_datum(
|
|
521
|
-
self,
|
|
522
|
-
*,
|
|
523
|
-
id: str,
|
|
524
|
-
label: str,
|
|
525
|
-
output: next_action_label_training_datum_params.Output,
|
|
526
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
527
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
528
|
-
extra_headers: Headers | None = None,
|
|
529
|
-
extra_query: Query | None = None,
|
|
530
|
-
extra_body: Body | None = None,
|
|
531
|
-
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
532
|
-
) -> None:
|
|
533
|
-
"""
|
|
534
|
-
Label an existing action training datum
|
|
535
|
-
|
|
536
|
-
Args:
|
|
537
|
-
extra_headers: Send extra headers
|
|
538
|
-
|
|
539
|
-
extra_query: Add additional query parameters to the request
|
|
540
|
-
|
|
541
|
-
extra_body: Add additional JSON properties to the request
|
|
542
|
-
|
|
543
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
|
544
|
-
"""
|
|
545
|
-
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
546
|
-
return await self._put(
|
|
547
|
-
"/admin/next_action/label_action_training_datum",
|
|
548
|
-
body=await async_maybe_transform(
|
|
549
|
-
{
|
|
550
|
-
"id": id,
|
|
551
|
-
"label": label,
|
|
552
|
-
"output": output,
|
|
553
|
-
},
|
|
554
|
-
next_action_label_training_datum_params.NextActionLabelTrainingDatumParams,
|
|
555
|
-
),
|
|
556
|
-
options=make_request_options(
|
|
557
|
-
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
558
|
-
),
|
|
559
|
-
cast_to=NoneType,
|
|
560
|
-
)
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
class NextActionResourceWithRawResponse:
|
|
564
|
-
def __init__(self, next_action: NextActionResource) -> None:
|
|
565
|
-
self._next_action = next_action
|
|
566
|
-
|
|
567
|
-
self.add_training_datum = to_raw_response_wrapper(
|
|
568
|
-
next_action.add_training_datum,
|
|
569
|
-
)
|
|
570
|
-
self.delete_training_data = to_raw_response_wrapper(
|
|
571
|
-
next_action.delete_training_data,
|
|
572
|
-
)
|
|
573
|
-
self.get_batched_training_data = to_raw_response_wrapper(
|
|
574
|
-
next_action.get_batched_training_data,
|
|
575
|
-
)
|
|
576
|
-
self.get_training_data = to_raw_response_wrapper(
|
|
577
|
-
next_action.get_training_data,
|
|
578
|
-
)
|
|
579
|
-
self.get_training_datum = to_raw_response_wrapper(
|
|
580
|
-
next_action.get_training_datum,
|
|
581
|
-
)
|
|
582
|
-
self.label_training_datum = to_raw_response_wrapper(
|
|
583
|
-
next_action.label_training_datum,
|
|
584
|
-
)
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
class AsyncNextActionResourceWithRawResponse:
|
|
588
|
-
def __init__(self, next_action: AsyncNextActionResource) -> None:
|
|
589
|
-
self._next_action = next_action
|
|
590
|
-
|
|
591
|
-
self.add_training_datum = async_to_raw_response_wrapper(
|
|
592
|
-
next_action.add_training_datum,
|
|
593
|
-
)
|
|
594
|
-
self.delete_training_data = async_to_raw_response_wrapper(
|
|
595
|
-
next_action.delete_training_data,
|
|
596
|
-
)
|
|
597
|
-
self.get_batched_training_data = async_to_raw_response_wrapper(
|
|
598
|
-
next_action.get_batched_training_data,
|
|
599
|
-
)
|
|
600
|
-
self.get_training_data = async_to_raw_response_wrapper(
|
|
601
|
-
next_action.get_training_data,
|
|
602
|
-
)
|
|
603
|
-
self.get_training_datum = async_to_raw_response_wrapper(
|
|
604
|
-
next_action.get_training_datum,
|
|
605
|
-
)
|
|
606
|
-
self.label_training_datum = async_to_raw_response_wrapper(
|
|
607
|
-
next_action.label_training_datum,
|
|
608
|
-
)
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
class NextActionResourceWithStreamingResponse:
|
|
612
|
-
def __init__(self, next_action: NextActionResource) -> None:
|
|
613
|
-
self._next_action = next_action
|
|
614
|
-
|
|
615
|
-
self.add_training_datum = to_streamed_response_wrapper(
|
|
616
|
-
next_action.add_training_datum,
|
|
617
|
-
)
|
|
618
|
-
self.delete_training_data = to_streamed_response_wrapper(
|
|
619
|
-
next_action.delete_training_data,
|
|
620
|
-
)
|
|
621
|
-
self.get_batched_training_data = to_streamed_response_wrapper(
|
|
622
|
-
next_action.get_batched_training_data,
|
|
623
|
-
)
|
|
624
|
-
self.get_training_data = to_streamed_response_wrapper(
|
|
625
|
-
next_action.get_training_data,
|
|
626
|
-
)
|
|
627
|
-
self.get_training_datum = to_streamed_response_wrapper(
|
|
628
|
-
next_action.get_training_datum,
|
|
629
|
-
)
|
|
630
|
-
self.label_training_datum = to_streamed_response_wrapper(
|
|
631
|
-
next_action.label_training_datum,
|
|
632
|
-
)
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
class AsyncNextActionResourceWithStreamingResponse:
|
|
636
|
-
def __init__(self, next_action: AsyncNextActionResource) -> None:
|
|
637
|
-
self._next_action = next_action
|
|
638
|
-
|
|
639
|
-
self.add_training_datum = async_to_streamed_response_wrapper(
|
|
640
|
-
next_action.add_training_datum,
|
|
641
|
-
)
|
|
642
|
-
self.delete_training_data = async_to_streamed_response_wrapper(
|
|
643
|
-
next_action.delete_training_data,
|
|
644
|
-
)
|
|
645
|
-
self.get_batched_training_data = async_to_streamed_response_wrapper(
|
|
646
|
-
next_action.get_batched_training_data,
|
|
647
|
-
)
|
|
648
|
-
self.get_training_data = async_to_streamed_response_wrapper(
|
|
649
|
-
next_action.get_training_data,
|
|
650
|
-
)
|
|
651
|
-
self.get_training_datum = async_to_streamed_response_wrapper(
|
|
652
|
-
next_action.get_training_datum,
|
|
653
|
-
)
|
|
654
|
-
self.label_training_datum = async_to_streamed_response_wrapper(
|
|
655
|
-
next_action.label_training_datum,
|
|
656
|
-
)
|