> For the complete documentation index, see [llms.txt](https://docs.tonic.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.tonic.ai/textual/guided-redaction/guided-redaction-cross-project-config/redaction-reference-codes.md).

# Configuring reference codes for guided redaction

Reference codes are used to indicate the type of value that is redacted.

Before you can start a guided redaction, you must set up the reference codes.

You can optionally link each reference code to one or more Textual entity types. Make sure that you map reference codes to all of the entity types that appear in your files.

## Displaying the reference codes

On the **Guided Redaction** page, to display the list of reference codes, click **Reference Codes Settings**.

For each each reference code, the list includes:

* Code value
* Any Textual entity types that the code is mapped to
* The user who most recently updated the code configuration
* When the code was most recently updated

<figure><img src="/files/LEFsDIettDVRzg6mmdAj" alt=""><figcaption><p>Reference codes list for guided redaction</p></figcaption></figure>

## Creating a reference code

{% hint style="info" %}
**Required global permission:** Create redaction reference codes
{% endhint %}

To create a reference code:

1. Click **New Reference Code**.
2. In the **Reference Code** field, type the code.
3. Optionally, check the checkbox next to each built-in entity type that applies to the reference code.\
   \
   You can link up to 5 entity types to a reference code. For example, a reference code is used for any name value. You would link the reference code to both the Given Name and Family Name entity types.\
   \
   The list indicates when an entity type is already linked to a reference code. You can link the same entity type to multiple reference codes.\
   \
   Linking entity types is optional. If the reference code represents a value that is not represented in the Textual entity types, then you do not link it.
4. Click **Create**.

## Editing a reference code

{% hint style="info" %}
**Required global permission:** Edit redaction reference codes
{% endhint %}

For a reference code, you can change the code value and the assigned built-in entity types.

To edit a reference code:

1. Click the settings icon for the code.
2. On the details panel, update the code. You can change the code and the assigned entity types.
3. Click **Save**.

## Deleting a reference code

{% hint style="info" %}
**Required global permission:** Edit redaction reference codes
{% endhint %}

You cannot delete a reference code that is currently assigned to a redaction.

To delete a reference code, click its delete icon.


---

# 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.tonic.ai/textual/guided-redaction/guided-redaction-cross-project-config/redaction-reference-codes.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.
