Available in
Marketplaces, most starred first
Tags
Add to README
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
By cameronfreerv4.12.0MITIn 1 marketplace
Turns informal math claims into Lean 4 theorem skeletons and proves them, with LSP-backed build checks. Guardrail hooks soft-gate git push and hard-block reset --hard inside Lean projects.
Trending plugins
7-day copy clicks
You run one by typing its /name in Claude Code.
1 caution to review before installing
A hook runs when Claude uses the Bash tool
Static checks of hooks, mods, MCP servers and commands. Not a security audit.
1 marketplace, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Executables (bin/) — files in this plugin's bin/ directory are added to the Bash tool's PATH while the plugin is enabled.
Public GitHub repos that commit this plugin as enabled in their Claude Code settings
Native host adapters. This directory implements the Claude Code plugin (hooks, guardrails, slash commands) and the Codex plugin (skill discovery, absolute-path SessionStart context, prompt validation, advisory guardrails). The underlying SKILL.md, references, wrappers, and scripts remain canonical and host-agnostic. See the root README for installation.
Unified Lean 4 plugin for theorem proving, interactive learning, and formalization.
| Command | Description |
|---|---|
/lean4:draft | Draft Lean declaration skeletons from informal claims |
/lean4:formalize | Interactive formalization — drafting plus guided proving |
/lean4:autoformalize | Autonomous end-to-end formalization from informal sources |
/lean4:prove | Guided cycle-by-cycle theorem proving with explicit checkpoints |
/lean4:autoprove | Autonomous multi-cycle theorem proving with explicit stop budgets |
/lean4:disprove | Guided counterexample search with certified refutation |
/lean4:checkpoint | Save progress with a safe commit checkpoint |
/lean4:review | Read-only code review of Lean proofs |
/lean4:refactor | Leverage mathlib, extract helpers, simplify proof strategies |
/lean4:golf | Improve Lean proofs for directness, clarity, performance, and brevity |
/lean4:learn | Interactive teaching and mathlib exploration |
/lean4:diagnose | Diagnostics, cleanup, and migration help |
/lean4:* entries are Claude Code aliases; under Codex, invoke $lean4 and
ask for the named workflow.
Each command's full semantics live in commands/; worked transcripts live in command-examples.md. CLI-like inputs to the seven parameter-heavy commands are validated by a host-agnostic parser — see the Command Invocation Contract.
Without a command: editing .lean files activates the skill for one
bounded pass — it fixes the immediate issue (a build error, a single sorry),
does not loop or escalate, and ends by suggesting the right command:
draft/formalize for statement work, prove/autoprove for proof work.
For a goal that resists the pass, it follows the
Blocked-Goal Triage loop.
The proving commands (prove, autoprove, formalize, autoformalize) run
one 6-phase cycle — Plan → Work → Checkpoint → Review → Replan →
Continue/Stop — discovering sorries via LSP, then per sorry: mathlib search,
tactic attempts, validation, staging only touched files. When stuck (same
blocker seen twice), both force a review + replan regardless of settings.
prove asks before continuing; autoprove auto-continues under stop budgets.
disprove shares the phase skeleton but specializes Phase 5 as Accumulate
(per-cycle evidence append) with dynamic evidence-seeded menus.
Commit behavior: prove defaults to --commit=ask, autoprove to
--commit=auto; both stage only files actually touched, never git add -A.
Full phase semantics, stuck definition, and deep-mode safety: cycle-engine.md.
Guardrails activate only in Lean project context (a directory tree containing
lakefile.lean, lean-toolchain, or lakefile.toml); outside Lean projects
they are silently skipped. Git operations fall into three tiers: allow
(status/diff/log/add/commit and other read-or-append ops, no gate),
soft-gate (collaboration ops like git push / git commit --amend /
gh pr create and path-scoped destructive ops — policy-controlled per op,
one-shot LEAN4_GUARDRAILS_BYPASS=1 bypass in ask mode), and hard-block
(whole-worktree destructive ops like git reset --hard and git clean -f —
absolute, never bypassable).
The full policy — override environment variables, per-op collaboration
policies and their host/ask/allow/block modes, hard-blocked push
variants, destructive-op coverage, and bypass semantics — lives in
GUARDRAILS.md.
LSP tools are normative (required first-pass), not merely preferred:
lean_goal for exact goal state, the search ladder
(lean_local_search / lean_leanfinder / lean_leansearch / lean_loogle),
and lean_multi_attempt for candidate testing. Scripts provide sorry
analysis, axiom checking, and search fallback when LSP is unavailable;
compiler-guided repair is escalation-only. See the
LSP-first protocol.
7-day copy clicks
Built from public signals: copy clicks on this site, GitHub stars and activity, the README and the manifest. Not a security audit or an endorsement.
npx claudepluginhub cameronfreer/lean4-skills --plugin lean4Plugins from other owners that cover similar ground