ford442 commited on
Commit
7bd01b2
·
verified ·
1 Parent(s): c31cd7a

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -83,8 +83,8 @@ model = AutoModelForCausalLM.from_pretrained(checkpoint, device_map='balanced')
83
 
84
  def filter_text(text):
85
  """Filters out the text up to and including 'Rewritten Prompt:'."""
86
- phrase = "Rewritten Prompt: "
87
- phraseB = "rewritten text: "
88
  pattern = f"(.*?){re.escape(phrase)}(.*)"
89
  patternB = f"(.*?){re.escape(phraseB)}(.*)"
90
  # matchB = re.search(patternB, text)
 
83
 
84
  def filter_text(text):
85
  """Filters out the text up to and including 'Rewritten Prompt:'."""
86
+ phrase = "Rewritten Prompt:"
87
+ phraseB = "rewritten text:"
88
  pattern = f"(.*?){re.escape(phrase)}(.*)"
89
  patternB = f"(.*?){re.escape(phraseB)}(.*)"
90
  # matchB = re.search(patternB, text)