feat(01-learn): add 18-input-output-guardrails tutorial - #267
Conversation
|
@manoj-selvakumar5 Ready for review. This is the Input/Output Guardrails tutorial. |
|
Pushed a fix commit (476e346) — inlined content filter classes directly into notebooks and added logger definitions so each notebook runs independently without cross-file dependencies. All 6 notebooks tested clean on SageMaker Studio. |
|
Hi @SyedAn-Git - There's some overlap with 01-learn/16-hooks-lifecycle and 03-integrate/guardrails/ so I'd suggest moving this to 05-technical-use-cases/guardrails/ treating hooks as a prerequisite instead of re-teaching them. |
…hooks as prerequisite Addresses review feedback on PR strands-agents#267: - Move 01-learn/18-input-output-guardrails -> 05-technical-use-cases/guardrails/custom-python-guardrails - Reframe README and notebook markdown to treat 16-hooks-lifecycle as a prerequisite instead of re-teaching hook mechanics - Fix broken link to guardrail integrations (now 03-integrate/guardrails) - Remove stale references to the old inlined content_filters.py module Notebook code cells are unchanged.
… samples Distinguish the three guardrail approaches in the README: this hooks-based sample, the managed Amazon Bedrock Guardrails sample (01-learn/05-guardrails), and the third-party integrations (03-integrate/guardrails).
|
Thanks for the review, @manoj-selvakumar5! I've addressed the overlap feedback: Moved the tutorial from 01-learn/18-input-output-guardrails/ → 05-technical-use-cases/guardrails/custom-python-guardrails/ (via git mv, so history is preserved). Reframed hooks as a prerequisite instead of re-teaching them:
Clarified how this relates to the other guardrail samples, the README now distinguishes the three approaches: this pure-Python/hooks sample, the managed 01-learn/05-guardrails (Amazon Bedrock Guardrails), and the third-party 03-integrate/guardrails integrations. Re-tested: all 6 notebooks execute end-to-end with zero cell errors on strands-agents 1.53.0. The guardrail-specific code cells are unchanged from the original. |
Adds Input/Output Guardrails tutorial to python/01-learn/
Covers:
Tested on SageMaker Studio with strands-agents 1.40.0