# GroundingSpec

- [JSON representation](https://docs.cloud.google.com/gemini/enterprise/docs/reference/rest/v1alpha/GroundingSpec#SCHEMA_REPRESENTATION)
- [FilteringLevel](https://docs.cloud.google.com/gemini/enterprise/docs/reference/rest/v1alpha/GroundingSpec#FilteringLevel)

Grounding specification.

| JSON representation |
|---|
| ``` { "includeGroundingSupports": boolean, "filteringLevel": enum (`https://docs.cloud.google.com/gemini/enterprise/docs/reference/rest/v1alpha/GroundingSpec#FilteringLevel`) } ``` |

| Fields ||
|---|---|
| `includeGroundingSupports` | `boolean` Optional. Specifies whether to include groundingSupports in the answer. The default value is `false`. When this field is set to `true`, returned answer will have `groundingScore` and will contain GroundingSupports for each claim. |
| `filteringLevel` | ``enum (`https://docs.cloud.google.com/gemini/enterprise/docs/reference/rest/v1alpha/GroundingSpec#FilteringLevel`)`` Optional. Specifies whether to enable the filtering based on grounding score and at what level. |

## FilteringLevel

Level to filter based on answer grounding.

| Enums ||
|---|---|
| `FILTERING_LEVEL_UNSPECIFIED` | Default is no filter |
| `FILTERING_LEVEL_LOW` | Filter answers based on a low threshold. |
| `FILTERING_LEVEL_HIGH` | Filter answers based on a high threshold. |