What does Dense Data Workbenches conclude, in numbers, about “Method: Three Losses, Four Metrics, Evidence Grades and the Liu Yan Reporting System”?

Answer: Chapter 1 is the method. The invented buying agent Harbourbridge has 1,200 ledger rows and 18 true anomalies a day; six whole-row red rules paint 435 rows red with a positive predictive value of only 0.037; with a budget of 60 proper checks a day, loosening the threshold can push the miss rate from 0.500 to 0.853; and a before-and-after comparison run during a rising peak season recovers on average less than half of the true effect, while randomly alternating days within weeks brings the estimate back to −0.1040.

Scope of the numbers: The book is not accounting, audit or legal advice. Marked boxes separate published evidence, runnable calculations, sources and the author's hypotheses, each stating what would refute it; the source studied is the reporting system of the Tang finance minister Liu Yan, given in paraphrase.

中文版

Data table

The numbers below are printed verbatim by the chapter's Python program and can be reproduced by running it. standard-library Python onlyprinted values that match the answer: 0.500, 0.853, 1200, 18, 60

rows 1200, true anomalies 18, d' 2.0, careful checks per day 60
threshhit_ratefalse_alarmred_rowsred_sharePPVcaughtmissedmiss_rate
3.50.0670.00021.50.0010.8141.2016.800.933
3.00.1590.00134.50.0040.6422.8615.140.841
2.50.3090.006212.90.0110.4315.5512.450.691
2.00.5000.022835.90.0300.2519.009.000.500
1.50.6910.066891.40.0760.1368.179.830.546
1.00.8410.1587202.70.1690.0754.4813.520.751
0.50.9330.3085381.50.3180.0442.6415.360.853
0.00.9770.5000608.60.5070.0291.7316.270.904
-0.50.9940.6915835.20.6960.0211.2916.710.929
most anomalies caught at threshold 2.0: 9.00 caught with 35.9 red rows
threshold where red rows equal the budget: 1.733; caught there 10.89
Show the full program
# Chapter 1. p11: Why more red can mean more misses: a fixed careful-check budget meets a loosening rule.
# Equal-variance signal detection: normal rows score N(0,1), true anomalies score N(d',1). A rule paints a
# row red when its score exceeds threshold c. The team can check only B red rows carefully per day and,
# since red rows all look alike, picks them at random. Settings, not measurements: d' = 2.0, B = 60.
import math

ROWS, ANOM = 1200, 18
NORMAL = ROWS - ANOM
D_PRIME = 2.0
BUDGET = 60


def tail(x):
    return 0.5 * math.erfc(x / math.sqrt(2.0))


print("rows {}, true anomalies {}, d' {}, careful checks per day {}".format(ROWS, ANOM, D_PRIME, BUDGET))
print("thresh  hit_rate  false_alarm  red_rows  red_share  PPV    caught  missed  miss_rate")
best = None
for c10 in range(35, -6, -5):
    c = c10 / 10.0
    hit, fa = tail(c - D_PRIME), tail(c)
    tp, fp = ANOM * hit, NORMAL * fa
    red = tp + fp
    caught = tp * min(1.0, BUDGET / red)
    print("{:6.1f}  {:8.3f}  {:11.4f}  {:8.1f}  {:9.3f}  {:.3f}  {:6.2f}  {:6.2f}  {:9.3f}".format(
        c, hit, fa, red, red / ROWS, tp / red, caught, ANOM - caught, 1 - caught / ANOM))
    if best is None or caught > best[1]:
        best = (c, caught, red)
print("most anomalies caught at threshold {:.1f}: {:.2f} caught with {:.1f} red rows".format(*best))
lo, hi = 0.0, 6.0
for _ in range(80):
    mid = (lo + hi) / 2.0
    if ANOM * tail(mid - D_PRIME) + NORMAL * tail(mid) > BUDGET:
        lo = mid
    else:
        hi = mid
c = (lo + hi) / 2.0
print("threshold where red rows equal the budget: {:.3f}; caught there {:.2f}".format(
    c, ANOM * tail(c - D_PRIME)))

Single source and citation

Fan, Y. (2026). Cognitive Unloading of Dense Data Workbenches, Conditional-Format Salience and Zero-Training Error-Proof Form Engineering (Version 0.1.0), Chapter 1: Method: Three Losses, Four Metrics, Evidence Grades and the Liu Yan Reporting System. 5D Library. DOI pending

DOI pending · monograph page goes live after publication · 5DL-B-138 · v0.1.0 · CC-BY-NC-ND-4.0

BibTeX
@book{fan2026138,
  author    = {Fan, Yafu},
  title     = {Cognitive Unloading of Dense Data Workbenches, Conditional-Format Salience and Zero-Training Error-Proof Form Engineering},
  year      = {2026},
  publisher = {5D Library},
  edition   = {0.1.0},
  note      = {DOI pending}
}

Other chapter answers in this book