Where: explainers/underdiagnosis-bias.md - the "Detection Code" python block and its "Output Interpretation" prose.
The gap: the explainer's claimed output (true_recall 80.5% for Group A vs. 41.2% for Group B, a "39.3-point" gap; Q4 biomarker-band diagnosis rate 0.887 vs. 0.536) does not match what the exact code block in the same file actually produces.
Repro (code extracted verbatim from the file's own fenced python block, run directly):
$ python3 -c "
import re
text = open('explainers/underdiagnosis-bias.md').read()
block = re.findall(r'\`\`\`python\n(.*?)\`\`\`', text, re.S)[0]
open('/tmp/underdiagnosis_extracted.py', 'w').write(block)
"
$ python3 /tmp/underdiagnosis_extracted.py
=== 1. MODEL AUDIT: OBSERVED EHR LABELS VS TRUE DISEASE STATE ===
obs_recall true_recall obs_fnr true_fnr
group
Group A (Reference) 0.638037 0.625000 0.361963 0.375000
Group B (Underserved) 0.330275 0.292135 0.669725 0.707865
=== 2. BIOMARKER-TO-LABEL CONSISTENCY AUDIT ===
...
Q4 (Low-High Risk) 0.785 0.497
Reproduced identically across repeated runs (the script is seeded with np.random.seed(42)). Real true_recall is 62.5%/29.2% (a 33.3-point gap, not 39.3), and the real Q4 rate is 0.785/0.497, not the claimed 0.887/0.536.
Why it matters: the specific numbers a reader is told to expect from running this code don't match what the code actually prints - the same "output block pasted from an earlier version of the code and never regenerated after an edit" pattern as the parallel issue for reject-inference.md.
Suggested fix: regenerate the "Output Interpretation" prose numbers from an actual run of the current code block (true_recall 0.625/0.292, a 33.3-point gap; Q4 rate 0.785/0.497), rather than leaving the stale figures in place.
Where:
explainers/underdiagnosis-bias.md- the "Detection Code" python block and its "Output Interpretation" prose.The gap: the explainer's claimed output (true_recall 80.5% for Group A vs. 41.2% for Group B, a "39.3-point" gap; Q4 biomarker-band diagnosis rate 0.887 vs. 0.536) does not match what the exact code block in the same file actually produces.
Repro (code extracted verbatim from the file's own fenced python block, run directly):
Reproduced identically across repeated runs (the script is seeded with
np.random.seed(42)). Real true_recall is 62.5%/29.2% (a 33.3-point gap, not 39.3), and the real Q4 rate is 0.785/0.497, not the claimed 0.887/0.536.Why it matters: the specific numbers a reader is told to expect from running this code don't match what the code actually prints - the same "output block pasted from an earlier version of the code and never regenerated after an edit" pattern as the parallel issue for
reject-inference.md.Suggested fix: regenerate the "Output Interpretation" prose numbers from an actual run of the current code block (true_recall 0.625/0.292, a 33.3-point gap; Q4 rate 0.785/0.497), rather than leaving the stale figures in place.