# check_lean-and-lean-tools

check_lean-and-lean-tools is a Claude Code skill that verifies Lean proofs for universal claims involving induction or recursion. It joins coding, debugging, review, or design tasks when a claim needs machine-checked lemmas.

- skill · `type=skill` · Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf (Devin Desktop), Claude.ai · ★ 171 repo stars
- Author: drawthingsai
- License: GPL-3.0 · policy=link-only · description only; the file stays with the author
- Source: https://github.com/drawthingsai/local-code-community/tree/HEAD/Apps/LocalCode/Resources/Skills/check_lean-and-lean-tools/SKILL.md
- Updated: 2026-11-17
- Security check: automated, 2026-11-17 (text) — no signs of malicious code found.
- HTML: https://affpapa.org/en/nevibecode/skills/check-lean-and-lean-tools

## What it does

The skill sends Lean source to the `check_lean` and `lean` commands to verify a significant claim across all inputs. For compact arithmetic, bitvector, or finite-state problems, it recommends `check_smt`; ordinary tests cover concrete cases.

Lean runs through Bash with bundled Init, Std, Lean, and Lake modules, which are loaded as imports call for them. Mathlib has a separate installation workflow. This is not a desktop Lean toolchain: `lake` and `elan` commands are unavailable, and importing a local `.lean` file does not compile it automatically.

\`check_lean` takes source text; files can be passed through `--stdin`. Declarations do not carry over between calls, so each submission needs its definitions and helper lemmas. A `conditional` result relies on extra assumptions.

## Install

### Claude Code (native platform)

1. **Skills CLI (Vercel)**
```bash
npx skills add drawthingsai/local-code-community --skill check_lean-and-lean-tools -a claude-code
```

2. **Manually: put the files in place**
- File: `~/.claude/skills/check_lean-and-lean-tools/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/check_lean-and-lean-tools/

### Codex

1. **Skills CLI (Vercel)**
```bash
npx skills add drawthingsai/local-code-community --skill check_lean-and-lean-tools -a codex
```

2. **Manually: put the files in place**
- File: `.agents/skills/check_lean-and-lean-tools/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

1. **Skills CLI (Vercel)**
```bash
npx skills add drawthingsai/local-code-community --skill check_lean-and-lean-tools -a cursor
```

2. **Manually: put the files in place**
- File: `.cursor/skills/check_lean-and-lean-tools/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install drawthingsai/local-code-community Apps/LocalCode/Resources/Skills/check_lean-and-lean-tools
```

2. **Manually: put the files in place**
- File: `.github/skills/check_lean-and-lean-tools/SKILL.md`

### Gemini CLI

1. **Skills CLI (Vercel)**
```bash
npx skills add drawthingsai/local-code-community --skill check_lean-and-lean-tools -a gemini-cli
```

2. **Platform CLI**
```bash
gemini skills install https://github.com/drawthingsai/local-code-community --path Apps/LocalCode/Resources/Skills/check_lean-and-lean-tools
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/check_lean-and-lean-tools/SKILL.md` — The legacy .windsurf/skills/ path still works

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/drawthingsai/local-code-community/tree/HEAD/Apps/LocalCode/Resources/Skills/check_lean-and-lean-tools/SKILL.md

## When to use it
- prove a property across every depth of a recursive structure
- verify a function property by induction
- inspect which extra assumptions a theorem depends on
- distinguish a universal proof from a test of specific cases

## Example prompts
- Use `check_lean` to verify this claim about the recursive function.
- Prove by induction that mirroring a tree twice returns the original tree.
- Check whether this theorem relies on additional axioms.

## Similar
- [writing-lean-proofs](https://affpapa.org/en/nevibecode/skills/writing-lean-proofs.md) — skill · 1800 installs
- [lean-formalize](https://affpapa.org/en/nevibecode/skills/lean-formalize.md) — skill · 103 installs
- [proof-theory](https://affpapa.org/en/nevibecode/skills/proof-theory.md) — skill · 1 install
- [create-formal-verification-skill](https://affpapa.org/en/nevibecode/skills/create-formal-verification-skill.md) — skill · 6200 installs
- [maintain-formal-verification-skill](https://affpapa.org/en/nevibecode/skills/maintain-formal-verification-skill.md) — skill · 6100 installs
- [LeanWarp](https://affpapa.org/en/nevibecode/mcp/leanwarp.md) — MCP server · ★ 7 repo stars

From the same set: [drawthingsai/local-code-community](https://affpapa.org/en/nevibecode/by/drawthingsai/local-code-community.md) — 20 cards

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
