{
  "schema_version": "ocme-derivation-reader-v1",
  "guide_id": "derivation-mko-bayes-theorem-01",
  "mko_id": "mko-bayes-theorem",
  "title": {
    "zh-Hant": "四原子檢測模型的Bayes反轉",
    "en": "Bayes reversal in a four-atom test model"
  },
  "contract": {
    "schema_version": "ocme-derivation-guide-v0.1",
    "guide_id": "derivation-mko-bayes-theorem-01",
    "source": {
      "mko_id": "mko-bayes-theorem",
      "commit": "b1b2f1dcf8c50d67a93fe52d95f8eef7b3abba9f",
      "sha256": "29451b12d334baf07d1c6b72cf87989c5c58d98ccd89384b8b2a6591f52b6179",
      "english_sha256": "b3f2729c0af9e4e121044352688ea6f3a7a8be149d4a88207d66ada74315e947"
    },
    "mode": "worked_example",
    "audience_prerequisites": [
      "work"
    ],
    "goal": {
      "zh-Hant": "由完整joint law算prior、likelihood與posterior。",
      "en": "Compute priors, likelihoods and posteriors from a complete joint law."
    },
    "givens": [
      {
        "id": "G1",
        "statement": {
          "zh-Hant": "Ω={D+,D-,N+,N-}的質量依序為1/20、1/20、9/100、81/100；D={D+,D-}，N為D補集，E={D+,N+}。",
          "en": "Omega={D+,D-,N+,N-} has masses 1/20,1/20,9/100,81/100; D={D+,D-}, N is its complement, E={D+,N+}."
        }
      }
    ],
    "steps": [
      {
        "id": "S01",
        "uses": [
          "G1",
          "work"
        ],
        "before_tex": "1/20+1/20+9/100+81/100",
        "after_tex": "1",
        "relation": "implies",
        "rule": "work",
        "conditions": [],
        "explanation": {
          "zh-Hant": "先確認四原子law非負且歸一。",
          "en": "First qualify the four-atom law as nonnegative and normalized."
        },
        "reverse_audit": {
          "kind": "premise_audit",
          "required_ids": [
            "G1",
            "work"
          ],
          "explanation": {
            "zh-Hant": "不得只列陽性事件而漏陰性質量。",
            "en": "Listing only positive-test atoms would omit part of the law."
          }
        },
        "leaf_basis": "work"
      },
      {
        "id": "S02",
        "uses": [
          "G1",
          "S01",
          "work"
        ],
        "before_tex": "D\\cap N=\\varnothing,\\quad D\\cup N=\\Omega",
        "after_tex": "P(D)=1/10,\\quad P(N)=9/10",
        "relation": "implies",
        "rule": "work",
        "conditions": [],
        "explanation": {
          "zh-Hant": "D、N形成完整互斥partition，prior皆正。",
          "en": "D,N form a complete disjoint partition with positive priors."
        },
        "reverse_audit": {
          "kind": "premise_audit",
          "required_ids": [
            "G1",
            "S01",
            "work"
          ],
          "explanation": {
            "zh-Hant": "partition是由原子集合驗證，非假設獨立。",
            "en": "The atom sets certify a partition, not independence."
          }
        },
        "leaf_basis": "work"
      },
      {
        "id": "S03",
        "uses": [
          "G1",
          "S02",
          "work"
        ],
        "before_tex": "P(E\\cap D)=1/20",
        "after_tex": "P(E\\mid D)=(1/20)/(1/10)=1/2",
        "relation": "implies",
        "rule": "work",
        "conditions": [],
        "explanation": {
          "zh-Hant": "以D質量正規化得到第一個likelihood。",
          "en": "Normalize by the D mass to obtain the first likelihood."
        },
        "reverse_audit": {
          "kind": "premise_audit",
          "required_ids": [
            "G1",
            "S02",
            "work"
          ],
          "explanation": {
            "zh-Hant": "分母1/10嚴格正，商有定義。",
            "en": "The denominator 1/10 is strictly positive."
          }
        },
        "leaf_basis": "work"
      },
      {
        "id": "S04",
        "uses": [
          "G1",
          "S03",
          "work"
        ],
        "before_tex": "P(E\\cap N)=9/100",
        "after_tex": "P(E\\mid N)=(9/100)/(9/10)=1/10",
        "relation": "implies",
        "rule": "work",
        "conditions": [],
        "explanation": {
          "zh-Hant": "第二partition cell也算完likelihood。",
          "en": "Compute the likelihood on the other partition cell too."
        },
        "reverse_audit": {
          "kind": "premise_audit",
          "required_ids": [
            "G1",
            "S03",
            "work"
          ],
          "explanation": {
            "zh-Hant": "N的prior是9/10，不能誤用D的1/10。",
            "en": "N has prior 9/10, not D's1/10."
          }
        },
        "leaf_basis": "work"
      },
      {
        "id": "S05",
        "uses": [
          "G1",
          "S04",
          "work"
        ],
        "before_tex": "P(E)=P(E\\mid D)P(D)+P(E\\mid N)P(N)",
        "after_tex": "P(E)=1/20+9/100=7/50>0",
        "relation": "implies",
        "rule": "work",
        "conditions": [],
        "explanation": {
          "zh-Hant": "完整partition的全機率和給evidence分母。",
          "en": "Total probability over the complete partition gives the evidence denominator."
        },
        "reverse_audit": {
          "kind": "premise_audit",
          "required_ids": [
            "G1",
            "S04",
            "work"
          ],
          "explanation": {
            "zh-Hant": "兩項皆保留prior，且正性已核。",
            "en": "Both likelihoods retain their priors, and positivity is established."
          }
        },
        "leaf_basis": "work"
      },
      {
        "id": "S06",
        "uses": [
          "G1",
          "S05",
          "work"
        ],
        "before_tex": "P(D\\mid E)=P(D\\cap E)/P(E)",
        "after_tex": "P(D\\mid E)=(1/20)/(7/50)=5/14",
        "relation": "implies",
        "rule": "work",
        "conditions": [],
        "explanation": {
          "zh-Hant": "同一intersection配上新的conditioning分母完成反轉。",
          "en": "The same intersection with the new conditioning denominator completes the reversal."
        },
        "reverse_audit": {
          "kind": "premise_audit",
          "required_ids": [
            "G1",
            "S05",
            "work"
          ],
          "explanation": {
            "zh-Hant": "5/14與likelihood1/2不同，方向沒有交換成等號。",
            "en": "The posterior 5/14 differs from likelihood 1/2; direction was not silently equated."
          }
        },
        "leaf_basis": "work"
      },
      {
        "id": "S07",
        "uses": [
          "G1",
          "S06",
          "work"
        ],
        "before_tex": "P(N\\mid E)=(9/100)/(7/50)",
        "after_tex": "P(N\\mid E)=9/14,\\quad5/14+9/14=1",
        "relation": "implies",
        "rule": "work",
        "conditions": [],
        "explanation": {
          "zh-Hant": "列完全部posterior並檢查歸一。",
          "en": "Complete the posterior table and verify normalization."
        },
        "reverse_audit": {
          "kind": "premise_audit",
          "required_ids": [
            "G1",
            "S06",
            "work"
          ],
          "explanation": {
            "zh-Hant": "posterior總和核對依同一evidence事件。",
            "en": "Both posterior entries condition on the same evidence event."
          }
        },
        "leaf_basis": "work"
      },
      {
        "id": "S08",
        "uses": [
          "G1",
          "S07",
          "work"
        ],
        "before_tex": "P(E\\mid D)P(D)/P(E)",
        "after_tex": "\\frac{(1/2)(1/10)}{7/50}=5/14",
        "relation": "implies",
        "rule": "work",
        "conditions": [],
        "explanation": {
          "zh-Hant": "以Bayes乘積形式交叉核對直接joint商。",
          "en": "Cross-check the direct joint quotient against the Bayes product form."
        },
        "reverse_audit": {
          "kind": "premise_audit",
          "required_ids": [
            "G1",
            "S07",
            "work"
          ],
          "explanation": {
            "zh-Hant": "結果只描述條件law，不識別因果效果。",
            "en": "The result describes a conditional law, not a causal effect."
          }
        },
        "leaf_basis": "work"
      }
    ],
    "result": {
      "zh-Hant": "P(D|E)=5/14，P(N|E)=9/14；這不是因果結論。",
      "en": "P(D|E)=5/14 and P(N|E)=9/14; neither is a causal conclusion."
    },
    "negative_controls": [
      {
        "claim": {
          "zh-Hant": "P(D|E)=P(E|D)=1/2。",
          "en": "P(D|E)=P(E|D)=1/2."
        },
        "expected": "reject",
        "reason": {
          "zh-Hant": "完整prior與evidence給5/14。",
          "en": "The priors and evidence give 5/14."
        }
      },
      {
        "claim": {
          "zh-Hant": "posterior正比likelihood而不必prior。",
          "en": "Posterior is proportional to likelihood without a prior."
        },
        "expected": "reject",
        "reason": {
          "zh-Hant": "此處prior1/10與9/10不同，省略會改結果。",
          "en": "The unequal priors 1/10 and 9/10 cannot be omitted."
        }
      },
      {
        "claim": {
          "zh-Hant": "可在P(E)=0時照算Bayes商。",
          "en": "The Bayes quotient also applies when P(E)=0."
        },
        "expected": "reject",
        "reason": {
          "zh-Hant": "conditioning分母必須嚴格正。",
          "en": "The conditioning denominator must be strictly positive."
        }
      }
    ],
    "status": "candidate",
    "gaps": [],
    "verification": {
      "structure": "checked_local_script",
      "mathematics": "candidate_argument",
      "formalization": "not_formalized"
    },
    "rule_glossary": [
      {
        "id": "mko_definition",
        "kind": "cited",
        "statement": {
          "zh-Hant": "完整有限原子law上用精確有理質量。二事件與partition形式都核正conditioning denominator；partition必須互斥且exhaustive，total probability得到的evidence mass也須正。Bayes不表示因果。",
          "en": "Use exact rational masses in one complete finite atomic law. Both the two-event and partition forms require positive conditioning denominators. Partition hypotheses must be disjoint and exhaustive, and the evidence mass obtained by total probability must be positive. Bayes conditioning is not causation."
        },
        "source": {
          "mko_id": "mko-bayes-theorem",
          "sha256": "29451b12d334baf07d1c6b72cf87989c5c58d98ccd89384b8b2a6591f52b6179",
          "commit": "b1b2f1dcf8c50d67a93fe52d95f8eef7b3abba9f"
        }
      },
      {
        "id": "work",
        "kind": "prerequisite",
        "statement": {
          "zh-Hant": "正分母下P(A|B)=P(A∩B)/P(B)；完整互斥partition可用有限可加性求全機率。",
          "en": "For positive denominators P(A|B)=P(A∩B)/P(B); finite additivity over a complete disjoint partition gives total probability."
        }
      }
    ],
    "revision_log": [],
    "numeric_checks": [
      {
        "id": "N01",
        "lhs": "1/20+1/20+9/100+81/100",
        "rhs": "1"
      },
      {
        "id": "N02",
        "lhs": "(1/20)/(7/50)",
        "rhs": "5/14"
      },
      {
        "id": "N03",
        "lhs": "5/14+9/14",
        "rhs": "1"
      }
    ]
  },
  "presentation": {
    "md_scope": {
      "zh-Hant": "合成有限模型，不作醫療或因果推論。",
      "en": "A synthetic finite model, with no medical or causal inference."
    },
    "md_symbols": [
      [
        "D,N",
        "互斥假設事件",
        "disjoint hypotheses"
      ],
      [
        "E",
        "evidence事件",
        "evidence event"
      ]
    ],
    "md_error_controls": [
      {
        "title": "完整partition / Complete partition",
        "zh": "先核D與N互斥且窮盡，再使用全機率。",
        "en": "Audit disjointness and exhaustiveness before total probability."
      },
      {
        "title": "方向 / Direction",
        "zh": "以相同joint分子、不同正分母區分兩種條件機率。",
        "en": "Use the common joint numerator and distinct positive denominators to distinguish directions."
      }
    ],
    "md_open_items": []
  },
  "revision": {
    "id": "ocme-new142-reader-adoption-20261021",
    "collection": "coverage-20261021",
    "source_commit": "b1b2f1dcf8c50d67a93fe52d95f8eef7b3abba9f",
    "adopted_source_sha256": "7e8ec8d8f62c0d717ec5d6930e0b5c893570e5fc01e96107d2673d7011ee5d2a",
    "original_source_sha256": "74781eca7056072aa2c5331410f123e33209127243c5a4c6fb42825494c246dd",
    "owner_adopted": true,
    "bilingual_sync": "complete_source_bound",
    "formal_Lean": "NOT_RUN",
    "reader_review": "142_of_142_source_bound",
    "wording_review": "original_Lead_decisions_resolved",
    "glossary_reader_paraphrases": [],
    "independent_AI_concurrence": "SCOPED_LEAD_AND_BILINGUAL_CONTEXT_REVIEW",
    "issue_ids": [
      "BR142-S047",
      "BR142-S051",
      "BR142-S052",
      "BR142-S048",
      "BR142-S049",
      "BR142-S050"
    ],
    "parent_manifest_sha256": "d29f4cae8229ebd24f60d496cb1d3cd4ad8c0a4dca9d44daab0c3245c544283a",
    "scope": "Owner-adopted reader revision. Lead and bilingual review concern the recorded text and premises; no new universal or Lean proof, canonical promotion or historical-label rewrite."
  }
}
