Skip to content

Creates a new dataset resource asynchronously

Description

Creates a new dataset resource asynchronously. Returns immediately with status CREATING. Poll get_dataset until status transitions to ACTIVE or CREATE_FAILED.

Usage

bedrockagentcorecontrol_create_dataset(clientToken, datasetName,
  description, source, schemaType, kmsKeyArn, tags)

Arguments

  • clientToken

    A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If you don't specify this field, a value is randomly generated for you. If this token matches a previous request, the service ignores the request, but doesn't return an error. For more information, see Ensuring idempotency.

  • datasetName

    [required] Human-readable name for the dataset. Must be unique within the account. Immutable after creation.

  • description

    A description of the dataset.

  • source

    [required] Source of initial examples. Provide either inline examples or an S3 URI pointing to a JSONL file.

  • schemaType

    [required] Versioned schema type governing the structure of examples. Immutable after creation.

  • kmsKeyArn

    Optional KMS key ARN for server-side encryption on service Amazon S3 writes.

  • tags

    A map of tag keys and values to assign to the dataset.

Value

A list with the following syntax:

list(
  datasetArn = "string",
  datasetId = "string",
  status = "CREATING"|"UPDATING"|"DELETING"|"ACTIVE"|"CREATE_FAILED"|"UPDATE_FAILED"|"DELETE_FAILED",
  createdAt = as.POSIXct(
    "2015-01-01"
  )
)

Request syntax

svc$create_dataset(
  clientToken = "string",
  datasetName = "string",
  description = "string",
  source = list(
    inlineExamples = list(
      examples = list(
        list()
      )
    ),
    s3Source = list(
      s3Uri = "string"
    )
  ),
  schemaType = "AGENTCORE_EVALUATION_PREDEFINED_V1"|"AGENTCORE_EVALUATION_SIMULATED_V1"|"THIRD_PARTY_EVALUATION_V1",
  kmsKeyArn = "string",
  tags = list(
    "string"
  )
)