yxmauw commited on
Commit
9dddbaf
1 Parent(s): f57f2aa

Update load_llms.py

Browse files
Files changed (1) hide show
  1. load_llms.py +6 -6
load_llms.py CHANGED
@@ -18,12 +18,6 @@ def model_choices():
18
  model_description = {model['filename']: model['description'] for model in data_json}
19
 
20
 
21
- def llm_intro(selected_model):
22
- html_string = model_description.get(selected_model, "No description available for this model selection.")
23
- formatted_description = html_string.replace("<ul>", "").replace("</ul>", "").replace("</li>", "").replace("<br>", "\n").replace("</br>", "").replace("<li>", "\n➤ ")
24
- return formatted_description
25
-
26
-
27
  def remove_endtags(html_string, tags):
28
  """Remove rear HTML tags from the input string."""
29
  for tag in tags:
@@ -53,6 +47,12 @@ def format_html_string(html_string):
53
 
54
  return formatted_string
55
 
 
 
 
 
 
 
56
 
57
  # cache models for faster reloads
58
  model_cache = {}
 
18
  model_description = {model['filename']: model['description'] for model in data_json}
19
 
20
 
 
 
 
 
 
 
21
  def remove_endtags(html_string, tags):
22
  """Remove rear HTML tags from the input string."""
23
  for tag in tags:
 
47
 
48
  return formatted_string
49
 
50
+
51
+ def llm_intro(selected_model):
52
+ html_string = model_description.get(selected_model, "No description available for this model selection.")
53
+ formatted_description = format_html_string(html_string)
54
+ return formatted_description
55
+
56
 
57
  # cache models for faster reloads
58
  model_cache = {}