The Reject
Node¶
Sometimes it makes sense to terminate an interview prematurely. For these cases, PolicyModels has a reject
node. When the runtime gets to a reject
node, the interview stops, and the rejection reason is presented to the user.
Consider a data tagging system that matches a data handling policy to a dataset. Theoretically, every dataset should have a matching policy. The reality is a bit more complex: there is a special case. Datasets that were obtained by violating laws or regulations cannot be automatically accepted to repositories (if at all).
It’s Not Us, Its You¶
A reject
node has a textual body, explaining the rejection reason. They look like this:
[reject: Data cannot be accepted.
It is illegal to gather data by hunting down baby unicorns.]

Baby unicorn (illustration by the author)¶
In the following questionnaire (files: tag space
, decision graph
), the interview starts with a short validation of the legality of the dataset. If the dataset is, indeed, legal, the interview continues. Otherwise, it ends on the reject
node at line 21.
1<*
2Sample toy interview
3*>
4[call: ensureLegality]
5[ask:
6 {text: Do the data contains personally identifiable information?}
7 {terms:
8 {Personally identifiable information: Any information
9 about an individual... }
10 }
11 {answers:
12 {yes: [set: Storage=encrypt; Transfer=encrypt]}
13 {no: [set: Storage=clear; Transfer=clear]}}]
14[todo: Test for additional ...] <-- Issue #42 follows
15[end]
16
17[>ensureLegality< ask:
18 {text: Did you get parental consent?}
19 {answers:
20 {no:
21 [reject: Must get parental consent before collecting
22 data from subjects under 18.]}}]
23[end]
Warning
This questionnaire is, of course, is intended to show the usage of the reject
node. NOT TO BE USED AS LEGAL ADVICE.

The education interview.¶

Rejection message from the DataTaggingServer, due to a likely PPRA violation.¶
Next up, we’ll demonstrate how to use the current slot values to conditionally visit parts of the decsion graph.