wwpop commited on
Commit
03e68a3
·
verified ·
1 Parent(s): 4a2e422

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +0 -18
app.py CHANGED
@@ -40,23 +40,6 @@ def respond(
40
  yield response
41
 
42
 
43
- # Gradio ChatInterface setup with MathJax
44
- mathjax_script = """
45
- <script src="https://polyfill.io/v3/polyfill.min.js?features=es6"></script>
46
- <script id="MathJax-script" async src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js"></script>
47
- <script>
48
- document.addEventListener('DOMContentLoaded', function() {
49
- MathJax = {
50
- tex: {
51
- inlineMath: [['$', '$'], ['\$$', '\\)']]
52
- },
53
- svg: {
54
- fontCache: 'global'
55
- }
56
- };
57
- });
58
- </script>
59
- """
60
  demo = gr.ChatInterface(
61
  respond,
62
  examples=[["你好,你是谁?"], ["你是谁开发的?"]],
@@ -69,7 +52,6 @@ demo = gr.ChatInterface(
69
  gr.Slider(minimum=0.1, maximum=4.0, value=0.7, step=0.1, label="Temperature"),
70
  gr.Slider(minimum=0.1, maximum=1.0, value=0.95, step=0.05, label="Top-p (nucleus sampling)"),
71
  ],
72
- css=mathjax_script,
73
  chatbot=gr.Chatbot(show_label=False, show_share_button=False, show_copy_button=True, likeable=True, layout="panel")
74
 
75
  )
 
40
  yield response
41
 
42
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
43
  demo = gr.ChatInterface(
44
  respond,
45
  examples=[["你好,你是谁?"], ["你是谁开发的?"]],
 
52
  gr.Slider(minimum=0.1, maximum=4.0, value=0.7, step=0.1, label="Temperature"),
53
  gr.Slider(minimum=0.1, maximum=1.0, value=0.95, step=0.05, label="Top-p (nucleus sampling)"),
54
  ],
 
55
  chatbot=gr.Chatbot(show_label=False, show_share_button=False, show_copy_button=True, likeable=True, layout="panel")
56
 
57
  )