CineAI commited on
Commit
63ed31d
1 Parent(s): 7801155

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -57,8 +57,9 @@ def switching(text):
57
  components.html(html_doge_wallet, height=600, scrolling=False)
58
  elif re.search("long live liberty", text.lower(), re.IGNORECASE):
59
  exctracted_statement = exctrator(text.lower(), phrase="long live liberty")
60
- print(f"exctracted_statement: {exctracted_statement}")
61
- prompt = f"Evaluate how far the statement from libertarian ideology 1 to 10 and why?\n\n{exctracted_statement}"
 
62
  print(f"Liberty prompt: {prompt}")
63
  result = get_response(prompt)
64
  else:
 
57
  components.html(html_doge_wallet, height=600, scrolling=False)
58
  elif re.search("long live liberty", text.lower(), re.IGNORECASE):
59
  exctracted_statement = exctrator(text.lower(), phrase="long live liberty")
60
+ cleaned_sentence = re.sub(r'^\W+', '', exctracted_statement)
61
+ print(f"exctracted_statement: {cleaned_sentence}")
62
+ prompt = f"Evaluate how far the statement from libertarian ideology 1 to 10 and why?\n\n{cleaned_sentence}"
63
  print(f"Liberty prompt: {prompt}")
64
  result = get_response(prompt)
65
  else: