agentleFS
r-irber-irbe/proof-skills/skills/lean-dependency-management/SKILL.md

lean-dependency-management

Skill3 starsChanged 13 days agoApache-2.0View on GitHub

USE FOR: evaluating Reservoir/GitHub Lean packages, toolchain pin bumps, and substrate vendoring. DO NOT USE FOR: ordinary lemma search (@lean-research) or broken-proof repair (@lean-proof-repair). TRIGGERS: Lean package, Reservoir, Lake dependency, Mathlib bump, vendor substrate, toolchain pin.

The file

We split this skill into the rules it gives an agent

1 rule. About 0 are common, 0 are distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Never hand-edit lake-manifest.json hashes.

    line 52

≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Lean 4 Package Evaluation, Pin Upgrades & Substrate Vendoring

Evaluate external Lean 4 packages on Reservoir/GitHub, plan compatible lean-toolchain + lake-manifest.json upgrades, and execute license-verified, axiom-audited substrate vendoring when Lake require is unsuitable.

Routing

  • USE FOR: package discovery (lean_search(source: "reservoir")), Lake dependency vs. vendoring trade-offs, license/SPDX verification (Apache-2.0 / MIT), and provenance-tracked vendoring.
  • DO NOT USE FOR: general theorem search (@lean-research) or interactive tactic repair after bumping (@lean-proof-repair).

Workflow

  1. Evaluate Candidates -- Query Reservoir/GitHub for toolchain pin alignment, sorry/axiom cleanliness, maintenance velocity, and transitive dependency weight.
  2. Choose Integration Mode -- Prefer pinned Lake require when toolchains align; choose isolated Vendor/ subtree vendoring only when extracting a narrow sorry-free slice across incompatible pins.
  3. Verify License & Provenance -- Confirm permissive SPDX license (Apache-2.0 / MIT), preserve upstream LICENSE + copyright headers, and record exact upstream repo URL + commit SHA.
  4. Compile & Axiom-Lock -- Build via @lean-build, repair API drift via @lean-proof-repair, and run @lean-verification-gate (lean_axiom_closure) over every imported/vendored declaration.

Recovery & STOP

  • Reject any upstream package with incompatible copyleft/missing license or custom axiom / unsafe declarations in the target slice.
  • Never hand-edit lake-manifest.json hashes; always resolve pins through lake update <pkg>.

Handoffs

  • Predecessors: lean-research, lean-setup.
  • Successors: lean-build, lean-proof-repair, lean-verification-gate.

Detailed reference

  • Layer-1 Fast Lookup Card (read first): references/cards/lean-dependency-management-tables.md
  • Full handbook: ../../references/handbooks/lean-dependency-management-handbook.md

See also

  • ../lean-setup/SKILL.md -- Toolchain & Lake project setup
  • ../lean-proof-repair/SKILL.md -- Repairing proofs across toolchain/Mathlib bumps

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.