|
Hello Reader, Agents are everywhere. But there’s a big difference between using an agent and building one end-to-end. Let's face it - if you tell a recruiter that you played with Claude or ChatGPT, or even created a workflow using n8n, that won't impress them. Because when a company hires you, it expects you to know how to build agent using the infrastructure components. With that in mind, let's turn our attention to how to build an agent. Good AgentLet's take a look at building a good agent. A decent agent should have some code integrating with LLM on Cloud, and various tools. You can use MCP for some tools. A lot of candidates will do this. This is good, but NOT delightful. To delight, you need add couple more things:
Tool call - LLM decides when to call what tool, in which order Hook - YOU decide when to call a tool or process. You probably know about tool calls, but hook is used all the time in production agents. Where can we use hooks in this case? Saving and extracting info from memory is done via hooks. After you ask agent a question, and agent responds, using hook you can save it into the memory. And later, when you initiate or resume a chat session, you can run a hook, to get information from the memory. Hooks ensure guaranteed execution, and not dependent on LLM. And the final delight factor is running the Agent on the cloud. Now that we understand what separates a good vs delightful agent, let's look into agent building lifecycle. Agent Build LifecycleYou'd see example agent code everywhere. But in reality, no one builds the full agent code as a regular code from get go. We use Jupyter Notebook, which can run the python agent code block by block :
For our agent, we are building a movie recommendation agent. The components are as follows:
Finally when agent is ready, agent code will be converted into a full python code using Open Source framework Strands. This part is easy because in our notebook, we are already using Strands, so it's just a matter of stitching all those blocks together to a single program. And finally, we will move the Strands code to Amazon Agentcore Runtime, and the whole thing will be on Cloud! Command "agentcore configure"
Command "agentcore launch"
Below are the characteristics of the AgentCore:
Now that we understand the agent components, and their implementation, let's run our agent GitHub Repo and Code SnippetsMain GitHub Repo: https://github.com/saha-rajdeep/Strands-agents-demo/tree/main (If this is useful, please star it) Movie Agent Jupyter Notebook, and Strands Code: https://github.com/saha-rajdeep/Strands-agents-demo/tree/main/movie-agent-with-memory Notable Code Snippets:
If you want to see this in action, watch out my video: Once you do this, and when talking to a recruiter, don’t impress with vagueness. Impress with specifics. Instead of saying: “Yeah I built an agent with memory.” Say: “I implemented short-term and long-term memory using Bedrock AgentCore. I used hooks to persist preferences and RAG to retrieve semantic context across sessions.” 🙏 Quick favor - just hit reply and say “hey” so your inbox knows we’re friends. It helps future emails land in your main inbox instead of spam. If you have found this newsletter helpful, and want to support me : Checkout my bestselling courses on AWS, System Design, Kubernetes, DevOps, and more: Max discounted links AWS SA Bootcamp with Live Classes, Mock Interviews, Hands-On, Resume Improvement and more: https://www.sabootcamp.com/ Keep learning and keep rocking 🚀, Raj |
Free Cloud Interview Guide to crush your next interview. Plus, real-world answers for cloud interviews, and system design from a top AWS Solutions Architect.
Hello Reader, Not all System Designs are created equal! To make matters complicated, there are so many designs out there. As a former Principal Solutions Architect at AWS and Distinguished Cloud Architect at Verizon, I have taken over 300+ interviews, and I have seen three patterns coming over and over in interviews. In this newsletter edition, we will go through 3 System Design patterns that appear the MOST in cloud interviews and actual projects. If you nail these 3, you will be ahead of...
Hello Reader, Claude. ChatGPT. Gemini. Copilot. If you're not using at least one of these daily, you're the outlier. So here's the uncomfortable truth: walking into an interview and saying "I use Claude Code every day" is no longer impressive. It's table stakes. That's the average answer. And average doesn't get you hired. In today's edition, I'll show you what separates a forgettable Gen AI answer from one that makes the interviewer lean forward. The Average Answer (And Why It Fails) Here's...
Hello Reader, Recruiters reaching out to you for interviews. That's the dream, right? And one of the best ways to make that happen is a badge most cloud professionals have never heard of - the AWS Community Builder. I've had multiple students get accepted into this program recently. Recruiters started finding them on LinkedIn. Interview calls went up. And the best part? You don't need to be a Principal Architect or a 10x AWS certified rockstar to qualify. In today's newsletter, I'll show you...