From 3af85543520722e6506cbf45f38747f7d5ed978d Mon Sep 17 00:00:00 2001 From: "ci.datadog-api-spec" Date: Fri, 22 May 2026 18:27:38 +0000 Subject: [PATCH] Regenerate client from commit 2c81a59 of spec repo --- .generator/schemas/v2/openapi.yaml | 439 ++++++++++++++++++ docs/datadog_api_client.v2.model.rst | 63 +++ .../GetLLMObsDatasetDraftState.py | 17 + .../ListLLMObsDatasetVersions.py | 17 + .../LockLLMObsDatasetDraftState.py | 17 + .../UnlockLLMObsDatasetDraftState.py | 15 + src/datadog_api_client/configuration.py | 4 + .../v2/api/llm_observability_api.py | 206 ++++++++ .../model/llm_obs_dataset_draft_state_data.py | 60 +++ ...obs_dataset_draft_state_data_attributes.py | 47 ++ .../llm_obs_dataset_draft_state_response.py | 40 ++ .../model/llm_obs_dataset_draft_state_type.py | 35 ++ .../model/llm_obs_dataset_draft_state_user.py | 72 +++ .../v2/model/llm_obs_dataset_version_data.py | 58 +++ ...llm_obs_dataset_version_data_attributes.py | 54 +++ .../v2/model/llm_obs_dataset_version_type.py | 35 ++ .../llm_obs_dataset_versions_response.py | 40 ++ src/datadog_api_client/v2/models/__init__.py | 20 + tests/v2/features/llm_observability.feature | 108 +++++ tests/v2/features/undo.json | 24 + 20 files changed, 1371 insertions(+) create mode 100644 examples/v2/llm-observability/GetLLMObsDatasetDraftState.py create mode 100644 examples/v2/llm-observability/ListLLMObsDatasetVersions.py create mode 100644 examples/v2/llm-observability/LockLLMObsDatasetDraftState.py create mode 100644 examples/v2/llm-observability/UnlockLLMObsDatasetDraftState.py create mode 100644 src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_data.py create mode 100644 src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_data_attributes.py create mode 100644 src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_response.py create mode 100644 src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_type.py create mode 100644 src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_user.py create mode 100644 src/datadog_api_client/v2/model/llm_obs_dataset_version_data.py create mode 100644 src/datadog_api_client/v2/model/llm_obs_dataset_version_data_attributes.py create mode 100644 src/datadog_api_client/v2/model/llm_obs_dataset_version_type.py create mode 100644 src/datadog_api_client/v2/model/llm_obs_dataset_versions_response.py diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index 60ae5f2857..0334b34754 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -43111,6 +43111,78 @@ components: - type - attributes type: object + LLMObsDatasetDraftStateData: + description: Data object for an LLM Observability dataset draft state. + properties: + attributes: + $ref: "#/components/schemas/LLMObsDatasetDraftStateDataAttributes" + id: + description: Unique identifier of the dataset draft state. Matches the dataset ID. + example: "9f64e5c7-dc5a-45c8-a17c-1b85f0bec97d" + type: string + type: + $ref: "#/components/schemas/LLMObsDatasetDraftStateType" + required: + - id + - type + - attributes + type: object + LLMObsDatasetDraftStateDataAttributes: + description: Attributes of an LLM Observability dataset draft state. + properties: + drafting_since: + description: Timestamp when the dataset draft session started. + example: "2024-01-15T10:30:00Z" + format: date-time + type: string + user: + $ref: "#/components/schemas/LLMObsDatasetDraftStateUser" + required: + - user + - drafting_since + type: object + LLMObsDatasetDraftStateResponse: + description: Response containing the draft state of an LLM Observability dataset. + properties: + data: + $ref: "#/components/schemas/LLMObsDatasetDraftStateData" + required: + - data + type: object + LLMObsDatasetDraftStateType: + description: Resource type of an LLM Observability dataset draft state. + enum: + - draft_state_data + example: draft_state_data + type: string + x-enum-varnames: + - DRAFT_STATE_DATA + LLMObsDatasetDraftStateUser: + description: User information associated with a dataset draft state. + properties: + email: + description: Email address of the user. + example: "jane.doe@example.com" + type: string + handle: + description: Handle of the user. + example: "jane.doe@example.com" + type: string + icon: + description: Icon for the user. + example: "" + type: string + id: + description: Unique identifier of the user holding the draft lock. + example: "00000000-0000-0000-0000-000000000010" + type: string + name: + description: Display name of the user. + example: "Jane Doe" + type: string + required: + - id + type: object LLMObsDatasetRecordDataResponse: description: A single LLM Observability dataset record. properties: @@ -43337,6 +43409,67 @@ components: required: - data type: object + LLMObsDatasetVersionData: + description: Data object for an LLM Observability dataset version. + properties: + attributes: + $ref: "#/components/schemas/LLMObsDatasetVersionDataAttributes" + id: + description: Unique identifier of the dataset version. + example: "3fd6b5e0-8910-4b1c-a7d0-5b84de329012" + type: string + type: + $ref: "#/components/schemas/LLMObsDatasetVersionType" + required: + - id + - type + - attributes + type: object + LLMObsDatasetVersionDataAttributes: + description: Attributes of an LLM Observability dataset version. + properties: + dataset_id: + description: Unique identifier of the dataset this version belongs to. + example: "9f64e5c7-dc5a-45c8-a17c-1b85f0bec97d" + type: string + last_used: + description: Timestamp when this dataset version was last referenced. Null if the version has never been used. + example: "2024-01-15T10:30:00Z" + format: date-time + nullable: true + type: string + version_number: + description: Sequential version number for this dataset version. + example: 1 + format: int32 + maximum: 2147483647 + type: integer + required: + - dataset_id + - version_number + - last_used + type: object + LLMObsDatasetVersionType: + description: Resource type of an LLM Observability dataset version. + enum: + - dataset_version + example: dataset_version + type: string + x-enum-varnames: + - DATASET_VERSION + LLMObsDatasetVersionsResponse: + description: Response containing the active versions of an LLM Observability dataset. + properties: + data: + $ref: "#/components/schemas/LLMObsDatasetVersionsResponseData" + required: + - data + type: object + LLMObsDatasetVersionsResponseData: + description: List of dataset versions. + items: + $ref: "#/components/schemas/LLMObsDatasetVersionData" + type: array LLMObsDatasetsResponse: description: Response containing a list of LLM Observability datasets. properties: @@ -125122,6 +125255,229 @@ paths: x-unstable: |- **Note**: This endpoint is in preview and is subject to change. If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/). + /api/v2/llm-obs/v1/{project_id}/datasets/{dataset_id}/draft_state: + get: + description: Retrieve the draft state of a dataset, including whether it is currently locked for editing and which user holds the lock. + operationId: GetLLMObsDatasetDraftState + parameters: + - description: The ID of the LLM Observability project. + example: "a33671aa-24fd-4dcd-9b33-a8ec7dde7751" + in: path + name: project_id + required: true + schema: + type: string + - description: The ID of the LLM Observability dataset. + example: "9f64e5c7-dc5a-45c8-a17c-1b85f0bec97d" + in: path + name: dataset_id + required: true + schema: + type: string + responses: + "200": + content: + application/json: + examples: + default: + value: + data: + attributes: + drafting_since: "2024-01-15T10:30:00Z" + user: + email: jane.doe@example.com + handle: jane.doe@example.com + id: 00000000-0000-0000-0000-000000000010 + name: Jane Doe + id: 9f64e5c7-dc5a-45c8-a17c-1b85f0bec97d + type: draft_state_data + schema: + $ref: "#/components/schemas/LLMObsDatasetDraftStateResponse" + description: OK + "400": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Bad Request + "401": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Unauthorized + "403": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Forbidden + "404": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Not Found + "429": + $ref: "#/components/responses/TooManyRequestsResponse" + "500": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Internal Server Error + security: + - apiKeyAuth: [] + appKeyAuth: [] + summary: Get LLM Observability dataset draft state + tags: + - LLM Observability + x-unstable: |- + **Note**: This endpoint is in preview and is subject to change. + If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/). + /api/v2/llm-obs/v1/{project_id}/datasets/{dataset_id}/draft_state/lock: + patch: + description: Acquire the draft lock on a dataset for the calling user. The lock prevents other users from concurrently editing the dataset draft. + operationId: LockLLMObsDatasetDraftState + parameters: + - description: The ID of the LLM Observability project. + example: "a33671aa-24fd-4dcd-9b33-a8ec7dde7751" + in: path + name: project_id + required: true + schema: + type: string + - description: The ID of the LLM Observability dataset. + example: "9f64e5c7-dc5a-45c8-a17c-1b85f0bec97d" + in: path + name: dataset_id + required: true + schema: + type: string + responses: + "200": + content: + application/json: + examples: + default: + value: + data: + attributes: + drafting_since: "2024-01-15T10:30:00Z" + user: + email: jane.doe@example.com + handle: jane.doe@example.com + id: 00000000-0000-0000-0000-000000000010 + name: Jane Doe + id: 9f64e5c7-dc5a-45c8-a17c-1b85f0bec97d + type: draft_state_data + schema: + $ref: "#/components/schemas/LLMObsDatasetDraftStateResponse" + description: OK + "400": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Bad Request + "401": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Unauthorized + "403": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Forbidden + "404": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Not Found + "429": + $ref: "#/components/responses/TooManyRequestsResponse" + "500": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Internal Server Error + security: + - apiKeyAuth: [] + appKeyAuth: [] + summary: Lock LLM Observability dataset draft state + tags: + - LLM Observability + x-unstable: |- + **Note**: This endpoint is in preview and is subject to change. + If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/). + /api/v2/llm-obs/v1/{project_id}/datasets/{dataset_id}/draft_state/unlock: + patch: + description: Release the draft lock on a dataset held by the calling user, allowing other users to edit the dataset draft. + operationId: UnlockLLMObsDatasetDraftState + parameters: + - description: The ID of the LLM Observability project. + example: "a33671aa-24fd-4dcd-9b33-a8ec7dde7751" + in: path + name: project_id + required: true + schema: + type: string + - description: The ID of the LLM Observability dataset. + example: "9f64e5c7-dc5a-45c8-a17c-1b85f0bec97d" + in: path + name: dataset_id + required: true + schema: + type: string + responses: + "200": + description: OK + "400": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Bad Request + "401": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Unauthorized + "403": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Forbidden + "404": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Not Found + "429": + $ref: "#/components/responses/TooManyRequestsResponse" + "500": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Internal Server Error + security: + - apiKeyAuth: [] + appKeyAuth: [] + summary: Unlock LLM Observability dataset draft state + tags: + - LLM Observability + x-unstable: |- + **Note**: This endpoint is in preview and is subject to change. + If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/). /api/v2/llm-obs/v1/{project_id}/datasets/{dataset_id}/records: get: description: List all records in an LLM Observability dataset, sorted by creation date, newest first. @@ -125432,6 +125788,89 @@ paths: x-unstable: |- **Note**: This endpoint is in preview and is subject to change. If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/). + /api/v2/llm-obs/v1/{project_id}/datasets/{dataset_id}/versions: + get: + description: List the active versions of a dataset. A version is created each time a dataset is referenced by an experiment run. + operationId: ListLLMObsDatasetVersions + parameters: + - description: The ID of the LLM Observability project. + example: "a33671aa-24fd-4dcd-9b33-a8ec7dde7751" + in: path + name: project_id + required: true + schema: + type: string + - description: The ID of the LLM Observability dataset. + example: "9f64e5c7-dc5a-45c8-a17c-1b85f0bec97d" + in: path + name: dataset_id + required: true + schema: + type: string + responses: + "200": + content: + application/json: + examples: + default: + value: + data: + - attributes: + dataset_id: 9f64e5c7-dc5a-45c8-a17c-1b85f0bec97d + last_used: "2024-01-15T10:30:00Z" + version_number: 1 + id: 3fd6b5e0-8910-4b1c-a7d0-5b84de329012 + type: dataset_version + - attributes: + dataset_id: 9f64e5c7-dc5a-45c8-a17c-1b85f0bec97d + last_used: "2024-02-20T14:45:00Z" + version_number: 2 + id: 4ee7c6f1-9a01-5c2d-b8e1-6c95ef43a123 + type: dataset_version + schema: + $ref: "#/components/schemas/LLMObsDatasetVersionsResponse" + description: OK + "400": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Bad Request + "401": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Unauthorized + "403": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Forbidden + "404": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Not Found + "429": + $ref: "#/components/responses/TooManyRequestsResponse" + "500": + content: + application/json: + schema: + $ref: "#/components/schemas/JSONAPIErrorResponse" + description: Internal Server Error + security: + - apiKeyAuth: [] + appKeyAuth: [] + summary: List LLM Observability dataset versions + tags: + - LLM Observability + x-unstable: |- + **Note**: This endpoint is in preview and is subject to change. + If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/). /api/v2/llm-obs/v3/experiments/{experiment_id}/events: get: description: Retrieve spans and experiment-level summary metrics for a given experiment with cursor-based pagination. diff --git a/docs/datadog_api_client.v2.model.rst b/docs/datadog_api_client.v2.model.rst index b5e6a78ea4..3dd4fc899b 100644 --- a/docs/datadog_api_client.v2.model.rst +++ b/docs/datadog_api_client.v2.model.rst @@ -18855,6 +18855,41 @@ datadog\_api\_client.v2.model.llm\_obs\_dataset\_data\_response module :members: :show-inheritance: +datadog\_api\_client.v2.model.llm\_obs\_dataset\_draft\_state\_data module +-------------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.llm_obs_dataset_draft_state_data + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.llm\_obs\_dataset\_draft\_state\_data\_attributes module +-------------------------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.llm_obs_dataset_draft_state_data_attributes + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.llm\_obs\_dataset\_draft\_state\_response module +------------------------------------------------------------------------------ + +.. automodule:: datadog_api_client.v2.model.llm_obs_dataset_draft_state_response + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.llm\_obs\_dataset\_draft\_state\_type module +-------------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.llm_obs_dataset_draft_state_type + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.llm\_obs\_dataset\_draft\_state\_user module +-------------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.llm_obs_dataset_draft_state_user + :members: + :show-inheritance: + datadog\_api\_client.v2.model.llm\_obs\_dataset\_record\_data\_response module ------------------------------------------------------------------------------ @@ -18981,6 +19016,34 @@ datadog\_api\_client.v2.model.llm\_obs\_dataset\_update\_request module :members: :show-inheritance: +datadog\_api\_client.v2.model.llm\_obs\_dataset\_version\_data module +--------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.llm_obs_dataset_version_data + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.llm\_obs\_dataset\_version\_data\_attributes module +--------------------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.llm_obs_dataset_version_data_attributes + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.llm\_obs\_dataset\_version\_type module +--------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.llm_obs_dataset_version_type + :members: + :show-inheritance: + +datadog\_api\_client.v2.model.llm\_obs\_dataset\_versions\_response module +-------------------------------------------------------------------------- + +.. automodule:: datadog_api_client.v2.model.llm_obs_dataset_versions_response + :members: + :show-inheritance: + datadog\_api\_client.v2.model.llm\_obs\_datasets\_response module ----------------------------------------------------------------- diff --git a/examples/v2/llm-observability/GetLLMObsDatasetDraftState.py b/examples/v2/llm-observability/GetLLMObsDatasetDraftState.py new file mode 100644 index 0000000000..417e3ecadd --- /dev/null +++ b/examples/v2/llm-observability/GetLLMObsDatasetDraftState.py @@ -0,0 +1,17 @@ +""" +Get LLM Observability dataset draft state returns "OK" response +""" + +from datadog_api_client import ApiClient, Configuration +from datadog_api_client.v2.api.llm_observability_api import LLMObservabilityApi + +configuration = Configuration() +configuration.unstable_operations["get_llm_obs_dataset_draft_state"] = True +with ApiClient(configuration) as api_client: + api_instance = LLMObservabilityApi(api_client) + response = api_instance.get_llm_obs_dataset_draft_state( + project_id="project_id", + dataset_id="dataset_id", + ) + + print(response) diff --git a/examples/v2/llm-observability/ListLLMObsDatasetVersions.py b/examples/v2/llm-observability/ListLLMObsDatasetVersions.py new file mode 100644 index 0000000000..e4ca977dcb --- /dev/null +++ b/examples/v2/llm-observability/ListLLMObsDatasetVersions.py @@ -0,0 +1,17 @@ +""" +List LLM Observability dataset versions returns "OK" response +""" + +from datadog_api_client import ApiClient, Configuration +from datadog_api_client.v2.api.llm_observability_api import LLMObservabilityApi + +configuration = Configuration() +configuration.unstable_operations["list_llm_obs_dataset_versions"] = True +with ApiClient(configuration) as api_client: + api_instance = LLMObservabilityApi(api_client) + response = api_instance.list_llm_obs_dataset_versions( + project_id="project_id", + dataset_id="dataset_id", + ) + + print(response) diff --git a/examples/v2/llm-observability/LockLLMObsDatasetDraftState.py b/examples/v2/llm-observability/LockLLMObsDatasetDraftState.py new file mode 100644 index 0000000000..3641f53e41 --- /dev/null +++ b/examples/v2/llm-observability/LockLLMObsDatasetDraftState.py @@ -0,0 +1,17 @@ +""" +Lock LLM Observability dataset draft state returns "OK" response +""" + +from datadog_api_client import ApiClient, Configuration +from datadog_api_client.v2.api.llm_observability_api import LLMObservabilityApi + +configuration = Configuration() +configuration.unstable_operations["lock_llm_obs_dataset_draft_state"] = True +with ApiClient(configuration) as api_client: + api_instance = LLMObservabilityApi(api_client) + response = api_instance.lock_llm_obs_dataset_draft_state( + project_id="project_id", + dataset_id="dataset_id", + ) + + print(response) diff --git a/examples/v2/llm-observability/UnlockLLMObsDatasetDraftState.py b/examples/v2/llm-observability/UnlockLLMObsDatasetDraftState.py new file mode 100644 index 0000000000..96754fd273 --- /dev/null +++ b/examples/v2/llm-observability/UnlockLLMObsDatasetDraftState.py @@ -0,0 +1,15 @@ +""" +Unlock LLM Observability dataset draft state returns "OK" response +""" + +from datadog_api_client import ApiClient, Configuration +from datadog_api_client.v2.api.llm_observability_api import LLMObservabilityApi + +configuration = Configuration() +configuration.unstable_operations["unlock_llm_obs_dataset_draft_state"] = True +with ApiClient(configuration) as api_client: + api_instance = LLMObservabilityApi(api_client) + api_instance.unlock_llm_obs_dataset_draft_state( + project_id="project_id", + dataset_id="dataset_id", + ) diff --git a/src/datadog_api_client/configuration.py b/src/datadog_api_client/configuration.py index 862dfb0898..2b7170ad59 100644 --- a/src/datadog_api_client/configuration.py +++ b/src/datadog_api_client/configuration.py @@ -286,18 +286,22 @@ def __init__( "v2.get_llm_obs_annotated_interactions_by_trace_i_ds": False, "v2.get_llm_obs_annotation_queue_label_schema": False, "v2.get_llm_obs_custom_eval_config": False, + "v2.get_llm_obs_dataset_draft_state": False, "v2.list_llm_obs_annotation_queues": False, "v2.list_llm_obs_dataset_records": False, "v2.list_llm_obs_datasets": False, + "v2.list_llm_obs_dataset_versions": False, "v2.list_llm_obs_experiment_events": False, "v2.list_llm_obs_experiments": False, "v2.list_llm_obs_integration_accounts": False, "v2.list_llm_obs_integration_models": False, "v2.list_llm_obs_projects": False, "v2.list_llm_obs_spans": False, + "v2.lock_llm_obs_dataset_draft_state": False, "v2.search_llm_obs_experimentation": False, "v2.search_llm_obs_spans": False, "v2.simple_search_llm_obs_experimentation": False, + "v2.unlock_llm_obs_dataset_draft_state": False, "v2.update_llm_obs_annotation_queue": False, "v2.update_llm_obs_annotation_queue_label_schema": False, "v2.update_llm_obs_custom_eval_config": False, diff --git a/src/datadog_api_client/v2/api/llm_observability_api.py b/src/datadog_api_client/v2/api/llm_observability_api.py index 671175658e..274d296ec0 100644 --- a/src/datadog_api_client/v2/api/llm_observability_api.py +++ b/src/datadog_api_client/v2/api/llm_observability_api.py @@ -73,11 +73,13 @@ from datadog_api_client.v2.model.llm_obs_dataset_request import LLMObsDatasetRequest from datadog_api_client.v2.model.llm_obs_delete_datasets_request import LLMObsDeleteDatasetsRequest from datadog_api_client.v2.model.llm_obs_dataset_update_request import LLMObsDatasetUpdateRequest +from datadog_api_client.v2.model.llm_obs_dataset_draft_state_response import LLMObsDatasetDraftStateResponse from datadog_api_client.v2.model.llm_obs_dataset_records_list_response import LLMObsDatasetRecordsListResponse from datadog_api_client.v2.model.llm_obs_dataset_records_mutation_response import LLMObsDatasetRecordsMutationResponse from datadog_api_client.v2.model.llm_obs_dataset_records_update_request import LLMObsDatasetRecordsUpdateRequest from datadog_api_client.v2.model.llm_obs_dataset_records_request import LLMObsDatasetRecordsRequest from datadog_api_client.v2.model.llm_obs_delete_dataset_records_request import LLMObsDeleteDatasetRecordsRequest +from datadog_api_client.v2.model.llm_obs_dataset_versions_response import LLMObsDatasetVersionsResponse from datadog_api_client.v2.model.llm_obs_experiment_events_v2_response import LLMObsExperimentEventsV2Response @@ -614,6 +616,35 @@ def __init__(self, api_client=None): api_client=api_client, ) + self._get_llm_obs_dataset_draft_state_endpoint = _Endpoint( + settings={ + "response_type": (LLMObsDatasetDraftStateResponse,), + "auth": ["apiKeyAuth", "appKeyAuth"], + "endpoint_path": "/api/v2/llm-obs/v1/{project_id}/datasets/{dataset_id}/draft_state", + "operation_id": "get_llm_obs_dataset_draft_state", + "http_method": "GET", + "version": "v2", + }, + params_map={ + "project_id": { + "required": True, + "openapi_types": (str,), + "attribute": "project_id", + "location": "path", + }, + "dataset_id": { + "required": True, + "openapi_types": (str,), + "attribute": "dataset_id", + "location": "path", + }, + }, + headers_map={ + "accept": ["application/json"], + }, + api_client=api_client, + ) + self._list_llm_obs_annotation_queues_endpoint = _Endpoint( settings={ "response_type": (LLMObsAnnotationQueuesResponse,), @@ -729,6 +760,35 @@ def __init__(self, api_client=None): api_client=api_client, ) + self._list_llm_obs_dataset_versions_endpoint = _Endpoint( + settings={ + "response_type": (LLMObsDatasetVersionsResponse,), + "auth": ["apiKeyAuth", "appKeyAuth"], + "endpoint_path": "/api/v2/llm-obs/v1/{project_id}/datasets/{dataset_id}/versions", + "operation_id": "list_llm_obs_dataset_versions", + "http_method": "GET", + "version": "v2", + }, + params_map={ + "project_id": { + "required": True, + "openapi_types": (str,), + "attribute": "project_id", + "location": "path", + }, + "dataset_id": { + "required": True, + "openapi_types": (str,), + "attribute": "dataset_id", + "location": "path", + }, + }, + headers_map={ + "accept": ["application/json"], + }, + api_client=api_client, + ) + self._list_llm_obs_experiment_events_endpoint = _Endpoint( settings={ "response_type": (LLMObsExperimentEventsV2Response,), @@ -970,6 +1030,35 @@ def __init__(self, api_client=None): api_client=api_client, ) + self._lock_llm_obs_dataset_draft_state_endpoint = _Endpoint( + settings={ + "response_type": (LLMObsDatasetDraftStateResponse,), + "auth": ["apiKeyAuth", "appKeyAuth"], + "endpoint_path": "/api/v2/llm-obs/v1/{project_id}/datasets/{dataset_id}/draft_state/lock", + "operation_id": "lock_llm_obs_dataset_draft_state", + "http_method": "PATCH", + "version": "v2", + }, + params_map={ + "project_id": { + "required": True, + "openapi_types": (str,), + "attribute": "project_id", + "location": "path", + }, + "dataset_id": { + "required": True, + "openapi_types": (str,), + "attribute": "dataset_id", + "location": "path", + }, + }, + headers_map={ + "accept": ["application/json"], + }, + api_client=api_client, + ) + self._search_llm_obs_experimentation_endpoint = _Endpoint( settings={ "response_type": (LLMObsExperimentationSearchResponse,), @@ -1030,6 +1119,35 @@ def __init__(self, api_client=None): api_client=api_client, ) + self._unlock_llm_obs_dataset_draft_state_endpoint = _Endpoint( + settings={ + "response_type": None, + "auth": ["apiKeyAuth", "appKeyAuth"], + "endpoint_path": "/api/v2/llm-obs/v1/{project_id}/datasets/{dataset_id}/draft_state/unlock", + "operation_id": "unlock_llm_obs_dataset_draft_state", + "http_method": "PATCH", + "version": "v2", + }, + params_map={ + "project_id": { + "required": True, + "openapi_types": (str,), + "attribute": "project_id", + "location": "path", + }, + "dataset_id": { + "required": True, + "openapi_types": (str,), + "attribute": "dataset_id", + "location": "path", + }, + }, + headers_map={ + "accept": ["*/*"], + }, + api_client=api_client, + ) + self._update_llm_obs_annotation_queue_endpoint = _Endpoint( settings={ "response_type": (LLMObsAnnotationQueueResponse,), @@ -1664,6 +1782,28 @@ def get_llm_obs_custom_eval_config( return self._get_llm_obs_custom_eval_config_endpoint.call_with_http_info(**kwargs) + def get_llm_obs_dataset_draft_state( + self, + project_id: str, + dataset_id: str, + ) -> LLMObsDatasetDraftStateResponse: + """Get LLM Observability dataset draft state. + + Retrieve the draft state of a dataset, including whether it is currently locked for editing and which user holds the lock. + + :param project_id: The ID of the LLM Observability project. + :type project_id: str + :param dataset_id: The ID of the LLM Observability dataset. + :type dataset_id: str + :rtype: LLMObsDatasetDraftStateResponse + """ + kwargs: Dict[str, Any] = {} + kwargs["project_id"] = project_id + + kwargs["dataset_id"] = dataset_id + + return self._get_llm_obs_dataset_draft_state_endpoint.call_with_http_info(**kwargs) + def list_llm_obs_annotation_queues( self, *, @@ -1773,6 +1913,28 @@ def list_llm_obs_datasets( return self._list_llm_obs_datasets_endpoint.call_with_http_info(**kwargs) + def list_llm_obs_dataset_versions( + self, + project_id: str, + dataset_id: str, + ) -> LLMObsDatasetVersionsResponse: + """List LLM Observability dataset versions. + + List the active versions of a dataset. A version is created each time a dataset is referenced by an experiment run. + + :param project_id: The ID of the LLM Observability project. + :type project_id: str + :param dataset_id: The ID of the LLM Observability dataset. + :type dataset_id: str + :rtype: LLMObsDatasetVersionsResponse + """ + kwargs: Dict[str, Any] = {} + kwargs["project_id"] = project_id + + kwargs["dataset_id"] = dataset_id + + return self._list_llm_obs_dataset_versions_endpoint.call_with_http_info(**kwargs) + def list_llm_obs_experiment_events( self, experiment_id: str, @@ -2007,6 +2169,28 @@ def list_llm_obs_spans( return self._list_llm_obs_spans_endpoint.call_with_http_info(**kwargs) + def lock_llm_obs_dataset_draft_state( + self, + project_id: str, + dataset_id: str, + ) -> LLMObsDatasetDraftStateResponse: + """Lock LLM Observability dataset draft state. + + Acquire the draft lock on a dataset for the calling user. The lock prevents other users from concurrently editing the dataset draft. + + :param project_id: The ID of the LLM Observability project. + :type project_id: str + :param dataset_id: The ID of the LLM Observability dataset. + :type dataset_id: str + :rtype: LLMObsDatasetDraftStateResponse + """ + kwargs: Dict[str, Any] = {} + kwargs["project_id"] = project_id + + kwargs["dataset_id"] = dataset_id + + return self._lock_llm_obs_dataset_draft_state_endpoint.call_with_http_info(**kwargs) + def search_llm_obs_experimentation( self, body: LLMObsExperimentationSearchRequest, @@ -2065,6 +2249,28 @@ def simple_search_llm_obs_experimentation( return self._simple_search_llm_obs_experimentation_endpoint.call_with_http_info(**kwargs) + def unlock_llm_obs_dataset_draft_state( + self, + project_id: str, + dataset_id: str, + ) -> None: + """Unlock LLM Observability dataset draft state. + + Release the draft lock on a dataset held by the calling user, allowing other users to edit the dataset draft. + + :param project_id: The ID of the LLM Observability project. + :type project_id: str + :param dataset_id: The ID of the LLM Observability dataset. + :type dataset_id: str + :rtype: None + """ + kwargs: Dict[str, Any] = {} + kwargs["project_id"] = project_id + + kwargs["dataset_id"] = dataset_id + + return self._unlock_llm_obs_dataset_draft_state_endpoint.call_with_http_info(**kwargs) + def update_llm_obs_annotation_queue( self, queue_id: str, diff --git a/src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_data.py b/src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_data.py new file mode 100644 index 0000000000..51ea9d733b --- /dev/null +++ b/src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_data.py @@ -0,0 +1,60 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import TYPE_CHECKING + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +if TYPE_CHECKING: + from datadog_api_client.v2.model.llm_obs_dataset_draft_state_data_attributes import ( + LLMObsDatasetDraftStateDataAttributes, + ) + from datadog_api_client.v2.model.llm_obs_dataset_draft_state_type import LLMObsDatasetDraftStateType + + +class LLMObsDatasetDraftStateData(ModelNormal): + @cached_property + def openapi_types(_): + from datadog_api_client.v2.model.llm_obs_dataset_draft_state_data_attributes import ( + LLMObsDatasetDraftStateDataAttributes, + ) + from datadog_api_client.v2.model.llm_obs_dataset_draft_state_type import LLMObsDatasetDraftStateType + + return { + "attributes": (LLMObsDatasetDraftStateDataAttributes,), + "id": (str,), + "type": (LLMObsDatasetDraftStateType,), + } + + attribute_map = { + "attributes": "attributes", + "id": "id", + "type": "type", + } + + def __init__( + self_, attributes: LLMObsDatasetDraftStateDataAttributes, id: str, type: LLMObsDatasetDraftStateType, **kwargs + ): + """ + Data object for an LLM Observability dataset draft state. + + :param attributes: Attributes of an LLM Observability dataset draft state. + :type attributes: LLMObsDatasetDraftStateDataAttributes + + :param id: Unique identifier of the dataset draft state. Matches the dataset ID. + :type id: str + + :param type: Resource type of an LLM Observability dataset draft state. + :type type: LLMObsDatasetDraftStateType + """ + super().__init__(kwargs) + + self_.attributes = attributes + self_.id = id + self_.type = type diff --git a/src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_data_attributes.py b/src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_data_attributes.py new file mode 100644 index 0000000000..33611fce20 --- /dev/null +++ b/src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_data_attributes.py @@ -0,0 +1,47 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import TYPE_CHECKING + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, + datetime, +) + + +if TYPE_CHECKING: + from datadog_api_client.v2.model.llm_obs_dataset_draft_state_user import LLMObsDatasetDraftStateUser + + +class LLMObsDatasetDraftStateDataAttributes(ModelNormal): + @cached_property + def openapi_types(_): + from datadog_api_client.v2.model.llm_obs_dataset_draft_state_user import LLMObsDatasetDraftStateUser + + return { + "drafting_since": (datetime,), + "user": (LLMObsDatasetDraftStateUser,), + } + + attribute_map = { + "drafting_since": "drafting_since", + "user": "user", + } + + def __init__(self_, drafting_since: datetime, user: LLMObsDatasetDraftStateUser, **kwargs): + """ + Attributes of an LLM Observability dataset draft state. + + :param drafting_since: Timestamp when the dataset draft session started. + :type drafting_since: datetime + + :param user: User information associated with a dataset draft state. + :type user: LLMObsDatasetDraftStateUser + """ + super().__init__(kwargs) + + self_.drafting_since = drafting_since + self_.user = user diff --git a/src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_response.py b/src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_response.py new file mode 100644 index 0000000000..b7048e073e --- /dev/null +++ b/src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_response.py @@ -0,0 +1,40 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import TYPE_CHECKING + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +if TYPE_CHECKING: + from datadog_api_client.v2.model.llm_obs_dataset_draft_state_data import LLMObsDatasetDraftStateData + + +class LLMObsDatasetDraftStateResponse(ModelNormal): + @cached_property + def openapi_types(_): + from datadog_api_client.v2.model.llm_obs_dataset_draft_state_data import LLMObsDatasetDraftStateData + + return { + "data": (LLMObsDatasetDraftStateData,), + } + + attribute_map = { + "data": "data", + } + + def __init__(self_, data: LLMObsDatasetDraftStateData, **kwargs): + """ + Response containing the draft state of an LLM Observability dataset. + + :param data: Data object for an LLM Observability dataset draft state. + :type data: LLMObsDatasetDraftStateData + """ + super().__init__(kwargs) + + self_.data = data diff --git a/src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_type.py b/src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_type.py new file mode 100644 index 0000000000..14b2d78ce0 --- /dev/null +++ b/src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_type.py @@ -0,0 +1,35 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + + +from datadog_api_client.model_utils import ( + ModelSimple, + cached_property, +) + +from typing import ClassVar + + +class LLMObsDatasetDraftStateType(ModelSimple): + """ + Resource type of an LLM Observability dataset draft state. + + :param value: If omitted defaults to "draft_state_data". Must be one of ["draft_state_data"]. + :type value: str + """ + + allowed_values = { + "draft_state_data", + } + DRAFT_STATE_DATA: ClassVar["LLMObsDatasetDraftStateType"] + + @cached_property + def openapi_types(_): + return { + "value": (str,), + } + + +LLMObsDatasetDraftStateType.DRAFT_STATE_DATA = LLMObsDatasetDraftStateType("draft_state_data") diff --git a/src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_user.py b/src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_user.py new file mode 100644 index 0000000000..abd5b67824 --- /dev/null +++ b/src/datadog_api_client/v2/model/llm_obs_dataset_draft_state_user.py @@ -0,0 +1,72 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import Union + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, + unset, + UnsetType, +) + + +class LLMObsDatasetDraftStateUser(ModelNormal): + @cached_property + def openapi_types(_): + return { + "email": (str,), + "handle": (str,), + "icon": (str,), + "id": (str,), + "name": (str,), + } + + attribute_map = { + "email": "email", + "handle": "handle", + "icon": "icon", + "id": "id", + "name": "name", + } + + def __init__( + self_, + id: str, + email: Union[str, UnsetType] = unset, + handle: Union[str, UnsetType] = unset, + icon: Union[str, UnsetType] = unset, + name: Union[str, UnsetType] = unset, + **kwargs, + ): + """ + User information associated with a dataset draft state. + + :param email: Email address of the user. + :type email: str, optional + + :param handle: Handle of the user. + :type handle: str, optional + + :param icon: Icon for the user. + :type icon: str, optional + + :param id: Unique identifier of the user holding the draft lock. + :type id: str + + :param name: Display name of the user. + :type name: str, optional + """ + if email is not unset: + kwargs["email"] = email + if handle is not unset: + kwargs["handle"] = handle + if icon is not unset: + kwargs["icon"] = icon + if name is not unset: + kwargs["name"] = name + super().__init__(kwargs) + + self_.id = id diff --git a/src/datadog_api_client/v2/model/llm_obs_dataset_version_data.py b/src/datadog_api_client/v2/model/llm_obs_dataset_version_data.py new file mode 100644 index 0000000000..581adbedf9 --- /dev/null +++ b/src/datadog_api_client/v2/model/llm_obs_dataset_version_data.py @@ -0,0 +1,58 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import TYPE_CHECKING + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +if TYPE_CHECKING: + from datadog_api_client.v2.model.llm_obs_dataset_version_data_attributes import LLMObsDatasetVersionDataAttributes + from datadog_api_client.v2.model.llm_obs_dataset_version_type import LLMObsDatasetVersionType + + +class LLMObsDatasetVersionData(ModelNormal): + @cached_property + def openapi_types(_): + from datadog_api_client.v2.model.llm_obs_dataset_version_data_attributes import ( + LLMObsDatasetVersionDataAttributes, + ) + from datadog_api_client.v2.model.llm_obs_dataset_version_type import LLMObsDatasetVersionType + + return { + "attributes": (LLMObsDatasetVersionDataAttributes,), + "id": (str,), + "type": (LLMObsDatasetVersionType,), + } + + attribute_map = { + "attributes": "attributes", + "id": "id", + "type": "type", + } + + def __init__( + self_, attributes: LLMObsDatasetVersionDataAttributes, id: str, type: LLMObsDatasetVersionType, **kwargs + ): + """ + Data object for an LLM Observability dataset version. + + :param attributes: Attributes of an LLM Observability dataset version. + :type attributes: LLMObsDatasetVersionDataAttributes + + :param id: Unique identifier of the dataset version. + :type id: str + + :param type: Resource type of an LLM Observability dataset version. + :type type: LLMObsDatasetVersionType + """ + super().__init__(kwargs) + + self_.attributes = attributes + self_.id = id + self_.type = type diff --git a/src/datadog_api_client/v2/model/llm_obs_dataset_version_data_attributes.py b/src/datadog_api_client/v2/model/llm_obs_dataset_version_data_attributes.py new file mode 100644 index 0000000000..1b6684b314 --- /dev/null +++ b/src/datadog_api_client/v2/model/llm_obs_dataset_version_data_attributes.py @@ -0,0 +1,54 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import Union + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, + datetime, + none_type, +) + + +class LLMObsDatasetVersionDataAttributes(ModelNormal): + validations = { + "version_number": { + "inclusive_maximum": 2147483647, + }, + } + + @cached_property + def openapi_types(_): + return { + "dataset_id": (str,), + "last_used": (datetime, none_type), + "version_number": (int,), + } + + attribute_map = { + "dataset_id": "dataset_id", + "last_used": "last_used", + "version_number": "version_number", + } + + def __init__(self_, dataset_id: str, last_used: Union[datetime, none_type], version_number: int, **kwargs): + """ + Attributes of an LLM Observability dataset version. + + :param dataset_id: Unique identifier of the dataset this version belongs to. + :type dataset_id: str + + :param last_used: Timestamp when this dataset version was last referenced. Null if the version has never been used. + :type last_used: datetime, none_type + + :param version_number: Sequential version number for this dataset version. + :type version_number: int + """ + super().__init__(kwargs) + + self_.dataset_id = dataset_id + self_.last_used = last_used + self_.version_number = version_number diff --git a/src/datadog_api_client/v2/model/llm_obs_dataset_version_type.py b/src/datadog_api_client/v2/model/llm_obs_dataset_version_type.py new file mode 100644 index 0000000000..590a6c3860 --- /dev/null +++ b/src/datadog_api_client/v2/model/llm_obs_dataset_version_type.py @@ -0,0 +1,35 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + + +from datadog_api_client.model_utils import ( + ModelSimple, + cached_property, +) + +from typing import ClassVar + + +class LLMObsDatasetVersionType(ModelSimple): + """ + Resource type of an LLM Observability dataset version. + + :param value: If omitted defaults to "dataset_version". Must be one of ["dataset_version"]. + :type value: str + """ + + allowed_values = { + "dataset_version", + } + DATASET_VERSION: ClassVar["LLMObsDatasetVersionType"] + + @cached_property + def openapi_types(_): + return { + "value": (str,), + } + + +LLMObsDatasetVersionType.DATASET_VERSION = LLMObsDatasetVersionType("dataset_version") diff --git a/src/datadog_api_client/v2/model/llm_obs_dataset_versions_response.py b/src/datadog_api_client/v2/model/llm_obs_dataset_versions_response.py new file mode 100644 index 0000000000..d79104833a --- /dev/null +++ b/src/datadog_api_client/v2/model/llm_obs_dataset_versions_response.py @@ -0,0 +1,40 @@ +# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. +# This product includes software developed at Datadog (https://www.datadoghq.com/). +# Copyright 2019-Present Datadog, Inc. +from __future__ import annotations + +from typing import List, TYPE_CHECKING + +from datadog_api_client.model_utils import ( + ModelNormal, + cached_property, +) + + +if TYPE_CHECKING: + from datadog_api_client.v2.model.llm_obs_dataset_version_data import LLMObsDatasetVersionData + + +class LLMObsDatasetVersionsResponse(ModelNormal): + @cached_property + def openapi_types(_): + from datadog_api_client.v2.model.llm_obs_dataset_version_data import LLMObsDatasetVersionData + + return { + "data": ([LLMObsDatasetVersionData],), + } + + attribute_map = { + "data": "data", + } + + def __init__(self_, data: List[LLMObsDatasetVersionData], **kwargs): + """ + Response containing the active versions of an LLM Observability dataset. + + :param data: List of dataset versions. + :type data: [LLMObsDatasetVersionData] + """ + super().__init__(kwargs) + + self_.data = data diff --git a/src/datadog_api_client/v2/models/__init__.py b/src/datadog_api_client/v2/models/__init__.py index d6f7e69ecb..8adfd9864a 100644 --- a/src/datadog_api_client/v2/models/__init__.py +++ b/src/datadog_api_client/v2/models/__init__.py @@ -3425,6 +3425,13 @@ from datadog_api_client.v2.model.llm_obs_dataset_data_attributes_response import LLMObsDatasetDataAttributesResponse from datadog_api_client.v2.model.llm_obs_dataset_data_request import LLMObsDatasetDataRequest from datadog_api_client.v2.model.llm_obs_dataset_data_response import LLMObsDatasetDataResponse +from datadog_api_client.v2.model.llm_obs_dataset_draft_state_data import LLMObsDatasetDraftStateData +from datadog_api_client.v2.model.llm_obs_dataset_draft_state_data_attributes import ( + LLMObsDatasetDraftStateDataAttributes, +) +from datadog_api_client.v2.model.llm_obs_dataset_draft_state_response import LLMObsDatasetDraftStateResponse +from datadog_api_client.v2.model.llm_obs_dataset_draft_state_type import LLMObsDatasetDraftStateType +from datadog_api_client.v2.model.llm_obs_dataset_draft_state_user import LLMObsDatasetDraftStateUser from datadog_api_client.v2.model.llm_obs_dataset_record_data_response import LLMObsDatasetRecordDataResponse from datadog_api_client.v2.model.llm_obs_dataset_record_item import LLMObsDatasetRecordItem from datadog_api_client.v2.model.llm_obs_dataset_record_update_item import LLMObsDatasetRecordUpdateItem @@ -3451,6 +3458,10 @@ ) from datadog_api_client.v2.model.llm_obs_dataset_update_data_request import LLMObsDatasetUpdateDataRequest from datadog_api_client.v2.model.llm_obs_dataset_update_request import LLMObsDatasetUpdateRequest +from datadog_api_client.v2.model.llm_obs_dataset_version_data import LLMObsDatasetVersionData +from datadog_api_client.v2.model.llm_obs_dataset_version_data_attributes import LLMObsDatasetVersionDataAttributes +from datadog_api_client.v2.model.llm_obs_dataset_version_type import LLMObsDatasetVersionType +from datadog_api_client.v2.model.llm_obs_dataset_versions_response import LLMObsDatasetVersionsResponse from datadog_api_client.v2.model.llm_obs_datasets_response import LLMObsDatasetsResponse from datadog_api_client.v2.model.llm_obs_delete_annotation_queue_interactions_data_attributes_request import ( LLMObsDeleteAnnotationQueueInteractionsDataAttributesRequest, @@ -10806,6 +10817,11 @@ "LLMObsDatasetDataAttributesResponse", "LLMObsDatasetDataRequest", "LLMObsDatasetDataResponse", + "LLMObsDatasetDraftStateData", + "LLMObsDatasetDraftStateDataAttributes", + "LLMObsDatasetDraftStateResponse", + "LLMObsDatasetDraftStateType", + "LLMObsDatasetDraftStateUser", "LLMObsDatasetRecordDataResponse", "LLMObsDatasetRecordItem", "LLMObsDatasetRecordUpdateItem", @@ -10824,6 +10840,10 @@ "LLMObsDatasetUpdateDataAttributesRequest", "LLMObsDatasetUpdateDataRequest", "LLMObsDatasetUpdateRequest", + "LLMObsDatasetVersionData", + "LLMObsDatasetVersionDataAttributes", + "LLMObsDatasetVersionType", + "LLMObsDatasetVersionsResponse", "LLMObsDatasetsResponse", "LLMObsDeleteAnnotationQueueInteractionsDataAttributesRequest", "LLMObsDeleteAnnotationQueueInteractionsDataRequest", diff --git a/tests/v2/features/llm_observability.feature b/tests/v2/features/llm_observability.feature index d21a1f8048..63b64631db 100644 --- a/tests/v2/features/llm_observability.feature +++ b/tests/v2/features/llm_observability.feature @@ -417,6 +417,33 @@ Feature: LLM Observability When the request is sent Then the response status is 404 Not Found + @generated @skip @team:DataDog/ml-observability + Scenario: Get LLM Observability dataset draft state returns "Bad Request" response + Given operation "GetLLMObsDatasetDraftState" enabled + And new "GetLLMObsDatasetDraftState" request + And request contains "project_id" parameter from "REPLACE.ME" + And request contains "dataset_id" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 400 Bad Request + + @generated @skip @team:DataDog/ml-observability + Scenario: Get LLM Observability dataset draft state returns "Not Found" response + Given operation "GetLLMObsDatasetDraftState" enabled + And new "GetLLMObsDatasetDraftState" request + And request contains "project_id" parameter from "REPLACE.ME" + And request contains "dataset_id" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 404 Not Found + + @generated @skip @team:DataDog/ml-observability + Scenario: Get LLM Observability dataset draft state returns "OK" response + Given operation "GetLLMObsDatasetDraftState" enabled + And new "GetLLMObsDatasetDraftState" request + And request contains "project_id" parameter from "REPLACE.ME" + And request contains "dataset_id" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 200 OK + @generated @skip @team:DataDog/ml-observability Scenario: Get a custom evaluator configuration returns "Bad Request" response Given operation "GetLLMObsCustomEvalConfig" enabled @@ -538,6 +565,33 @@ Feature: LLM Observability When the request is sent Then the response status is 200 OK + @generated @skip @team:DataDog/ml-observability + Scenario: List LLM Observability dataset versions returns "Bad Request" response + Given operation "ListLLMObsDatasetVersions" enabled + And new "ListLLMObsDatasetVersions" request + And request contains "project_id" parameter from "REPLACE.ME" + And request contains "dataset_id" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 400 Bad Request + + @generated @skip @team:DataDog/ml-observability + Scenario: List LLM Observability dataset versions returns "Not Found" response + Given operation "ListLLMObsDatasetVersions" enabled + And new "ListLLMObsDatasetVersions" request + And request contains "project_id" parameter from "REPLACE.ME" + And request contains "dataset_id" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 404 Not Found + + @generated @skip @team:DataDog/ml-observability + Scenario: List LLM Observability dataset versions returns "OK" response + Given operation "ListLLMObsDatasetVersions" enabled + And new "ListLLMObsDatasetVersions" request + And request contains "project_id" parameter from "REPLACE.ME" + And request contains "dataset_id" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 200 OK + @generated @skip @team:DataDog/ml-observability Scenario: List LLM Observability datasets returns "Bad Request" response Given operation "ListLLMObsDatasets" enabled @@ -662,6 +716,33 @@ Feature: LLM Observability When the request is sent Then the response status is 200 OK + @generated @skip @team:DataDog/ml-observability + Scenario: Lock LLM Observability dataset draft state returns "Bad Request" response + Given operation "LockLLMObsDatasetDraftState" enabled + And new "LockLLMObsDatasetDraftState" request + And request contains "project_id" parameter from "REPLACE.ME" + And request contains "dataset_id" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 400 Bad Request + + @generated @skip @team:DataDog/ml-observability + Scenario: Lock LLM Observability dataset draft state returns "Not Found" response + Given operation "LockLLMObsDatasetDraftState" enabled + And new "LockLLMObsDatasetDraftState" request + And request contains "project_id" parameter from "REPLACE.ME" + And request contains "dataset_id" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 404 Not Found + + @generated @skip @team:DataDog/ml-observability + Scenario: Lock LLM Observability dataset draft state returns "OK" response + Given operation "LockLLMObsDatasetDraftState" enabled + And new "LockLLMObsDatasetDraftState" request + And request contains "project_id" parameter from "REPLACE.ME" + And request contains "dataset_id" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 200 OK + @generated @skip @team:DataDog/ml-observability Scenario: Push events for an LLM Observability experiment returns "Accepted" response Given operation "CreateLLMObsExperimentEvents" enabled @@ -765,6 +846,33 @@ Feature: LLM Observability When the request is sent Then the response status is 200 OK + @generated @skip @team:DataDog/ml-observability + Scenario: Unlock LLM Observability dataset draft state returns "Bad Request" response + Given operation "UnlockLLMObsDatasetDraftState" enabled + And new "UnlockLLMObsDatasetDraftState" request + And request contains "project_id" parameter from "REPLACE.ME" + And request contains "dataset_id" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 400 Bad Request + + @generated @skip @team:DataDog/ml-observability + Scenario: Unlock LLM Observability dataset draft state returns "Not Found" response + Given operation "UnlockLLMObsDatasetDraftState" enabled + And new "UnlockLLMObsDatasetDraftState" request + And request contains "project_id" parameter from "REPLACE.ME" + And request contains "dataset_id" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 404 Not Found + + @generated @skip @team:DataDog/ml-observability + Scenario: Unlock LLM Observability dataset draft state returns "OK" response + Given operation "UnlockLLMObsDatasetDraftState" enabled + And new "UnlockLLMObsDatasetDraftState" request + And request contains "project_id" parameter from "REPLACE.ME" + And request contains "dataset_id" parameter from "REPLACE.ME" + When the request is sent + Then the response status is 200 OK + @generated @skip @team:DataDog/ml-observability Scenario: Update LLM Observability dataset records returns "Bad Request" response Given operation "UpdateLLMObsDatasetRecords" enabled diff --git a/tests/v2/features/undo.json b/tests/v2/features/undo.json index e93351a7e2..f452679baf 100644 --- a/tests/v2/features/undo.json +++ b/tests/v2/features/undo.json @@ -3925,6 +3925,24 @@ "type": "idempotent" } }, + "GetLLMObsDatasetDraftState": { + "tag": "LLM Observability", + "undo": { + "type": "safe" + } + }, + "LockLLMObsDatasetDraftState": { + "tag": "LLM Observability", + "undo": { + "type": "idempotent" + } + }, + "UnlockLLMObsDatasetDraftState": { + "tag": "LLM Observability", + "undo": { + "type": "idempotent" + } + }, "ListLLMObsDatasetRecords": { "tag": "LLM Observability", "undo": { @@ -3962,6 +3980,12 @@ "type": "unsafe" } }, + "ListLLMObsDatasetVersions": { + "tag": "LLM Observability", + "undo": { + "type": "safe" + } + }, "ListLLMObsExperimentEvents": { "tag": "LLM Observability", "undo": {