scaffold-lean-library

scaffold-lean-library is a skill for Claude Code from cboone/agent-harness-plugins. It costs 43 tokens per session (2,554 once invoked), scanned A, original, MIT.

A project starter for a Lean 4 library, including Lake project setup, optional Mathlib or PFR dependencies, tests, linting, and GitHub Actions checks.

In plain words
What is it for?
Use it to create a Lean repository for proving mathematics in code, including projects based on Mathlib or PFR.
Why use it?
It removes the specialized setup work needed to begin a Lean mathematical formalization or library.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: mentions CLAUDE.md; mentions AGENTS.md.

Part of the scaffold-lean-library plugin — 1 skill shipped together

Good fit Use it to create a Lean repository for proving mathematics in code, including projects based on Mathlib or PFR.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/cboone/agent-harness-plugins/scaffold-lean-library
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add cboone/agent-harness-plugins --skill scaffold-lean-library
Clone the repo
git clone --depth 1 https://github.com/cboone/agent-harness-plugins

Made for: Claude Code.

Or install scaffold-lean-library, the plugin that ships this one along with the rest of its 1 skill.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for scaffold-lean-library

README.md
[![agentmods](https://agentmods.dev/badge/skills/cboone/agent-harness-plugins/scaffold-lean-library/github.svg)](https://agentmods.dev/skills/cboone/agent-harness-plugins/scaffold-lean-library)
Your own site
<a href="https://agentmods.dev/skills/cboone/agent-harness-plugins/scaffold-lean-library"><img src="https://agentmods.dev/badge/skills/cboone/agent-harness-plugins/scaffold-lean-library/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for scaffold-lean-library

Your own site · 80×15
<a href="https://agentmods.dev/skills/cboone/agent-harness-plugins/scaffold-lean-library"><img src="https://agentmods.dev/badge/skills/cboone/agent-harness-plugins/scaffold-lean-library.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 43 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,554 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00043 $0.02554
Opus 5.5 $0.00017 $0.01022
Sonnet 5.5 $0.00009 $0.00511
Haiku 4.5 $0.00004 $0.00255

Measured 1mo ago against content hash 89fcd7e1ed96, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

scaffold-lean-library scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/scaffold-lean-library/skills/scaffold-lean-library/SKILL.md · 243 lines

How it starts

The opening of the file, as written. The whole thing — 243 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Scaffold Lean Library

Generate a Lean 4 library repository with Lake, Mathlib or PFR dependencies, compile-time API regression tests, local Makefile targets, GitHub Actions CI, text linting, and agent instructions.

Workflow

1. Gather Project Information

If the user provided values in the request, use them and do not ask again. Derive safe defaults from context only when they are unambiguous.

Ask for any missing values:

  • Project name: kebab-case repository and Lake package name, for example entropy-inequalities.
  • Short description: one sentence for README, marketplace-style summaries, and agent instructions.
  • Top-level Lean namespace: UpperCamelCase, for example EntropyInequalities. Derive from the project name when the result is readable; ask if acronyms or domain terms make the derivation ambiguous.
  • Lean toolchain version: the exact lean-toolchain content, for example leanprover/lean4:v4.25.0.
  • Dependency family: Mathlib or PFR.
  • Dependency git ref: a Mathlib tag/ref or a PFR git ref.
  • Paper-backed mode: whether to add references/ stubs and Pandoc-academic lint ignores for formalizations tied to papers or transcriptions.
  • GitHub username: for repository URLs.
  • Copyright holder: for LICENSE and source headers.

Detect the GitHub username and full name when possible:

gh api user -q .login
git config user.name

If either command fails or returns an empty value, ask the user.

2. Resolve Dependency Ref

For Mathlib projects:

  1. If the user supplied a dependency ref, use it.

  2. Otherwise, if the Lean toolchain is exactly leanprover/lean4:vX.Y.Z or vX.Y.Z, derive the Mathlib ref vX.Y.Z.

  3. Verify the derived ref exists before using it:

    git ls-remote --tags https://github.com/leanprover-community/mathlib4.git refs/tags/vX.Y.Z
    
  4. If the tag does not exist, or if the Lean toolchain is nightly, a branch, or otherwise not a clean stable version, ask the user for the Mathlib ref.

Read the full file on GitHub · 243 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago Changed · -6 lines · -85 tokens per session 89fcd7e1ed96
  2. 1mo ago First seen · 249 lines · 128 tokens per session scan A 2479167f831a

Subscribe to this mod's changes

scaffold-lean-library is a skill published in the GitHub repository cboone/agent-harness-plugins (2 stars, last pushed today), licensed MIT. It adds 43 tokens to every session and 2,554 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

cirq

Google quantum computing framework. Use when targeting Google Quantum AI hardware, designing noise-aware circuits, or running quantum characterization experiments. Best for Google hardware, noise modeling, and low-level circuit design. For IBM hardware use qiskit; for quantum ML with autodiff use pennylane; for…

agentlas-ai/agentlas-desktop · 67 tokens

biopython

Comprehensive molecular biology toolkit. Use for sequence manipulation, file parsing (FASTA/GenBank/PDB), phylogenetics, and programmatic NCBI/PubMed access (Bio.Entrez). Best for batch processing, custom bioinformatics pipelines, BLAST automation. For quick lookups use gget; for multi-service integration use…

agentlas-ai/agentlas-desktop · 76 tokens

scikit-bio

Biological data toolkit. Sequence analysis, alignments, phylogenetic trees, diversity metrics (alpha/beta, UniFrac), ordination (PCoA), PERMANOVA, FASTA/Newick I/O, for microbiome analysis.

agentlas-ai/agentlas-desktop · 54 tokens

simpy

Build, inspect, test, and analyze bounded process-based discrete-event simulations with SimPy, including events, resources, interrupts, monitoring, replications, warm-up, and reproducible output analysis.

agentlas-ai/agentlas-desktop · 42 tokens

scvelo

RNA velocity analysis with scVelo. Estimate cell state transitions from unspliced/spliced mRNA dynamics, infer trajectory directions, compute latent time, and identify driver genes in single-cell RNA-seq data. Complements Scanpy/scVI-tools for trajectory inference.

agentlas-ai/agentlas-desktop · 56 tokens

julia

Julia development guidelines covering multiple dispatch, type system, performance optimization, and scientific computing best practices.

Mindrally/skills · 22 tokens