Skip
Custodis
Back to guides
Professionals deciding how to redact documents for AI

Black Bars vs. Tokens: Redacting Documents for AI

A visual black bar may leave PDF text selectable underneath. Custodis replaces detected values with tokens, and you review the protected text before using AI.

2 own documents free on iPhone (no account), Web (free account), and ChatGPT Plugin 0.6.2. Failed attempts do not count. Review every hidden field before saving or sharing.

Quick Answer

A visual overlay may leave the underlying text selectable and extractable. Custodis replaces detected sensitive values with tokens on your device, and you review the protected text before deciding whether to send it to AI.

A black bar removes a selected value from the shared copy; a token leaves a labeled placeholder that Custodis restores to the real value on your device.

What to do

  • Check the real output — read the "What AI Will See" tab; do not assume a black box removed the text.
  • Confirm each private value is a category token like ⟦PERSON_8F2A1C⟧, not a visible value or an empty gap.
  • Use "Mark on PDF" to redact anything the automatic pass left showing.
  • Review the protected text before sending; the request may also include your prompt, provider choice, and any values you deliberately allowed.
  • For a copy a person will read, use "Download redacted PDF" and inspect the flattened result before sharing it.
  • Have the responsible professional review the result — the review-unread flag points at anything Custodis could not confidently read.

Step by step

  1. 1

    Open the return in Custodis

    On the start screen, add the PDF under "Drop a document to redact." A sample 1040 works if you are just trying it out. "One document" is the default mode; "More workflows" contains multi-document and comparison options. Reading, OCR, and detection run in your browser without sending the document to Custodis for processing.

  2. 2

    Review "What AI Will See"

    In the workspace header, switch from the PDF tab to "What AI Will See." Detected values appear as labelled chips that stand in for tokens such as ⟦SSN_B13C7E⟧. Read the entire protected text and check for any private value that remains visible before you choose to send it.

    Review "What AI Will See"
  3. 3

    Mark anything automatic detection missed

    Back on the PDF tab, click "Mark on PDF" and draw over any value that should remain hidden. Custodis applies the mark to the corresponding protected text so you can verify that the value has become a token before sending.

    Mark anything automatic detection missed
  4. 4

    Review the hidden fields, then approve

    Use "Review hidden fields" to check the detected values one by one. The visible "Review this document carefully" flag points to text Custodis could not read confidently, especially on scanned or handwritten pages. After you have reviewed the entire protected text, click "Looks ready."

  5. 5

    Export a flattened copy for the human file

    For a version a person will read or print, click "Download redacted PDF." Custodis re-renders each page as a flat image with the reviewed redaction areas applied. Inspect every page and try to select or search each covered value before sharing the export.

Before and after local tokenization

Before

Raw prompt

Client: Dolores Ferreira-Osei

SSN: 415-22-8890

Address: 88 Rowan St, Dayton, OH 45402

Please explain the difference between lines 16 and 22.

After

Protected prompt

Client: ⟦PERSON_8F2A1C⟧

SSN: ⟦SSN_B13C7E⟧

Address: ⟦ADDRESS_44ED90⟧

Please explain the difference between lines 16 and 22.

Why covering text may not remove it

A black bar drawn on a PDF may be a visual overlay rather than a deletion. The original text can remain selectable underneath it, appear in file metadata, or return when someone copies the page. Custodis instead replaces detected sensitive values with tokens on your device. You must review the protected text because detection can miss information.

The short version: a box hides pixels, it does not remove data. If your goal is to keep a name or an SSN away from a cloud model, hiding it visually is not the same as removing it from the text the model actually reads.

Why a visual overlay may not remove PDF text

Some quick redaction tools draw a filled rectangle on top of the page. When that rectangle is only an annotation layer, the words remain in the document and can reappear in several ways.

First, selectable text under the box. Select-all and copy, or run the file through a text extractor, and the covered characters can reappear because an overlay does not remove them. Second, metadata and prior state. Author fields, form-field values, comments, and earlier saved versions can carry the same value even when the visible page looks clean. Third, copy and paste. Pasting the page — or letting an AI ingest the raw PDF — can expose the underlying text beneath the black bar.

A person selecting text, or a model reading the PDF text stream, may receive the original value when the file contains only a rectangle drawn over it.

Why deleting every value can make AI less useful

Deleting a value removes it from the text, but replacing every private field with a blank or the same generic word can also remove useful structure. The AI may no longer know which number belongs to which line, which person has which role, or what happened in what order.

For a document a person will only read or print, deletion can be appropriate. For an AI request, category-specific tokens can preserve useful roles and relationships without including the detected original values.

How tokens preserve useful context

Tokenization replaces each detected sensitive value with a category-specific placeholder, such as ⟦PERSON_8F2A1C⟧, ⟦SSN_B13C7E⟧, or ⟦ADDRESS_44ED90⟧. A stable placeholder remains in the protected text so sentences and relationships can still make sense.

The same detected person receives the same token throughout the document, which helps the model follow roles without receiving the replaced name. The randomized tag does not contain the original value.

Custodis keeps the record that links each token to its original value on your device and does not include that record in the AI request. Custodis can use it to replace supported tokens after an answer returns.

Side by side: manual black bars vs Custodis tokenization

What may be sent. If a PDF with a visual overlay is uploaded to AI, the underlying text may go with it. Custodis prepares protected text on your device. After reviewing it, you choose whether to send that text, your prompt, provider details, and any values you deliberately allowed.

What the AI can still do. A visual overlay may leave the value readable, while deleting every value may remove needed context. Category-specific tokens let the model follow roles and relationships without receiving the detected values that were replaced.

Where the restoration information stays. Custodis keeps the map between tokens and original values on your device and does not include it in an AI request. That lets Custodis restore supported tokens locally when the final work product needs them.

What copy and paste yields. Copying through a visual overlay can return the original text. Copying reviewed protected text from Custodis returns tokens for the values you kept hidden. Custodis changes the text prepared for the model rather than only covering the page visually.

How Custodis exports differ

For a redacted copy a person will read or print, "Download redacted PDF" re-renders each page as a flat image and applies the reviewed redaction areas. Covered page content is not retained as selectable text beneath those boxes.

Open the exported PDF, inspect every page, and try to select, copy, search, or extract each covered value. Keep the original and restoration map on your device, and share the flattened export only after checking it.

Common questions

Does a flattened Custodis export remove the underlying text?

When you click "Download redacted PDF," Custodis re-renders each page as a flat image and paints reviewed redaction areas into the exported copy. Check the export before sharing it: try to select the covered text or inspect it with a text extractor. A value that was not detected or marked cannot be removed from the export automatically.

Does Custodis send the token restoration map to the AI?

No. Custodis keeps the restoration map on your device and does not include it in the AI request. The request uses a token such as ⟦SSN_B13C7E⟧ in place of a detected value. Review the surrounding text as well, because context can still reveal information even when a direct identifier has been replaced.

Is manual black-bar redaction ever enough?

For a document a person will only view or print, a true redaction that removes the underlying text can be appropriate. Some tools instead draw an opaque overlay while leaving the original text selectable or present in metadata. For an AI request, category-specific tokens can preserve roles and relationships after detected values are removed. This is general information, not legal advice.

Does tokenization hurt the AI's answer?

It can if too much context is removed. Custodis uses category-consistent tokens, so the same detected person receives the same token throughout the document. This may help the model follow roles and sequence without receiving the replaced name. Review whether the remaining context is both useful and appropriate to send.

Custodis is a privacy app for your documents

Don't paste sensitive details into a chatbot. Tokenize with Custodis first.