← Explore all skills

CONTENT MODERATION / Microsoft

Azure AI Content Safety for Python

Pins Microsoft's Python Content Safety skill, which keeps new code on Entra credentials and can stop analysis when a blocklist matches.

“Azure AI Content Safety SDK for Python. Use for detecting harmful content in text and images with multi-severity classification. Triggers: "azure-ai-contentsafety", "ContentSafetyClient", "content moderation", "harmful content", "text analysis", "image analysis". ”

01 / THE REASONING

Why this made the selection.

  • New code is told to use DefaultAzureCredential, and AzureKeyCredential is limited to an existing keyed deployment that has not been migrated to Entra ID.
  • A text analysis can set halt_on_blocklist_hit so a blocklist match stops immediately, and the best-practice list says to use that for immediate rejection and to pre-moderate model output before it is shown.

02 / THE REVIEW RECORD

What we actually inspected.

Source review has boundaries.
A clear record is more useful than a “safe” badge.

Material inspected

  • .github/plugins/azure-sdk-python/skills/azure-ai-contentsafety-py/SKILL.md
  • README.md
  • .github/plugins/azure-sdk-python/README.md
  • .github/plugins/azure-sdk-python/.claude-plugin/plugin.json
  • LICENSE

Our findings

  • Production DefaultAzureCredential is constrained with AZURE_TOKEN_CREDENTIALS=prod, and API keys are avoided because they bypass Entra audit and rotation.
  • AzureKeyCredential is reserved for an existing keyed deployment that has not moved to Entra ID, and CONTENT_SAFETY_KEY is marked as only for that legacy path.
  • The blocklist analysis sample sets halt_on_blocklist_hit, and the best practices say to use it for immediate rejection.
  • The best practices say to pre-moderate AI outputs before showing them to users.
  • Sync and async Content Safety clients must not be mixed, and clients are closed with context managers so token caches are released.

Not established by this review

  • The resource was not executed and its tools were not called.
  • No text or image was analyzed and no blocklist was created or updated.
  • The referenced capability and non-hero files were not opened.
  • The azure-sdk-python plugin was not installed.
  • Not executed: it was not installed or run.

The review applies to the material and revision named here. A newer upstream release can change its behavior.

03 / PUT IT TO WORK

Add a skill to your workflow.

Upstream setup instructions ↗

DOCUMENTED COMMAND

/plugin install azure-sdk-python@skills

Copying does not execute this command. It may retrieve a newer version than the reviewed source.

  1. The azure-sdk-python plugin README shows `/plugin install azure-sdk-python@skills`. That installs the azure-sdk-python plugin, not this one file.
  2. The same README shows `npx skills add microsoft/skills --skill azure-sdk-python`, which also names the plugin rather than this file.
  3. The repository README shows `/plugin marketplace add microsoft/skills` and `/plugin install azure@skills` for a different plugin, plus `npx skills add microsoft/skills` for a repository wizard.

Before you start

  • The skill shows `pip install azure-ai-contentsafety`. This review did not run it.
  • CONTENT_SAFETY_ENDPOINT as named in the skill
  • DefaultAzureCredential through Azure CLI, VS Code, Developer CLI, or a managed identity, as the skill describes
  • CONTENT_SAFETY_KEY only for the legacy API-key path the skill limits to an unmigrated keyed deployment
  • Copilot CLI for the slash-command install line

04 / FOLLOW THE EVIDENCE

The source trail.

Our notes are separate from the original resource.
Check upstream before adopting a new version.

  1. https://github.com/microsoft/skills/blob/fc164ba1d7a0c10377dbcc1c9ac07253b9329fdb/.github/plugins/azure-sdk-python/skills/azure-ai-contentsafety-py/SKILL.md

    Supports: Entra credential preference, legacy key limit, blocklist halt, and pre-moderation

  2. https://github.com/microsoft/skills/blob/fc164ba1d7a0c10377dbcc1c9ac07253b9329fdb/.github/plugins/azure-sdk-python/README.md

    Supports: /plugin install azure-sdk-python@skills and the npx plugin install line

  3. https://github.com/microsoft/skills/blob/fc164ba1d7a0c10377dbcc1c9ac07253b9329fdb/.github/plugins/azure-sdk-python/.claude-plugin/plugin.json

    Supports: plugin name azure-sdk-python and MIT

  4. Repository README ↗Checked

    https://github.com/microsoft/skills/blob/fc164ba1d7a0c10377dbcc1c9ac07253b9329fdb/README.md

    Supports: MIT statement, Copilot CLI install, and a different azure plugin install line

  5. Repository LICENSE ↗Checked

    https://github.com/microsoft/skills/blob/fc164ba1d7a0c10377dbcc1c9ac07253b9329fdb/LICENSE

    Supports: MIT License

  6. https://raw.githubusercontent.com/microsoft/skills/fc164ba1d7a0c10377dbcc1c9ac07253b9329fdb/.github/plugins/azure-sdk-python/skills/azure-ai-contentsafety-py/SKILL.md

    Supports: upstreamDescription, access.permissions, review

Evidence & Ask