lean4-memories

Store and retrieve Lean 4 proof patterns and conventions via MCP memory server.

Updated Jan 15, 2026
One-click install
npx skills add https://github.com/KaiserWhoLearns/skillsbench --skill lean4-memories-kaiserwholearns
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: lean4-memories
Source: https://github.com/KaiserWhoLearns/skillsbench/tree/main/tasks/lean4-proof/environment/skills/lean4-memories
Command: npx skills add https://github.com/KaiserWhoLearns/skillsbench --skill lean4-memories-kaiserwholearns

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

Persistent memory for Lean 4 proof work across sessions, enabling retention of successful proof patterns, conventions, and user preferences via MCP memory server integration.

Core Features & Use Cases

  • Cross-session memory: stores ProofPattern, FailedApproach, ProjectConvention, and UserPreference entities to accelerate future formalizations.
  • Memory workflows: store, retrieve, update, and prune memories; surface related conventions and helper lemmas to reuse.
  • Team collaboration: share project-specific patterns and conventions to align across developers.

Quick Start

Enable the MCP memory server, then run your Lean proofs with lean4-memories enabled to automatically store and retrieve proof patterns.

Frequently Asked Questions about lean4-memories

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I save Lean 4 proof patterns to reuse across coding sessions?

To save Lean 4 proof patterns across sessions, this Skill stores entities like ProofPattern and ProjectConvention via an MCP memory server. It automatically retains successful tactics and conventions for future formalization tasks.

What is the best way to manage team-wide Lean 4 formalization conventions?

Managing team-wide Lean 4 formalization conventions is done by storing and sharing ProjectConvention entities in an MCP memory server. This aligns developers by surfacing recurring proof patterns and helper lemmas across modules.

Do I need an MCP memory server to persist Lean 4 tactics and failed approaches?

Yes, you need an MCP memory server to persist Lean 4 tactics and failed approaches. The Skill requires this server to store, retrieve, and prune memory entities like FailedApproach and UserPreference with timestamps.

How does cross-session memory work for recurring Lean 4 proofs?

Cross-session memory for recurring Lean 4 proofs works by storing ProofPattern entities with goal patterns and tactics in an MCP memory server. It retrieves these memories during development to accelerate formalization.

Can I update and prune stored Lean 4 proof patterns during a project?

Yes, you can update and prune stored Lean 4 proof patterns during a project. The Skill provides memory workflows to manage entities, ensuring outdated conventions or failed approaches are removed from the MCP memory server.