Class HarmBlockThreshold (2.37.0)
Stay organized with collections
Save and categorize content based on your preferences.
HarmBlockThreshold(value)
Harm block thresholds for the safety settings.
Enums |
| Name |
Description |
HARM_BLOCK_THRESHOLD_UNSPECIFIED |
The harm block threshold is unspecified. |
BLOCK_LOW_AND_ABOVE |
Block content with a low harm probability or higher. |
BLOCK_MEDIUM_AND_ABOVE |
Block content with a medium harm probability or higher. |
BLOCK_ONLY_HIGH |
Block content with a high harm probability. |
BLOCK_NONE |
Do not block any content, regardless of its harm probability. |
OFF |
Turn off the safety filter entirely. |
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2026-06-23 UTC.
[null,null,["Last updated 2026-06-23 UTC."],[],[]]