Listen to this Post

Introduction:
The convergence of generative AI (GenAI) and cloud computing is reshaping enterprise technology, but with great power comes great complexity. AWS Community Day Singapore 2026 brought together builders and practitioners to tackle the most pressing challenges in this new landscape—from taming runaway GenAI costs to orchestrating multi-agent systems and rethinking security for an AI-driven world. This article distills the key technical sessions from the event, providing actionable insights, verified commands, and configuration guides for AWS professionals looking to implement agentic AI responsibly and cost-effectively.
Learning Objectives & Secrets:
- Objective 1: Master GenAI Cost Optimization – Learn how to shift from “cost per token” to “cost per success” by implementing model tiering, prompt optimization, and semantic caching strategies that can reduce inference costs by up to 50%.
-
Objective 2 Secret Tip: Leverage AgentCore Runtime for Persistent Multi-Agent Collaboration – Deploy multiple agents on a single Amazon Bedrock AgentCore Runtime instance with a shared session directory, enabling agents to collaborate through a common file system rather than making API calls for every handoff.
-
Objective 3 Secret Tip: Use Property-Based Testing to Catch Edge Cases – Implement property-based tests with Kiro to validate business logic across all possible inputs, catching bugs that conventional unit tests miss.
You Should Know:
- Taming GenAI Bills with “Cost per Success” Thinking
The session “Cost per Success, Not Cost per Token” highlighted a critical paradigm shift in AI cost management. In AWS Bedrock, you pay per token—but not all tokens are created equal. The key is optimizing for successful outcomes rather than minimizing token count alone.
Step-by-Step Cost Optimization Guide:
- Implement Model Tiering: Reserve expensive models (e.g., Amazon Nova Pro at $0.80 per 1M input tokens) for complex reasoning tasks, and use smaller models (Nova Lite at $0.06 per 1M input tokens, Nova Micro at $0.035 per 1M) for simple classification or extraction.
-
Optimize System Prompts: A 3,000-token system prompt costs twice as much as a 1,500-token one before any other optimization. Audit and prune every system prompt.
-
Implement Semantic Caching: Cache responses for frequently asked questions using deterministic or semantic caching patterns to reduce unnecessary model calls.
-
Monitor Token Metrics: Use Amazon CloudWatch to track input/output token consumption in real-time and set budget alerts to prevent overspend.
Linux/macOS Command to Monitor Bedrock Costs via AWS CLI:
Get Bedrock invocation metrics for the last hour aws cloudwatch get-metric-statistics \ --1amespace AWS/Bedrock \ --metric-1ame InvocationCount \ --dimensions Name=ModelId,Value=amazon.nova-pro-v1:0 \ --start-time $(date -u -d '1 hour ago' +%Y-%m-%dT%H:%M:%SZ) \ --end-time $(date -u +%Y-%m-%dT%H:%M:%SZ) \ --period 3600 \ --statistics Sum
Windows PowerShell Equivalent:
Get Bedrock invocation metrics (PowerShell)
$startTime = (Get-Date).AddHours(-1).ToString("yyyy-MM-ddTHH:mm:ssZ")
$endTime = (Get-Date).ToString("yyyy-MM-ddTHH:mm:ssZ")
aws cloudwatch get-metric-statistics `
--1amespace AWS/Bedrock `
--metric-1ame InvocationCount `
--dimensions Name=ModelId,Value=amazon.nova-pro-v1:0 `
--start-time $startTime `
--end-time $endTime `
--period 3600 `
--statistics Sum
- Building Enterprise-Grade Multi-Agent Systems with Amazon Bedrock AgentCore
AgentCore is AWS’s platform for building, deploying, and operating AI agents at scale, supporting any framework or foundation model. The session on multi-agent architectures revealed why specialized agents—rather than one general-purpose agent—are becoming the standard for enterprise AI.
Step-by-Step Multi-Agent Deployment Guide:
- Define Agent Roles: Create purpose-built agents for specific functions. A cloud migration framework, for example, might include: Intake Agent (automated discovery), IaC Agent (generates infrastructure code), Migration Intelligence Agent (portfolio reporting), and SRE Agent (proactive operations).
-
Choose Your Compute Option: AgentCore offers two runtime options:
– Serverless microVMs: For real-time interactions and workloads up to 8 hours.
– Runtime Instances (EC2-backed): For persistent sessions up to 14 days, with shared file systems and GPU acceleration.
- Enable Multi-Agent Collaboration: Deploy multiple agents into a single runtime instance with a shared session directory. Agents can collaborate on the same host through a common file system rather than calling each other’s APIs for every handoff.
-
Integrate with Strands Agents SDK: Build agents using the open-source Strands SDK and deploy them with a simple `@app.entrypoint` decorator using either zip files or container images.
Example Agent Definition (Python with Strands SDK):
from strands import Agent, tool class IaCAgent(Agent): def <strong>init</strong>(self): super().<strong>init</strong>(name="IaC-Generator") @tool def generate_terraform(self, requirements: dict) -> str: """Generate Terraform code from application requirements""" Implementation here return terraform_code @tool def validate_security(self, template: str) -> bool: """Validate infrastructure template against security best practices""" Implementation here return True
- Security Evolution: Jeff Moss on 30 Years of Hacking
Jeff Moss, founder of DEF CON and Black Hat, delivered a keynote on how hacking and security have co-evolved over three decades. His key insight: “If you don’t understand how attacks work, it’s difficult to build an effective defense”. In the AI era, this principle takes on new urgency as attack surfaces expand to include model poisoning, prompt injection, and data exfiltration through LLM outputs.
Security Hardening Checklist for AI Workloads:
- Implement Session Isolation: Use AgentCore’s true session isolation to prevent cross-tenant data leakage.
- Enforce Identity-Based Access: Leverage AgentCore’s built-in identity and policy capabilities for fine-grained access control.
- Enable Observability: Monitor agent behavior, tool usage, and data access patterns.
- Apply Human-in-the-Loop Controls: Ensure agents support decision-making rather than independently executing production changes.
AWS CLI Command to Configure IAM Roles for AgentCore:
Create an IAM role for AgentCore with least-privilege permissions
aws iam create-role \
--role-1ame AgentCoreExecutionRole \
--assume-role-policy-document '{
"Version": "2012-10-17",
"Statement": [{
"Effect": "Allow",
"Principal": {"Service": "bedrock.amazonaws.com"},
"Action": "sts:AssumeRole"
}]
}'
Attach minimal permissions policy
aws iam attach-role-policy \
--role-1ame AgentCoreExecutionRole \
--policy-arn arn:aws:iam::aws:policy/AmazonBedrockFullAccess
4. Kiro: Property-Based Testing for AI-Generated Code
The Kiro workshop demonstrated how property-based testing can catch edge cases that pass unit tests but break in production. Unlike example-based testing, property-based tests assert rules that must hold across all inputs.
Step-by-Step Kiro Testing Workflow:
1. Install Kiro CLI:
curl -fsSL https://cli.kiro.dev/install | bash
- Define Properties: Instead of writing specific test cases, define invariants that should always be true. For example, “sorting a list should always return a list of the same length” or “a withdrawal should never exceed the account balance.”
-
Generate Tests: Kiro automatically generates test scenarios from your specifications, exploring edge cases and boundary conditions.
4. Run Property-Based Tests:
kiro test --property --spec ./specs/withdrawal.feature
- Integrate with CI/CD: Use Kiro’s headless CLI to review PRs and fix bugs without opening an editor.
Example Property Definition (Hypothesis library in Python):
from hypothesis import given, strategies as st @given(st.lists(st.integers())) def test_sort_returns_same_length(numbers): sorted_list = sorted(numbers) assert len(sorted_list) == len(numbers) @given(st.integers(min_value=0), st.integers(min_value=0)) def test_withdrawal_never_exceeds_balance(balance, amount): if amount <= balance: new_balance = balance - amount assert new_balance >= 0 else: with pytest.raises(InsufficientFundsError): withdraw(balance, amount)
5. Cloud Migration Acceleration with Agentic AI
One of the most impactful sessions demonstrated how multi-agent AI frameworks can compress cloud migration timelines from years to months. A framework developed by AWS Professional Services reduced infrastructure-as-code (IaC) development time from 3–4 weeks per application to minutes across a portfolio of over 300 applications.
Multi-Agent Migration Architecture:
| Agent | Responsibility | Key Tools |
|-|-|–|
| Intake Agent | Automated application discovery and dependency mapping | AWS Application Discovery Service |
| IaC Agent | Generate Terraform/CloudFormation code | AWS CDK, Terraform |
| Migration Intelligence Agent | Portfolio reporting and governance | Jira, Confluence APIs |
| SRE Agent | Proactive monitoring and remediation | Amazon CloudWatch, AWS Systems Manager |
Terraform Example Generated by IaC Agent:
Example Terraform for a migrated application
resource "aws_instance" "app_server" {
ami = "ami-0c55b159cbfafe1f0"
instance_type = "t3.medium"
vpc_security_group_ids = [aws_security_group.app_sg.id]
tags = {
Name = "migrated-app-server"
Environment = "production"
MigratedBy = "IaC-Agent"
}
}
resource "aws_security_group" "app_sg" {
name_prefix = "app-sg-"
ingress {
from_port = 443
to_port = 443
protocol = "tcp"
cidr_blocks = ["10.0.0.0/8"]
}
}
What Undercode Say:
- Key Takeaway 1: GenAI cost optimization isn’t just about reducing token usage—it’s about redefining success metrics. “Cost per success” forces organizations to think holistically about model selection, prompt engineering, and caching strategies as an integrated system, not isolated tactics.
-
Key Takeaway 2: Multi-agent architectures represent a fundamental shift in how we build AI systems. Rather than trying to create a single “super agent,” the future lies in specialized agents that collaborate through shared contexts—just like human teams. AgentCore’s Runtime Instances, with persistent sessions and shared file systems, enable this paradigm at enterprise scale.
Prediction:
-
+1 Agentic AI will become the default paradigm for enterprise cloud operations by 2028, with multi-agent frameworks like AgentCore reducing migration timelines by 70–80% and becoming as standard as CI/CD pipelines are today.
-
+1 Property-based testing will emerge as the industry standard for validating AI-generated code, as conventional unit testing proves insufficient for the combinatorial complexity of LLM outputs.
-
-1 The democratization of agentic AI will create new security vulnerabilities at an unprecedented scale, requiring organizations to invest heavily in AI-specific security controls—session isolation, identity management, and observability—or risk catastrophic data breaches.
-
-1 Without disciplined cost optimization strategies, GenAI workloads will consume an unsustainable portion of cloud budgets, forcing a consolidation phase where only organizations with mature FinOps practices survive.
▶️ Related Video (80% Match):
https://www.youtube.com/watch?v=-8DMrsrkTG8
🎯Let’s Practice For Free:
🎓 Live Courses & Certifications:
Join Undercode Academy for Verified Certifications
🚀 Request a Custom Project:
Secure, high-velocity infrastructure and disruptive technological engineering. Contact our engineering team for high-tier development and proprietary systems:
[email protected]
💎 Smart Architecture | 🛡️ Secure by Design | ⭐ Trusted by Thousands
IT/Security Reporter URL:
Reported By: https://lnkd.in/p/eYqGEhCq – Hackers Feeds
Extra Hub: Undercode MoN
Basic Verification: Pass ✅


