View source: R/content-safety-extra.R
| foundry_protected_material | R Documentation |
Call the Azure AI Content Safety protected-material detector.
foundry_protected_material(
text,
endpoint = NULL,
api_key = NULL,
api_version = "2024-09-01"
)
text |
Character vector. |
endpoint |
Character. Optional Content Safety endpoint. |
api_key |
Character. Optional Content Safety key. |
api_version |
Character. API version. Defaults to |
A tibble with one row per input text.
# Requires a configured Azure Content Safety endpoint and credentials.
if (interactive() &&
nzchar(Sys.getenv("AZURE_CONTENT_SAFETY_ENDPOINT")) &&
nzchar(Sys.getenv("AZURE_CONTENT_SAFETY_KEY"))) {
foundry_protected_material("A short text sample.")
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.