Pendrokar commited on
Commit
4024260
β€’
1 Parent(s): 11f2f1a

func reorder

Browse files
resources/app/plugins/deepmoji_plugin/sentiment.py CHANGED
@@ -48,6 +48,22 @@ model_amplifiers = {
48
  }
49
  amplifier_value = None
50
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
51
  def setup(data=None):
52
  global game_list, model_amplifiers
53
 
@@ -203,21 +219,6 @@ def fetch_text_batch(data=None):
203
  # 'Emoji_1', 'Emoji_2', 'Emoji_3', 'Emoji_4', 'Emoji_5',
204
  # 'Pct_1', 'Pct_2', 'Pct_3', 'Pct_4', 'Pct_5'])
205
 
206
- def clean_special_chars(text):
207
- # quotemarks " can create problems for dict_replace
208
- # remove the ones at start and end of text
209
- if text.strip()[0]:\
210
- text = text.replace("\"", "", 1)
211
- if text.strip()[-1]:\
212
- text = text[::-1].replace("\"", "", 1)[::-1]
213
- # replace all others with a colon
214
- text = text.replace("\"", ":")
215
-
216
- # remove asterisks
217
- text.replace("*","")
218
-
219
- return text
220
-
221
  def adjust_values(data=None):
222
  global root_path, os, csv, example_helper,\
223
  isBatch, isXVAPitch, isEnglish, logger, emoji_count, text_scores, plugin_settings,\
 
48
  }
49
  amplifier_value = None
50
 
51
+
52
+ def clean_special_chars(text):
53
+ # quotemarks " can create problems for dict_replace
54
+ # remove the ones at start and end of text
55
+ if text.strip()[0]:\
56
+ text = text.replace("\"", "", 1)
57
+ if text.strip()[-1]:\
58
+ text = text[::-1].replace("\"", "", 1)[::-1]
59
+ # replace all others with a colon
60
+ text = text.replace("\"", ":")
61
+
62
+ # remove asterisks
63
+ text.replace("*","")
64
+
65
+ return text
66
+
67
  def setup(data=None):
68
  global game_list, model_amplifiers
69
 
 
219
  # 'Emoji_1', 'Emoji_2', 'Emoji_3', 'Emoji_4', 'Emoji_5',
220
  # 'Pct_1', 'Pct_2', 'Pct_3', 'Pct_4', 'Pct_5'])
221
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
222
  def adjust_values(data=None):
223
  global root_path, os, csv, example_helper,\
224
  isBatch, isXVAPitch, isEnglish, logger, emoji_count, text_scores, plugin_settings,\