{
  "_format": "hh-sol-artifact-1",
  "contractName": "PoraMine",
  "sourceName": "contracts/miner/Mine.sol",
  "abi": [
    {
      "inputs": [
        {
          "internalType": "uint256",
          "name": "settings",
          "type": "uint256"
        }
      ],
      "stateMutability": "nonpayable",
      "type": "constructor"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": true,
          "internalType": "bytes32",
          "name": "minerId",
          "type": "bytes32"
        },
        {
          "indexed": true,
          "internalType": "address",
          "name": "beneficiary",
          "type": "address"
        }
      ],
      "name": "NewMinerId",
      "type": "event"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": true,
          "internalType": "uint256",
          "name": "epoch",
          "type": "uint256"
        },
        {
          "indexed": true,
          "internalType": "bytes32",
          "name": "minerId",
          "type": "bytes32"
        },
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "epochIndex",
          "type": "uint256"
        },
        {
          "indexed": false,
          "internalType": "uint256",
          "name": "recallPosition",
          "type": "uint256"
        }
      ],
      "name": "NewSubmission",
      "type": "event"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": true,
          "internalType": "bytes32",
          "name": "role",
          "type": "bytes32"
        },
        {
          "indexed": true,
          "internalType": "bytes32",
          "name": "previousAdminRole",
          "type": "bytes32"
        },
        {
          "indexed": true,
          "internalType": "bytes32",
          "name": "newAdminRole",
          "type": "bytes32"
        }
      ],
      "name": "RoleAdminChanged",
      "type": "event"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": true,
          "internalType": "bytes32",
          "name": "role",
          "type": "bytes32"
        },
        {
          "indexed": true,
          "internalType": "address",
          "name": "account",
          "type": "address"
        },
        {
          "indexed": true,
          "internalType": "address",
          "name": "sender",
          "type": "address"
        }
      ],
      "name": "RoleGranted",
      "type": "event"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": true,
          "internalType": "bytes32",
          "name": "role",
          "type": "bytes32"
        },
        {
          "indexed": true,
          "internalType": "address",
          "name": "account",
          "type": "address"
        },
        {
          "indexed": true,
          "internalType": "address",
          "name": "sender",
          "type": "address"
        }
      ],
      "name": "RoleRevoked",
      "type": "event"
    },
    {
      "anonymous": false,
      "inputs": [
        {
          "indexed": true,
          "internalType": "bytes32",
          "name": "minerId",
          "type": "bytes32"
        },
        {
          "indexed": true,
          "internalType": "address",
          "name": "from",
          "type": "address"
        },
        {
          "indexed": true,
          "internalType": "address",
          "name": "to",
          "type": "address"
        }
      ],
      "name": "UpdateMinerId",
      "type": "event"
    },
    {
      "inputs": [],
      "name": "DEFAULT_ADMIN_ROLE",
      "outputs": [
        {
          "internalType": "bytes32",
          "name": "",
          "type": "bytes32"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "PARAMS_ADMIN_ROLE",
      "outputs": [
        {
          "internalType": "bytes32",
          "name": "",
          "type": "bytes32"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [
        {
          "components": [
            {
              "internalType": "bytes32",
              "name": "contextDigest",
              "type": "bytes32"
            },
            {
              "internalType": "bytes32",
              "name": "nonce",
              "type": "bytes32"
            },
            {
              "internalType": "bytes32",
              "name": "minerId",
              "type": "bytes32"
            },
            {
              "components": [
                {
                  "internalType": "uint256",
                  "name": "startPosition",
                  "type": "uint256"
                },
                {
                  "internalType": "uint256",
                  "name": "mineLength",
                  "type": "uint256"
                },
                {
                  "internalType": "uint64",
                  "name": "shardId",
                  "type": "uint64"
                },
                {
                  "internalType": "uint64",
                  "name": "shardMask",
                  "type": "uint64"
                }
              ],
              "internalType": "struct RecallRange",
              "name": "range",
              "type": "tuple"
            },
            {
              "internalType": "uint256",
              "name": "recallPosition",
              "type": "uint256"
            },
            {
              "internalType": "uint256",
              "name": "sealOffset",
              "type": "uint256"
            },
            {
              "internalType": "bytes32",
              "name": "sealedContextDigest",
              "type": "bytes32"
            },
            {
              "internalType": "bytes32[128]",
              "name": "sealedData",
              "type": "bytes32[128]"
            },
            {
              "internalType": "bytes32[]",
              "name": "merkleProof",
              "type": "bytes32[]"
            }
          ],
          "internalType": "struct MineLib.PoraAnswer",
          "name": "answer",
          "type": "tuple"
        },
        {
          "components": [
            {
              "internalType": "uint256",
              "name": "epoch",
              "type": "uint256"
            },
            {
              "internalType": "uint256",
              "name": "mineStart",
              "type": "uint256"
            },
            {
              "internalType": "bytes32",
              "name": "flowRoot",
              "type": "bytes32"
            },
            {
              "internalType": "uint256",
              "name": "flowLength",
              "type": "uint256"
            },
            {
              "internalType": "bytes32",
              "name": "blockDigest",
              "type": "bytes32"
            },
            {
              "internalType": "bytes32",
              "name": "digest",
              "type": "bytes32"
            }
          ],
          "internalType": "struct MineContext",
          "name": "context",
          "type": "tuple"
        }
      ],
      "name": "basicCheck",
      "outputs": [],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "bytes32",
          "name": "",
          "type": "bytes32"
        }
      ],
      "name": "beneficiaries",
      "outputs": [
        {
          "internalType": "address",
          "name": "",
          "type": "address"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "canSubmit",
      "outputs": [
        {
          "internalType": "bool",
          "name": "",
          "type": "bool"
        }
      ],
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "bytes32",
          "name": "minerId",
          "type": "bytes32"
        }
      ],
      "name": "computeWorkerContext",
      "outputs": [
        {
          "components": [
            {
              "components": [
                {
                  "internalType": "uint256",
                  "name": "epoch",
                  "type": "uint256"
                },
                {
                  "internalType": "uint256",
                  "name": "mineStart",
                  "type": "uint256"
                },
                {
                  "internalType": "bytes32",
                  "name": "flowRoot",
                  "type": "bytes32"
                },
                {
                  "internalType": "uint256",
                  "name": "flowLength",
                  "type": "uint256"
                },
                {
                  "internalType": "bytes32",
                  "name": "blockDigest",
                  "type": "bytes32"
                },
                {
                  "internalType": "bytes32",
                  "name": "digest",
                  "type": "bytes32"
                }
              ],
              "internalType": "struct MineContext",
              "name": "context",
              "type": "tuple"
            },
            {
              "internalType": "uint256",
              "name": "poraTarget",
              "type": "uint256"
            },
            {
              "internalType": "bytes32",
              "name": "subtaskDigest",
              "type": "bytes32"
            },
            {
              "internalType": "uint64",
              "name": "maxShards",
              "type": "uint64"
            }
          ],
          "internalType": "struct WorkerContext",
          "name": "answer",
          "type": "tuple"
        }
      ],
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "currentSubmissions",
      "outputs": [
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "dataProofEnabled",
      "outputs": [
        {
          "internalType": "bool",
          "name": "",
          "type": "bool"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "difficultyAdjustRatio",
      "outputs": [
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "fixedDifficulty",
      "outputs": [
        {
          "internalType": "bool",
          "name": "",
          "type": "bool"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "flow",
      "outputs": [
        {
          "internalType": "address",
          "name": "",
          "type": "address"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "bytes32",
          "name": "role",
          "type": "bytes32"
        }
      ],
      "name": "getRoleAdmin",
      "outputs": [
        {
          "internalType": "bytes32",
          "name": "",
          "type": "bytes32"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "bytes32",
          "name": "role",
          "type": "bytes32"
        },
        {
          "internalType": "uint256",
          "name": "index",
          "type": "uint256"
        }
      ],
      "name": "getRoleMember",
      "outputs": [
        {
          "internalType": "address",
          "name": "",
          "type": "address"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "bytes32",
          "name": "role",
          "type": "bytes32"
        }
      ],
      "name": "getRoleMemberCount",
      "outputs": [
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [
        {
          "components": [
            {
              "internalType": "uint256",
              "name": "epoch",
              "type": "uint256"
            },
            {
              "internalType": "uint256",
              "name": "mineStart",
              "type": "uint256"
            },
            {
              "internalType": "bytes32",
              "name": "flowRoot",
              "type": "bytes32"
            },
            {
              "internalType": "uint256",
              "name": "flowLength",
              "type": "uint256"
            },
            {
              "internalType": "bytes32",
              "name": "blockDigest",
              "type": "bytes32"
            },
            {
              "internalType": "bytes32",
              "name": "digest",
              "type": "bytes32"
            }
          ],
          "internalType": "struct MineContext",
          "name": "context",
          "type": "tuple"
        },
        {
          "internalType": "bytes32",
          "name": "minerId",
          "type": "bytes32"
        }
      ],
      "name": "getSubtaskDigest",
      "outputs": [
        {
          "internalType": "bytes32",
          "name": "",
          "type": "bytes32"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "bytes32",
          "name": "role",
          "type": "bytes32"
        },
        {
          "internalType": "address",
          "name": "account",
          "type": "address"
        }
      ],
      "name": "grantRole",
      "outputs": [],
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "bytes32",
          "name": "role",
          "type": "bytes32"
        },
        {
          "internalType": "address",
          "name": "account",
          "type": "address"
        }
      ],
      "name": "hasRole",
      "outputs": [
        {
          "internalType": "bool",
          "name": "",
          "type": "bool"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "uint256",
          "name": "difficulty",
          "type": "uint256"
        },
        {
          "internalType": "address",
          "name": "flow_",
          "type": "address"
        },
        {
          "internalType": "address",
          "name": "reward_",
          "type": "address"
        }
      ],
      "name": "initialize",
      "outputs": [],
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "initialized",
      "outputs": [
        {
          "internalType": "bool",
          "name": "",
          "type": "bool"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "lastMinedEpoch",
      "outputs": [
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "maxShards",
      "outputs": [
        {
          "internalType": "uint64",
          "name": "",
          "type": "uint64"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "minDifficulty",
      "outputs": [
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "nSubtasks",
      "outputs": [
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [
        {
          "components": [
            {
              "internalType": "bytes32",
              "name": "contextDigest",
              "type": "bytes32"
            },
            {
              "internalType": "bytes32",
              "name": "nonce",
              "type": "bytes32"
            },
            {
              "internalType": "bytes32",
              "name": "minerId",
              "type": "bytes32"
            },
            {
              "components": [
                {
                  "internalType": "uint256",
                  "name": "startPosition",
                  "type": "uint256"
                },
                {
                  "internalType": "uint256",
                  "name": "mineLength",
                  "type": "uint256"
                },
                {
                  "internalType": "uint64",
                  "name": "shardId",
                  "type": "uint64"
                },
                {
                  "internalType": "uint64",
                  "name": "shardMask",
                  "type": "uint64"
                }
              ],
              "internalType": "struct RecallRange",
              "name": "range",
              "type": "tuple"
            },
            {
              "internalType": "uint256",
              "name": "recallPosition",
              "type": "uint256"
            },
            {
              "internalType": "uint256",
              "name": "sealOffset",
              "type": "uint256"
            },
            {
              "internalType": "bytes32",
              "name": "sealedContextDigest",
              "type": "bytes32"
            },
            {
              "internalType": "bytes32[128]",
              "name": "sealedData",
              "type": "bytes32[128]"
            },
            {
              "internalType": "bytes32[]",
              "name": "merkleProof",
              "type": "bytes32[]"
            }
          ],
          "internalType": "struct MineLib.PoraAnswer",
          "name": "answer",
          "type": "tuple"
        },
        {
          "internalType": "bytes32",
          "name": "subtaskDigest",
          "type": "bytes32"
        }
      ],
      "name": "pora",
      "outputs": [
        {
          "internalType": "bytes32",
          "name": "",
          "type": "bytes32"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "poraTarget",
      "outputs": [
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "poraVersion",
      "outputs": [
        {
          "internalType": "uint64",
          "name": "",
          "type": "uint64"
        }
      ],
      "stateMutability": "pure",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "bytes32",
          "name": "role",
          "type": "bytes32"
        },
        {
          "internalType": "address",
          "name": "account",
          "type": "address"
        }
      ],
      "name": "renounceRole",
      "outputs": [],
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "address",
          "name": "beneficiary",
          "type": "address"
        },
        {
          "internalType": "uint64",
          "name": "seed",
          "type": "uint64"
        }
      ],
      "name": "requestMinerId",
      "outputs": [],
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "bytes32",
          "name": "role",
          "type": "bytes32"
        },
        {
          "internalType": "address",
          "name": "account",
          "type": "address"
        }
      ],
      "name": "revokeRole",
      "outputs": [],
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "reward",
      "outputs": [
        {
          "internalType": "address",
          "name": "",
          "type": "address"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "sealDataEnabled",
      "outputs": [
        {
          "internalType": "bool",
          "name": "",
          "type": "bool"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "uint256",
          "name": "difficultyAdjustRatio_",
          "type": "uint256"
        }
      ],
      "name": "setDifficultyAdjustRatio",
      "outputs": [],
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "uint64",
          "name": "maxShards_",
          "type": "uint64"
        }
      ],
      "name": "setMaxShards",
      "outputs": [],
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "uint256",
          "name": "minDifficulty_",
          "type": "uint256"
        }
      ],
      "name": "setMinDifficulty",
      "outputs": [],
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "uint256",
          "name": "nSubtasks_",
          "type": "uint256"
        }
      ],
      "name": "setNumSubtasks",
      "outputs": [],
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "uint256",
          "name": "targetMineBlocks_",
          "type": "uint256"
        }
      ],
      "name": "setTargetMineBlocks",
      "outputs": [],
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "uint256",
          "name": "targetSubmissions_",
          "type": "uint256"
        }
      ],
      "name": "setTargetSubmissions",
      "outputs": [],
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "inputs": [
        {
          "components": [
            {
              "internalType": "bytes32",
              "name": "contextDigest",
              "type": "bytes32"
            },
            {
              "internalType": "bytes32",
              "name": "nonce",
              "type": "bytes32"
            },
            {
              "internalType": "bytes32",
              "name": "minerId",
              "type": "bytes32"
            },
            {
              "components": [
                {
                  "internalType": "uint256",
                  "name": "startPosition",
                  "type": "uint256"
                },
                {
                  "internalType": "uint256",
                  "name": "mineLength",
                  "type": "uint256"
                },
                {
                  "internalType": "uint64",
                  "name": "shardId",
                  "type": "uint64"
                },
                {
                  "internalType": "uint64",
                  "name": "shardMask",
                  "type": "uint64"
                }
              ],
              "internalType": "struct RecallRange",
              "name": "range",
              "type": "tuple"
            },
            {
              "internalType": "uint256",
              "name": "recallPosition",
              "type": "uint256"
            },
            {
              "internalType": "uint256",
              "name": "sealOffset",
              "type": "uint256"
            },
            {
              "internalType": "bytes32",
              "name": "sealedContextDigest",
              "type": "bytes32"
            },
            {
              "internalType": "bytes32[128]",
              "name": "sealedData",
              "type": "bytes32[128]"
            },
            {
              "internalType": "bytes32[]",
              "name": "merkleProof",
              "type": "bytes32[]"
            }
          ],
          "internalType": "struct MineLib.PoraAnswer",
          "name": "answer",
          "type": "tuple"
        }
      ],
      "name": "submit",
      "outputs": [],
      "stateMutability": "nonpayable",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "bytes4",
          "name": "interfaceId",
          "type": "bytes4"
        }
      ],
      "name": "supportsInterface",
      "outputs": [
        {
          "internalType": "bool",
          "name": "",
          "type": "bool"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "targetMineBlocks",
      "outputs": [
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "targetSubmissions",
      "outputs": [
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [],
      "name": "targetSubmissionsNextEpoch",
      "outputs": [
        {
          "internalType": "uint256",
          "name": "",
          "type": "uint256"
        }
      ],
      "stateMutability": "view",
      "type": "function"
    },
    {
      "inputs": [
        {
          "internalType": "address",
          "name": "to",
          "type": "address"
        },
        {
          "internalType": "bytes32",
          "name": "minerId",
          "type": "bytes32"
        }
      ],
      "name": "transferBeneficial",
      "outputs": [],
      "stateMutability": "nonpayable",
      "type": "function"
    }
  ],
  "bytecode": "[encoded data, 31040 characters]",
  "deployedBytecode": "[encoded data, 30672 characters]",
  "linkReferences": {},
  "deployedLinkReferences": {}
}
