> ## Documentation Index
> Fetch the complete documentation index at: https://docs.gp.scale.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Create Evaluation Dataset

> ### Description
Creates a evaluation dataset

### Details
This API can be used to create a evaluation dataset. To use this API, review the request schema and pass in all fields that are required to create a evaluation dataset.



## OpenAPI

````yaml https://app.stainlessapi.com/api/spec/documented/sgp/openapi.yml post /v4/evaluation-datasets
openapi: 3.1.0
info:
  title: EGP API V4
  description: >-
    This is the parent API for all EGP APIs. If you are looking for the EGP API,
    please go to https://api.egp.scale.com/docs.
  contact:
    name: Scale Generative AI Platform
    url: https://scale.com/genai-platform
  version: 0.1.0
servers:
  - url: https://api.egp.scale.com
security: []
tags:
  - name: Models
    description: Model API.
paths:
  /v4/evaluation-datasets:
    post:
      tags:
        - Evaluation Datasets
      summary: Create Evaluation Dataset
      description: >-
        ### Description

        Creates a evaluation dataset


        ### Details

        This API can be used to create a evaluation dataset. To use this API,
        review the request schema and pass in all fields that are required to
        create a evaluation dataset.
      operationId: POST-V4-/evaluation-datasets
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateEvaluationDatasetRequest'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/EvaluationDatasetResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      x-codeSamples:
        - lang: Python
          source: |-
            import os
            from scale_gp import SGPClient

            client = SGPClient(
                api_key=os.environ.get("SGP_API_KEY"),  # This is the default and can be omitted
            )
            evaluation_dataset = client.evaluation_datasets.create(
                account_id="account_id",
                name="name",
                schema_type="GENERATION",
            )
            print(evaluation_dataset.id)
        - lang: Go
          source: "package main\n\nimport (\n\t\"context\"\n\t\"fmt\"\n\n\t\"github.com/stainless-sdks/sgp-go\"\n\t\"github.com/stainless-sdks/sgp-go/option\"\n)\n\nfunc main() {\n\tclient := sgp.NewClient(\n\t\toption.WithAPIKey(\"My API Key\"),\n\t)\n\tevaluationDataset, err := client.EvaluationDatasets.New(context.TODO(), sgp.EvaluationDatasetNewParams{\n\t\tBody: sgp.EvaluationDatasetNewParamsBodyManualEvaluationDatasetRequest{\n\t\t\tAccountID:  sgp.F(\"account_id\"),\n\t\t\tName:       sgp.F(\"name\"),\n\t\t\tSchemaType: sgp.F(sgp.EvaluationDatasetNewParamsBodyManualEvaluationDatasetRequestSchemaTypeGeneration),\n\t\t\tType:       sgp.F(sgp.EvaluationDatasetNewParamsBodyManualEvaluationDatasetRequestTypeManual),\n\t\t},\n\t})\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\tfmt.Printf(\"%+v\\n\", evaluationDataset.ID)\n}\n"
components:
  schemas:
    CreateEvaluationDatasetRequest:
      oneOf:
        - $ref: '#/components/schemas/ManualEvaluationDatasetRequest'
        - $ref: '#/components/schemas/AutoGeneratedEvaluationDatasetRequest'
        - $ref: '#/components/schemas/SafetyEvaluationDatasetRequest'
      title: CreateEvaluationDatasetRequest
      discriminator:
        propertyName: type
        mapping:
          autogenerated:
            $ref: '#/components/schemas/AutoGeneratedEvaluationDatasetRequest'
          manual:
            $ref: '#/components/schemas/ManualEvaluationDatasetRequest'
          safety:
            $ref: '#/components/schemas/SafetyEvaluationDatasetRequest'
    EvaluationDatasetResponse:
      properties:
        name:
          type: string
          title: Name
          description: The name of the dataset
        schema_type:
          $ref: '#/components/schemas/EvaluationDatasetORMSchemaTypeEnum'
          description: The schema type of the dataset.
        knowledge_base_id:
          title: Knowledge Base Id
          description: >-
            ID of the knowledge base that the evaluation dataset is associated
            with.
          can_patch: false
          type: string
        evaluation_dataset_metadata:
          title: Evaluation Dataset Metadata
          description: Metadata about the Evaluation Dataset that it is associated with
          can_patch: false
          additionalProperties: true
          type: object
        out_of_date:
          title: Out Of Date
          description: >-
            Boolean to check whether or not the knowledge base has been uploaded
            to since publication of the dataset.
          can_patch: false
          type: boolean
        vendor:
          $ref: '#/components/schemas/EvaluationDatasetVendor'
          description: >-
            The vendor of the evaluation dataset (e.g. 'Scale' for Scale
            off-the-shelf datasets). Null if the evaluation dataset is not from
            a vendor (e.g., is created by the customer).
        id:
          type: string
          title: Id
          description: The unique identifier of the entity.
        created_at:
          type: string
          format: date-time
          title: Created At
          description: The date and time when the entity was created in ISO format.
        updated_at:
          type: string
          format: date-time
          title: Updated At
          description: The date and time when the entity was last updated in ISO format.
        account_id:
          type: string
          title: Account Id
          description: The ID of the account that owns the given entity.
          can_patch: false
        created_by_user_id:
          type: string
          title: Created By User Id
          description: The user who originally created the entity.
        created_by_identity_type:
          $ref: '#/components/schemas/IdentifierTypeEnum'
          description: The type of identity that created the entity.
        archived_at:
          title: Archived At
          description: The date and time when the entity was archived in ISO format.
          type: string
          format: date-time
        schema_sub_type:
          $ref: '#/components/schemas/EvaluationDatasetSchemaSubType'
      type: object
      required:
        - name
        - schema_type
        - id
        - created_at
        - updated_at
        - account_id
        - created_by_user_id
        - created_by_identity_type
      title: EvaluationDatasetResponse
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ManualEvaluationDatasetRequest:
      properties:
        type:
          type: string
          const: manual
          title: Type
          description: Manually or automatically generated dataset
          default: manual
        name:
          type: string
          title: Name
          description: The name of the dataset
        schema_type:
          $ref: '#/components/schemas/EvaluationDatasetORMSchemaTypeEnum'
          description: The schema type of the dataset
        account_id:
          type: string
          title: Account Id
          description: The ID of the account that owns the given entity.
          can_patch: false
      type: object
      required:
        - name
        - schema_type
        - account_id
      title: ManualEvaluationDatasetRequest
    AutoGeneratedEvaluationDatasetRequest:
      properties:
        type:
          type: string
          const: autogenerated
          title: Type
          description: Manually or automatically generated dataset
          default: autogenerated
        name:
          type: string
          title: Name
          description: The name of the dataset
        schema_type:
          type: string
          const: GENERATION
          title: Schema Type
          description: >-
            The schema type of the dataset. Only GENERATION is currently
            supported.
        knowledge_base_id:
          title: Knowledge Base Id
          description: ID of the knowledge base to generate the evaluation dataset from.
          type: string
        account_id:
          type: string
          title: Account Id
          description: The ID of the account that owns the given entity.
          can_patch: false
      type: object
      required:
        - name
        - schema_type
        - knowledge_base_id
        - account_id
      title: AutoGeneratedEvaluationDatasetRequest
    SafetyEvaluationDatasetRequest:
      properties:
        type:
          type: string
          const: safety
          title: Type
          description: Manually or automatically generated dataset
          default: safety
        name:
          type: string
          title: Name
          description: The name of the dataset
        schema_type:
          type: string
          const: GENERATION
          title: Schema Type
          description: >-
            The schema type of the dataset. Only GENERATION is currently
            supported.
        account_id:
          type: string
          title: Account Id
          description: The ID of the account that owns the given entity.
          can_patch: false
        harms_list:
          items:
            type: string
          type: array
          title: Harms List
          description: List of harms to generate the dataset for.
        advanced_config:
          additionalProperties:
            items:
              type: string
            type: array
          type: object
          title: Advanced Config
          description: Advanced configuration for the safety evaluation dataset.
      type: object
      required:
        - name
        - schema_type
        - account_id
        - harms_list
        - advanced_config
      title: SafetyEvaluationDatasetRequest
    EvaluationDatasetORMSchemaTypeEnum:
      type: string
      enum:
        - GENERATION
        - FLEXIBLE
      title: EvaluationDatasetORMSchemaTypeEnum
    EvaluationDatasetVendor:
      type: string
      enum:
        - scale
      title: EvaluationDatasetVendor
    IdentifierTypeEnum:
      type: string
      enum:
        - user
        - service_account
      title: IdentifierTypeEnum
    EvaluationDatasetSchemaSubType:
      type: string
      enum:
        - summarization
        - translation
      title: EvaluationDatasetSchemaSubType
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
          additionalProperties: true
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError

````