# Feature


```
@Retention(value = AnnotationRetention.SOURCE)
@IntDef(value = [1, 2, 3, 4, 5])
annotation Feature
```

<br />

*** ** * ** ***

Features (capabilities) that may be supported by a generative model.

## Summary

| ### Constants |
|---|---|
| `const https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html` | `https://developers.google.com/android/reference/kotlin/com/google/mlkit/genai/prompt/Feature#FUNCTION_CALLING() = 5` Function calling (tool use) to interact with external systems. |
| `const https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html` | `https://developers.google.com/android/reference/kotlin/com/google/mlkit/genai/prompt/Feature#PREFIX_CACHING() = 3` Prefix caching (context caching) to optimize inference latency. |
| `const https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html` | `https://developers.google.com/android/reference/kotlin/com/google/mlkit/genai/prompt/Feature#STRUCTURED_OUTPUT() = 4` Structured JSON output conforming to a schema. |
| `const https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html` | `https://developers.google.com/android/reference/kotlin/com/google/mlkit/genai/prompt/Feature#SYSTEM_PROMPT() = 1` System prompts (instructions) to guide the model's behavior. |
| `const https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html` | `https://developers.google.com/android/reference/kotlin/com/google/mlkit/genai/prompt/Feature#THINKING_MODE() = 2` Thinking mode (reasoning) for complex tasks. |

| ### Public constructors |
|---|
| `https://developers.google.com/android/reference/kotlin/com/google/mlkit/genai/prompt/Feature#Feature()()` |

## Constants

### FUNCTION_CALLING

```
const val FUNCTION_CALLING = 5: Int
```

Function calling (tool use) to interact with external systems.

### PREFIX_CACHING

```
const val PREFIX_CACHING = 3: Int
```

Prefix caching (context caching) to optimize inference latency.

### STRUCTURED_OUTPUT

```
const val STRUCTURED_OUTPUT = 4: Int
```

Structured JSON output conforming to a schema.

### SYSTEM_PROMPT

```
const val SYSTEM_PROMPT = 1: Int
```

System prompts (instructions) to guide the model's behavior.

### THINKING_MODE

```
const val THINKING_MODE = 2: Int
```

Thinking mode (reasoning) for complex tasks.

## Public constructors

### Feature

```
Feature()
```