/opt/philter/profiles
. You can edit the filter profiles directly there using a text editor or you can use Philter's API to upload a filter profile. In this case we recommend just using a text editor on the Philter instance to create a filter profile.cp /opt/philter/profiles/default.json /opt/philter/profiles/evaluation.json
/opt/philter/profiles/evaluation.json
in a text editor. (The content of evaluation.json
will be similar to what's shown below but may have minor differences between different versions of Philter.)default
with evaluation
and save the file.enabled
property to false. Using the enabled
property allows you to keep the filter configuration in the filter profile in case it is needed later but both options have the same effect.strategy
and redactionFormat
values for each filter should be fine for evaluation. file.txt
to Philter. The ?p=evaluation
tells Philter to apply the evaluation
filter profile that we have been editing. Philter's response to this command will be the redacted contents of file.txt
as defined in the filter profile.file.txt
and the redacted contents returned by Philter, we can now compare those files to begin evaluating Philter's performance. You can diff
the text to find the redacted information or use some other method.endpoint
:explain
API endpoint produces a detailed description of the redaction. The response will include a list of spans that contain the start and stop positions of redacted text and the type of sensitive information that was redacted. Using this information we can compare the redacted information to our annotated file to calculate precision and recall metrics.