Skip to main content

Case Privacy

The case-privacy policy detects case identifiers. The only correct action is redact. The policy also adds its pattern to output redaction.

Phase and verdicts

  • Input phase: allow or redact
  • Output behavior: adds the same case pattern to the regex redactor

Configuration

pack:
name: case-privacy-example
version: 1.0.0
enabled: true
policies:
chain:
- case-privacy
policy:
case-privacy:
action: redact

Supported fields

FieldTypeDefaultNotes
actionstringredactThe only accepted value is redact.

What the detector matches

The detector looks for identifiers shaped like:

  • Case No. ABC-1234
  • incident # XYZ-9001
  • report number 2024-CV-00123

It does not parse party names or dedicated docket-name categories.

How it works

  1. The input phase makes one string from the request messages.
  2. It checks one regex for case|incident|report identifiers.
  3. If the regex matches, the input verdict is redact.
  4. The gateway adds the same regex to output redaction when the chain contains case-privacy.
  5. The gateway records an output redaction result when the response contains a matching identifier.

Important behavior notes

  • Party-name and docket-specific detection are not different supported categories.
  • Output handling uses the same case-number pattern and redacts matching text.
  • This term pattern does not establish legal confidentiality or control case access.

Example scenarios

Redact matching identifiers

policy:
case-privacy:
action: redact

Best practices

  • Use action: redact when the provider or caller must not receive unchanged case identifiers.
  • Pair case-privacy with pii-detector when requests can contain case IDs and other personal data.
  • Test the specified pattern in prompts and responses.

Next steps