# Department Boxes

## What is a Department Box?

A **department box** is a container within an agent that stores and manages items using a specific storage engine. The procedures in this section allow you to add, retrieve, remove, clean, and export items from a department box.

## Storage Engines

Department boxes support the following storage engines: **S3**, **DynamoDB**, and **OpenSearch**.

### S3

AWS S3 is ideal for storing large amounts of data where simple queries or direct retrievals are sufficient. It’s best when you don’t need complex search capabilities.

### DynamoDB

AWS DynamoDB is a good engine to use for fast key-value lookups and updates. Use DynamoDB when you need quick access to individual items.

### OpenSearch

AWS OpenSearch is designed for advanced searching and querying, including fuzzy matching, full-text search, and vector-based similarity queries. Choose OpenSearch when your use case requires sophisticated querying.

## Use Cases

### Scenario 1: Data Sharing Between Separate Runs

When you need to share data between two separate runs where parallelization can be used, department boxes provide a reliable storage mechanism.

**Example Use Case - Carrier Booking:** A customer will send in a document from which you extract information. A few days later, they send a revised document and you need to determine the differences to keep your system updated. In this scenario:

1. Store the initial document data in the department box.
2. When the revised document arrives, retrieve the original data.
3. Compare the documents to identify changes.
4. Update the department box with the revised information.

### Scenario 2: Data Retrieval

When you need to retrieve a constant data value based on other data, department boxes serve as an efficient lookup mechanism.

**Example Use Case - Location Code Lookup**: Extract a location from a document and use that location to find the corresponding location code in the department box. This is useful for:

* Address standardization
* Regional code mapping
* Regulatory compliance lookups


---

# Agent Instructions: 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.kognitos.com/legacy/legacy-experience/automation-areas/department-box.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.
