MCPcopy Create free account
hub / github.com/DataArcTech/ToG / extract_answer

Function extract_answer

ToG/utils.py:163–169  ·  view source on GitHub ↗
(text)

Source from the content-addressed store, hash-verified

161
162
163def extract_answer(text):
164 start_index = text.find("{")
165 end_index = text.find("}")
166 if start_index != -1 and end_index != -1:
167 return text[start_index+1:end_index].strip()
168 else:
169 return ""
170
171
172def if_true(prompt):

Callers 2

reasoningFunction · 0.85
reasoningFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected