zrrr commited on
Commit
138f323
·
1 Parent(s): 773d22c

Update README with arxiv link, scaffolding use case, and prompt format

Browse files
Files changed (1) hide show
  1. README.md +55 -3
README.md CHANGED
@@ -6,15 +6,67 @@ tags:
6
  - lean4
7
  - theorem-proving
8
  - verification
 
9
  base_model: Qwen/Qwen3-8B
10
  ---
11
 
12
  # Goedel-Code-Prover-8B
13
 
14
- A Lean 4 code verification model fine-tuned from Qwen3-8B through supervised fine-tuning and reinforcement learning with online proof checking.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
15
 
16
  ## Model Details
17
 
18
  - **Base model:** Qwen3-8B
19
- - **Training:** SFT on decomposition and proof completion trajectories, followed by GRPO with online Lean 4 verification rewards
20
- - **Use case:** Verifying Lean 4 proof attempts for code correctness specifications
 
 
 
 
 
 
 
 
 
 
6
  - lean4
7
  - theorem-proving
8
  - verification
9
+ - code-verification
10
  base_model: Qwen/Qwen3-8B
11
  ---
12
 
13
  # Goedel-Code-Prover-8B
14
 
15
+ **Paper:** [Goedel-Prover-V2: Advancing Formal Reasoning in LLMs](https://arxiv.org/abs/2603.19329)
16
+
17
+ Goedel-Code-Prover-8B is a Lean 4 proof generation model specialized in **proof decomposition** for code correctness verification. Given a formal specification in Lean 4, it decomposes the proof into smaller lemmas and proves the target theorem by combining them.
18
+
19
+ ## Use Case
20
+
21
+ This model is designed to work within a **decompose-then-verify scaffolding**:
22
+
23
+ 1. **Input:** A Lean 4 formal problem (theorem statement with `sorry` body).
24
+ 2. **Decomposition:** The model breaks down the proof into small, self-contained lemmas, each targeting a single logical step.
25
+ 3. **Proof:** The model proves the target theorem by composing the introduced lemmas, ideally without any `sorry`.
26
+ 4. **Verification:** The generated proof is compiled against a Lean 4 server to check correctness.
27
+
28
+ ## Prompt Format
29
+
30
+ Use the chat completions API with the following structure:
31
+
32
+ **System prompt:**
33
+ ```
34
+ You are an expert in Lean 4 theorem proving and proof decomposition.
35
+
36
+ Given a formal problem in Lean 4, your task is to:
37
+ 1. First, analyze and reason about how to decompose the proof into smaller lemmas
38
+ 2. Then, provide the complete proof with all necessary lemmas
39
+
40
+ Requirements for the proof breakdown:
41
+ - Break down the theorem into the smallest possible lemmas
42
+ - Each lemma should ideally involve a single Lean 4 basic function operation
43
+ - The introduced lemmas should not involve universe types
44
+ - Ensure logical ordering: lemmas should be defined before they are used
45
+
46
+ Requirements for the format of the proof:
47
+ - The original theorem MUST be proved WITHOUT sorry (using the defined lemmas)
48
+ - Each lemma should be proved with a complete proof if possible
49
+ - Use the 'lemma' keyword for lemmas and the 'theorem' keyword for the original theorem
50
+ - Wrap all proof code in ```lean code blocks
51
+ ```
52
+
53
+ **User message:**
54
+ ```
55
+ Formal Problem:
56
+ <lean4 theorem statement>
57
+ ```
58
 
59
  ## Model Details
60
 
61
  - **Base model:** Qwen3-8B
62
+ - **Training:** Supervised fine-tuning on proof decomposition and completion trajectories, followed by GRPO reinforcement learning with online Lean 4 verification rewards.
63
+
64
+ ## Citation
65
+
66
+ ```bibtex
67
+ @article{goedelproverv2,
68
+ title={Goedel-Prover-V2: Advancing Formal Reasoning in LLMs},
69
+ year={2025},
70
+ url={https://arxiv.org/abs/2603.19329}
71
+ }
72
+ ```