mirror of
https://github.com/tcsenpai/agenticSeek.git
synced 2025-06-06 11:05:26 +00:00
set code safety on by default
This commit is contained in:
parent
68ed1834a9
commit
c6688355a7
@ -123,6 +123,8 @@ class Agent():
|
|||||||
"""
|
"""
|
||||||
start_tag = "<think>"
|
start_tag = "<think>"
|
||||||
end_tag = "</think>"
|
end_tag = "</think>"
|
||||||
|
if text is None:
|
||||||
|
return None
|
||||||
start_idx = text.find(start_tag)
|
start_idx = text.find(start_tag)
|
||||||
end_idx = text.rfind(end_tag)+8
|
end_idx = text.rfind(end_tag)+8
|
||||||
return text[start_idx:end_idx]
|
return text[start_idx:end_idx]
|
||||||
@ -240,7 +242,7 @@ class Agent():
|
|||||||
if blocks != None:
|
if blocks != None:
|
||||||
for block in blocks:
|
for block in blocks:
|
||||||
self.show_block(block)
|
self.show_block(block)
|
||||||
output = tool.execute([block])
|
output = tool.execute([block], safety=True)
|
||||||
feedback = tool.interpreter_feedback(output) # tool interpreter feedback
|
feedback = tool.interpreter_feedback(output) # tool interpreter feedback
|
||||||
success = not tool.execution_failure_check(output)
|
success = not tool.execution_failure_check(output)
|
||||||
self.blocks_result.append(executorResult(block, feedback, success, name))
|
self.blocks_result.append(executorResult(block, feedback, success, name))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user