# Cost Control

### Core Concepts

| Term                   | Definition                                                                                                                                                         |
| ---------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| **Compute Block (CB)** | The unit that measures resource consumption on the platform. Every action - such as sending a chat message or uploading a file - consumes a defined number of CBs. |
| **CB Limit**           | The maximum number of Compute Blocks a user may consume within a given timeframe.                                                                                  |
| **Timeframe**          | The period over which CB consumption is counted and reset - either Daily, Weekly, or Monthly.                                                                      |
| **Hard Limit**         | A strict enforcement mechanism. Once the CB limit is reached, no further CB-consuming actions are possible until the limit is increased by an admin.               |
| **Default Limit**      | A system-wide CB limit that applies to all users unless an individual override is set.                                                                             |

> The feature is disabled by default. Administrators must turn in on in order to use the Compute Block Limit.

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

### Admin Configuration

#### Default CB Limit

Administrators configure a **default limit** that applies to all users globally. This limit consists of two parameters:

| Parameter          | Default Value | Available Options        |
| ------------------ | ------------- | ------------------------ |
| **Compute Blocks** | 500.000       | Any custom numeric value |
| **Timeframe**      | Monthly       | Daily / Weekly / Monthly |

> The default limit is the baseline for every user account. It takes effect unless an individual override is configured for a specific user.

***

#### Per-User Limit Override

Admins can override the default limit for any individual user directly in **User Management**. Two columns are available per user:

* **Compute Blocks** - the maximum CB allowance for that user
* **Timeframe** - the reset period for that user's limit

**To override a user's limit:**

1. Go to **User Management**.
2. Find the user in the list.
3. Edit the **Compute Blocks** and **Timeframe** values in that user's row.
4. Save your changes.

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

> An individual user's limit always takes **precedence** over the global default limit.

***

#### Custom Notification Message

When a user hits their CB limit, a popup notification is displayed. Admins can define the **text content** of this message.

The popup automatically includes:

* The admin-defined message text
* The user's assigned CB limit
* The active timeframe

**Example admin-defined message:**

> *"You have reached your usage limit. To request an increase, please contact* [*admin@yourcompany.com*](mailto:admin@yourcompany.com)*."*

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

***

#### Adjusting Limits

CB limits can be updated at any time in **User Management** - both the default limit and individual user overrides. Changes take effect **immediately** upon saving.

***

### User-Facing Behavior

#### Usage Visibility

Users can monitor their CB consumption in their **User Profile**. Usage is displayed as a **progress bar**, showing:

* Total CBs consumed in the current timeframe
* The assigned CB limit

***

#### Limit Enforcement

Once a user's CB limit is reached, the following behavior is triggered:

1. A **popup notification** appears, displaying:
   * The administrator's custom message
   * The user's limit and timeframe
2. The popup can be **dismissed**, but will **re-appear** every time the user attempts to:
   * Open or interact with a **Chat form**
   * Upload files in **Knowledge Management**
3. All CB-consuming actions are **fully blocked** until the admin increases the limit.

> The user can still freely **navigate** the platform. Only actions that consume Compute Blocks are restricted.

***

#### Regaining Access

Users **cannot self-service** a limit increase. To regain full access:

* Contact your administrator and request a CB limit adjustment.
* Once the admin increases the limit, access is **restored immediately**.


---

# 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.blockbrain.ai/for-admins/cost-control.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.
