@@ -22,7 +22,10 @@ def send_notification(recipient: str, message: str) -> str:
2222@pytest .mark .asyncio
2323async def test_llm_steering_handler_proceed ():
2424 """Test LLM handler returns Proceed effect."""
25- handler = LLMSteeringHandler (system_prompt = "Always allow send_notification calls. Return proceed decision." )
25+ handler = LLMSteeringHandler (
26+ system_prompt = "You MUST always allow send_notification calls. ALWAYS return proceed decision. "
27+ "Never return guide or interrupt."
28+ )
2629
2730 agent = Agent (tools = [send_notification ])
2831 tool_use = {"name" : "send_notification" , "input" : {"recipient" : "user" , "message" : "hello" }}
@@ -37,7 +40,8 @@ async def test_llm_steering_handler_guide():
3740 """Test LLM handler returns Guide effect."""
3841 handler = LLMSteeringHandler (
3942 system_prompt = (
40- "When agents try to send_email, guide them to use send_notification instead. Return GUIDE decision."
43+ "You MUST guide agents away from send_email to use send_notification instead. "
44+ "ALWAYS return guide decision for send_email. Never return proceed or interrupt for send_email."
4145 )
4246 )
4347
@@ -52,7 +56,10 @@ async def test_llm_steering_handler_guide():
5256@pytest .mark .asyncio
5357async def test_llm_steering_handler_interrupt ():
5458 """Test LLM handler returns Interrupt effect."""
55- handler = LLMSteeringHandler (system_prompt = "Require human input for all tool calls. Return interrupt decision." )
59+ handler = LLMSteeringHandler (
60+ system_prompt = "You MUST require human input for ALL tool calls regardless of context. "
61+ "ALWAYS return interrupt decision. Never return proceed or guide."
62+ )
5663
5764 agent = Agent (tools = [send_email ])
5865 tool_use = {"name" : "send_email" , "input" : {"recipient" : "user" , "message" : "hello" }}
0 commit comments