> For the complete documentation index, see [llms.txt](https://docs.antsomi.com/cdp-365-user-guide-en/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.antsomi.com/cdp-365-user-guide-en/use-cases/personas/segments/how-to-create-a-dynamic-segment.md). Agents can also search and read this documentation through its [MCP server](https://docs.antsomi.com/cdp-365-user-guide-en/~gitbook/mcp).

# How to create a Dynamic Segment

## Use case:

I want to create a segment in which the customers have viewed products of Men at least 1 time in the last 30 days and compute it 6 times

## Steps:

1. On the left hand side menu, hover your mouse over **Profiles**, select **Segments**, click ![](https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FUcSCmjmVq2jiCNMHrFBH%2Fimage.png?alt=media\&token=7dcfe303-29a0-4bc1-8e3d-afdaae23ee78)and choose **Customer Segment** in the Segment data table interface&#x20;

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2F1UZCUVRI6foXaQVTcws3%2Fimage.png?alt=media&amp;token=d8dcbd6a-fdd8-4238-99e3-3571553679bf" alt=""><figcaption></figcaption></figure>

2\. **Configure Segment:**

**2.1.** Audience Name: Customer viewed Men Product in the last 30 days

**2.2.** Update Segment: Dynamic Segment - scheduled update

**2.3.** Member input method: Conditions

**2.4**. Include people that: click **Add condition,** select **Perform event**, and choose **Event Counter**

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FMqeN9eYsl752kf6YG7fB%2Fimage.png?alt=media&amp;token=fb22a3b8-99e5-4169-90a9-8a0d268da7eb" alt=""><figcaption></figcaption></figure>

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FbD3AbAN0dVTnXwZWZSdt%2Fimage.png?alt=media&amp;token=8b6a7842-756b-4528-b389-065071634ab9" alt=""><figcaption></figcaption></figure>

* Select event: View product

  Condition: greater than 1 (times)
* In any source of: Websites
* Where: Product>>product.cate\_l1

  Condition: match any of Men
* Time range: Last 30 days

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2F03sPtQT6De7PHUtmo1YC%2Fimage.png?alt=media&amp;token=6d4775eb-dd6f-4897-a17b-97a6b63ea93e" alt=""><figcaption></figcaption></figure>

**2.5.** Segment Member: No limit

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FuYlzh90TVGYVBGdmNZxN%2FCreate%20Static%20Segment%20-%20Matching%20file%20%E2%80%93%20Segment%20member.png?alt=media&amp;token=1e776f61-2eef-4806-91d1-113a73907d8f" alt=""><figcaption></figcaption></figure>

2.6. Computation Schedule:&#x20;

* Repeat by: day at 03:00 AM
* Repeat every 1 day
* Start time: 02/08/2024
* End time: after 6 occurrences

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FAH0IFAifQgVoUXihMCpI%2Fimage.png?alt=media&amp;token=ca135df8-0e4f-4ed0-8459-79239c4d44f6" alt=""><figcaption></figcaption></figure>

**2.7.** Notification Setup: Notify when the computation fails by **sending an Email and pushing a notification**

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2F2OgyOujsvgloonkq8rgG%2Fimage.png?alt=media&amp;token=0e034168-b790-4717-8a24-78c3113e8406" alt=""><figcaption></figcaption></figure>

**2.8. Forecast (optional)**

You can preview a sample of users in this audience by clicking **Forecast** on the right of the screen

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FtENV9siKsZAdSPlkXsjJ%2Fimage.png?alt=media&amp;token=4f68c789-9bf6-4137-9f70-393fae1e14d4" alt=""><figcaption></figcaption></figure>

The Forecast is:&#x20;

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FPDERqaUcZA7gWB7xqAVC%2Fimage.png?alt=media&amp;token=cdfc49a9-28b3-47a0-b1a6-9cbd2e932baf" alt=""><figcaption></figcaption></figure>

3\. Click **Save**

## The result of Segment Computation

### Computation Status

You can check the **Computation Status of the Customer viewed Men Product in the last 30 days** in the data table of the **Computation History** tab

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2FZEnvaxUrMh9kEoARNr1i%2Fimage.png?alt=media&amp;token=2b5890fa-0f8f-4bc4-8c21-172842fcb8d8" alt=""><figcaption></figcaption></figure>

### Segment information

You can find **detailed information about the Segment** by clicking Segment name - **Customer viewed Men Product in the last 30 days**

<figure><img src="https://826840553-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbtU4vFUxT5JkWYHePuoX%2Fuploads%2Fi9CUwXtZqAErISYLL0RE%2Fimage.png?alt=media&amp;token=b3bd44e6-afb5-4d82-9a38-9617418f5423" alt=""><figcaption></figcaption></figure>

{% embed url="<https://drive.google.com/file/d/181MYc8R77n0dbeRInTEz8SRw4fYJPC10/view?usp=sharing>" %}


---

# 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 by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.antsomi.com/cdp-365-user-guide-en/use-cases/personas/segments/how-to-create-a-dynamic-segment.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
