# Update Dataset Update a dataset. In order to use a dataset in a model training, its status must be set to completed. Once a dataset status is changed to completed: * Images cannot be added or removed * Image captions cannot be edited * Caption prefix cannot be modified If the caption prefix needs to be changed, update it here first, then use the endpoint to refresh all captions with the new prefix. If you want to generate an advanced , use the endpoint before updating the dataset. It is recommended to use the route Clone Dataset As Draft in order to create a new version of a dataset. Constraints: * Cannot update caption_prefix if dataset status is completed * Dataset must have at least 1 image to be marked as completed Endpoint: PUT /tailored-gen/datasets/{dataset_id} ## Path parameters: - `dataset_id` (string, required) Dataset ID ## Header parameters: - `api_token` (string, required) ## Request fields (application/json): - `name` (string) New dataset name (optional) - `caption_prefix` (string) New caption prefix (optional). Cannot be updated if dataset status is completed. If the user has updated the caption prefix, it is crucial to Regenerate All Captions using the endpoint PUT /datasets/{dataset_id}/images/. Use to generate an advanced prefix. - `status` (string) Dataset status (optional). Can be set to completed to enable usage in model training Enum: "draft", "completed" ## Response 200 fields (application/json): - `id` (integer) Unique identifier for the dataset - `project_id` (integer) Associated project ID - `name` (string) Dataset name - `caption_prefix` (string) Text automatically prepended to all image captions in the dataset. Each image caption should naturally continues this prefix. A default prefix is automatically created but can be modified, and this same prefix is later used as the default generation prefix during image generation. - `status` (string) Status of the dataset Enum: "draft", "completed" - `captions_update_status` (string) Status of captions update process Enum: "empty", "in_progress", "completed" - `upload_type` (string) The method used to upload images to the dataset. 'basic' is the default. Enum: "basic", "advanced" - `captions_source` (string) The source of the captions. For 'basic' datasets, this is a null. For 'advanced' datasets, this indicates if captions were generated 'automatic' or provided 'manual'. Enum: "automatic", "manual" - `created_at` (string) Timestamp when the dataset was created - `updated_at` (string) Timestamp when the dataset was last updated ## Response 409 fields (application/json): - `message` (string) Error message explaining the conflict