优化 Agent 核心提示词结构

This commit is contained in:
jxxghp
2026-05-28 11:22:56 +08:00
parent f8f06a602a
commit bf4f5f8744
2 changed files with 48 additions and 31 deletions
+10
View File
@@ -51,6 +51,16 @@ class TestAgentPromptStyle(unittest.TestCase):
"If the user has not explicitly requested an operation that changes system behavior",
prompt,
)
self.assertIn("<non_negotiable_boundaries>", prompt)
self.assertIn("<confirmation_policy>", prompt)
self.assertIn(
"Treat read-only inspection as allowed",
prompt,
)
self.assertIn(
"Use `execute_command` only for diagnostics, read-only inspection, or commands the user explicitly asked to run",
prompt,
)
self.assertIn("当前日期", prompt)
self.assertNotIn("当前时间", prompt)