← 返回
未分类 中文

openmath-open-theorem

Queries open formal verification theorems from the OpenMath platform. Use when the user asks for a list of open theorems, wants Lean or Rocq-specific theorem...
从OpenMath平台查询开放形式验证定理。当用户请求开放定理列表或需要Lean或Rocq特定的定理时使用。
bennyzhe
未分类 clawhub v1.0.2 1 版本 100000 Key: 无需
★ 0
Stars
📥 537
下载
💾 1
安装
1
版本
#latest

概述

OpenMath Open Theorem

Instructions

Query the OpenMath library to discover and scaffold open theorems. The discovery scripts use OPENMATH_SITE_URL and OPENMATH_API_HOST when set, and otherwise fall back to the default production endpoints.

First-run gate

Before discovery on a new machine or workspace, check the shared openmath-env.json. Auto-discovery only checks ./.openmath-skills/openmath-env.json and ~/.openmath-skills/openmath-env.json.

This gate is mandatory. If openmath-env.json is missing, or if it exists but preferred_language is missing, stop. Do not query the OpenMath theorem list, theorem detail, or download APIs until setup is complete.

If no config exists, stop and ask the user where to create it, then collect at least:

  • preferred_language: lean or rocq
  • config visibility / save scope: ./.openmath-skills or ~/.openmath-skills
  • the submit/authz fields only if the user wants end-to-end submission later

Command:

python3 scripts/check_openmath_env.py

Workflow checklist

  • [ ] Env: Run check_openmath_env.py. If openmath-env.json is missing from ./.openmath-skills and ~/.openmath-skills, or preferred_language is missing, ask the user to finish setup before continuing.
  • [ ] Explore: Run fetch_theorems.py [language] only after the first-run gate passes. If no language is passed, it uses preferred_language from openmath-env.json and must not fan out to other languages automatically.
  • [ ] Detail: Run fetch_theorem_detail.py only after the first-run gate passes.
  • [ ] Download: Run download_theorem.py only after the first-run gate passes.
  • [ ] Prove: Use the openmath-lean-theorem skill for environment setup, preflight checks, and proving.
  • [ ] Submit: Use the openmath-submit-theorem skill to hash and submit the proof.
  • [ ] Verify: Run fetch_theorem_detail.py and confirm your address is the prover and status is verified.
  • [ ] Claim: Use the openmath-claim-reward skill to generate the withdrawal command.

Scripts

ScriptCommandUse when
---------------------------
Shared env checkpython3 scripts/check_openmath_env.py [--config ]Mandatory first-run gate; validates shared config, preferred language, and the resolved OpenMath website/API endpoints.
List open theoremspython3 scripts/fetch_theorems.py [--config ] [language]Listing or filtering open theorems after the first-run gate passes. language: optional lean or rocq. Without an explicit CLI language, query only the configured preferred_language.
Theorem detailpython3 scripts/fetch_theorem_detail.py [--config ] Need description, metadata, and formal definition (source) for a theorem ID; refuses to run until the first-run gate passes.
Download & scaffoldpython3 scripts/download_theorem.py [--config ] [--output-dir ] [--force]Creating a local Lean or Rocq proof workspace after the first-run gate passes.

openmath_api.py is the shared API client. openmath_env_config.py reads shared user preferences from openmath-env.json.

Notes

  • Endpoints: Default website is https://openmath.shentu.org; default API host is https://openmath-be.shentu.org. Runtime overrides: OPENMATH_SITE_URL, OPENMATH_API_HOST.
  • Language: User-facing and API language naming is rocq.
  • No fallback: If preferred_language is lean, query only Lean by default. If no theorems are found, report that result and stop; do not automatically query Rocq, and vice versa.
  • Lean scaffold: Pins Lean and mathlib4 to v4.28.0. Rocq scaffold is _CoqProject-based.
  • After download: Use the openmath-lean-theorem skill for Lean environment setup, preflight, external skill installation, and the proving workflow.

References

Load when needed (one level from this file):

版本历史

共 1 个版本

  • v1.0.2 当前
    2026-03-30 08:47 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

openmath-claim-reward

bennyzhe
认领 OpenMath 平台赚取的奖励。用于用户查询可领取的导入/证明奖励,或在...后提取已验证的 Shentu 奖励。
★ 0 📥 456

openmath-submit-theorem

bennyzhe
使用两阶段提交-揭示流程向OpenMath平台提交证明。适用于用户希望提交证明哈希或在平台上揭示Lean/Rocq证明的场景。
★ 0 📥 573

openmath-rocq-theorem

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