yizhangliu commited on
Commit
021407a
1 Parent(s): 9d752bb

update app.py

Browse files
Files changed (2) hide show
  1. app.py +2 -2
  2. requirements.txt +2 -2
app.py CHANGED
@@ -66,7 +66,7 @@ def check_code_error(code, language='python'):
66
 
67
  return {'result': True, 'error': False, 'root_node': root_node}
68
  except Exception as e:
69
- return {'result': False, 'error': str(e)}
70
 
71
  def history_to_messages(history: History, system: str) -> Messages:
72
  messages = [{'role': 'system', 'content': system}]
@@ -186,7 +186,7 @@ with gr.Blocks(css_paths="app.css", title="Qwen2.5 Coder Artifacts (+SambaNova+F
186
  code_language_example = gr.Textbox(show_label=False, lines=1, container=False, visible=False)
187
  input_text_title= gr.TextArea(show_label=False, container=False, visible=False)
188
  input_text_example = gr.TextArea(show_label=False, container=False, visible=False)
189
- with gr.Tab("Examples_HTML"):
190
  input_examples = get_input_examples()
191
  gr.Examples(
192
  examples=input_examples,
 
66
 
67
  return {'result': True, 'error': False, 'root_node': root_node}
68
  except Exception as e:
69
+ return {'result': False, 'error': f"error:{str(e)}"}
70
 
71
  def history_to_messages(history: History, system: str) -> Messages:
72
  messages = [{'role': 'system', 'content': system}]
 
186
  code_language_example = gr.Textbox(show_label=False, lines=1, container=False, visible=False)
187
  input_text_title= gr.TextArea(show_label=False, container=False, visible=False)
188
  input_text_example = gr.TextArea(show_label=False, container=False, visible=False)
189
+ with gr.Tab("Examples_HTML"):
190
  input_examples = get_input_examples()
191
  gr.Examples(
192
  examples=input_examples,
requirements.txt CHANGED
@@ -2,6 +2,6 @@ dashscope
2
  modelscope_studio~=1.0.0b
3
  sambanova_gradio
4
  openai
5
- tree-sitter
6
- tree-sitter-languages
7
  loguru
 
2
  modelscope_studio~=1.0.0b
3
  sambanova_gradio
4
  openai
5
+ tree-sitter==0.21.3
6
+ tree-sitter-languages==1.10.2
7
  loguru