prove skill
Formal theorem proving with research, testing, and verification phases
Is the prove skill safe?
Read the findings before you install it. We read 1 file in the folder on 2026-09-28.
- high
SKILL.md:25Downloads a script and runs it in one step, so what runs is whatever that server sends that day. Common for installers, and still worth a look at the address.
curl https://raw.githubusercontent.com/leanprover/elan/master/elan-init.sh -sSf | sh
Install the prove skill
A skill is a folder. Copy it into your agent's skills folder and the agent loads it when the task matches its description.
git clone --depth 1 https://github.com/parcadei/Continuous-Claude-v3.git /tmp/Continuous-Claude-v3 mkdir -p ~/.claude/skills cp -r /tmp/Continuous-Claude-v3/.claude/skills/prove ~/.claude/skills/prove
In the Claude apps, zip the folder and upload it from the Skills settings. The folder on GitHub
The instructions your agent would load
SKILL.md as published, without the frontmatter. Read it on GitHub
/prove - Machine-Verified Proofs (5-Phase Workflow)
For mathematicians who want verified proofs without learning Lean syntax.
Prerequisites
Before using this skill, check Lean4 is installed:
# Check if lake is available
command -v lake &>/dev/null && echo "Lean4 installed" || echo "Lean4 NOT installed"If not installed:
# Install elan (Lean version manager)
curl https://raw.githubusercontent.com/leanprover/elan/master/elan-init.sh -sSf | sh
# Restart shell, then verify
lake --versionFirst run of /prove will download Mathlib (~2GB) via lake build.
Usage
/prove every group homomorphism preserves identity
/prove Monsky's theorem
/prove continuous functions on compact sets are uniformly continuousThe 5-Phase Workflow
┌─────────────────────────────────────────────────────────────┐
│ 📚 RESEARCH → 🏗️ DESIGN → 🧪 TEST → ⚙️ IMPLEMENT → ✅ VERIFY │
└─────────────────────────────────────────────────────────────┘Phase 1: RESEARCH (before any Lean)
Goal: Understand if/how this can be formalized.
- Search Mathlib with Loogle (PRIMARY - type-aware search)
# Use loogle for type signature search - finds lemmas by shape
loogle-search "pattern_here"
# Examples:
loogle-search "Nontrivial _ ↔ _" # Find Nontrivial lemmas
loogle-search "(?a → ?b) → List ?a → List ?b" # Map-like functions
loogle-search "IsCyclic, center" # Multiple conceptsQuery syntax:
- _ = any single type
- ?a, ?b = type variables (same var = same type)
- Foo, Bar = must mention both
- Search External - What's the known proof strategy?
- Use Nia MCP if available: mcpniasearch
- Use Perplexity MCP if available: mcpperplexitysearch
- Fall back to WebSearch for papers/references
- Check: Is there an existing formalization elsewhere (Coq, Isabelle)?
- Identify Obstacles
- What lemmas are NOT in Mathlib?
- Does proof require axioms beyond ZFC? (Choice, LEM, etc.)
- Is the statement even true? (search for counterexamples)
- Output: Brief summary of proof strategy and obstacles
CHECKPOINT: If obstacles found, use AskUserQuestion:
- "This requires [X]. Options: (a) restricted version, (b) accept axiom, (c) abort"
Phase 2: DESIGN (skeleton with sorries)
Goal: Build proof structure before filling details.
- Create Lean file with:
- Imports
- Definitions needed
- Main theorem statement
- Helper lemmas as sorry
- Annotate each sorry:
-- SORRY: needs proof (straightforward)
-- SORRY: needs proof (complex - ~50 lines)
-- AXIOM CANDIDATE: v₂ constraint - will test in Phase 3- Verify skeleton compiles (with sorries)
Output: proofs/.lean with annotated structure
Phase 3: TEST (counterexample search)
Goal: Catch false lemmas BEFORE trying to prove them.
For each AXIOM CANDIDATE sorry:
- Generate test cases
-- Create #eval or example statements
#eval testLemma (randomInput1) -- should return true
#eval testLemma (randomInput2) -- should return true- Run tests
lake env lean test_lemmas.lean- If counterexample found:
- Report the counterexample
- Use AskUserQuestion: "Lemma is FALSE. Options: (a) restrict domain, (b) reformulate, (c) abort"
CHECKPOINT: Only proceed if all axiom candidates pass testing.
Phase 4: IMPLEMENT (fill sorries)
Goal: Complete the proofs.
Standard iteration loop:
- Pick a sorry
- Write proof attempt
- Compiler-in-the-loop checks (hook fires automatically)
- If error, Godel-Prover suggests fixes
- Iterate until sorry is filled
- Repeat for all sorries
Tools active:
- compiler-in-the-loop hook (on every Write)
- Godel-Prover suggestions (on errors)
Phase 5: VERIFY (audit)
Goal: Confirm proof quality.
- Axiom Audit
lake build && grep "depends on axioms" output- Standard: propext, Classical.choice, Quot.sound ✓
- Custom axioms: LIST EACH ONE
- Sorry Count
grep -c "sorry" proofs/<file>.lean- Must be 0 for "complete" proof
- Generate Summary
✓ MACHINE VERIFIED (or ⚠️ PARTIAL - N axioms)
Theorem: <statement>
Proof Strategy: <brief description>
Proved:
- <lemma 1>
- <lemma 2>
Axiomatized (if any):
- <axiom>: <why it's needed>
File: proofs/<name>.leanResearch Tool Priority
More skills from parcadei/Continuous-Claude-v3
- Aagent-context-isolationAgent Context Isolation
- Aagent-orchestrationAgent Orchestration Rules
- Aagentic-workflowAgentic Workflow Pattern
- Aagentica-claude-proxyGuide for integrating Agentica SDK with Claude Code CLI proxy
- Aagentica-infrastructureReference guide for Agentica multi-agent infrastructure APIs
- Aagentica-promptsWrite reliable prompts for Agentica/REPL agents that avoid LLM instruction ambiguity
- Aagentica-sdkBuild Python agents with Agentica SDK - @agentic decorator, spawn(), persistence, MCP integration
- Aagentica-serverAgentica server + Claude proxy setup - architecture, startup sequence, debugging
- Aagentica-spawnSpawn Agentica multi-agent patterns
- Aanalytic-functionsProblem-solving strategies for analytic functions in complex analysis
- Aast-grep-findAST-based code search and refactoring via ast-grep MCP
- Aasync-repl-protocolAsync REPL Protocol