diff --git a/LeanCopilot/Frontend.lean b/LeanCopilot/Frontend.lean index b158982..476f465 100644 --- a/LeanCopilot/Frontend.lean +++ b/LeanCopilot/Frontend.lean @@ -30,13 +30,12 @@ def suggestion (tac : String) (msgs : MessageLog := {}) : TacticM Suggestion := let e ← g.withContext do (PrettyPrinter.ppExpr goalType) str := str ++ Format.pretty ("\n⊢ " ++ e) pure (some str) - let style? := if goals.isEmpty then some .success else none let msg? ← msgs.toList.findM? fun m => do pure <| m.severity == MessageSeverity.information && (← m.data.toString).startsWith "Try this: " let suggestion ← match msg? with | some m => pure <| SuggestionText.string (((← m.data.toString).drop 10).takeWhile (· != '\n')) | none => pure <| SuggestionText.string tac - return { suggestion, postInfo?, style? } + return { suggestion, postInfo? } /-- Run a tactic, returning any new messages rather than adding them to the message log. -/ diff --git a/README.md b/README.md index 5df5af2..81b564a 100644 --- a/README.md +++ b/README.md @@ -59,7 +59,7 @@ moreLinkArgs = ["-L./.lake/packages/LeanCopilot/.lake/build/lib", "-lctranslate2 require LeanCopilot from git "https://github.com/lean-dojo/LeanCopilot.git" @ "LEAN_COPILOT_VERSION" ``` -For stable Lean versions (e.g., `v4.24.0`), set `LEAN_COPILOT_VERSION` to be that version. For the latest unstable Lean versions (e.g., `v4.25.0-rc1`), set `LEAN_COPILOT_VERSION` to `main`. In either case, make sure the version is compatible with other dependencies such as mathlib. If your project uses lakefile.toml instead of lakefile.lean, it should include: +For stable Lean versions (e.g., `v4.25.0`), set `LEAN_COPILOT_VERSION` to be that version. For the latest unstable Lean versions (e.g., `v4.26.0-rc1`), set `LEAN_COPILOT_VERSION` to `main`. In either case, make sure the version is compatible with other dependencies such as mathlib. If your project uses lakefile.toml instead of lakefile.lean, it should include: ```toml [[require]] diff --git a/lake-manifest.json b/lake-manifest.json index 78c1a37..54dbe9f 100644 --- a/lake-manifest.json +++ b/lake-manifest.json @@ -5,20 +5,20 @@ "type": "git", "subDir": null, "scope": "", - "rev": "725ac8cd67acd70a7beaf47c3725e23484c1ef50", + "rev": "26e4c7c0e63eb3e6cce3cf7faba27b8526ea8349", "name": "aesop", "manifestFile": "lake-manifest.json", - "inputRev": "master", + "inputRev": "26e4c7c0e63eb3e6cce3cf7faba27b8526ea8349", "inherited": false, "configFile": "lakefile.toml"}, {"url": "https://github.com/leanprover-community/batteries.git", "type": "git", "subDir": null, "scope": "", - "rev": "8da40b72fece29b7d3fe3d768bac4c8910ce9bee", + "rev": "39260e31b7b3f7f05643da95242463b462dc05f1", "name": "batteries", "manifestFile": "lake-manifest.json", - "inputRev": "main", + "inputRev": "39260e31b7b3f7f05643da95242463b462dc05f1", "inherited": false, "configFile": "lakefile.toml"}], "name": "LeanCopilot", diff --git a/lakefile.lean b/lakefile.lean index b466d88..7216878 100644 --- a/lakefile.lean +++ b/lakefile.lean @@ -422,8 +422,8 @@ extern_lib libleanffi pkg := do buildStaticLib (pkg.sharedLibDir / name) #[ct2O] -require batteries from git "https://github.com/leanprover-community/batteries.git" @ "main" -require aesop from git "https://github.com/leanprover-community/aesop" @ "master" +require batteries from git "https://github.com/leanprover-community/batteries.git" @ "39260e31b7b3f7f05643da95242463b462dc05f1" +require aesop from git "https://github.com/leanprover-community/aesop" @ "26e4c7c0e63eb3e6cce3cf7faba27b8526ea8349" meta if get_config? env = some "dev" then -- dev is so not everyone has to build it require «doc-gen4» from git "https://github.com/leanprover/doc-gen4" @ "main" diff --git a/lean-toolchain b/lean-toolchain index 58ae245..1d4c9d4 100644 --- a/lean-toolchain +++ b/lean-toolchain @@ -1 +1 @@ -leanprover/lean4:v4.24.0 \ No newline at end of file +leanprover/lean4:v4.25.0 \ No newline at end of file