# Proof dependency database — GRAPH_VERSION: 4 ROOTS: CORPUS: CONVENTIONS: STANDING_ASSUMPTIONS: EXTERNAL_POLICY: FROZEN_ANCHORS: FROZEN_MANIFEST: > WRITER: GLOBAL_REVIEWER: GLOBAL_REVIEW_REF: The dependency direction is `NODE -> prerequisite`. `DEPS` is conjunctive. `ROUTES` lists alternative `KIND: route` nodes; one route is sufficient. Lean fields are initialized planning metadata and are not evaluated here. This source-extraction skill writes only `NOT_STARTED`, `EXTERNAL`, or `ASSUMED`. A later Lean workflow owns every subsequent status and its meaning. `CONTRACT_ID` and `CONTRACT_VERSION` together form the versioned contract identity and are extracted only from the source statement. `DEPS` may never add a premise to them: proof ingredients belong in the graph, not in the theorem's hypothesis list. `FROZEN_ANCHORS` is the graph's ABI boundary. Each named node corresponds to one author-approved Lean declaration file and exact declaration name. With `--source-root`, the linter hashes the JSON manifest file named in the header, then binds every frozen node to its unique manifest entry by anchor ID, path, export, contract ID/version, and elaborated ABI hash. It deliberately neither reads Lean bodies nor interprets a manifest entry's proof/status fields. A changed contract requires a new versioned declaration, anchor, and manifest hash; prior audit evidence does not transfer. The graph may add or correct `DEPS`, but can never alter an anchor's declaration, statement, or ABI. ## Node schema ```text NODE: KIND: theorem|proposition|lemma|corollary|claim|definition|display|step|application|route|external|assumption TITLE: STATEMENT_SOURCE: PROOF_SOURCE: CONTRACT_ID: CONTRACT_VERSION: SOURCE_HYPOTHESES: SOURCE_QUANTIFIERS: SOURCE_CONCLUSION: CONSTANT_SCOPE: FROZEN_FILE: FROZEN_DECL: FROZEN_ANCHOR_ID: FROZEN_ABI_SHA256: <64 lowercase hexadecimal manifest abi_sha256 for a FROZEN_ANCHORS ID | -> DEPS: ROUTES: ROUTE_FOR: EDGE: | | TOPOLOGY_STATUS: PROPOSED|REVIEWED|DISPUTED EXTRACTOR: REVIEWER: LEAN_STATUS: LEAN_REF: LEAN_NOTE: NOTE: ``` For a dependency-free node, omit `EDGE:` lines. For every ID in `DEPS` or `ROUTES`, include exactly one matching `EDGE:` line. Every `ROOTS` ID must also appear in `FROZEN_ANCHORS`. Frozen anchors may have only `KIND: theorem|proposition|lemma|corollary|claim|definition|display`; they may not be route, step, application, assumption, or external nodes. Each frozen file and declaration is unique. Ordinary nodes use `-` in all four `FROZEN_*` fields. ## Nodes NODE: KIND: theorem TITLE: STATEMENT_SOURCE: PROOF_SOURCE: CONTRACT_ID: CONTRACT_VERSION: 1 SOURCE_HYPOTHESES: SOURCE_QUANTIFIERS: SOURCE_CONCLUSION: CONSTANT_SCOPE: FROZEN_FILE: Frozen/.lean FROZEN_DECL: FROZEN_ANCHOR_ID: FROZEN_ABI_SHA256: <64 lowercase hexadecimal manifest ABI hash> DEPS: ROUTES: - ROUTE_FOR: - TOPOLOGY_STATUS: PROPOSED EXTRACTOR: REVIEWER: - LEAN_STATUS: NOT_STARTED LEAN_REF: - LEAN_NOTE: - NOTE: source extraction pending independent review ## Append-only structural amendments ```text AMEND: TARGET: AUTHOR: REVIEWER: ADD_DEPS: DROP_DEPS: ADD_ROUTES: DROP_ROUTES: SET_TITLE: SET_STATEMENT_SOURCE: SET_PROOF_SOURCE: SET_CONTRACT_ID: SET_CONTRACT_VERSION: SET_SOURCE_HYPOTHESES: SET_SOURCE_QUANTIFIERS: SET_SOURCE_CONCLUSION: SET_CONSTANT_SCOPE: SET_ROUTE_FOR: EDGE: | | NOTE: ``` An amendment may correct proof topology around a frozen anchor, but may not use `SET_STATEMENT_SOURCE`, `SET_PROOF_SOURCE`, `SET_CONTRACT_ID`, `SET_CONTRACT_VERSION`, or a `SET_SOURCE_*` field on it. Frozen source locators and statement-contract fields require a new frozen declaration and graph version; no amendment field exists for changing `FROZEN_FILE`, `FROZEN_DECL`, `FROZEN_ANCHOR_ID`, or `FROZEN_ABI_SHA256`. Run `proof_depgraph.py --write-dashboard` to replace this body.