Spaces:
Runtime error
Runtime error
Tonic commited on
adds examples
Browse files92 unmodified lines9394959697989976 unmodified lines1761771781791801811821831844 unmodified lines18919019119219319419519692 unmodified lines[unimath1, additional_info_prompt, 2500],[unimath2, additional_info_prompt, 2500],[unimath3, additional_info_prompt, 2500],[unimath4, additional_info_prompt, 2500]]model_name = "AI-MO/Kimina-Prover-Distill-8B"76 unmodified lineswith gr.Column:gr.Markdown(description)with gr.Column:gr.Markdown(joinus)with gr.Row():with gr.Column():user_input = gr.Textbox(label="Your message or formal statement", lines=4)informal = gr.Textbox(value=additional_info_prompt, label="Optional informal prefix")max_tokens = gr.Slider(minimum=150, maximum=4096, value=2500, label="Max Tokens")4 unmodified linesjson_out = gr.JSON(label="Full Output")code_out = gr.Code(label="Extracted Lean4 Code", language="python")state = gr.State([])# On submit, call chat_handlersubmit.click(chat_handler, [user_input, informal, max_tokens, state], [chat, json_out, code_out, state])gr.Markdown(citation)demo.launch()92 unmodified lines9394959697989910010110210310410510610710810911011111211311411576 unmodified lines1921931941951961971981992002014 unmodified lines20620720820921021121221321421521621792 unmodified lines[unimath1, additional_info_prompt, 2500],[unimath2, additional_info_prompt, 2500],[unimath3, additional_info_prompt, 2500],[unimath4, additional_info_prompt, 2500],# New examples['''import Mathlib\nimport Aesop\n\nset_option maxHeartbeats 0\n\nopen BigOperators Real Nat Topology Rat\n\n/-- Let $a_1, a_2,\cdots, a_n$ be real constants, $x$ a real variable, and $f(x)=\\cos(a_1+x)+\\frac{1}{2}\\cos(a_2+x)+\\frac{1}{4}\\cos(a_3+x)+\\cdots+\\frac{1}{2^{n-1}}\\cos(a_n+x).$ Given that $f(x_1)=f(x_2)=0,$ prove that $x_2-x_1=m\\pi$ for some integer $m.$-/\ntheorem imo_1969_p2 (m n : \\R) (k : \\N) (a : \\N \\rightarrow \\R) (y : \\R \\rightarrow \\R) (hβ : 0 < k)\n(hβ : \\forall x, y x = \\sum i in Finset.range k, Real.cos (a i + x) / 2 ^ i) (hβ : y m = 0)\n(hβ : y n = 0) : \\exists t : \\Z, m - n = t * Real.pi := by''',"/-- Let $a_1, a_2,\\cdots, a_n$ be real constants, $x$ a real variable, and $f(x)=\\cos(a_1+x)+\\frac{1}{2}\\cos(a_2+x)+\\frac{1}{4}\\cos(a_3+x)+\\cdots+\\frac{1}{2^{n-1}}\\cos(a_n+x).$ Given that $f(x_1)=f(x_2)=0,$ prove that $x_2-x_1=m\\pi$ for some integer $m.$-/",2500],['''import Mathlib\nimport Aesop\n\nset_option maxHeartbeats 0\n\nopen BigOperators Real Nat Topology Rat\n\n/-- Suppose that $h(x)=f^{-1}(x)$. If $h(2)=10$, $h(10)=1$ and $h(1)=2$, what is $f(f(10))$? Show that it is 1.-/\ntheorem mathd_algebra_209 (Ο : Equiv \\R \\R) (hβ : Ο.2 2 = 10) (hβ : Ο.2 10 = 1) (hβ : Ο.2 1 = 2) :\nΟ.1 (Ο.1 10) = 1 := by''',"/-- Suppose that $h(x)=f^{-1}(x)$. If $h(2)=10$, $h(10)=1$ and $h(1)=2$, what is $f(f(10))$? Show that it is 1.-/",2500],['''import Mathlib\nimport Aesop\n\nset_option maxHeartbeats 0\n\nopen BigOperators Real Nat Topology Rat\n\n/-- At which point do the lines $s=9-2t$ and $t=3s+1$ intersect? Give your answer as an ordered pair in the form $(s, t).$ Show that it is (1,4).-//\ntheorem mathd_algebra_44 (s t : \\R) (hβ : s = 9 - 2 * t) (hβ : t = 3 * s + 1) : s = 1 \\wedge t = 4 := by''',"/-- At which point do the lines $s=9-2t$ and $t=3s+1$ intersect? Give your answer as an ordered pair in the form $(s, t).$ Show that it is (1,4).-/",2500],]model_name = "AI-MO/Kimina-Prover-Distill-8B"76 unmodified lineswith gr.Column:gr.Markdown(description)with gr.Column:gr.Markdown(joinus)with gr.Row():with gr.Column():user_input = gr.Textbox(label="Your message or formal statement", lines=4)informal = gr.Textbox(value=additional_info_prompt, label="Optional informal prefix")max_tokens = gr.Slider(minimum=150, maximum=4096, value=2500, label="Max Tokens")4 unmodified linesjson_out = gr.JSON(label="Full Output")code_out = gr.Code(label="Extracted Lean4 Code", language="python")state = gr.State([])submit.click(chat_handler, [user_input, informal, max_tokens, state], [chat, json_out, code_out, state])gr.Examples(examples=examples,inputs=["user_input", "informal", "max_tokens"],label="Example Problems")gr.Markdown(citation)demo.launch()
app.py+24-3