Setting probability thresholds with error costs Decide in the open, episode 91 Anna: Craig has published design notes for a threshold calculator he plans to build. It takes what a wrong yes and a wrong no cost, and shows how sure a model must be before acting. Tom: A decision model or a person usually produces a probability, like being eighty-five per cent sure an invoice is fine. But that probability alone doesn't tell you whether to pay it. Anna: The answer depends on what a mistake costs. If paying a bad invoice costs ten times more than delaying a good one, you need to be very sure. Setting a threshold you can defend explains the reasoning, and the calculator does the arithmetic. Tom: What does the arithmetic look like for a straight yes or no choice? Anna: You enter two numbers: what a wrong yes costs and what a wrong no costs. The threshold is wrong yes divided by wrong yes plus wrong no. Say yes when your probability is at or above the threshold. Below it, say no. Tom: He gives a worked example with illustrative figures. Anna: An invoice check. Paying a bad invoice costs fifty pounds to put right. Delaying a good one costs five pounds in goodwill and admin. The threshold is fifty divided by fifty-five, which is zero point nine one. You pay automatically only when the model is at least ninety-one per cent sure. Tom: Most real processes have a third option, though. You can ask a person. Anna: That brings in a review cost, mainly someone's time. In his example, a person checking an invoice costs two pounds of their time. The calculator uses that to set two lines: act when probability is at least one minus review cost divided by wrong yes, and stop when probability is at most review cost divided by wrong no. Tom: So the act threshold becomes one minus two divided by fifty, which is zero point nine six. Anna: And the stop line is two divided by five, which is zero point four zero. You stop at or below forty per cent, act at or above ninety-six per cent, and ask a person in between. Tom: Having a human review option actually raised the threshold for automatic action from ninety-one per cent to ninety-six per cent. Anna: It raises the bar because a cheap check is now available for uncertain cases. These lines come directly from comparing expected costs: acting has an expected cost of one minus p times wrong yes, stopping costs p times wrong no, and asking costs the review cost. Each line is where two of those costs are equal. Tom: What happens if the review cost is too high? Anna: The three-way version breaks if the review cost is higher than the expected cost of acting or stopping everywhere. The ask band disappears, and the stop line can end up above the act line. Craig worked that out by trying awkward numbers on paper. The calculator has to detect that and fall back to the two-way answer, with an explanatory note. Tom: He also flags that the probability itself might be wrong. Anna: A threshold is only as good as the model's calibration. He is still checking how to show that uncertainty on the page. Tom: The tool is not built yet, though. This is only the design. Anna: He wrote the design first to check he understands the maths before writing code. When it is built, it will be a static tool running in the browser. The page will have three inputs and a chart showing the three expected costs as lines across probabilities from zero to one. Inputs stay in the page address so you can share results or save them in a decision record. Tom: And the code will be public once it is on the site. Anna: Which item on this list changes a decision your team has already made? Tom: You can read the full page, and the rest of the site, at craigstanley.work.