Module 03 Amazon Bedrock Agents - akash-coded/aws-bedrock-agentcore-strands GitHub Wiki
Console to code: action groups, orchestration, and controlling behaviour.
Module 03 of 16 ยท track Invoke ยท Estimated time: 6โ7 hours ยท Prerequisites: Module 02.
Bedrock Agents give you a managed agent loop. You will build one in the console, then rebuild it in code so you understand what the console was doing for you โ and then hand-build the loop yourself so nothing is magic.
Open the module on GitHub โ: the slides, notebooks, exercises and solutions are there. This page is the reading order, with the tutorial and the workbench alongside.
The lesson that frames this module is P1 Design & Spec: Write a Spec an AI Agent Can Build From (8 min): what a spec an agent can build looks like, before the console. Then try the autonomy decision record in the workbench: the same decision, with your numbers.
- Create a Bedrock Agent in the console and invoke it from Python
- Define action groups backed by Lambda and a correct OpenAPI schema
- Trace an agent's reasoning and debug a failed orchestration
- Control verbosity, latency and cost through instructions and configuration
- Hand-build the agent loop so the managed one holds no mystery
| Portable GenAI concepts | AWS-specific surface |
|---|---|
| Agent loop | Bedrock Agents |
| Tool routing | Action groups |
| ReAct-style orchestration | AWS Lambda |
| Prompt-driven behaviour control | OpenAPI schemas |
| Agent tracing | |
| CloudWatch |
Portable concepts transfer to any stack. The AWS column is where this module touches the cloud โ see docs/concepts/portability-matrix.md.
| # | Step | What it is | |
|---|---|---|---|
| 1 | ๐ | slides/Day8_Deck1_Console_to_Code.pptx |
Console to code |
| 2 | ๐ป | notebooks/00_connect_to_agent.ipynb |
Connect to your agent |
| 3 | ๐ป | notebooks/01_setup_invoke_trace.ipynb |
Setup, invoke, and read the trace |
| 4 | ๐ป | notebooks/02_handbuilt_loop.ipynb |
Hand-build the loop โ the demystifier |
| 5 | ๐ป | notebooks/03_action_groups.ipynb |
Action groups with Lambda |
| 6 | โ๏ธ | exercises/Day8_Guided_Practice_Agent_Loops_and_Action_Groups.md |
Guided practice |
| 7 | ๐ | slides/Day8_Deck2_Controlling_Behavior.pptx |
Controlling behaviour |
| 8 | ๐ป | notebooks/04_controlling_behavior.ipynb |
Behaviour control in practice |
| 9 | โ๏ธ | exercises/verbosity_tax_exercise.md |
The verbosity tax โ cost of chatty agents |
| 10 | ๐ป | notebooks/05_production_and_insights.ipynb |
Production patterns and insights |
| 11 | โ๏ธ | exercises/disruption_desk_exercise.md |
Disruption desk โ the full scenario |
๐ read ๐ป run โ๏ธ practise ๐ workbook ๐ reference
Worked solutions live in solutions/. Attempt every exercise closed-book first โ the solutions are written to be read after you have a wrong answer to compare against.
- An OpenAPI schema the model cannot read. Vague descriptions produce wrong tool calls.
- Forgetting Lambda resource-based permissions for the agent to invoke it.
- Treating verbosity as free. Every extra sentence is tokens on every turn.
Every error anyone has hit in this course is in the Error Index, by the exact string. Model access and region problems are in Model and Region Notes. If it is a question rather than an error, check the answered ones first, then ask in Q&A.
Frameworks
- Autonomy Ladder โ What the managed loop is doing for you
- Token Tax Ledger โ The verbosity tax, quantified
- Failure Signature Catalog โ 16 signatures โ cause โ fix
Quick reference
- Bedrock Converse API โ The loop underneath the managed agent
- IAM for agents โ Agent โ Lambda resource policies
Recipes and procedures
- Runbook ยท runaway loop โ When the loop does not converge
โ Module 02 ยท Amazon Bedrock Essentials ยท All modules ยท Module 04 ยท Agent Builder, Knowledge Bases and Guardrails โ
โ๏ธ This page is generated from modules/03-bedrock-agents/README.md. To change it, edit the module README: an edit made here is replaced at the next sync.