Spaces:
Sleeping
Sleeping
Zekun Wu
commited on
Commit
•
fabf9a0
1
Parent(s):
66437b8
update
Browse files- util/generation.py +1 -0
util/generation.py
CHANGED
@@ -38,6 +38,7 @@ def invoke_retry(prompt,agent,parameters):
|
|
38 |
while attempts < max_attempts:
|
39 |
try:
|
40 |
score_text = agent.invoke(prompt, **parameters)
|
|
|
41 |
score = re.search(r'\d+', score_text)
|
42 |
return int(score.group()) if score else -1
|
43 |
except Exception as e:
|
|
|
38 |
while attempts < max_attempts:
|
39 |
try:
|
40 |
score_text = agent.invoke(prompt, **parameters)
|
41 |
+
print(f"Score text: {score_text}")
|
42 |
score = re.search(r'\d+', score_text)
|
43 |
return int(score.group()) if score else -1
|
44 |
except Exception as e:
|