### Summary
Adds `is_enabled` parameter to `Agent.as_tool()` method for
conditionally enabling/disabling agent tools at runtime. Supports
boolean values and callable functions for dynamic tool filtering
in multi-agent orchestration.
### Test plan
- Added unit tests in `tests/test_agent_as_tool.py`
- Added example in
`examples/agent_patterns/agents_as_tools_conditional.py`
- Updated documentation in `docs/tools.md`
- All tests pass
### Issue number
Closes#1097
### Checks
- [x] I've added new tests (if relevant)
- [x] I've added/updated the relevant documentation
- [x] I've run `make lint` and `make format`
- [x] I've made sure tests pass
---------
Co-authored-by: thein <thein@MacBook-Pro.local>
Updated the evaluator agent’s instructions in llm_as_a_judge.py to
prevent infinite evaluation loops. The agent is now instructed to
provide a final evaluation after 5 attempts, allowing approval if the
story outline is good enough, even if it is not perfect.
Remove the `not` keyword from the `tripwire_triggered` parameter in the `math_guardrail` function in `examples/agent_patterns/input_guardrails.py`.
The not keyword prevented the guardrail from being triggered, which defeats the purpose of the example.