{
  "schema_version": "ocme-reviewed-question-reader-v1",
  "question_id": "q-20261013-advance-20261019-r05-algorithm-correctness-0057",
  "pilot_number": "R0018-09557",
  "number": 9557,
  "family_id": "qf-ext19-correctness-ranking-audit",
  "title": {
    "zh-Hant": "第 9557 題：算法正確性責任",
    "en": "Question 9557: Ranking Decrease, Stuck States, and Actual Termination"
  },
  "original_question": {
    "schema_version": "ocme-question-v0.1",
    "id": "q-20261013-advance-20261019-r05-algorithm-correctness-0057",
    "batch_id": "batch-20261013-advance-20261019-r05-algorithm-correctness-foundations",
    "language": "zh-Hant",
    "source_mko_ids": [
      "mko-algorithm-correctness"
    ],
    "title_zh": "算法正確性責任",
    "stem_zh": "完整有限正確性模型。操作=correctness-ranking-audit；資料={\"n\":6,\"init\":[0],\"halt\":[5],\"steps\":[[0,1],[1,2],[2,5],[3,4],[4,5]],\"rank\":[12,5,4,3,2,0]}。請依 [rank,bad_decrease_edges,ranking_valid,stuck,ranking_plus_no_stuck,actual_termination] 欄序回答。",
    "answer": {
      "kind": "expression",
      "value": "([12, 5, 4, 3, 2, 0], [], 是, [], 是, 是)",
      "explanation_zh": "第二批擴展核對=([12, 5, 4, 3, 2, 0], [], 是, [], 是, 是)；依完整明示資料重算；有限／合成資料核對不是一般形式證明；部分正確性與終止性分離；一條成功路徑不證總正確。"
    },
    "difficulty": {
      "band": "undergraduate_core",
      "level": 1,
      "skills": [
        "算法正確性責任"
      ]
    },
    "variant": {
      "family_id": "qf-ext19-correctness-ranking-audit",
      "seed": 202610195057,
      "parameters": {
        "n": 6,
        "init": [
          0
        ],
        "halt": [
          5
        ],
        "steps": [
          [
            0,
            1
          ],
          [
            1,
            2
          ],
          [
            2,
            5
          ],
          [
            3,
            4
          ],
          [
            4,
            5
          ]
        ],
        "rank": [
          12,
          5,
          4,
          3,
          2,
          0
        ],
        "domain": "Fin_correctness_model",
        "operation": "correctness-ranking-audit",
        "semantic_template": "qf-ext19-correctness-ranking-audit/{\"halt\":[5],\"init\":[0],\"n\":6,\"rank\":[12,5,4,3,2,0],\"steps\":[[0,1],[1,2],[2,5],[3,4],[4,5]]}"
      }
    },
    "verification": {
      "status": "candidate",
      "checks": [
        "producer_exact_finite_model",
        "producer_source_snapshot_check",
        "producer_substantive_template_deduplication",
        "producer_json_schema"
      ],
      "warning_zh": "僅為產生端候選及自檢；主端須另驗，不構成人工審定、一般程式證明、Lean執行或形式Evidence。"
    },
    "provenance": {
      "generator_role": "question_producer",
      "generator_model": "model_unknown",
      "generated_at": "2026-10-13",
      "contract_version": "ocme-question-factory-v0.1"
    }
  },
  "original_english_edition": {
    "schema_version": "ocme-question-localization-v0.1",
    "question_id": "q-20261013-advance-20261019-r05-algorithm-correctness-0057",
    "batch_id": "batch-20261013-advance-20261019-r05-algorithm-correctness-foundations",
    "locale": "en",
    "translation_state": "ai_candidate",
    "source": {
      "question_sha256": "764649f8ca2b7daeb0738e06ce551a25e65b1079ca922714280a28468b131f9d",
      "family_id": "qf-ext19-correctness-ranking-audit",
      "seed": 202610195057,
      "semantic_template": "qf-ext19-correctness-ranking-audit/{\"halt\":[5],\"init\":[0],\"n\":6,\"rank\":[12,5,4,3,2,0],\"steps\":[[0,1],[1,2],[2,5],[3,4],[4,5]]}"
    },
    "fields": {
      "title": "Ranking Decrease, Stuck States, and Actual Termination",
      "stem": "Use the complete finite, possibly nondeterministic transition model S=Fin(6)={0,…,5}, Init=[0], Halt=[5], Step=[[0, 1], [1, 2], [2, 5], [3, 4], [4, 5]]. Normalize sets and ordered transition pairs. Execution stops at a declared Halt state, ignoring all of its outgoing edges. A stuck nonhalting state is not a successful halt; finite prefixes prove no general termination. Natural ranking vector=[12, 5, 4, 3, 2, 0]. Give (rank vector, reachable nonhalt Step edges failing strict decrease, ranking valid?, reachable stuck states, ranking valid and no stuck states?, actual all-path termination?).",
      "answer": {
        "kind": "expression",
        "value": "([12, 5, 4, 3, 2, 0], [], Yes, [], Yes, Yes)",
        "explanation": "Check ranking decrease on every reachable nonhalt transition; vacuous edge decrease alone does not eliminate a stuck nonhalt. A failed ranking need not mean the model fails to terminate. Finite/synthetic checks are not new general formal Evidence. The exact result, retaining the requested order, is ([12, 5, 4, 3, 2, 0], [], Yes, [], Yes, Yes)."
      },
      "skills": [
        "Ranking Decrease, Stuck States, and Actual Termination"
      ],
      "verification_warning": "This is a candidate exercise. Mechanical recomputation checks only the stated conditions and this instance; it is neither a formal proof nor human review."
    }
  },
  "givens": [
    {
      "id": "G001",
      "text": {
        "zh-Hant": "完整有限正確性模型。操作=correctness-ranking-audit；資料={\"n\":6,\"init\":[0],\"halt\":[5],\"steps\":[[0,1],[1,2],[2,5],[3,4],[4,5]],\"rank\":[12,5,4,3,2,0]}。請依 [rank,bad_decrease_edges,ranking_valid,stuck,ranking_plus_no_stuck,actual_termination] 欄序回答。",
        "en": "Use the complete finite, possibly nondeterministic transition model S=Fin(6)={0,…,5}, Init=[0], Halt=[5], Step=[[0, 1], [1, 2], [2, 5], [3, 4], [4, 5]]. Normalize sets and ordered transition pairs. Execution stops at a declared Halt state, ignoring all of its outgoing edges. A stuck nonhalting state is not a successful halt; finite prefixes prove no general termination. Natural ranking vector=[12, 5, 4, 3, 2, 0]. Give (rank vector, reachable nonhalt Step edges failing strict decrease, ranking valid?, reachable stuck states, ranking valid and no stuck states?, actual all-path termination?)."
      }
    }
  ],
  "steps": [
    {
      "id": "S001",
      "uses": [
        "G001"
      ],
      "before": "n=6;raw Init=[0];raw Halt=[5];raw Step=[[0, 1], [1, 2], [2, 5], [3, 4], [4, 5]]",
      "after": "Init=[0];Halt=[5];canonical raw Step=[[0, 1], [1, 2], [2, 5], [3, 4], [4, 5]]",
      "relation": "implies",
      "rule_id": "finite_transition_normalization",
      "conditions": [],
      "explanation": {
        "zh-Hant": "整張有限資料先合型，再去重原有向邊。保留halt的原始出邊在資料中，但執行語意在halt停止；不把stuck當成功halt，也不由一條prefix推一般程式終止。",
        "en": "Type the complete finite data and deduplicate directed edges.Retain raw outgoing halt edges as data,but execution stops at halt.Stuck is not successful halt,and one prefix proves no general program termination."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S002",
      "uses": [
        "G001",
        "S001"
      ],
      "before": "Init=[0]",
      "after": "zero-step reachable=[0]",
      "relation": "implies",
      "rule_id": "zero_step_reachability",
      "conditions": [],
      "explanation": {
        "zh-Hant": "每個初始狀態以0步可達，包括初始即halt者；空Init沒有可達狀態。",
        "en": "Every initial state is reachable in zero steps,including an initial halt.An empty Init has no reachable states."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S003",
      "uses": [
        "G001",
        "S002"
      ],
      "before": "depth=0;state=0;halt=否;raw successors=[1]",
      "after": "expanded successors=[1];newly reached=[1]",
      "relation": "implies",
      "rule_id": "reachability_halt_truncates_expansion",
      "conditions": [],
      "explanation": {
        "zh-Hant": "從非halt狀態展開全部後繼，不只挑一條路；已見狀態不重複加入。halt即使列有出邊也不展開。",
        "en": "Expand every successor of a nonhalt state,not just one chosen path.Add unseen states only.A halt is not expanded even when raw outgoing edges exist."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S004",
      "uses": [
        "G001",
        "S003"
      ],
      "before": "completed frontier=[0];depth=0",
      "after": "next frontier=[1];all reached=[0, 1]",
      "relation": "implies",
      "rule_id": "complete_finite_reachability_layer",
      "conditions": [],
      "explanation": {
        "zh-Hant": "前緣清空時才到達完整閉包；有限狀態及只加未見者保證此列舉終止，不依賴路徑長度抽樣。",
        "en": "The closure is complete only when the frontier empties.Finitely many states and adding only unseen states ensure enumeration terminates,without sampling a path-length cutoff."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S005",
      "uses": [
        "G001",
        "S004"
      ],
      "before": "depth=1;state=1;halt=否;raw successors=[2]",
      "after": "expanded successors=[2];newly reached=[2]",
      "relation": "implies",
      "rule_id": "reachability_halt_truncates_expansion",
      "conditions": [],
      "explanation": {
        "zh-Hant": "從非halt狀態展開全部後繼，不只挑一條路；已見狀態不重複加入。halt即使列有出邊也不展開。",
        "en": "Expand every successor of a nonhalt state,not just one chosen path.Add unseen states only.A halt is not expanded even when raw outgoing edges exist."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S006",
      "uses": [
        "G001",
        "S005"
      ],
      "before": "completed frontier=[1];depth=1",
      "after": "next frontier=[2];all reached=[0, 1, 2]",
      "relation": "implies",
      "rule_id": "complete_finite_reachability_layer",
      "conditions": [],
      "explanation": {
        "zh-Hant": "前緣清空時才到達完整閉包；有限狀態及只加未見者保證此列舉終止，不依賴路徑長度抽樣。",
        "en": "The closure is complete only when the frontier empties.Finitely many states and adding only unseen states ensure enumeration terminates,without sampling a path-length cutoff."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S007",
      "uses": [
        "G001",
        "S006"
      ],
      "before": "depth=2;state=2;halt=否;raw successors=[5]",
      "after": "expanded successors=[5];newly reached=[5]",
      "relation": "implies",
      "rule_id": "reachability_halt_truncates_expansion",
      "conditions": [],
      "explanation": {
        "zh-Hant": "從非halt狀態展開全部後繼，不只挑一條路；已見狀態不重複加入。halt即使列有出邊也不展開。",
        "en": "Expand every successor of a nonhalt state,not just one chosen path.Add unseen states only.A halt is not expanded even when raw outgoing edges exist."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S008",
      "uses": [
        "G001",
        "S007"
      ],
      "before": "completed frontier=[2];depth=2",
      "after": "next frontier=[5];all reached=[0, 1, 2, 5]",
      "relation": "implies",
      "rule_id": "complete_finite_reachability_layer",
      "conditions": [],
      "explanation": {
        "zh-Hant": "前緣清空時才到達完整閉包；有限狀態及只加未見者保證此列舉終止，不依賴路徑長度抽樣。",
        "en": "The closure is complete only when the frontier empties.Finitely many states and adding only unseen states ensure enumeration terminates,without sampling a path-length cutoff."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S009",
      "uses": [
        "G001",
        "S008"
      ],
      "before": "depth=3;state=5;halt=是;raw successors=[]",
      "after": "expanded successors=[];newly reached=[]",
      "relation": "implies",
      "rule_id": "reachability_halt_truncates_expansion",
      "conditions": [],
      "explanation": {
        "zh-Hant": "從非halt狀態展開全部後繼，不只挑一條路；已見狀態不重複加入。halt即使列有出邊也不展開。",
        "en": "Expand every successor of a nonhalt state,not just one chosen path.Add unseen states only.A halt is not expanded even when raw outgoing edges exist."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S010",
      "uses": [
        "G001",
        "S009"
      ],
      "before": "completed frontier=[5];depth=3",
      "after": "next frontier=[];all reached=[0, 1, 2, 5]",
      "relation": "implies",
      "rule_id": "complete_finite_reachability_layer",
      "conditions": [],
      "explanation": {
        "zh-Hant": "前緣清空時才到達完整閉包；有限狀態及只加未見者保證此列舉終止，不依賴路徑長度抽樣。",
        "en": "The closure is complete only when the frontier empties.Finitely many states and adding only unseen states ensure enumeration terminates,without sampling a path-length cutoff."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S011",
      "uses": [
        "G001",
        "S010"
      ],
      "before": "reached state=0;declared halt=否;raw successors=[1]",
      "after": "status=active-nonhalt",
      "relation": "implies",
      "rule_id": "halt_stuck_active_are_distinct",
      "conditions": [],
      "explanation": {
        "zh-Hant": "halt標記優先；非halt且無後繼才是stuck，有後繼者為active。沒有出邊不會自動變成成功停止。",
        "en": "The halt designation takes precedence.Only a nonhalt with no successor is stuck;one with successors is active.No outgoing edge does not automatically mean successful termination."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S012",
      "uses": [
        "G001",
        "S011"
      ],
      "before": "reached state=1;declared halt=否;raw successors=[2]",
      "after": "status=active-nonhalt",
      "relation": "implies",
      "rule_id": "halt_stuck_active_are_distinct",
      "conditions": [],
      "explanation": {
        "zh-Hant": "halt標記優先；非halt且無後繼才是stuck，有後繼者為active。沒有出邊不會自動變成成功停止。",
        "en": "The halt designation takes precedence.Only a nonhalt with no successor is stuck;one with successors is active.No outgoing edge does not automatically mean successful termination."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S013",
      "uses": [
        "G001",
        "S012"
      ],
      "before": "reached state=2;declared halt=否;raw successors=[5]",
      "after": "status=active-nonhalt",
      "relation": "implies",
      "rule_id": "halt_stuck_active_are_distinct",
      "conditions": [],
      "explanation": {
        "zh-Hant": "halt標記優先；非halt且無後繼才是stuck，有後繼者為active。沒有出邊不會自動變成成功停止。",
        "en": "The halt designation takes precedence.Only a nonhalt with no successor is stuck;one with successors is active.No outgoing edge does not automatically mean successful termination."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S014",
      "uses": [
        "G001",
        "S013"
      ],
      "before": "reached state=5;declared halt=是;raw successors=[]",
      "after": "status=halt",
      "relation": "implies",
      "rule_id": "halt_stuck_active_are_distinct",
      "conditions": [],
      "explanation": {
        "zh-Hant": "halt標記優先；非halt且無後繼才是stuck，有後繼者為active。沒有出邊不會自動變成成功停止。",
        "en": "The halt designation takes precedence.Only a nonhalt with no successor is stuck;one with successors is active.No outgoing edge does not automatically mean successful termination."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S015",
      "uses": [
        "G001",
        "S014"
      ],
      "before": "natural rank vector=[12, 5, 4, 3, 2, 0];reachable=[0, 1, 2, 5];Halt=[5]",
      "after": "all active ranking edges=[[0, 1], [1, 2], [2, 5]]",
      "relation": "implies",
      "rule_id": "ranking_reachable_nonhalt_edge_scope",
      "conditions": [],
      "explanation": {
        "zh-Hant": "自然數ranking只在可達非halt出邊要求嚴格下降，包含進入halt的邊；halt原始出邊不構成繼續執行。",
        "en": "A natural ranking must strictly decrease on every reachable nonhalt outgoing edge,including edges into halt.Raw outgoing halt edges are not execution steps."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S016",
      "uses": [
        "G001",
        "S015"
      ],
      "before": "rank decrease on edge0,1 := sub(12, 5)",
      "after": "rank decrease on edge0,1 = 7",
      "relation": "calculation",
      "rule_id": "exact_rational_arithmetic",
      "conditions": [],
      "explanation": {
        "zh-Hant": "前態rank減後態rank，必須嚴格大於0才下降。",
        "en": "Subtract successor rank from predecessor rank;strict decrease requires a value>0."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "以精確有理數重算 rank decrease on edge0,1，不以小數近似替代。",
          "en": "Recompute rank decrease on edge0,1 with exact rational arithmetic, not rounded decimals."
        }
      },
      "arithmetic": {
        "operation": "sub",
        "inputs": [
          "12",
          "5"
        ],
        "output": "7",
        "label": "rank decrease on edge0,1"
      }
    },
    {
      "id": "S017",
      "uses": [
        "G001",
        "S016"
      ],
      "before": "edge=[0, 1];ranks=[12, 5];difference=7",
      "after": "strictly decreasing=是",
      "relation": "implies",
      "rule_id": "ranking_each_strict_decrease",
      "conditions": [],
      "explanation": {
        "zh-Hant": "相等不算下降；保留所有不下降的原邊，不只報第一條。",
        "en": "Equality is not decrease.Retain every nondecreasing original edge,not just the first."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S018",
      "uses": [
        "G001",
        "S017"
      ],
      "before": "rank decrease on edge1,2 := sub(5, 4)",
      "after": "rank decrease on edge1,2 = 1",
      "relation": "calculation",
      "rule_id": "exact_rational_arithmetic",
      "conditions": [],
      "explanation": {
        "zh-Hant": "前態rank減後態rank，必須嚴格大於0才下降。",
        "en": "Subtract successor rank from predecessor rank;strict decrease requires a value>0."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "以精確有理數重算 rank decrease on edge1,2，不以小數近似替代。",
          "en": "Recompute rank decrease on edge1,2 with exact rational arithmetic, not rounded decimals."
        }
      },
      "arithmetic": {
        "operation": "sub",
        "inputs": [
          "5",
          "4"
        ],
        "output": "1",
        "label": "rank decrease on edge1,2"
      }
    },
    {
      "id": "S019",
      "uses": [
        "G001",
        "S018"
      ],
      "before": "edge=[1, 2];ranks=[5, 4];difference=1",
      "after": "strictly decreasing=是",
      "relation": "implies",
      "rule_id": "ranking_each_strict_decrease",
      "conditions": [],
      "explanation": {
        "zh-Hant": "相等不算下降；保留所有不下降的原邊，不只報第一條。",
        "en": "Equality is not decrease.Retain every nondecreasing original edge,not just the first."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S020",
      "uses": [
        "G001",
        "S019"
      ],
      "before": "rank decrease on edge2,5 := sub(4, 0)",
      "after": "rank decrease on edge2,5 = 4",
      "relation": "calculation",
      "rule_id": "exact_rational_arithmetic",
      "conditions": [],
      "explanation": {
        "zh-Hant": "前態rank減後態rank，必須嚴格大於0才下降。",
        "en": "Subtract successor rank from predecessor rank;strict decrease requires a value>0."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "以精確有理數重算 rank decrease on edge2,5，不以小數近似替代。",
          "en": "Recompute rank decrease on edge2,5 with exact rational arithmetic, not rounded decimals."
        }
      },
      "arithmetic": {
        "operation": "sub",
        "inputs": [
          "4",
          "0"
        ],
        "output": "4",
        "label": "rank decrease on edge2,5"
      }
    },
    {
      "id": "S021",
      "uses": [
        "G001",
        "S020"
      ],
      "before": "edge=[2, 5];ranks=[4, 0];difference=4",
      "after": "strictly decreasing=是",
      "relation": "implies",
      "rule_id": "ranking_each_strict_decrease",
      "conditions": [],
      "explanation": {
        "zh-Hant": "相等不算下降；保留所有不下降的原邊，不只報第一條。",
        "en": "Equality is not decrease.Retain every nondecreasing original edge,not just the first."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S022",
      "uses": [
        "G001",
        "S021"
      ],
      "before": "reachable=[0, 1, 2, 5];Halt=[5]",
      "after": "reachable nonhalt graph vertices=[0, 1, 2]",
      "relation": "implies",
      "rule_id": "reachable_nonhalt_cycle_scope",
      "conditions": [],
      "explanation": {
        "zh-Hant": "只在可達且非halt的子圖查環；不可達環與halt出邊不影響這個執行問題。",
        "en": "Inspect cycles only in the reachable nonhalt subgraph.Unreachable cycles and outgoing halt edges do not affect this execution question."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S023",
      "uses": [
        "G001",
        "S022"
      ],
      "before": "peeling layer=0;remaining=[0, 1, 2]",
      "after": "vertices with no remaining nonhalt successor=[2]",
      "relation": "implies",
      "rule_id": "finite_cycle_sink_peeling",
      "conditions": [],
      "explanation": {
        "zh-Hant": "逐層移除沒有剩餘非halt後繼的頂點；有向環的頂點不可能被這樣移除。stuck也可能被移除，所以另保留stuck檢查。",
        "en": "Repeatedly remove vertices with no remaining nonhalt successor.A directed cycle cannot be removed this way.Stuck vertices may be removed too,so keep the separate stuck check."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S024",
      "uses": [
        "G001",
        "S023"
      ],
      "before": "peeling layer=1;remaining=[0, 1]",
      "after": "vertices with no remaining nonhalt successor=[1]",
      "relation": "implies",
      "rule_id": "finite_cycle_sink_peeling",
      "conditions": [],
      "explanation": {
        "zh-Hant": "逐層移除沒有剩餘非halt後繼的頂點；有向環的頂點不可能被這樣移除。stuck也可能被移除，所以另保留stuck檢查。",
        "en": "Repeatedly remove vertices with no remaining nonhalt successor.A directed cycle cannot be removed this way.Stuck vertices may be removed too,so keep the separate stuck check."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S025",
      "uses": [
        "G001",
        "S024"
      ],
      "before": "peeling layer=2;remaining=[0]",
      "after": "vertices with no remaining nonhalt successor=[0]",
      "relation": "implies",
      "rule_id": "finite_cycle_sink_peeling",
      "conditions": [],
      "explanation": {
        "zh-Hant": "逐層移除沒有剩餘非halt後繼的頂點；有向環的頂點不可能被這樣移除。stuck也可能被移除，所以另保留stuck檢查。",
        "en": "Repeatedly remove vertices with no remaining nonhalt successor.A directed cycle cannot be removed this way.Stuck vertices may be removed too,so keep the separate stuck check."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S026",
      "uses": [
        "G001",
        "S025"
      ],
      "before": "all reachable nonhalt vertices peeled",
      "after": "reachable nonhalt graph is acyclic",
      "relation": "implies",
      "rule_id": "complete_acyclic_nonhalt_certificate",
      "conditions": [],
      "explanation": {
        "zh-Hant": "全部移除等價無有向環；這不是僅因某次執行看不到環。",
        "en": "Removing all vertices certifies absence of a directed cycle,not merely failure to encounter one on a single run."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S027",
      "uses": [
        "G001",
        "S026"
      ],
      "before": "reachable stuck=[];reachable nonhalt cycle=否",
      "after": "all paths reach Halt=是",
      "relation": "implies",
      "rule_id": "finite_all_paths_termination_joint_gate",
      "conditions": [],
      "explanation": {
        "zh-Hant": "有限模型中，無窮非halt路徑必重複狀態而有環；有限極大路徑若不halt就停在stuck。因此排除兩者才是所有路徑到halt。空Init時是空泛真，不外推任意無限狀態程式。",
        "en": "In a finite model an infinite nonhalt path repeats a state and forms a cycle;a finite maximal nonhalting path ends stuck.Exclude both to ensure every path reaches Halt.Empty Init is vacuous;this does not establish termination of arbitrary infinite-state programs."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    },
    {
      "id": "S028",
      "uses": [
        "G001",
        "S027"
      ],
      "before": "ranking valid=是;reachable stuck=[]",
      "after": "ranking plus no stuck=是;actual all-path termination=是",
      "relation": "implies",
      "rule_id": "ranking_candidate_not_actual_termination_identity",
      "conditions": [],
      "explanation": {
        "zh-Hant": "自然數嚴格下降排除無窮執行，但仍要排除stuck才到成功halt。候選ranking失敗不代表模型不終止；實際終止性由完整有限圖另核。",
        "en": "Strict natural descent excludes infinite execution,but stuck states must also be excluded to reach successful halt.A failed ranking candidate does not mean the model fails to terminate;actual termination is independently checked from the full finite graph."
      },
      "reverse_audit": {
        "kind": "premise_and_result_audit",
        "explanation": {
          "zh-Hant": "回到原始資料與本步條件核對，不把單向推論誤稱等價。",
          "en": "Check against the original data and this step's premises; a one-way implication is not an equivalence."
        }
      },
      "arithmetic": null
    }
  ],
  "math_model": {
    "result": [
      [
        12,
        5,
        4,
        3,
        2,
        0
      ],
      [],
      true,
      [],
      true,
      true
    ]
  },
  "conclusion": {
    "canonical_value": "([12, 5, 4, 3, 2, 0], [], 是, [], 是, 是)",
    "explanation": {
      "zh-Hant": "依上列完整代值及條件核對得到原題答案；原題編號、格式與狀態保持不變。",
      "en": "The full substitutions and premise checks give the original answer; source identity,format and status are unchanged."
    }
  },
  "definition_note": {
    "zh-Hant": "沿用原題明示的論域、假設與來源 MKO 定義。本題已完成第二對話數理與中英語義覆核，並由原始參數逐題獨立重算模型、答案與每個算術步驟；原題仍為 candidate。",
    "en": "Use the original question domain, assumptions and cited MKO definitions. This item has second-context mathematical and bilingual review, with the model, answer and every arithmetic step independently recomputed from the original parameters; the source question remains a candidate."
  },
  "source": {
    "input_commit": "0f7be61e2c22317a4075561dc822c87d881a50db",
    "question_binding": {
      "batch_id": "batch-20261013-advance-20261019-r05-algorithm-correctness-foundations",
      "batch_path": "public/data/questions/batches/batch-20261013-advance-20261019-r05-algorithm-correctness-foundations/questions.jsonl",
      "batch_sha256": "703aa1b3f31f48ec8b83f7f6c0f3fd482538ae384d981ee9c41e22de7727dc2f",
      "original_line": 57,
      "original_line_sha256": "56981852c4ba579c7fc627693f087bfff715bd1b2b64485c154c2f859d584b1c",
      "question_compact_sha256": "764649f8ca2b7daeb0738e06ce551a25e65b1079ca922714280a28468b131f9d",
      "english_row_compact_sha256": "3807964409ef3b507a114e9bade628edc3d661311697c8fcf39672c6539b6a7b",
      "english_manifest_path": "public/data/i18n/editions/batch-20261013-advance-20261019-r05-algorithm-correctness-foundations.en.json",
      "english_rows_path": "public/data/i18n/questions/batch-20261013-advance-20261019-r05-algorithm-correctness-foundations.en.jsonl"
    },
    "mko_bindings": {
      "mko-algorithm-correctness": {
        "sha256": "d9789607b7391a897a2a291245a0699d81ef6dbbdfac86b9b86c04cf7dc0ad27",
        "english_sha256": "33d91b7ce0b46158c3d90a3ec3dfc6506626564456beeabe3e4337d620f07e87",
        "original_path": "public/data/mko/algorithm-correctness.json",
        "english_path": "public/data/i18n/editions/mko-algorithm-correctness.en.json"
      }
    },
    "selected_manifest_sha256": "5233edba9654a6cffd8b6b2d83c932f82ded15f9c0b7c733bd049943e672acff",
    "selected_part_sha256": "2cf5df7bf9c3d48dfd41d968723b60d910c4ecfec9c2089d22ac1cda059a6086",
    "original_candidate_sha256": "dfc21b23211cc7f8e9bf3da01bd89bac34aa6e89d4f09edd51f60dcf4a8ddf6d",
    "original_candidate_line_sha256": "dfc21b23211cc7f8e9bf3da01bd89bac34aa6e89d4f09edd51f60dcf4a8ddf6d"
  },
  "historical_source_state": {
    "review_state": {
      "derivation": "candidate_authored_and_locally_checked",
      "source_question_state": "candidate",
      "independent_AI_or_human_review": "NOT_PERFORMED",
      "formalization": "not_formalized",
      "Lean": "NOT_RUN"
    },
    "scope_note": {
      "zh-Hant": "來源綁定教學推導候選；精確核對不等於獨立AI／人工審查或一般形式證明。原題、答案、MKO、公式、AST與歷史不變。",
      "en": "Source-bound pedagogical derivation candidate.Exact checking is not independent AI/human review or general formal proof.Original questions,answers,MKOs,formulas,ASTs and history remain unchanged."
    },
    "label": "Frozen producer metadata; current per-question review is separate below."
  },
  "revision": {
    "id": "review-20261026-006-p19",
    "review_date": "2026-10-26",
    "owner_authorized_reader_publication": true,
    "scope": "One hundred sixty family prototypes and their mathematical/bilingual reasoning variants, stems, boundary statements and every distinct explanation shape were reviewed in a context independent of the producer; parameter substitutions, source bindings, full math models, both answer strings and every arithmetic step were independently reconstructed per question from the original parameters only, with negative controls. This grouped method does not claim a separate literal AI reading of every repeated sentence or an extra AI voter.",
    "review_receipts": {
      "semantic_review_sha256": "bd35da62087a15d6b89b45585dc46e89b9efbe097cba7b3c707b5030496f013c",
      "question_first_witness_sha256": "fab45a10d8ac95c7d61d32e47d1bdd3ca862c17c3289a6bf4b01d4dc9492fbb6"
    },
    "status": "second_context_reviewed",
    "mathematical_semantics": true,
    "bilingual_semantics": true,
    "steps_reviewed": 28,
    "method": "family_template_semantic_review_plus_independent_per_instance_reconstruction",
    "exact_question_first_check": {
      "model_sha256": "4735bee1cd7ee119542e159f629de50061db3713e63a449098b96219e89769e3",
      "arithmetic_steps": 3
    },
    "uses_answer_as_premise": false,
    "human_review": "NOT_PERFORMED",
    "formalization": "not_formalized",
    "Lean": "NOT_RUN",
    "Canonical_truth_promotion": false,
    "authority": "Owner-authorized reviewed reader publication; original question/candidate states remain historical and unchanged."
  }
}
