Hugo Pitorro commited on
Commit
ca5b7fd
·
1 Parent(s): 7a49f84

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -1
app.py CHANGED
@@ -72,7 +72,9 @@ def rank_candidate_text(sentences):
72
  def full_pipeline(source, simpl_model, simpl_tok, tokens, lexical=False):
73
 
74
  modified, complex_words = id_replace_complex(
75
- source, threshold=0.2) if lexical else source, None
 
 
76
  cands = generate_candidate_text(tokens+modified, simpl_model, simpl_tok)
77
  output = rank_candidate_text(cands)
78
  return output, complex_words
@@ -118,6 +120,7 @@ def main():
118
 
119
  tokens = " ".join([t+str(v) for t, v in zip(aug_tok, user_values)]) + " "
120
  output, words = full_pipeline(input_sentence, simpl_model, simpl_tok, tokens, lexical)
 
121
 
122
  c1, c2 = st.columns([1,2])
123
 
 
72
  def full_pipeline(source, simpl_model, simpl_tok, tokens, lexical=False):
73
 
74
  modified, complex_words = id_replace_complex(
75
+ source, threshold=0.2) if lexical else source, None´
76
+
77
+ print(modified)
78
  cands = generate_candidate_text(tokens+modified, simpl_model, simpl_tok)
79
  output = rank_candidate_text(cands)
80
  return output, complex_words
 
120
 
121
  tokens = " ".join([t+str(v) for t, v in zip(aug_tok, user_values)]) + " "
122
  output, words = full_pipeline(input_sentence, simpl_model, simpl_tok, tokens, lexical)
123
+ print(tokens, lexical)
124
 
125
  c1, c2 = st.columns([1,2])
126