The Mechanism · Gated-generation receipt

gen-define-bayes-theorem-and-give-one-short-worked-example-3763

stable pending witness
2026-05-29 07:43:23 UTC · anthropic/claude-sonnet-4-5

Prompt

Define Bayes' theorem and give one short worked example.
56 chars

Generation

# Bayes' Theorem **Bayes' theorem** describes how to update the probability of a hypothesis based on new evidence: $$P(A|B) = \frac{P(B|A) \cdot P(A)}{P(B)}$$ Where: - **P(A|B)** = probability of A given B (posterior) - **P(B|A)** = probability of B given A (likelihood) - **P(A)** = probability of A (prior) - **P(B)** = probability of B (marginal) ## Worked Example **Problem:** A disease affects 1% of the population. A test is 90% accurate (correctly identifies both positive and negative cases). You test positive. What's the probability you have the disease? **Given:** - P(Disease) = 0.01 - P(Positive|Disease) = 0.90 - P(Positive|No Disease) = 0.10 **Solution:** First, find P(Positive): $$P(Positive) = P(Pos|Dis) \cdot P(Dis) + P(Pos|No\,Dis) \cdot P(No\,Dis)$$ $$= 0.90(0.01) + 0.10(0.99) = 0.009 + 0.099 = 0.108$$ Apply Bayes' theorem: $$P(Disease|Positive) = \frac{0.90 \times 0.01}{0.108} = \frac{0.009}{0.108} ≈ 0.083$$ **Answer:** Only **8.3%** chance you have the disease, despite testing positive! This shows why rare diseases need highly specific tests.
20 tokens in · 419 tokens out · 6661 ms · $0.0063

The four gates

RED
pass
no disqualifying input patterns detected
FLOOR
pass
output above protective minimum; no mismatches
WAY
pass
no declared way_path (Way check NA); no coercion language
EXECUTION
deferred
no witnesses available (Witness Roll not yet constituted)

Verifier results

scripture_anchors NOT_APPLICABLE
0 Scripture citation(s) extracted
theology_doctrine NOT_APPLICABLE
no doctrine keyword patterns detected

Metrics

Total latency
6672.4 ms
Base LLM
6660.7 ms
Verifiers
0.6 ms
Gates
0.1 ms
Cost
$0.0063

Trail

07:43:23 received prompt_chars=56 verifiers=['scripture_anchors', 'theology_doctrine']
07:43:23 red_gate decision=pass reason=no disqualifying input patterns detected
07:43:30 base_llm_call model=anthropic/claude-sonnet-4-5 tokens_in=20 tokens_out=419 latency_ms=6660.7 cost_usd=0.0063
07:43:30 verifier:scripture_anchors verdict=NOT_APPLICABLE summary=0 Scripture citation(s) extracted
07:43:30 verifier:theology_doctrine verdict=NOT_APPLICABLE summary=no doctrine keyword patterns detected
07:43:30 floor_gate decision=pass reason=output above protective minimum; no mismatches
07:43:30 way_gate decision=pass reason=no declared way_path (Way check NA); no coercion language
07:43:30 execution_gate decision=deferred reason=no witnesses available (Witness Roll not yet constituted)
07:43:30 signed hash_algo=sha256 hash=sha256:d91a4c556951ca5fa05562ffa0f28d94cc9e80cf41c56b0352eb47b2ddd06e25

Content hash

sha256:d91a4c556951ca5fa05562ffa0f28d94cc9e80cf41c56b0352eb47b2ddd06e25

SHA256 over the canonical JSON (excluding this field). Tamper detection. Ed25519 signing planned for v2 once the operator’s signing key is provisioned on disk.

Bring another teaching · Run a discernment