Saturday, April 18, 2026
banner
Top Selling Multipurpose WP Theme

Amazon Bedrock AgentCore is an agent platform for safely constructing, deploying, and working efficient brokers at scale. Amazon Bedrock AgentCore Runtime is a totally managed service from Bedrock AgentCore that gives a low-latency, serverless setting for deploying brokers and instruments. It gives session isolation, helps a number of agent frameworks together with in style open supply frameworks, and handles multimodal workloads and long-running brokers.

definition suppliedThe agent iscontainer

choose don’t be concerned docker experience and container infrastructure On the time of introduction agents.

This publish reveals the best way to use direct code deployment (in Python).

Introducing Direct Code Deployment for AgentCore Runtime

Utilizing the container deployment technique, builders can Dockerfileconstruct ARM-compatible containers, handle ECR repositories, and add containers for code modifications. this works wonderful the place Container DevOps Within the pipeline already was finished Institution Automate your deployment.

Deployment, which one It could possibly considerably enhance developer time and productiveness. D

Clarify the benefits of every deployment choice It is going to show you how to select the suitable strategy to your use case.

To deploy code immediately, builders create a zipper archive of their code and dependencies, add it to Amazon S3, and configure a bucket of their agent configuration. When utilizing AgentCore Starter Toolkitthe toolkit handles dependency discovery, packaging, and importing, enormously simplifying the developer expertise. Direct deployment of code utilizing the API can also be supported.

Let’s roughly evaluate the implementation steps between the 2 strategies.

Container-based deployment

The container-based deployment technique contains the next steps:

  • Create a Dockerfile
  • Constructing an ARM suitable container
  • Creating an ECR repository
  • Add to ECR
  • Deploying to AgentCore runtime

Direct code deployment

The tactic for immediately deploying code entails the next steps:

  • Bundle your code and dependencies into a zipper archive
  • Add to S3
  • Configure buckets with agent configuration
  • Deploying to AgentCore runtime

Easy methods to deploy code immediately

Let’s illustrate how direct code deployment works with an agent created with the next command: Strand Agent SDK Deploy the agent utilizing the AgentCore Starter Toolkit.

Stipulations

Earlier than you start, ensure you have the next:

  • Any model of Python 3.10 to three.13
  • Your most well-liked package deal supervisor is put in. for instance, ultraviolet light package deal supervisor.
  • AWS account to create and deploy the agent
  • Accessing Anthropic Claude Sonnet 4.0 by Amazon Bedrock Fashions

Step 1: Initialize the undertaking

Arrange a brand new Python undertaking utilizing the uv package deal supervisor and navigate to your undertaking listing.

uv init <undertaking> --python 3.13
cd <undertaking>

Step 2: Add undertaking dependencies

Set up the Bedrock AgentCore libraries and growth instruments required to your undertaking. On this instance, dependencies are added utilizing: .toml It’s also possible to specify it in a file, however necessities.txt file:

uv add bedrock-agentcore strands-agents strands-agents-tools
uv add --dev bedrock-agentcore-starter-toolkit
supply .venv/bin/activate

Step 3: Create the Agent.py file

Create the primary agent implementation file that defines the conduct of the AI ​​agent.

from bedrock_agentcore import BedrockAgentCoreApp 
from strands import Agent, device 
from strands_tools import calculator  
from strands.fashions import BedrockModel 
import logging 

app = BedrockAgentCoreApp(debug=True) 

# Logging setup 
logging.basicConfig(degree=logging.INFO) 
logger = logging.getLogger(__name__) 

# Create a customized device  
@device 
def climate(): 
     """ Get climate """  
     return "sunny" 

model_id = "us.anthropic.claude-sonnet-4-20250514-v1:0" 
mannequin = BedrockModel( 
     model_id=model_id, 
) 

agent = Agent( 
     mannequin=mannequin, 
     instruments=[calculator, weather], 
     system_prompt="You are a useful assistant. You are able to do basic math calculation, and inform the climate." 
) 

@app.entrypoint 
def invoke(payload): 
     """Your AI agent operate""" 
     user_input = payload.get("immediate", "Hey! How can I show you how to right now?") 
     logger.information("n Person enter: %s", user_input) 
     response = agent(user_input) 
     logger.information("n Agent consequence: %s ", response.message) 
     return response.message['content'][0]['text'] 

if __name__ == "__main__": 
     app.run() 

Step 4: Deploy to AgentCore runtime

Configure the agent and deploy it to the AgentCore runtime setting.

agentcore configure --entrypoint agent.py --name <agent-name>

This launches an interactive session to configure your S3 bucket, add your zip deployment package deal, and choose your deployment configuration sort (see the next configuration). To decide on to extract the code immediately, choose choice 1 – Code Zip.

Deployment configuration

Choose your deployment sort:

  1. Code Zip (advisable) – Easy, serverless, no Docker required
  2. Containers – for customized runtimes or advanced dependencies

This command creates a zipper deployment package deal, uploads it to the desired S3 bucket, and begins an agent within the AgentCore runtime setting in order that it will probably obtain and course of requests.

To check our resolution, let’s ask the agent to test what the climate is like.

agentcore invoke '{"immediate":"How is the climate right now?"}'

Whereas the preliminary deployment takes roughly 30 seconds to finish, subsequent agent updates ought to profit from a streamlined direct-to-code deployment course of and take lower than half the time, rushing up iteration cycles throughout growth.

When to decide on direct code over container-based deployments

Let’s take a look at some features and see how direct code and container-based deployment choices differ. This can show you how to select the choice that fits you.

  • Implementation course of: Direct Code deploys brokers as zip recordsdata with out the necessity for Docker, ECR, or CodeBuild. Container-based deployments use Docker and ECR, which provide you with full management over your Dockerfile.
  • Deployment time: Though there isn’t any vital distinction within the preliminary deployment of the agent, subsequent updates to the agent are considerably sooner utilizing direct code deployment (from a median of 30 seconds for containers to roughly 10 seconds for direct code deployment).
  • Artifact storage: inth 2026
  • customization: Direct code deployment helps customized dependencies by way of ZIP-based packaging, whereas container-based depends on Dockerfiles.
  • package deal dimension: Deploying code immediately limits package deal dimension to 250 MB, whereas container-based packages might be as much as 2 GB in dimension.
  • Language help: Direct Code at the moment helps Python 3.10, 3.11, 3.12, and three.13. Container-based deployments help many languages ​​and runtimes.

Our basic steering is:

Container-based deployment is the suitable alternative In case your package deal is bigger than 250MB, you both have an present container CI/CD pipeline or require extremely specialised dependencies and customized packaging necessities. Select containers when you want multilingual help, customized system dependencies, or direct management over artifact storage and versioning inside your account.

Deploying your code immediately is the suitable alternative In case your package deal is lower than 250MB, you need to use Python 3.10-3.13 with in style frameworks similar to LangGraph, Strands, and CrewAI for speedy prototyping with quick iteration cycles. In case your construct course of is straightforward with out advanced dependencies and also you wish to take away the Docker/ECR/CodeBuild setup, select Direct Code.

Hybrid strategy works nicely for a lot of groupsuse direct code for speedy prototyping and experimentation, speed up growth with quick iterations and easy setup, after which transfer to production-ready containers when package deal dimension, multi-language necessities, or specialised construct processes require it.

conclusion

Amazon Bedrock AgentCore’s direct code deployment additional accelerates iterative agent growth cycles whereas sustaining enterprise safety and deployment economies of scale. Builders can now shortly prototype and iterate by immediately deploying code with out creating containers. To get began with direct code deployment of Amazon Bedrock AgentCore, go to our AWS documentation.


Concerning the creator

Chaitra Mathur I work as a GenAI Specialist Options Architect at AWS. She works with prospects throughout a wide range of industries to construct and operationalize scalable generative AI platforms. All through her profession, she has shared her experience at quite a few conferences and written a number of blogs within the discipline of machine studying and generative AI.

Author KiyoheiChinwei Lee Machine Studying Specialist at Amazon Internet Providers. He acquired his Ph.D. After abandoning his advisor’s analysis grant account and failing to obtain the promised Nobel Prize, he pursued a PhD in operations analysis. At present, he helps prospects within the monetary companies and insurance coverage trade construct machine studying options on AWS. In my spare time, I like studying and educating.

Kosti Vasilakakis At AWS, he’s a principal PM on the Agentic AI workforce, the place he led the design and growth of a number of Bedrock AgentCore companies from the bottom up, together with runtimes, browsers, code interpreters, and id. He beforehand labored on Amazon SageMaker from its early days, launching AI/ML capabilities that are actually utilized by hundreds of firms all over the world. Mr. Kosti was a knowledge scientist early in his profession. Outdoors of labor, he builds private productiveness automation programs, performs tennis, and enjoys life together with his spouse and kids.

banner
Top Selling Multipurpose WP Theme

Converter

Top Selling Multipurpose WP Theme

Newsletter

Subscribe my Newsletter for new blog posts, tips & new photos. Let's stay updated!

banner
Top Selling Multipurpose WP Theme

Leave a Comment

banner
Top Selling Multipurpose WP Theme

Latest

Best selling

22000,00 $
16000,00 $
6500,00 $
900000,00 $

Top rated

6500,00 $
22000,00 $
900000,00 $

Products

Knowledge Unleashed
Knowledge Unleashed

Welcome to Ivugangingo!

At Ivugangingo, we're passionate about delivering insightful content that empowers and informs our readers across a spectrum of crucial topics. Whether you're delving into the world of insurance, navigating the complexities of cryptocurrency, or seeking wellness tips in health and fitness, we've got you covered.