lean4-htt/src/Lean/Util.lean
Leonardo de Moura d748b0c8c9
feat: instantiate tactic parameter optimizer (#10916)
This PR implements parameter optimization for the generated
`instantiate` tactics produced by `finish?`.
We use a simple parameter optimizer that takes two sets as input: the
lower and upper bounds.
The lower bound consists of the theorems actually used in the proof
term, while the upper bound includes all the theorems instantiated in a
particular theorem instantiation step.
The lower bound is often sufficient to replay the proof, but in some
cases, additional theorems must be included because a theorem
instantiation may contribute to the proof by providing terms and many
not be present in the final proof term.
2025-10-23 01:22:33 +00:00

40 lines
1.3 KiB
Text

/-
Copyright (c) 2020 Microsoft Corporation. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Leonardo de Moura
-/
module
prelude
public import Lean.Util.CollectFVars
public import Lean.Util.CollectLevelParams
public import Lean.Util.CollectMVars
public import Lean.Util.CollectLevelMVars
public import Lean.Util.CollectLooseBVars
public import Lean.Util.FindMVar
public import Lean.Util.FindLevelMVar
public import Lean.Util.MonadCache
public import Lean.Util.PPExt
public import Lean.Util.Path
public import Lean.Util.Profile
public import Lean.Util.RecDepth
public import Lean.Util.ShareCommon
public import Lean.Util.Sorry
public import Lean.Util.Trace
public import Lean.Util.FindExpr
public import Lean.Util.ReplaceExpr
public import Lean.Util.ForEachExpr
public import Lean.Util.ForEachExprWhere
public import Lean.Util.ReplaceLevel
public import Lean.Util.FoldConsts
public import Lean.Util.SCC
public import Lean.Util.TestExtern
public import Lean.Util.OccursCheck
public import Lean.Util.HasConstCache
public import Lean.Util.Heartbeats
public import Lean.Util.SafeExponentiation
public import Lean.Util.NumObjs
public import Lean.Util.NumApps
public import Lean.Util.FVarSubset
public import Lean.Util.SortExprs
public import Lean.Util.Reprove
public import Lean.Util.ParamMinimizer