arjunanand13 commited on
Commit
c42f5d4
1 Parent(s): b27ddbb

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -4
app.py CHANGED
@@ -111,10 +111,8 @@ class DocumentRetrievalAndGeneration:
111
  if match1:
112
  solution_text = match1.group(1).strip()
113
  print(solution_text)
114
- match12 = re.search(r'Solution:(.*?)', solution_text, re.DOTALL)
115
- if match12:
116
- solution_text=match12.group(1).strip()
117
- print(solution_text)
118
  elif match2:
119
  solution_text = match2.group(1).strip()
120
  print(solution_text)
 
111
  if match1:
112
  solution_text = match1.group(1).strip()
113
  print(solution_text)
114
+ if "Solution:" in solution_text:
115
+ solution_text = solution_text.split("Solution:", 1)[1].strip()
 
 
116
  elif match2:
117
  solution_text = match2.group(1).strip()
118
  print(solution_text)