> ## Documentation Index
> Fetch the complete documentation index at: https://futureagi.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Create New Dataset

> Learn to create datasets to do experimentations on them

<CardGroup cols={2}>
  <Card title="Using SDK" icon="code" href="#using-sdk">
    Import your data using Future AGI SDK.
  </Card>

  <Card title="Upload File" icon="file-arrow-up" href="#upload-file">
    Upload CSV, JSON or JSONL files.
  </Card>

  <Card title="Synthetic Data Generation" icon="wand-magic-sparkles" href="#using-synthetic-data-generation">
    Synthetically generate data.
  </Card>

  <Card title="Manual Creation" icon="hand-pointer" href="#manually-create-dataset">
    Manually create dataset from scratch.
  </Card>

  <Card title="Import from Hugging Face" icon="grip" href="#importing-from-hugging-face">
    Import datasets directly from Hugging Face.
  </Card>

  <Card title="From Existing Dataset" icon="copy" href="#from-existing-dataset">
    Create a subset from an existing dataset.
  </Card>
</CardGroup>

***

## Using SDK

Use SDK to import your data to Future AGI.

<Steps>
  <Step title="Assign Dataset Name">
    Assign a name to your dataset and click on "Next" to proceed.

    <img src="https://mintcdn.com/futureagi/_BWZpFx7YR35DSc4/screenshot/product/dataset/how-to/create-new-dataset/1.png?fit=max&auto=format&n=_BWZpFx7YR35DSc4&q=85&s=ab6d3ac3f53ed0329c2dec93da35c3e1" alt="assign_dataset_name" width="992" height="432" data-path="screenshot/product/dataset/how-to/create-new-dataset/1.png" />
  </Step>

  <Step title="Add Rows via SDK">
    You will be greeted with a screen containing code snippet to add rows to your dataset.

    <CodeGroup>
      ```python Python theme={null}
      # pip install futureagi

      import os
      from fi.datasets import Dataset
      from fi.datasets.types import (
          Cell,
          Column,
          DatasetConfig,
          DataTypeChoices,
          ModelTypes,
          Row,
          SourceChoices,
      )

      # Set environment variables
      os.environ["FI_API_KEY"] = "<fi_api_key>"
      os.environ["FI_SECRET_KEY"] = "<fi_secret_key>"

      # Get existing dataset
      config = DatasetConfig(name="my-dataset", model_type= ModelTypes.GENERATIVE_LLM)
      dataset = Dataset(dataset_config=config)
      dataset = Dataset.get_dataset_config("my-dataset")

      # Define columns
      columns = [
          Column(
              name="user_query",
              data_type=DataTypeChoices.TEXT,
              source=SourceChoices.OTHERS
          ),
          Column(
              name="response_quality",
              data_type=DataTypeChoices.INTEGER,
              source=SourceChoices.OTHERS
          ),
          Column(
              name="is_helpful",
              data_type=DataTypeChoices.BOOLEAN,
              source=SourceChoices.OTHERS
          )
      ]

      # Define rows
      rows = [
          Row(
              order=1,
              cells=[
                  Cell(column_name="user_query", value="What is machine learning?"),
                  Cell(column_name="response_quality", value=8),
                  Cell(column_name="is_helpful", value=True)
              ]
          ),
          Row(
              order=2,
              cells=[
                  Cell(column_name="user_query", value="Explain quantum computing"),
                  Cell(column_name="response_quality", value=9),
                  Cell(column_name="is_helpful", value=True)
              ]
          )
      ]

      try:
          # Add columns and rows to dataset
          dataset = dataset.add_columns(columns=columns)
          dataset = dataset.add_rows(rows=rows)
          print("✓ Data added successfully")

      except Exception as e:
          print(f"Failed to add data: {e}")
      ```

      ```typescript Typescript theme={null}
      import { Dataset, DataTypeChoices, createRow, createCell } from "@future-agi/sdk";

      process.env["FI_API_KEY"] = "<fi_api_key>";
      process.env["FI_SECRET_KEY"] = "<fi_secret_key>";

      async function main() {
      try {
          const dsName = "my-dataset";

          // 1) Open the dataset (fetch if it exists, create if not)
          const dataset = await Dataset.open(dsName);

          // 2) Define columns
          const columns = [
          { name: "user_query", dataType: DataTypeChoices.TEXT },
          { name: "response_quality", dataType: DataTypeChoices.INTEGER },
          { name: "is_helpful", dataType: DataTypeChoices.BOOLEAN },
          ];

          // 3) Define rows
          const rows = [
          createRow({
              cells: [
              createCell({ columnName: "user_query", value: "What is machine learning?" }),
              createCell({ columnName: "response_quality", value: 8 }),
              createCell({ columnName: "is_helpful", value: true }),
              ],
          }),
          createRow({
              cells: [
              createCell({ columnName: "user_query", value: "Explain quantum computing" }),
              createCell({ columnName: "response_quality", value: 9 }),
              createCell({ columnName: "is_helpful", value: true }),
              ],
          }),
          ];

          // 4) Add columns and rows
          await dataset.addColumns(columns);
          await dataset.addRows(rows);
          console.log("✓ Data added successfully");
      } catch (err) {
          console.error("Failed to add data:", err);
      }
      }

      main();

      ```

      ```bash Curl theme={null}
      curl --request POST     --url https://api.futureagi.com/model-hub/develops/<dataset_id>/add_columns/     --header 'X-Api-Key: <fi_api_key>'     --header 'X-Secret-Key: <fi_secret_key>'     --header 'content-type: application/json'     --data '{
      "new_columns_data": [
          {
          "name": "user_query",
          "data_type": "text"
          },
          {
          "name": "response_quality",
          "data_type": "integer"
          },
          {
          "name": "is_helpful",
          "data_type": "boolean"
          }
      ]
      }'
      ```
    </CodeGroup>

    <Callout icon="key" color="#FFC107" iconType="regular">Click [here](https://app.futureagi.com/dashboard/keys) to access API Key and Secret Key.</Callout>
  </Step>
</Steps>

***

## Upload File

<Steps>
  <Step title="Upload CSV, JSON or JSONL files to create a dataset.">
    <img src="https://mintcdn.com/futureagi/_BWZpFx7YR35DSc4/screenshot/product/dataset/how-to/create-new-dataset/2.png?fit=max&auto=format&n=_BWZpFx7YR35DSc4&q=85&s=5ca93551ac4648c742d2a26863c8118d" alt="upload_file" width="1182" height="884" data-path="screenshot/product/dataset/how-to/create-new-dataset/2.png" />
  </Step>
</Steps>

***

## Using Synthetic Data Generation

Synthetically generate data and perform experimentations on it.

<Steps>
  <Step title="Add Details">
    Provide basic details about the dataset you want to generate.

    <img src="https://mintcdn.com/futureagi/_BWZpFx7YR35DSc4/screenshot/product/dataset/how-to/create-new-dataset/3.png?fit=max&auto=format&n=_BWZpFx7YR35DSc4&q=85&s=32f1445b9a6b53adb5dc118249d08b2e" alt="add_details" width="2462" height="1596" data-path="screenshot/product/dataset/how-to/create-new-dataset/3.png" />

    | Property                  | Description                                                                                                                                                                                                                                              |
    | ------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | Name                      | Name of the dataset                                                                                                                                                                                                                                      |
    | Knowledge Base (optional) | Select which <Tooltip tip="Useful for grounded, context-aware synthetic data generation and accurate evaluations." cta="Learn more about knowledge base" href="/future-agi/get-started/knowledge-base/concept">knowledge base</Tooltip> you want to use. |
    | Description               | Describe the dataset you want to generate                                                                                                                                                                                                                |
    | Objective (optional)      | Use case of the dataset                                                                                                                                                                                                                                  |
    | Pattern (optional)        | Style, tone or behavioral traits of the generated dataset                                                                                                                                                                                                |
    | No. of Rows               | Row count of the generated dataset (min 10 rows)                                                                                                                                                                                                         |
  </Step>

  <Step title="Add Column Properties">
    Define column types and properties

    <img src="https://mintcdn.com/futureagi/_BWZpFx7YR35DSc4/screenshot/product/dataset/how-to/create-new-dataset/4.png?fit=max&auto=format&n=_BWZpFx7YR35DSc4&q=85&s=04986d933d6a4d3e03af610c8915fe99" alt="add_column_properties" width="1664" height="898" data-path="screenshot/product/dataset/how-to/create-new-dataset/4.png" />

    | Property    | Description                                                                                            |
    | ----------- | ------------------------------------------------------------------------------------------------------ |
    | Column Name | Name of the column                                                                                     |
    | Column Type | Choose the type of the column (available types: text, boolean, integer, float,  json, array, datetime) |
  </Step>

  <Step title="Add Description">
    Now add description for each column. Describe in detail what values you want in this column.

    <img src="https://mintcdn.com/futureagi/_BWZpFx7YR35DSc4/screenshot/product/dataset/how-to/create-new-dataset/5.png?fit=max&auto=format&n=_BWZpFx7YR35DSc4&q=85&s=5b55e04d66705408bbd7991ae6acb31d" alt="add_column_description" width="1664" height="898" data-path="screenshot/product/dataset/how-to/create-new-dataset/5.png" />
  </Step>

  <Step title="Create Dataset">
    Click on "Create Dataset" button to generate the dataset. Your synthetic dataset will be generated in a few seconds and will be available in your dataset [dashboard](https://app.futureagi.com/dashboard/develop).

    If you are not satisfied with the generated dataset, you can click on "Configure Synthetic Data" button. It will allow you to edit the fields and generate the dataset again.

    <img src="https://mintcdn.com/futureagi/_BWZpFx7YR35DSc4/screenshot/product/dataset/how-to/create-new-dataset/6.png?fit=max&auto=format&n=_BWZpFx7YR35DSc4&q=85&s=b62ee0b3a29e1869ef77ea0a2a8f7f2a" alt="create_dataset" width="2598" height="1314" data-path="screenshot/product/dataset/how-to/create-new-dataset/6.png" />

    <img src="https://mintcdn.com/futureagi/_BWZpFx7YR35DSc4/screenshot/product/dataset/how-to/create-new-dataset/7.png?fit=max&auto=format&n=_BWZpFx7YR35DSc4&q=85&s=f27f36fa412d7a2dc3c455a00c0fcb4f" alt="configure_synthetic_data" width="2616" height="1464" data-path="screenshot/product/dataset/how-to/create-new-dataset/7.png" />
  </Step>
</Steps>

***

## Manually Create Dataset

Manually create dataset from scratch.

<Steps>
  <Step title="Provide Basic Details">
    To proceed with creating dataset manually from scratch, provdide the name you want to assign and the number of columns and rows you want.

    <img src="https://mintcdn.com/futureagi/_BWZpFx7YR35DSc4/screenshot/product/dataset/how-to/create-new-dataset/8.png?fit=max&auto=format&n=_BWZpFx7YR35DSc4&q=85&s=566928a71d2a35dad33f579550577418" alt="manually" width="944" height="648" data-path="screenshot/product/dataset/how-to/create-new-dataset/8.png" />

    You will be greeted with an empty dataset with the name you assigned and with empty rows and columns.

    <img src="https://mintcdn.com/futureagi/_BWZpFx7YR35DSc4/screenshot/product/dataset/how-to/create-new-dataset/9.png?fit=max&auto=format&n=_BWZpFx7YR35DSc4&q=85&s=31f158f1eed5f1f33acbdf02079abc7a" alt="empty_dataset" width="2612" height="1488" data-path="screenshot/product/dataset/how-to/create-new-dataset/9.png" />
  </Step>

  <Step title="Populating the dataset">
    You can populate the dataset by double-tapping over the empty cell you want to populate. It will open an editor where you can provide the details you want to fill in that cell.

    <img src="https://mintcdn.com/futureagi/_BWZpFx7YR35DSc4/screenshot/product/dataset/how-to/create-new-dataset/10.png?fit=max&auto=format&n=_BWZpFx7YR35DSc4&q=85&s=14e8d9c8239eb82c665b7f141998370c" alt="populate_dataset" width="2612" height="1488" data-path="screenshot/product/dataset/how-to/create-new-dataset/10.png" />
  </Step>
</Steps>

## Importing from Hugging Face

<Steps>
  <Step title="Search Hugging Face Dataset">
    Search for the dataset you want to import from Hugging Face. You can even refine the search by using flters given on left side.

    <img src="https://mintcdn.com/futureagi/_BWZpFx7YR35DSc4/screenshot/product/dataset/how-to/create-new-dataset/11.png?fit=max&auto=format&n=_BWZpFx7YR35DSc4&q=85&s=32f2ce3e71579d853d89f3c0d7bf2a85" alt="search_hugging_face_dataset" width="2612" height="1488" data-path="screenshot/product/dataset/how-to/create-new-dataset/11.png" />
  </Step>

  <Step title="Import Dataset">
    Once you have selected the dataset you want to import, click on that dataset and it will open a panel where you can select what subset and split you want to import.

    You can also select the number of rows you want to import. By default, it will import all the rows.

    <img src="https://mintcdn.com/futureagi/_BWZpFx7YR35DSc4/screenshot/product/dataset/how-to/create-new-dataset/12.png?fit=max&auto=format&n=_BWZpFx7YR35DSc4&q=85&s=00964ec801e46b5c975805a3e041614b" alt="import_dataset" width="2612" height="1488" data-path="screenshot/product/dataset/how-to/create-new-dataset/12.png" />

    Click on "Start Experimenting" button and it willl start importing the dataset and you will be able to see it in your dataset [dashboard](https://app.futureagi.com/dashboard/develop).
  </Step>
</Steps>

***

## From Existing Dataset

You can create a subset from an existing dataset.

<Steps>
  <Step title="Choose the existing dataset">
    Assign a name to this dataset and choose the existing dataset from the dropdown you want to create a subset from.

    <img src="https://mintcdn.com/futureagi/_BWZpFx7YR35DSc4/screenshot/product/dataset/how-to/create-new-dataset/13.png?fit=max&auto=format&n=_BWZpFx7YR35DSc4&q=85&s=a8e93e2281ba99e319c921a94204e2e3" alt="choose_existing_dataset" width="2152" height="1488" data-path="screenshot/product/dataset/how-to/create-new-dataset/13.png" />

    It allows you to import the dataset in two ways:

    1. Import Data: It will only import the original columns from the existing dataset.
    2. Import Data and Prompt Configuration: Along with original column, it will also import the prompt columns from that dataset.
  </Step>

  <Step title="Map the columns">
    You can choose what columns you want to use from that existing dataset and also you can assign a new name to the columns you want to use.

    <img src="https://mintcdn.com/futureagi/_BWZpFx7YR35DSc4/screenshot/product/dataset/how-to/create-new-dataset/14.png?fit=max&auto=format&n=_BWZpFx7YR35DSc4&q=85&s=0cd6a4fb57518de5683db39fc1c08ec7" alt="map_columns" width="2152" height="1488" data-path="screenshot/product/dataset/how-to/create-new-dataset/14.png" />
  </Step>

  <Step title="Import the dataset">
    Click on "Add" button and it will create a new dataset in your dataset [dashboard](https://app.futureagi.com/dashboard/develop).
  </Step>
</Steps>
