Skip to content

Commit

Permalink
Merge pull request #36 from lean-dojo/dev
Browse files Browse the repository at this point in the history
minor update
  • Loading branch information
Kaiyu Yang authored Dec 6, 2023
2 parents a4217a7 + 01e7ba4 commit 119a081
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion LeanCopilot/LlmAesop.lean
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ def tacGen : Aesop.TacGen := fun (mvarId : MVarId) => do
generate model state ""


macro "#init_llm_aesop" : command => `(@[aesop 100%] def tacGen := LeanCopilot.tacGen)
macro "#configure_llm_aesop" : command => `(@[aesop 100%] def tacGen := LeanCopilot.tacGen)


macro "search_proof" : tactic => `(tactic| aesop?)
Expand Down
2 changes: 1 addition & 1 deletion LeanCopilotTests/HighLevelAPIs.lean
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ example (a b c : Nat) : a + b + c = a + c + b := by
sorry

-- The example below wouldn't work without it.
#init_llm_aesop
#configure_llm_aesop

example (a b c : Nat) : a + b + c = c + b + a := by
aesop?
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
LeanCopilot: Native Neural Network Inference in Lean 4
=============================================
Lean Copilot: Language Models as Copilots for Theorem Proving in Lean
=====================================================================

<img width="1087" alt="LeanCopilot" src="https://github.com/lean-dojo/LeanCopilot/assets/5431913/f87ec407-29a5-4468-b2fb-a2f6e9105ae9">

LeanCopilot provides tactic suggestions by running LLMs through Lean's foreign function interface (FFI). It is in an early stage of development. In the long term, we aim to integrate Lean and machine learning by providing a general and efficient way to run the inference of neural networks in Lean.
Lean Copilot allows language models to be used in Lean for proof automation, e.g., suggesting tactics/premises and searching for proofs. It runs efficiently on either CPUs or GPUs. With Lean Copilot, you can access our built-in models from [LeanDojo](https://leandojo.org/) or bring your models that run either locally or on the cloud (such as GPT-4).


## Requirements
Expand Down Expand Up @@ -38,7 +38,7 @@ You may provide a prefix to constrain the generated tactics. For example, `sugge

### Searching for Proofs

You can combine the LLM-generated tactic suggestions with [aesop](https://github.com/leanprover-community/aesop) to search for complete proofs. To do this, simply add `#init_llm_aesop` before using aesop (see [this example](LeanCopilotTests/Aesop.lean)).
You can combine the LLM-generated tactic suggestions with [aesop](https://github.com/leanprover-community/aesop) to search for complete proofs. To do this, simply add `#configure_llm_aesop` before using aesop (see [this example](LeanCopilotTests/Aesop.lean)).


### Selecting Premises
Expand Down

0 comments on commit 119a081

Please sign in to comment.