Week 5 - Model Context Protocol in Practice and AI‑Powered Solution Validation
Batch 09 – BeSA Cloud Academy
Disclaimer:
These notes were drafted using AI for clarity, structure, and readability. They are intended solely for learning purposes.
These are the structured notes from Week 4, focused only on the two role plays. Writing this as a quick revision for those who attended the session and a concise recap for anyone who couldn’t make it.
Role Play 1 – Understanding Model Context Protocol (MCP)
Context
This conversation focused on understanding MCP (Model Context Protocol) and why it is becoming a foundational concept in agentic AI architectures.
Why MCP Matters
When building AI agents that need to perform real actions, a key challenge is connecting the agent to external systems.
Examples include:
- Querying databases
- Creating tickets
- Accessing APIs
- Checking inventory
The core question becomes:
How does the agent connect to all these tools in a scalable and standardized way?
MCP addresses this problem.
What is MCP
MCP (Model Context Protocol) is an open protocol that standardizes how AI applications:
- Provide context to LLMs
- Enable access to tools and external systems
Key idea:
Instead of building custom integrations for every combination of client and tool, MCP provides a standard interface.
Analogy used:
- Like a universal connector (similar to USB-C).
- Without MCP → every integration is custom.
- With MCP → one standard interface works everywhere.
From Custom Integrations to Standardization
Before MCP:
- Each AI client needed custom integration with each tool.
- This results in an N × M problem.
With MCP:
- Tools are built once as MCP servers.
- Any client can use them.
- This reduces complexity to an N + M model.
Key benefits:
- Reduced engineering effort
- Better scalability
- Improved maintainability
- Strong alignment with architectural best practices
Alignment with Architecture Principles
MCP aligns well with key architecture principles such as:
- Designed for change
- Modular scalability
- Standardization
- Operational efficiency
It also integrates easily with:
- External data sources
- APIs
- Enterprise systems
Core MCP Components
The architecture was explained using a simple analogy.
Host
- Acts as the control plane (e.g., Amazon Bedrock).
- Responsible for orchestrating communication.
MCP Clients
- Interact with the host.
- Represent the interface layer.
MCP Servers
- Provide specialized capabilities.
- Each server is responsible for a specific function (e.g., database access, ticketing).
The host mediates all communication between the model and MCP servers.
Core Concepts for Agents
Three key concepts were highlighted:
Tools
- Functions the agent can invoke.
- Example: lookup employee, create ticket.
- Tool descriptions are critical because they guide the agent’s decision-making.
Resources
- Data or documents the agent can read.
- Example: policy documents, knowledge bases.
Prompts
- Predefined templates for structured interaction.
- Help users initiate consistent workflows.
Summary:
- Tools → actions
- Resources → context
- Prompts → structured interaction
Request Flow
The typical flow works as follows:
User input → Host → LLM (with tool descriptions)
→ LLM selects tool → Host routes request to MCP Server
→ Server returns data → LLM generates response
Important point:
- The LLM does not directly communicate with MCP servers.
- The host acts as a control layer for security and governance.
Communication Methods
Two communication mechanisms were discussed:
stdio
- Used for local processes on the same machine.
HTTP with Server-Sent Events
- Used for remote and enterprise-grade integrations.
Multi-Tool Orchestration
Agents can use multiple tools in sequence.
Example scenario:
- Check weather
- Find calendar availability
- Schedule an event
The LLM handles reasoning and dependency between steps.
Building MCP-Based Systems
Typical steps involved:
- Create MCP server
- Register tools with clear descriptions
- Implement error handling
- Perform testing (unit, integration, natural language)
- Enable logging and debugging for traceability
Production Patterns on AWS
Recommended approach:
Lambda-backed MCP servers
- Serverless
- Scalable
- Cost-efficient
- Event-driven
For long-running workflows:
Use Bedrock Agent Core
- Supports long sessions (up to 8 hours)
- Provides session isolation
- Designed for stateful interactions
Security Considerations
Security is critical when exposing tools to AI systems.
Key practices:
Principle of least privilege
- Assign minimal required permissions using IAM roles
Human-in-the-loop
- Required for destructive or sensitive operations
Input validation
- Prevent prompt injection or malicious inputs
Architectural decisions remain human-driven, especially for:
- Scope definition
- Security boundaries
- Integration design
Role Play 2 – AI-Powered Solution Validation
Context
This conversation focused on validating AI-generated architectures to ensure they are production-ready.
While AI can generate solutions quickly, validation ensures they work in real-world conditions.
Why Validation is Critical
AI-generated architectures may:
- Look correct
- Follow best practices
- But fail under real-world constraints
Architects must validate designs across:
- Technical feasibility
- Business constraints
- Organizational realities
AI provides the technical baseline, but human validation ensures practical fit.
Validation Framework
A structured validation approach was discussed.
Key dimensions:
Context (Business Fit)
- Does the architecture align with business goals?
- Does it match customer constraints?
Security and Compliance
- Are regulatory requirements met (e.g., PCI DSS)?
- Are encryption and segmentation implemented?
Reliability and Performance
- Can the system handle expected load?
- Are there bottlenecks?
Cost Reality
- Is the architecture cost-effective?
- Are there opportunities to optimize?
Feasibility
- Can the team build and operate this system?
- Does it match their skill set?
Value Alignment
- Does the solution provide real value to the business?
Security and Compliance Validation
AI can identify potential issues such as:
- Missing encryption
- Lack of segmentation
Architects must:
- Prioritize based on compliance requirements
-
Distinguish between:
- Mandatory controls
- Best practices
Risk tolerance of the organization plays a key role.
Reliability and Performance Validation
AI can highlight bottlenecks such as:
- Database connection limits
- Service throttling
Architects must:
- Validate these concerns with actual numbers
- Consider real traffic patterns
Example:
- Scaling for peak events (e.g., holiday traffic).
Applying Business Context
AI often suggests optimal technical designs.
However, these may not align with business needs.
Example:
- AI recommends multi-region deployment for high availability
-
Business reality may prefer:
- Single-region
- Multi-AZ setup
- Lower cost
Human judgment is required to right-size solutions.
Cost Optimization
AI tools can provide real-time cost estimates.
They can:
- Break down costs by service
- Suggest alternatives
Example:
- Switching from a premium database option to a standard one
- Saving costs when advanced features are not required
Architects balance:
- Cost
- Performance
- Requirements
Preparing for Stakeholder Questions
AI can be used to simulate critical stakeholders.
Example:
- Prompt AI to act as a skeptical CTO
This helps generate:
- Tough questions
- Risk scenarios
- Objections
Architects can then:
- Prepare structured responses
- Back answers with data
Presenting Options Instead of Answers
Instead of a single solution, multiple options can be presented.
Example:
Option A
- Accept downtime risk
Option B
- Multi-region deployment (higher cost)
Option C
- Add buffering mechanisms (lower cost alternative)
This approach:
- Builds trust
- Enables informed decision-making
Key Takeaways from Validation Discussion
- Validation is a critical skill in AI-assisted architecture.
- AI accelerates design, but validation ensures correctness.
- Real-world constraints must always guide final decisions.
The combination of AI speed and human judgment leads to better outcomes.
Week 5 Consolidated Takeaways
From the first role play:
MCP provides a standardized way for agents to interact with tools and external systems, reducing complexity and enabling scalable, modular architectures.
From the second role play:
AI-generated architectures must be rigorously validated across business, technical, and operational dimensions before being considered production-ready.
This week emphasized two key themes:
- Standardization in agent integration through MCP
- The importance of validation to ensure AI-generated solutions work in real-world scenarios

Top comments (0)