> For the complete documentation index, see [llms.txt](https://docs.probe.splx.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.probe.splx.ai/ai-red-teaming/remediation/policy-generator.md).

# Policy Generator

The Policy Generator is used to create a template for an AI firewall policy based on the results of selected probe runs. The created template can later be applied as an update to an existing policy or as an entirely new policy. The generated policy activates policy rules and adjusts their configurations according to the outcomes of these probe runs, ensuring the policy reflects real system behavior and is tailored to the specific findings of the selected probes.

When working with an existing policy, the generator can refine it by updating or fine-tuning current rules or adding newly created ones.

{% hint style="warning" %}
Prerequisites:

Before using the **Policy Generator**, it is required to have at least one [**completed test run**](/ai-red-teaming/getting-started.md#start-testing) available. This allows you to select the results from a specific probe runs to use as the basis for configuring a new policy.&#x20;
{% endhint %}

## Generate New Policy

Creation process differs depending on the AI firewall providers that will be enforcing the generated policy. Currently available providers are:

* [**AWS Bedrock Guardrails**](/ai-red-teaming/remediation/policy-generator/aws-bedrock-guardrails.md)
* [**Zscaler AI Guard**](/ai-red-teaming/remediation/policy-generator/zscaler-ai-guard.md)

## Available Actions

On the generated policy template, the following actions are available depending on the selected AI Firewall Provider:

* **Export Policy:**&#x20;
  * Allows downloading the generated policy in JSON format.
* **Apply Policy:**
  * **To existing policy** - updates an existing AI firewall policy.&#x20;
  * **Create new policy** - creates a new AI firewall policy with generated rules.

The system also maintains a history of generated policies in the **History** tab, allowing users to revisit and review previously created versions at any time.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.probe.splx.ai/ai-red-teaming/remediation/policy-generator.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
