# Detect user intent

> [!WARNING]
> **Preview:** This Pre-GA product is subject to the "Pre-GA Offerings Terms" in the [Service Specific Terms](https://cloud.google.com/terms/service-terms#1), offered "as is" with limited support. See the [launch stage
> descriptions](https://cloud.google.com/products#product-launch-stages) for more details."

This page describes the
[user-intent-classification](https://github.com/rubenrgzr/nai-code-examples/tree/main/typescript-examples/user-intent-classification)
configuration pattern to effectively manage different user interactions within
an app and prevent issues like unwieldy prompts or agent confusion.

In this pattern Gemini analyzes and categorizes user queries to determine their
specific intents such as searching for information, using an application
feature, or adjusting settings.
This pattern is critical for directing users through appropriate application
flows. It helps developers avoid large, unmanageable prompts, keeping the Gemini
agent focused and effective.

Additional information and technical specifications are available in the
[README](https://github.com/rubenrgzr/nai-code-examples/blob/main/typescript-examples/user-intent-classification/README.md)
file.