Spaces:
basit123796
/
Runtime error

Tonic commited on
Commit
74d6bf5
โ€ข
1 Parent(s): c3409a3

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -3
app.py CHANGED
@@ -10,6 +10,8 @@ You can also use ๐Ÿ”ฎDeepSeekMath๐Ÿ“‰ by cloning this space. Simply click here:
10
  Join us : ๐ŸŒŸTeamTonic๐ŸŒŸ is always making cool demos! Join our active builder's ๐Ÿ› ๏ธcommunity ๐Ÿ‘ป [![Join us on Discord](https://img.shields.io/discord/1109943800132010065?label=Discord&logo=discord&style=flat-square)](https://discord.gg/GWpVpekp) On ๐Ÿค—Huggingface: [TeamTonic](https://huggingface.co/TeamTonic) & [MultiTransformer](https://huggingface.co/MultiTransformer) Math with [introspector](https://huggingface.co/introspector) On ๐ŸŒGithub: [Tonic-AI](https://github.com/tonic-ai) & contribute to๐ŸŒŸ [SciTonic](https://github.com/Tonic-AI/scitonic)๐Ÿค—Big thanks to Yuvi Sharma and all the folks at huggingface for the community grant ๐Ÿค—
11
  """
12
 
 
 
13
  unimath1 = """Goal:
14
 
15
  X : UU
@@ -147,9 +149,10 @@ def main():
147
  submit_button = gr.Button("๐Ÿ“‰Solve")
148
  question = gr.Code(language='python', value='what is the integral of x^2 from 0 to 2?', label="๐Ÿค”Enter your math problem")
149
  additional_info = gr.Text(value='Please reason step by step, and put your final answer within \\boxed{{}}', label="๐ŸชœOptional train-of-thought")
150
- with gr.Accordion("๐Ÿค–metaintrospector/UniMath Examples"):
151
- for example in unimath_examples:
152
- gr.Textbox(value=example, label="๐Ÿค–UniMath Example", lines=10)
 
153
 
154
  submit_button.click(fn=solve_math_problem, inputs=[question, additional_info, max_tokens], outputs=[full_answer_output, final_answer_output])
155
 
 
10
  Join us : ๐ŸŒŸTeamTonic๐ŸŒŸ is always making cool demos! Join our active builder's ๐Ÿ› ๏ธcommunity ๐Ÿ‘ป [![Join us on Discord](https://img.shields.io/discord/1109943800132010065?label=Discord&logo=discord&style=flat-square)](https://discord.gg/GWpVpekp) On ๐Ÿค—Huggingface: [TeamTonic](https://huggingface.co/TeamTonic) & [MultiTransformer](https://huggingface.co/MultiTransformer) Math with [introspector](https://huggingface.co/introspector) On ๐ŸŒGithub: [Tonic-AI](https://github.com/tonic-ai) & contribute to๐ŸŒŸ [SciTonic](https://github.com/Tonic-AI/scitonic)๐Ÿค—Big thanks to Yuvi Sharma and all the folks at huggingface for the community grant ๐Ÿค—
11
  """
12
 
13
+ additional_info_prompt = "Explain the above using mathematics, print entire answer in latex format:"
14
+
15
  unimath1 = """Goal:
16
 
17
  X : UU
 
149
  submit_button = gr.Button("๐Ÿ“‰Solve")
150
  question = gr.Code(language='python', value='what is the integral of x^2 from 0 to 2?', label="๐Ÿค”Enter your math problem")
151
  additional_info = gr.Text(value='Please reason step by step, and put your final answer within \\boxed{{}}', label="๐ŸชœOptional train-of-thought")
152
+ with gr.Accordion("๐Ÿค– UniMath Examples", open=False):
153
+ gr.Markdown("Click a ๐Ÿค– UniMath example to load it into the solver.")
154
+ for i, example in enumerate([unimath1, unimath2, unimath3, unimath4], start=1):
155
+ gr.Button(f"Example {i}", elem_id=f"example{i}").click(fn=set_example, inputs=example, outputs=[question_field, additional_info_field])
156
 
157
  submit_button.click(fn=solve_math_problem, inputs=[question, additional_info, max_tokens], outputs=[full_answer_output, final_answer_output])
158