qingxu99 commited on
Commit
4e11313
2 Parent(s): f046837 081acc6

Merge branch 'master' into v3.3

Browse files
README.md CHANGED
@@ -1,4 +1,9 @@
1
-
 
 
 
 
 
2
 
3
  # <img src="docs/logo.png" width="40" > ChatGPT 学术优化
4
 
 
1
+ > **Note**
2
+ >
3
+ > 本项目依赖的Gradio组件的新版pip包(Gradio 3.26~3.27)有严重bug。所以,请在安装时严格选择requirements.txt中**指定的版本**。
4
+ >
5
+ > `pip install -r requirements.txt -i https://mirrors.aliyun.com/pypi/simple/`
6
+ >
7
 
8
  # <img src="docs/logo.png" width="40" > ChatGPT 学术优化
9
 
crazy_functions/谷歌检索小助手.py CHANGED
@@ -70,6 +70,7 @@ def 谷歌检索小助手(txt, llm_kwargs, plugin_kwargs, chatbot, history, syst
70
  # 尝试导入依赖,如果缺少依赖,则给出安装建议
71
  try:
72
  import arxiv
 
73
  from bs4 import BeautifulSoup
74
  except:
75
  report_execption(chatbot, history,
@@ -80,23 +81,23 @@ def 谷歌检索小助手(txt, llm_kwargs, plugin_kwargs, chatbot, history, syst
80
 
81
  # 清空历史,以免输入溢出
82
  history = []
83
-
84
  meta_paper_info_list = yield from get_meta_information(txt, chatbot, history)
 
 
 
 
 
 
85
 
86
- if len(meta_paper_info_list[:10]) > 0:
87
- i_say = "下面是一些学术文献的数据,请从中提取出以下内容。" + \
88
- "1、英文题目;2、中文题目翻译;3、作者;4、arxiv公开(is_paper_in_arxiv);4、引用数量(cite);5、中文摘要翻译。" + \
89
- f"以下是信息源:{str(meta_paper_info_list[:10])}"
90
-
91
- inputs_show_user = f"请分析此页面中出现的所有文章:{txt}"
92
- gpt_say = yield from request_gpt_model_in_new_thread_with_ui_alive(
93
- inputs=i_say, inputs_show_user=inputs_show_user,
94
- llm_kwargs=llm_kwargs, chatbot=chatbot, history=[],
95
- sys_prompt="你是一个学术翻译,请从数据中提取信息。你必须使用Markdown格式。你必须逐个文献进行处理。"
96
- )
97
 
98
- history.extend([ "第一批", gpt_say ])
99
- meta_paper_info_list = meta_paper_info_list[10:]
100
 
101
  chatbot.append(["状态?",
102
  "已经全部完成,您可以试试让AI写一个Related Works,例如您可以继续输入Write a \"Related Works\" section about \"你搜索的研究领域\" for me."])
 
70
  # 尝试导入依赖,如果缺少依赖,则给出安装建议
71
  try:
72
  import arxiv
73
+ import math
74
  from bs4 import BeautifulSoup
75
  except:
76
  report_execption(chatbot, history,
 
81
 
82
  # 清空历史,以免输入溢出
83
  history = []
 
84
  meta_paper_info_list = yield from get_meta_information(txt, chatbot, history)
85
+ batchsize = 5
86
+ for batch in range(math.ceil(len(meta_paper_info_list)/batchsize)):
87
+ if len(meta_paper_info_list[:batchsize]) > 0:
88
+ i_say = "下面是一些学术文献的数据,提取出以下内容:" + \
89
+ "1、英文题目;2、中文题目翻译;3、作者;4、arxiv公开(is_paper_in_arxiv);4、引用数量(cite);5、中文摘要翻译。" + \
90
+ f"以下是信息源:{str(meta_paper_info_list[:batchsize])}"
91
 
92
+ inputs_show_user = f"请分析此页面中出现的所有文章:{txt},这是第{batch+1}批"
93
+ gpt_say = yield from request_gpt_model_in_new_thread_with_ui_alive(
94
+ inputs=i_say, inputs_show_user=inputs_show_user,
95
+ llm_kwargs=llm_kwargs, chatbot=chatbot, history=[],
96
+ sys_prompt="你是一个学术翻译,请从数据中提取信息。你必须使用Markdown表格。你必须逐个文献进行处理。"
97
+ )
 
 
 
 
 
98
 
99
+ history.extend([ f"第{batch+1}批", gpt_say ])
100
+ meta_paper_info_list = meta_paper_info_list[batchsize:]
101
 
102
  chatbot.append(["状态?",
103
  "已经全部完成,您可以试试让AI写一个Related Works,例如您可以继续输入Write a \"Related Works\" section about \"你搜索的研究领域\" for me."])
request_llm/bridge_chatglm.py CHANGED
@@ -32,6 +32,7 @@ class GetGLMHandle(Process):
32
  return self.chatglm_model is not None
33
 
34
  def run(self):
 
35
  # 第一次运行,加载参数
36
  retry = 0
37
  while True:
@@ -53,17 +54,24 @@ class GetGLMHandle(Process):
53
  self.child.send('[Local Message] Call ChatGLM fail 不能正常加载ChatGLM的参数。')
54
  raise RuntimeError("不能正常加载ChatGLM的参数!")
55
 
56
- # 进入任务等待状态
57
  while True:
 
58
  kwargs = self.child.recv()
 
59
  try:
60
  for response, history in self.chatglm_model.stream_chat(self.chatglm_tokenizer, **kwargs):
61
  self.child.send(response)
 
 
 
 
62
  except:
63
  self.child.send('[Local Message] Call ChatGLM fail.')
 
64
  self.child.send('[Finish]')
65
 
66
  def stream_chat(self, **kwargs):
 
67
  self.parent.send(kwargs)
68
  while True:
69
  res = self.parent.recv()
@@ -130,14 +138,17 @@ def predict(inputs, llm_kwargs, plugin_kwargs, chatbot, history=[], system_promp
130
  if "PreProcess" in core_functional[additional_fn]: inputs = core_functional[additional_fn]["PreProcess"](inputs) # 获取预处理函数(如果有的话)
131
  inputs = core_functional[additional_fn]["Prefix"] + inputs + core_functional[additional_fn]["Suffix"]
132
 
 
133
  history_feedin = []
134
  history_feedin.append(["What can I do?", system_prompt] )
135
  for i in range(len(history)//2):
136
  history_feedin.append([history[2*i], history[2*i+1]] )
137
 
 
138
  for response in glm_handle.stream_chat(query=inputs, history=history_feedin, max_length=llm_kwargs['max_length'], top_p=llm_kwargs['top_p'], temperature=llm_kwargs['temperature']):
139
  chatbot[-1] = (inputs, response)
140
  yield from update_ui(chatbot=chatbot, history=history)
141
 
 
142
  history.extend([inputs, response])
143
- yield from update_ui(chatbot=chatbot, history=history)
 
32
  return self.chatglm_model is not None
33
 
34
  def run(self):
35
+ # 子进程执行
36
  # 第一次运行,加载参数
37
  retry = 0
38
  while True:
 
54
  self.child.send('[Local Message] Call ChatGLM fail 不能正常加载ChatGLM的参数。')
55
  raise RuntimeError("不能正常加载ChatGLM的参数!")
56
 
 
57
  while True:
58
+ # 进入任务等待状态
59
  kwargs = self.child.recv()
60
+ # 收到消息,开始请求
61
  try:
62
  for response, history in self.chatglm_model.stream_chat(self.chatglm_tokenizer, **kwargs):
63
  self.child.send(response)
64
+ # # 中途接收可能的终止指令(如果有的话)
65
+ # if self.child.poll():
66
+ # command = self.child.recv()
67
+ # if command == '[Terminate]': break
68
  except:
69
  self.child.send('[Local Message] Call ChatGLM fail.')
70
+ # 请求处理结束,开始下一个循环
71
  self.child.send('[Finish]')
72
 
73
  def stream_chat(self, **kwargs):
74
+ # 主进程执行
75
  self.parent.send(kwargs)
76
  while True:
77
  res = self.parent.recv()
 
138
  if "PreProcess" in core_functional[additional_fn]: inputs = core_functional[additional_fn]["PreProcess"](inputs) # 获取预处理函数(如果有的话)
139
  inputs = core_functional[additional_fn]["Prefix"] + inputs + core_functional[additional_fn]["Suffix"]
140
 
141
+ # 处理历史信息
142
  history_feedin = []
143
  history_feedin.append(["What can I do?", system_prompt] )
144
  for i in range(len(history)//2):
145
  history_feedin.append([history[2*i], history[2*i+1]] )
146
 
147
+ # 开始接收chatglm的回复
148
  for response in glm_handle.stream_chat(query=inputs, history=history_feedin, max_length=llm_kwargs['max_length'], top_p=llm_kwargs['top_p'], temperature=llm_kwargs['temperature']):
149
  chatbot[-1] = (inputs, response)
150
  yield from update_ui(chatbot=chatbot, history=history)
151
 
152
+ # 总结输出
153
  history.extend([inputs, response])
154
+ yield from update_ui(chatbot=chatbot, history=history)
theme.py CHANGED
@@ -137,6 +137,16 @@ advanced_css = """
137
 
138
  /* 行内代码的背景设为淡灰色,设定圆角和间距. */
139
  .markdown-body code {
 
 
 
 
 
 
 
 
 
 
140
  display: inline;
141
  white-space: break-spaces;
142
  border-radius: 6px;
@@ -144,8 +154,19 @@ advanced_css = """
144
  padding: .2em .4em .1em .4em;
145
  background-color: rgba(175,184,193,0.2);
146
  }
 
147
  /* 设定代码块的样式,包括背景颜色、内、外边距、圆角。 */
148
  .markdown-body pre code {
 
 
 
 
 
 
 
 
 
 
149
  display: block;
150
  overflow: auto;
151
  white-space: pre;
@@ -160,72 +181,162 @@ advanced_css = """
160
  if CODE_HIGHLIGHT:
161
  advanced_css += """
162
 
163
- .hll { background-color: #ffffcc }
164
- .c { color: #3D7B7B; font-style: italic } /* Comment */
165
- .err { border: 1px solid #FF0000 } /* Error */
166
- .k { color: hsl(197, 94%, 51%); font-weight: bold } /* Keyword */
167
- .o { color: #666666 } /* Operator */
168
- .ch { color: #3D7B7B; font-style: italic } /* Comment.Hashbang */
169
- .cm { color: #3D7B7B; font-style: italic } /* Comment.Multiline */
170
- .cp { color: #9C6500 } /* Comment.Preproc */
171
- .cpf { color: #3D7B7B; font-style: italic } /* Comment.PreprocFile */
172
- .c1 { color: #3D7B7B; font-style: italic } /* Comment.Single */
173
- .cs { color: #3D7B7B; font-style: italic } /* Comment.Special */
174
- .gd { color: #A00000 } /* Generic.Deleted */
175
- .ge { font-style: italic } /* Generic.Emph */
176
- .gr { color: #E40000 } /* Generic.Error */
177
- .gh { color: #000080; font-weight: bold } /* Generic.Heading */
178
- .gi { color: #008400 } /* Generic.Inserted */
179
- .go { color: #717171 } /* Generic.Output */
180
- .gp { color: #000080; font-weight: bold } /* Generic.Prompt */
181
- .gs { font-weight: bold } /* Generic.Strong */
182
- .gu { color: #800080; font-weight: bold } /* Generic.Subheading */
183
- .gt { color: #a9dd00 } /* Generic.Traceback */
184
- .kc { color: #008000; font-weight: bold } /* Keyword.Constant */
185
- .kd { color: #008000; font-weight: bold } /* Keyword.Declaration */
186
- .kn { color: #008000; font-weight: bold } /* Keyword.Namespace */
187
- .kp { color: #008000 } /* Keyword.Pseudo */
188
- .kr { color: #008000; font-weight: bold } /* Keyword.Reserved */
189
- .kt { color: #B00040 } /* Keyword.Type */
190
- .m { color: #666666 } /* Literal.Number */
191
- .s { color: #BA2121 } /* Literal.String */
192
- .na { color: #687822 } /* Name.Attribute */
193
- .nb { color: #e5f8c3 } /* Name.Builtin */
194
- .nc { color: #ffad65; font-weight: bold } /* Name.Class */
195
- .no { color: #880000 } /* Name.Constant */
196
- .nd { color: #AA22FF } /* Name.Decorator */
197
- .ni { color: #717171; font-weight: bold } /* Name.Entity */
198
- .ne { color: #CB3F38; font-weight: bold } /* Name.Exception */
199
- .nf { color: #f9f978 } /* Name.Function */
200
- .nl { color: #767600 } /* Name.Label */
201
- .nn { color: #0000FF; font-weight: bold } /* Name.Namespace */
202
- .nt { color: #008000; font-weight: bold } /* Name.Tag */
203
- .nv { color: #19177C } /* Name.Variable */
204
- .ow { color: #AA22FF; font-weight: bold } /* Operator.Word */
205
- .w { color: #bbbbbb } /* Text.Whitespace */
206
- .mb { color: #666666 } /* Literal.Number.Bin */
207
- .mf { color: #666666 } /* Literal.Number.Float */
208
- .mh { color: #666666 } /* Literal.Number.Hex */
209
- .mi { color: #666666 } /* Literal.Number.Integer */
210
- .mo { color: #666666 } /* Literal.Number.Oct */
211
- .sa { color: #BA2121 } /* Literal.String.Affix */
212
- .sb { color: #BA2121 } /* Literal.String.Backtick */
213
- .sc { color: #BA2121 } /* Literal.String.Char */
214
- .dl { color: #BA2121 } /* Literal.String.Delimiter */
215
- .sd { color: #BA2121; font-style: italic } /* Literal.String.Doc */
216
- .s2 { color: #2bf840 } /* Literal.String.Double */
217
- .se { color: #AA5D1F; font-weight: bold } /* Literal.String.Escape */
218
- .sh { color: #BA2121 } /* Literal.String.Heredoc */
219
- .si { color: #A45A77; font-weight: bold } /* Literal.String.Interpol */
220
- .sx { color: #008000 } /* Literal.String.Other */
221
- .sr { color: #A45A77 } /* Literal.String.Regex */
222
- .s1 { color: #BA2121 } /* Literal.String.Single */
223
- .ss { color: #19177C } /* Literal.String.Symbol */
224
- .bp { color: #008000 } /* Name.Builtin.Pseudo */
225
- .fm { color: #0000FF } /* Name.Function.Magic */
226
- .vc { color: #19177C } /* Name.Variable.Class */
227
- .vg { color: #19177C } /* Name.Variable.Global */
228
- .vi { color: #19177C } /* Name.Variable.Instance */
229
- .vm { color: #19177C } /* Name.Variable.Magic */
230
- .il { color: #666666 } /* Literal.Number.Integer.Long */
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
231
  """
 
137
 
138
  /* 行内代码的背景设为淡灰色,设定圆角和间距. */
139
  .markdown-body code {
140
+ display: inline;
141
+ white-space: break-spaces;
142
+ border-radius: 6px;
143
+ margin: 0 2px 0 2px;
144
+ padding: .2em .4em .1em .4em;
145
+ background-color: rgba(13, 17, 23, 0.95);
146
+ color: #c9d1d9;
147
+ }
148
+
149
+ .dark .markdown-body code {
150
  display: inline;
151
  white-space: break-spaces;
152
  border-radius: 6px;
 
154
  padding: .2em .4em .1em .4em;
155
  background-color: rgba(175,184,193,0.2);
156
  }
157
+
158
  /* 设定代码块的样式,包括背景颜色、内、外边距、圆角。 */
159
  .markdown-body pre code {
160
+ display: block;
161
+ overflow: auto;
162
+ white-space: pre;
163
+ background-color: rgba(13, 17, 23, 0.95);
164
+ border-radius: 10px;
165
+ padding: 1em;
166
+ margin: 1em 2em 1em 0.5em;
167
+ }
168
+
169
+ .dark .markdown-body pre code {
170
  display: block;
171
  overflow: auto;
172
  white-space: pre;
 
181
  if CODE_HIGHLIGHT:
182
  advanced_css += """
183
 
184
+ .codehilite .hll { background-color: #6e7681 }
185
+ .codehilite .c { color: #8b949e; font-style: italic } /* Comment */
186
+ .codehilite .err { color: #f85149 } /* Error */
187
+ .codehilite .esc { color: #c9d1d9 } /* Escape */
188
+ .codehilite .g { color: #c9d1d9 } /* Generic */
189
+ .codehilite .k { color: #ff7b72 } /* Keyword */
190
+ .codehilite .l { color: #a5d6ff } /* Literal */
191
+ .codehilite .n { color: #c9d1d9 } /* Name */
192
+ .codehilite .o { color: #ff7b72; font-weight: bold } /* Operator */
193
+ .codehilite .x { color: #c9d1d9 } /* Other */
194
+ .codehilite .p { color: #c9d1d9 } /* Punctuation */
195
+ .codehilite .ch { color: #8b949e; font-style: italic } /* Comment.Hashbang */
196
+ .codehilite .cm { color: #8b949e; font-style: italic } /* Comment.Multiline */
197
+ .codehilite .cp { color: #8b949e; font-weight: bold; font-style: italic } /* Comment.Preproc */
198
+ .codehilite .cpf { color: #8b949e; font-style: italic } /* Comment.PreprocFile */
199
+ .codehilite .c1 { color: #8b949e; font-style: italic } /* Comment.Single */
200
+ .codehilite .cs { color: #8b949e; font-weight: bold; font-style: italic } /* Comment.Special */
201
+ .codehilite .gd { color: #ffa198; background-color: #490202 } /* Generic.Deleted */
202
+ .codehilite .ge { color: #c9d1d9; font-style: italic } /* Generic.Emph */
203
+ .codehilite .gr { color: #ffa198 } /* Generic.Error */
204
+ .codehilite .gh { color: #79c0ff; font-weight: bold } /* Generic.Heading */
205
+ .codehilite .gi { color: #56d364; background-color: #0f5323 } /* Generic.Inserted */
206
+ .codehilite .go { color: #8b949e } /* Generic.Output */
207
+ .codehilite .gp { color: #8b949e } /* Generic.Prompt */
208
+ .codehilite .gs { color: #c9d1d9; font-weight: bold } /* Generic.Strong */
209
+ .codehilite .gu { color: #79c0ff } /* Generic.Subheading */
210
+ .codehilite .gt { color: #ff7b72 } /* Generic.Traceback */
211
+ .codehilite .g-Underline { color: #c9d1d9; text-decoration: underline } /* Generic.Underline */
212
+ .codehilite .kc { color: #79c0ff } /* Keyword.Constant */
213
+ .codehilite .kd { color: #ff7b72 } /* Keyword.Declaration */
214
+ .codehilite .kn { color: #ff7b72 } /* Keyword.Namespace */
215
+ .codehilite .kp { color: #79c0ff } /* Keyword.Pseudo */
216
+ .codehilite .kr { color: #ff7b72 } /* Keyword.Reserved */
217
+ .codehilite .kt { color: #ff7b72 } /* Keyword.Type */
218
+ .codehilite .ld { color: #79c0ff } /* Literal.Date */
219
+ .codehilite .m { color: #a5d6ff } /* Literal.Number */
220
+ .codehilite .s { color: #a5d6ff } /* Literal.String */
221
+ .codehilite .na { color: #c9d1d9 } /* Name.Attribute */
222
+ .codehilite .nb { color: #c9d1d9 } /* Name.Builtin */
223
+ .codehilite .nc { color: #f0883e; font-weight: bold } /* Name.Class */
224
+ .codehilite .no { color: #79c0ff; font-weight: bold } /* Name.Constant */
225
+ .codehilite .nd { color: #d2a8ff; font-weight: bold } /* Name.Decorator */
226
+ .codehilite .ni { color: #ffa657 } /* Name.Entity */
227
+ .codehilite .ne { color: #f0883e; font-weight: bold } /* Name.Exception */
228
+ .codehilite .nf { color: #d2a8ff; font-weight: bold } /* Name.Function */
229
+ .codehilite .nl { color: #79c0ff; font-weight: bold } /* Name.Label */
230
+ .codehilite .nn { color: #ff7b72 } /* Name.Namespace */
231
+ .codehilite .nx { color: #c9d1d9 } /* Name.Other */
232
+ .codehilite .py { color: #79c0ff } /* Name.Property */
233
+ .codehilite .nt { color: #7ee787 } /* Name.Tag */
234
+ .codehilite .nv { color: #79c0ff } /* Name.Variable */
235
+ .codehilite .ow { color: #ff7b72; font-weight: bold } /* Operator.Word */
236
+ .codehilite .pm { color: #c9d1d9 } /* Punctuation.Marker */
237
+ .codehilite .w { color: #6e7681 } /* Text.Whitespace */
238
+ .codehilite .mb { color: #a5d6ff } /* Literal.Number.Bin */
239
+ .codehilite .mf { color: #a5d6ff } /* Literal.Number.Float */
240
+ .codehilite .mh { color: #a5d6ff } /* Literal.Number.Hex */
241
+ .codehilite .mi { color: #a5d6ff } /* Literal.Number.Integer */
242
+ .codehilite .mo { color: #a5d6ff } /* Literal.Number.Oct */
243
+ .codehilite .sa { color: #79c0ff } /* Literal.String.Affix */
244
+ .codehilite .sb { color: #a5d6ff } /* Literal.String.Backtick */
245
+ .codehilite .sc { color: #a5d6ff } /* Literal.String.Char */
246
+ .codehilite .dl { color: #79c0ff } /* Literal.String.Delimiter */
247
+ .codehilite .sd { color: #a5d6ff } /* Literal.String.Doc */
248
+ .codehilite .s2 { color: #a5d6ff } /* Literal.String.Double */
249
+ .codehilite .se { color: #79c0ff } /* Literal.String.Escape */
250
+ .codehilite .sh { color: #79c0ff } /* Literal.String.Heredoc */
251
+ .codehilite .si { color: #a5d6ff } /* Literal.String.Interpol */
252
+ .codehilite .sx { color: #a5d6ff } /* Literal.String.Other */
253
+ .codehilite .sr { color: #79c0ff } /* Literal.String.Regex */
254
+ .codehilite .s1 { color: #a5d6ff } /* Literal.String.Single */
255
+ .codehilite .ss { color: #a5d6ff } /* Literal.String.Symbol */
256
+ .codehilite .bp { color: #c9d1d9 } /* Name.Builtin.Pseudo */
257
+ .codehilite .fm { color: #d2a8ff; font-weight: bold } /* Name.Function.Magic */
258
+ .codehilite .vc { color: #79c0ff } /* Name.Variable.Class */
259
+ .codehilite .vg { color: #79c0ff } /* Name.Variable.Global */
260
+ .codehilite .vi { color: #79c0ff } /* Name.Variable.Instance */
261
+ .codehilite .vm { color: #79c0ff } /* Name.Variable.Magic */
262
+ .codehilite .il { color: #a5d6ff } /* Literal.Number.Integer.Long */
263
+
264
+ .dark .codehilite .hll { background-color: #2C3B41 }
265
+ .dark .codehilite .c { color: #79d618; font-style: italic } /* Comment */
266
+ .dark .codehilite .err { color: #FF5370 } /* Error */
267
+ .dark .codehilite .esc { color: #89DDFF } /* Escape */
268
+ .dark .codehilite .g { color: #EEFFFF } /* Generic */
269
+ .dark .codehilite .k { color: #BB80B3 } /* Keyword */
270
+ .dark .codehilite .l { color: #C3E88D } /* Literal */
271
+ .dark .codehilite .n { color: #EEFFFF } /* Name */
272
+ .dark .codehilite .o { color: #89DDFF } /* Operator */
273
+ .dark .codehilite .p { color: #89DDFF } /* Punctuation */
274
+ .dark .codehilite .ch { color: #79d618; font-style: italic } /* Comment.Hashbang */
275
+ .dark .codehilite .cm { color: #79d618; font-style: italic } /* Comment.Multiline */
276
+ .dark .codehilite .cp { color: #79d618; font-style: italic } /* Comment.Preproc */
277
+ .dark .codehilite .cpf { color: #79d618; font-style: italic } /* Comment.PreprocFile */
278
+ .dark .codehilite .c1 { color: #79d618; font-style: italic } /* Comment.Single */
279
+ .dark .codehilite .cs { color: #79d618; font-style: italic } /* Comment.Special */
280
+ .dark .codehilite .gd { color: #FF5370 } /* Generic.Deleted */
281
+ .dark .codehilite .ge { color: #89DDFF } /* Generic.Emph */
282
+ .dark .codehilite .gr { color: #FF5370 } /* Generic.Error */
283
+ .dark .codehilite .gh { color: #C3E88D } /* Generic.Heading */
284
+ .dark .codehilite .gi { color: #C3E88D } /* Generic.Inserted */
285
+ .dark .codehilite .go { color: #79d618 } /* Generic.Output */
286
+ .dark .codehilite .gp { color: #FFCB6B } /* Generic.Prompt */
287
+ .dark .codehilite .gs { color: #FF5370 } /* Generic.Strong */
288
+ .dark .codehilite .gu { color: #89DDFF } /* Generic.Subheading */
289
+ .dark .codehilite .gt { color: #FF5370 } /* Generic.Traceback */
290
+ .dark .codehilite .kc { color: #89DDFF } /* Keyword.Constant */
291
+ .dark .codehilite .kd { color: #BB80B3 } /* Keyword.Declaration */
292
+ .dark .codehilite .kn { color: #89DDFF; font-style: italic } /* Keyword.Namespace */
293
+ .dark .codehilite .kp { color: #89DDFF } /* Keyword.Pseudo */
294
+ .dark .codehilite .kr { color: #BB80B3 } /* Keyword.Reserved */
295
+ .dark .codehilite .kt { color: #BB80B3 } /* Keyword.Type */
296
+ .dark .codehilite .ld { color: #C3E88D } /* Literal.Date */
297
+ .dark .codehilite .m { color: #F78C6C } /* Literal.Number */
298
+ .dark .codehilite .s { color: #C3E88D } /* Literal.String */
299
+ .dark .codehilite .na { color: #BB80B3 } /* Name.Attribute */
300
+ .dark .codehilite .nb { color: #82AAFF } /* Name.Builtin */
301
+ .dark .codehilite .nc { color: #FFCB6B } /* Name.Class */
302
+ .dark .codehilite .no { color: #EEFFFF } /* Name.Constant */
303
+ .dark .codehilite .nd { color: #82AAFF } /* Name.Decorator */
304
+ .dark .codehilite .ni { color: #89DDFF } /* Name.Entity */
305
+ .dark .codehilite .ne { color: #FFCB6B } /* Name.Exception */
306
+ .dark .codehilite .nf { color: #82AAFF } /* Name.Function */
307
+ .dark .codehilite .nl { color: #82AAFF } /* Name.Label */
308
+ .dark .codehilite .nn { color: #FFCB6B } /* Name.Namespace */
309
+ .dark .codehilite .nx { color: #EEFFFF } /* Name.Other */
310
+ .dark .codehilite .py { color: #FFCB6B } /* Name.Property */
311
+ .dark .codehilite .nt { color: #FF5370 } /* Name.Tag */
312
+ .dark .codehilite .nv { color: #89DDFF } /* Name.Variable */
313
+ .dark .codehilite .ow { color: #89DDFF; font-style: italic } /* Operator.Word */
314
+ .dark .codehilite .pm { color: #89DDFF } /* Punctuation.Marker */
315
+ .dark .codehilite .w { color: #EEFFFF } /* Text.Whitespace */
316
+ .dark .codehilite .mb { color: #F78C6C } /* Literal.Number.Bin */
317
+ .dark .codehilite .mf { color: #F78C6C } /* Literal.Number.Float */
318
+ .dark .codehilite .mh { color: #F78C6C } /* Literal.Number.Hex */
319
+ .dark .codehilite .mi { color: #F78C6C } /* Literal.Number.Integer */
320
+ .dark .codehilite .mo { color: #F78C6C } /* Literal.Number.Oct */
321
+ .dark .codehilite .sa { color: #BB80B3 } /* Literal.String.Affix */
322
+ .dark .codehilite .sb { color: #C3E88D } /* Literal.String.Backtick */
323
+ .dark .codehilite .sc { color: #C3E88D } /* Literal.String.Char */
324
+ .dark .codehilite .dl { color: #EEFFFF } /* Literal.String.Delimiter */
325
+ .dark .codehilite .sd { color: #79d618; font-style: italic } /* Literal.String.Doc */
326
+ .dark .codehilite .s2 { color: #C3E88D } /* Literal.String.Double */
327
+ .dark .codehilite .se { color: #EEFFFF } /* Literal.String.Escape */
328
+ .dark .codehilite .sh { color: #C3E88D } /* Literal.String.Heredoc */
329
+ .dark .codehilite .si { color: #89DDFF } /* Literal.String.Interpol */
330
+ .dark .codehilite .sx { color: #C3E88D } /* Literal.String.Other */
331
+ .dark .codehilite .sr { color: #89DDFF } /* Literal.String.Regex */
332
+ .dark .codehilite .s1 { color: #C3E88D } /* Literal.String.Single */
333
+ .dark .codehilite .ss { color: #89DDFF } /* Literal.String.Symbol */
334
+ .dark .codehilite .bp { color: #89DDFF } /* Name.Builtin.Pseudo */
335
+ .dark .codehilite .fm { color: #82AAFF } /* Name.Function.Magic */
336
+ .dark .codehilite .vc { color: #89DDFF } /* Name.Variable.Class */
337
+ .dark .codehilite .vg { color: #89DDFF } /* Name.Variable.Global */
338
+ .dark .codehilite .vi { color: #89DDFF } /* Name.Variable.Instance */
339
+ .dark .codehilite .vm { color: #82AAFF } /* Name.Variable.Magic */
340
+ .dark .codehilite .il { color: #F78C6C } /* Literal.Number.Integer.Long */
341
+
342
  """