← 返回
未分类 中文

openmath-claim-reward

Claims earned rewards from the OpenMath platform. Use when the user wants to query claimable imported/proof rewards or withdraw verified Shentu rewards after...
认领 OpenMath 平台赚取的奖励。用于用户查询可领取的导入/证明奖励,或在...后提取已验证的 Shentu 奖励。
bennyzhe
未分类 clawhub v1.0.4 1 版本 99775.8 Key: 无需
★ 0
Stars
📥 445
下载
💾 1
安装
1
版本
#latest

概述

OpenMath Claim Reward

Instructions

Query and withdraw rewards for verified OpenMath activity on Shentu. Flow: query bounty rewards → withdraw via bounty withdraw-rewards → wait 5–10 s → re-query. Uses SHENTU_CHAIN_ID and SHENTU_NODE_URL for runtime chain/RPC settings, with built-in mainnet defaults if unset. Shared config resolution order: --config OPENMATH_ENV_CONFIG./.openmath-skills/openmath-env.json~/.openmath-skills/openmath-env.json. If OPENMATH_ENV_CONFIG is set, treat it as the selected config path. If that file is missing or invalid, stop and fix it instead of silently falling back.

Requires trusted local python3 and shentud binaries on PATH. Read-only reward queries shell out to local shentud and query a Shentu RPC endpoint. Withdrawals additionally rely on the local OS keyring via shentud --keyring-backend os. Before any withdrawal, confirm the key name, resolved address, and node URL with the user.

First-run gate

If the user already provided an address explicitly, reward query can run immediately.

If no address was provided, auto-discover prover_address from OPENMATH_ENV_CONFIG when it is set; otherwise check only ./.openmath-skills/openmath-env.json or ~/.openmath-skills/openmath-env.json. If no usable config exists, or if the config exists but prover_address is missing, do not guess the address. Follow references/init-setup.md.

For withdrawals, do not proceed until a local os keyring key is known for the same address.

Do not broadcast a withdrawal until the user confirms the matching key name/address and the RPC node they want to use.

Workflow checklist

  • [ ] Env: If needed, export SHENTU_CHAIN_ID / SHENTU_NODE_URL, or set OPENMATH_ENV_CONFIG to a specific openmath-env.json; otherwise use the built-in mainnet defaults and standard config auto-discovery.
  • [ ] Address: Use an explicit address, or let query_reward_status.py rewards auto-discover prover_address from OPENMATH_ENV_CONFIG or the standard openmath-env.json locations.
  • [ ] Query: Run query_reward_status.py rewards [address] (or shentud q bounty rewards
    --node ) to see imported_rewards and/or proof_rewards.
  • [ ] Withdraw: If any bucket is non-empty, first make sure a local os keyring key controls the same address, confirm shentud keys show -a --keyring-backend os matches the reward address, then run shentud tx bounty withdraw-rewards --from --keyring-backend os --chain-id --node --gas-prices 0.025uctk --gas-adjustment 2.0 --gas auto (use SHENTU_CHAIN_ID / SHENTU_NODE_URL or the built-in defaults).
  • [ ] Wait: 5–10 s for block inclusion.
  • [ ] Re-query: Run query_reward_status.py tx --wait-seconds 6, then query_reward_status.py rewards
    --wait-seconds 6 to confirm withdrawal; empty buckets are reported as zero, not error.

Scripts

ScriptCommandUse when
---------------------------
Query rewardspython3 scripts/query_reward_status.py rewards [address] [--config ] [--wait-seconds 0]Checking claimable imported_rewards and proof_rewards for an address, or auto-discovering prover_address from --config, OPENMATH_ENV_CONFIG, or the default config locations when omitted.
Query txpython3 scripts/query_reward_status.py tx [--wait-seconds 6]After withdraw broadcast to confirm inclusion.

Withdraw is done with raw shentud tx bounty withdraw-rewards --keyring-backend os (see workflow above).

Notes

  • Buckets: imported_rewards (theorem imported/referenced), proof_rewards (proofs verified). One withdraw pulls both if present.
  • Mainnet: Default --chain-id shentu-2.2 --node https://rpc.shentu.org:443.
  • Config override: Set OPENMATH_ENV_CONFIG=/path/to/openmath-env.json or use --config if you want a non-default config path.
  • Requirements: Requires trusted local python3 and shentud on PATH.
  • Env vars: OPENMATH_ENV_CONFIG, SHENTU_CHAIN_ID, and SHENTU_NODE_URL are optional overrides, not required for the default mainnet flow.
  • Keyring: Always use --keyring-backend os for reward withdrawal commands generated from this skill.
  • Trust boundary: Reward queries shell out to local shentud; withdrawals also sign through the local OS keyring. Verify the key name, resolved address, and RPC/node URL before broadcasting.

References

Load when needed (one level from this file):

Identity setup for theorem submission still lives in openmath-submit-theorem, but reward querying itself does not require openmath-env.json.

版本历史

共 1 个版本

  • v1.0.4 当前
    2026-03-30 18:04 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

openmath-lean-theorem

bennyzhe
配置 Lean 环境,安装外部证明插件,执行预检检查,并引导证明已下载 OpenMath Lean 定理的工作流...
★ 0 📥 489

openmath-open-theorem

bennyzhe
从OpenMath平台查询开放形式验证定理。当用户请求开放定理列表或需要Lean或Rocq特定的定理时使用。
★ 0 📥 548

openmath-rocq-theorem

bennyzhe
配置 Rocq 环境,执行预检,并引导 OpenMath Rocq 定理的证明工作流。适用于用户需要设置 Rocq 工具链、运行环境检查或完成定理证明任务的场景。
★ 0 📥 385