[a / b / c / d / e / f / g / gif / h / hr / k / m / o / p / s / t / u / v / vg / vm / vmg / vr / vrpg / vst / w / wg] [i / ic] [r9k / s4s / vip] [cm / hm / lgbt / y] [3 / aco / adv / an / bant / biz / cgl / ck / co / diy / fa / fit / gd / hc / his / int / jp / lit / mlp / mu / n / news / out / po / pol / pw / qst / sci / soc / sp / tg / toy / trv / tv / vp / vt / wsg / wsr / x / xs] [Settings] [Search] [Mobile] [Home]
Board
Settings Mobile Home
/sci/ - Science & Math

Name
Options
Comment
Verification
4chan Pass users can bypass this verification. [Learn More] [Login]
File
  • Please read the Rules and FAQ before posting.
  • Additional supported file types are: PDF
  • Use with [math] tags for inline and [eqn] tags for block equations.
  • Right-click equations to view the source.

08/21/20New boards added: /vrpg/, /vmg/, /vst/ and /vm/
05/04/17New trial board added: /bant/ - International/Random
10/04/16New board for 4chan Pass users: /vip/ - Very Important Posts
[Hide] [Show All]


Janitor acceptance emails will be sent out over the coming weeks. Make sure to check your spam folder!


[Advertise on 4chan]


Anyone here using Lean 4 with LLMs/math AIs? Not sure if to post this in the math thread, technology, or advice.

I’m trying to figure out the best workflow for getting an AI to solve math problems and produce/check Lean 4 proofs, instead of just giving a normal natural-language solution that might be wrong.

Questions:

- What models/tools are actually good with Lean 4 right now?
- Do people use ChatGPT/Claude/Gemini + a local Lean install, or is there a better setup?
- Is Mathlib required for most contest/undergrad-style problems?
- What’s the best way to prompt the AI so it writes valid Lean code instead of fake theorem names?
- Are there any good examples/repos where an AI iterates with Lean errors until the proof compiles?

Basically I want a setup where I can give it a problem, have it formalize the statement, try a proof, run Lean, read the errors, and keep fixing it until it works.

Any advice, examples, or workflows appreciated.
>>
File: 1767200036833602.jpg (120 KB, 770x600)
120 KB JPG
damn nigga math hittin dat lean now? fr that shit wild
>>
File: apucrying.jpg (5 KB, 220x218)
5 KB JPG
>>17002647
Claude's Fable 5.
>>
>>17002647
>run Lean, read the errors, and keep fixing it until it works.
Lean is the wrong system for that workflow. Use Idris instead, the type system is actually designed for interactive proof development:
https://idris-community.github.io/idris2-tutorial/Tutorial/Functions2/Holes.html
>>
the tool to use is codex cli or claude code
the loop you can vibe code using the same tool
just ask it to make a script that will check the lean file for errors and if any found then prompt your codex with "plz fix errorinos king make no mistakes this time over"
without the scripted loop it will give up after some time



[Advertise on 4chan]

Delete Post: [File Only] Style:
[Disable Mobile View / Use Desktop Site]

[Enable Mobile View / Use Mobile Site]

All trademarks and copyrights on this page are owned by their respective parties. Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.