A machine-checked proof, carried in the flow
reflow init --upgrade Lean \
--collection <collection-id>
Lean is installed on demand and ships a pinned Lean 4.36.0 toolchain with Init, Std, and the bv_decide SAT solver—no local elan or PATH toolchain required. Once locked in your application, teammates and CI install it automatically with reflow init.
Your coding agent inspects installed plugin commands via MCP, authors flows against your application knowledge, and pins versions in the application lock.
Flow excerptLean
---
name: Discount rule proofs
providers:
lean: Lean
---
```rfl step="Discount rule keeps its invariants"
lean.check (
file="Discount.lean"
statements=json(
{"Discount.total_le": "∀ (price discount : Nat), price - min discount price ≤ price"}
)
)
```
```lean file="Discount.lean"
namespace Discount
def total (price discount : Nat) : Nat := price - min discount price
theorem total_le (price discount : Nat) : total price discount ≤ price :=
Nat.sub_le price _
end Discount
```
Plugin locks and private target bindings are managed separately from flow source.