> For the complete documentation index, see [llms.txt](https://docs.datasaur.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.datasaur.ai/advanced/extensions/bounding-box-labels.md).

# Bounding Box Labels

The **Bounding box labels** extension is a core extension for bounding box labeling projects. It contains the label set (taxonomy) used for labeling.

You can add a label set in two ways:

* Upload a label set with a `.csv` , `.tsv` or `.json` format.
* Enter the labels in manually.

<figure><img src="/files/WNeAnvT03eEc0li3DAK4" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
In the project, you can also click a label instance to jump directly to its corresponding bounding box and open the label box for that item.
{% endhint %}

## Label set modification

If you created a project without a label set, you can add one anytime by:

* Dragging and dropping a label set file.
* Using the three-dot menu.

<figure><img src="/files/lpErsy021nLoNBjpQc4x" alt=""><figcaption></figcaption></figure>

To edit an existing label set, click the three-dot menu and select **Edit label set.**

<figure><img src="/files/edjMi90mw8N7dZiNY9mu" alt=""><figcaption></figcaption></figure>

The **Edit label set** dialog will open, allowing you to update the label classes and their configuration.

<figure><img src="/files/sprYc4OVHpmr6Fq7xTYd" alt=""><figcaption></figcaption></figure>

To replace the current label set, click the three-dot menu and select **Replace existing label set.**

<figure><img src="/files/edjMi90mw8N7dZiNY9mu" alt=""><figcaption></figcaption></figure>

You can then upload a new label set file or create it from scratch.

<figure><img src="/files/2evC7i2LpSd3P0XWayFv" alt=""><figcaption></figcaption></figure>

### Permissions

By default, both reviewers and labelers can modify label sets. To restrict this capability for labelers:

1. Go to **File > Settings > Administrator.**
2. Disable the **Label set modification** option.

<figure><img src="/files/WLdjWAKdyI5aaM39UIuR" alt=""><figcaption></figcaption></figure>

## Custom attributes for label classes

Each label class can include multiple custom attributes (questions). The question types are limited to [text](https://docs.datasaur.ai/advanced/extensions/pages/sjMjHjQsHtR5BrPf3PUF#id-1.-text-field) and [dropdown](https://docs.datasaur.ai/advanced/extensions/pages/sjMjHjQsHtR5BrPf3PUF#id-3.-dropdown). Each question can have a default answer.

To update custom attributes in a label set:

1. Open the label set editor.

   ![](/files/sprYc4OVHpmr6Fq7xTYd)
2. Switch to the **JSON** tab.

   ![](/files/JPt3rNIbnrwZWF3zLeVX)
3. Add or modify the <mark style="color:red;">`questions`</mark> field for the desired label class.

{% hint style="info" %}
Modifying the `type` or `internalId` of existing questions is not supported because it can affect previously applied labels unexpectedly.
{% endhint %}

#### Question structure

The <mark style="color:red;">`questions`</mark> field can contain multiple questions with the following properties:

1. **id**: ID of the question.
2. **label**: The question name.
3. **type**: The type of question. It can be <mark style="color:red;">`TEXT`</mark> or <mark style="color:red;">`DROPDOWN`</mark>.
4. **config**: Configuration settings for the question.
   1. **required**: Determines whether the question must be answered. It can be <mark style="color:red;">`true`</mark> or <mark style="color:red;">`false`</mark>.
   2. **defaultValue**: The default answer for the question.
      1. For <mark style="color:red;">`TEXT`</mark> questions, it can be any text.
      2. For <mark style="color:red;">`DROPDOWN`</mark> questions, it must be an <mark style="color:red;">`options.id`</mark> value.
   3. **multiline**: Specifies if the <mark style="color:red;">`TEXT`</mark> question allows multiple lines. It can be <mark style="color:red;">`true`</mark> or <mark style="color:red;">`false`</mark>.
   4. **options**: An array of options for the <mark style="color:red;">`DROPDOWN`</mark> question, each containing:
      1. **id**: ID of the dropdown option. It can be used in the <mark style="color:red;">`defaultValue`</mark>.
      2. **label**: The text label for the dropdown option.
5. **internalId**: Read-only unique ID used internally by Datasaur.

{% hint style="info" %}
For a detailed example, refer to the [Label Sets](/data-studio-projects/lets-get-labeling/bounding-box-labeling.md#label-sets) documentation for a sample bounding box label set with custom attributes.
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.datasaur.ai/advanced/extensions/bounding-box-labels.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
