Member-only story
How to Create an Azure OpenAI Content Filter Policy with Terraform
5 min readApr 8, 2025
The Azure OpenAI Service content filtering system detects and responds to specific categories of potentially harmful content in Input Prompts and Output Completions.
- An Input Prompt is essentially the text or set of instructions that we provide to a computer program — often an AI language model — to guide its response or behavior.
- Output completions refer to the responses or generated text that a language model or similar AI system produces after processing an input prompt. In essence, these completions are the direct outputs generated by the model based on the instructions or queries provided by the user.
The text content filtering models for the Hate, Sexual, Violence, and Self-harm categories have been specifically trained and tested in the following languages: English, German, Japanese, Spanish, French, Italian, Portuguese, and Chinese.
Other optional classification models:
- Protected Material for Text: Protected material text describes known text content (for example, song lyrics, articles, recipes, and selected web content) that large language models can output.
- Protected Material for Code: Protected material code describes source code that matches a set of source code from public repositories, which…