> For the complete documentation index, see [llms.txt](https://docs.ox.security/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.ox.security/vibesec/agent-guidelines.md).

# Agent Guidelines

Agent guidelines are secure coding instructions that OX provides to AI coding agents to help them generate code without introducing vulnerabilities.

When a developer submits a prompt to an AI coding agent, OX analyzes the prompt and determines which vulnerabilities could potentially be introduced by implementing the requested functionality. OX then returns the relevant secure coding guidance based on the predicted vulnerability and the programming language being used.

The guidance is provided to the AI coding agent before code generation begins and is applied automatically in the background. As a result, the agent generates code using secure implementation patterns from the outset, reducing the likelihood of introducing security vulnerabilities.

<figure><img src="/files/7wGOoTZT2eXIndexRgzx" alt="" width="563"><figcaption></figcaption></figure>

The Agent Guidelines page shows all guidelines available to your organization's AI coding agents. Each guideline targets a specific vulnerability and programming language combination.

### Guidelines list

Use the filters and search box above the list to find specific guidelines.

| Column   | Description                                                                                                                                                                                                  |
| -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| Toggle   | Enables or disables the guideline. When enabled, OX can provide the guideline to AI coding agents when the prompt matches the guideline's activation criteria. When disabled, the guideline is not returned. |
| Name     | The guideline name and target language. For example, `sql-injection-prevention (Python)`.                                                                                                                    |
| Category | The OX category the guideline belongs to. Agent guidelines currently belong to the Code Security category.                                                                                                   |
| Language | The programming language(s) the guideline targets.                                                                                                                                                           |
| Author   | The author of the guideline. OX-provided guidelines are labeled **Created by OX**.                                                                                                                           |

### Filtering guidelines

| Field    | Description                                                                                                 |
| -------- | ----------------------------------------------------------------------------------------------------------- |
| Language | Filters the list by programming language. Select **All** to display guidelines for all supported languages. |
| Status   | Filters the list by guideline status (**Enabled** or **Disabled**). Select **All** to display both.         |
| Search   | Searches for guidelines by name.                                                                            |

Select a guideline to view its details.

### Viewing guideline details

Each guideline includes the following information:

<figure><img src="/files/hFQ36iiElLblvN5GNjLu" alt="" width="563"><figcaption></figcaption></figure>

| Section             | Description                                                                                                                       |
| ------------------- | --------------------------------------------------------------------------------------------------------------------------------- |
| Description         | A summary of the vulnerability the guideline is designed to prevent.                                                              |
| Activation Criteria | The conditions OX evaluates in a developer's prompt to determine whether the guideline should be provided to the AI coding agent. |
| Instructions        | Secure coding guidance that helps the AI coding agent generate code without introducing the targeted vulnerability.               |
| Code Samples        | Example implementations that demonstrate the recommended secure coding pattern.                                                   |

OX provides the guidance and examples to the AI coding agent in the background. Developers do not interact with the guideline directly. Instead, the agent uses the guidance during code generation to produce code that follows the recommended secure implementation patterns.


---

# 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, and the optional `goal` query parameter:

```
GET https://docs.ox.security/vibesec/agent-guidelines.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
