---
title: "Label spec using JSON"
slug: "create-spec-json"
updated: 2025-08-18T12:13:34Z
published: 2025-08-18T12:13:34Z
canonical: "docs.akridata.ai/create-spec-json"
---

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

# Label spec using JSON

In addition to creating label specs using text prompts and images, you can import a JSON file to create a base spec that can be edited further. This article explains how to create a spec using JSON.

## Load basic JSON to initiate a label spec

This option lets you download a sample JSON file and update the file in the given structure/format.

1. Navigate to **Labeling** > **Specs**.
2. Click the drop-down arrow adjacent to the **Add Spec** button, and click **Load JSON**. ![](https://cdn.document360.io/3e9d4528-fbc6-4948-a804-8ee7068e7ac3/Images/Documentation/label-spec-load-json(1).jpg)
3. In the **Load JSON** window, click the **Sample JSON** option to download the sample file to your local folder. ![](https://cdn.document360.io/3e9d4528-fbc6-4948-a804-8ee7068e7ac3/Images/Documentation/load-json-window.jpg) A sample JSON file gets downloaded with the class definition, as shown below: ![](https://cdn.document360.io/3e9d4528-fbc6-4948-a804-8ee7068e7ac3/Images/Documentation/sample-json-file.jpg)
4. Update the file with the class details in the same format. You can add more than one class if needed.
5. In the **Load JSON** screen, click the attachment icon to browse the updated file, double-click to attach the file, and click **Proceed**. ![](https://cdn.document360.io/3e9d4528-fbc6-4948-a804-8ee7068e7ac3/Images/Documentation/load-json-attachment.jpg)
6. Select the **Spec Type** as **Classification** or **Detection**, and click Submit. The label spec gets populated with the classes defined in the sample JSON file.
7. Make any other necessary changes and approve the classes.
8. Save the label spec with a name.

## Import JSON to create label specs

If you have already created a label spec, you can import the JSON file of the spec and create a new spec.

1. Navigate to **Label** > **Specs**.
2. Locate the spec for which you want to download the JSON, and click **View**.
3. On the spec page, click the **Download Spec JSON** button at the bottom-right corner. ![](https://cdn.document360.io/3e9d4528-fbc6-4948-a804-8ee7068e7ac3/Images/Documentation/label-spec-import-json.jpg) The JSON file for the spec gets downloaded to your local folder.
4. In the Labeling Specs page, click the drop-down arrow adjacent to the **Add Spec** button, and click **Import Spec**. ![](https://cdn.document360.io/3e9d4528-fbc6-4948-a804-8ee7068e7ac3/Images/Documentation/label-import-spec.jpg)
5. In the **Import Spec** screen, click the attachment icon to browse to the updated file, double-click to attach the file, and click **Proceed**. ![](https://cdn.document360.io/3e9d4528-fbc6-4948-a804-8ee7068e7ac3/Images/Documentation/label-import-spec-window.jpg)
6. Select the **Spec Type** as **Classification** or **Detection**, as needed, and click **Submit**. ![](https://cdn.document360.io/3e9d4528-fbc6-4948-a804-8ee7068e7ac3/Images/Documentation/json-spec-type.jpg) A **New Spec** page appears with the classes populated as available in the imported spec JSON file.

> [!NOTE]
> Note that no images are imported to the new spec in this process.
7. Make any necessary changes to the classes or other details.
8. Once all classes are approved, click **Save** to save the label spec with a name.
