Today, we are excited to announce that DeepSeek R1 distilled Llama and Qwen models are available through Amazon Bedrock Marketplace and Amazon SageMaker JumpStart. With this launch, you can now release DeepSeek
AI's first-generation frontier design, DeepSeek-R1, along with the distilled versions varying from 1.5 to 70 billion parameters to develop, experiment, and responsibly scale your generative
AI ideas on AWS.

In this post, we demonstrate how to get going with DeepSeek-R1 on Amazon Bedrock Marketplace and SageMaker JumpStart. You can follow similar actions to release the distilled variations of the models too.

Overview of DeepSeek-R1
DeepSeek-R1 is a large language model (LLM) developed by DeepSeek
AI that utilizes reinforcement discovering to boost reasoning abilities through a multi-stage training procedure from a DeepSeek-V3-Base structure. A key identifying function is its reinforcement learning (RL) step, which was used to refine the model's responses beyond the standard pre-training and fine-tuning procedure. By including RL, DeepSeek-R1 can adjust more efficiently to user feedback and goals, ultimately boosting both relevance and clarity. In addition, DeepSeek-R1 utilizes a chain-of-thought (CoT) approach, suggesting it's geared up to break down complicated inquiries and reason through them in a detailed way. This assisted reasoning procedure allows the model to produce more accurate, transparent, and detailed responses. This model combines RL-based
fine-tuning with CoT capabilities, aiming to generate structured reactions while concentrating on interpretability and user interaction. With its wide-ranging abilities DeepSeek-R1 has caught the market's attention as a flexible text-generation model that can be incorporated into numerous workflows such as representatives, logical thinking and data analysis jobs.

DeepSeek-R1 uses a Mixture of Experts (MoE) architecture and is 671 billion criteria in size. The MoE architecture permits activation of 37 billion parameters, allowing efficient inference by routing questions to the most relevant expert "clusters." This technique enables the model to focus on different problem domains while maintaining total performance. DeepSeek-R1 needs at least 800 GB of HBM memory in FP8 format for reasoning. In this post, we will
utilize an ml.p5e.48 xlarge instance to release the model. ml.p5e.48 xlarge includes 8 Nvidia H200 GPUs supplying 1128 GB of
GPU memory.

DeepSeek-R1 distilled models bring the reasoning capabilities of the main R1 model to more efficient architectures based on popular open models like Qwen (1.5 B, 7B, 14B, and 32B) and Llama (8B and 70B). Distillation refers to a process of training smaller, more efficient designs to imitate the behavior and thinking patterns of the larger DeepSeek-R1 design, utilizing it as a teacher model.
You can deploy DeepSeek-R1 design either through SageMaker JumpStart or Bedrock Marketplace. Because DeepSeek-R1 is an emerging design, we recommend releasing this model with guardrails in location. In this blog site, we will use Amazon Bedrock Guardrails to introduce safeguards, prevent hazardous material, and examine models against essential security
requirements. At the time of writing this blog, for DeepSeek-R1 deployments on SageMaker JumpStart and Bedrock Marketplace, Bedrock Guardrails supports just the ApplyGuardrail API. You can produce several guardrails tailored to different usage cases and use them to the DeepSeek-R1 design, enhancing user experiences and standardizing security controls throughout your generative
AI applications.
Prerequisites
To release the DeepSeek-R1 model, you require access to an ml.p5e circumstances. To examine if you have quotas for P5e, open the Service Quotas console and under AWS Services, select Amazon SageMaker, and verify you're using ml.p5e.48 xlarge for endpoint use. Make certain that you have at least one ml.P5e.48 xlarge instance in the AWS Region you are deploying. To ask for a limit increase, develop a limitation boost demand and connect to your account team.
Because you will be deploying this design with Amazon Bedrock Guardrails, make certain you have the correct
AWS Identity and Gain Access To Management (IAM) permissions to utilize Amazon Bedrock Guardrails. For directions, see Establish authorizations to use guardrails for content filtering.
Implementing guardrails with the ApplyGuardrail API
Amazon Bedrock Guardrails allows you to introduce safeguards, avoid hazardous content, and assess models against essential safety requirements. You can
execute safety procedures for the DeepSeek-R1 model utilizing the Amazon Bedrock ApplyGuardrail API. This permits you to apply guardrails to assess user inputs and design actions released on Amazon Bedrock Marketplace and SageMaker JumpStart. You can create a guardrail utilizing the Amazon Bedrock console or the API. For the example code to develop the guardrail, see the GitHub repo.
The general circulation includes the following actions: First, the system receives an input for the design. This input is then processed through the ApplyGuardrail API. If the input passes the guardrail check, it's sent to the model for inference. After getting the model's output, another guardrail check is applied. If the output passes this last check, it's returned as the result. However, if either the input or output is stepped in by the guardrail, a message is returned suggesting the nature of the intervention and whether it happened at the input or output phase. The examples showcased in the following sections demonstrate
reasoning using this API.
Deploy DeepSeek-R1 in Amazon Bedrock Marketplace
Amazon Bedrock Marketplace offers you access to over 100 popular, emerging, and specialized structure designs (FMs) through Amazon Bedrock. To gain access to DeepSeek-R1 in Amazon Bedrock, complete the following steps:
1. On the Amazon Bedrock console, pick Model catalog under
Foundation models in the navigation pane.
At the time of writing this post, you can utilize the InvokeModel API to conjure up the model. It does not support Converse APIs and other Amazon Bedrock tooling.
2. Filter for DeepSeek as a supplier and select the DeepSeek-R1 design.
The model detail page supplies essential details about the model's capabilities, rates structure, and application standards. You can find detailed use guidelines, consisting of sample API calls and code snippets for integration. The design supports different text generation tasks, consisting of material creation, code generation, and concern answering, using its reinforcement discovering
optimization and CoT thinking abilities.
The page likewise includes release choices and licensing details to help you start with DeepSeek-R1 in your applications.
3. To begin utilizing DeepSeek-R1, select Deploy.
You will be prompted to set up the
implementation details for DeepSeek-R1. The design ID will be pre-populated.
4. For Endpoint name, go into an endpoint name (in between 1-50 alphanumeric characters).
5. For Number of circumstances, get in a number of circumstances (in between 1-100).
6. For example type, pick your circumstances type. For optimal efficiency with DeepSeek-R1, a GPU-based circumstances type like ml.p5e.48 xlarge is suggested.
Optionally, you can configure sophisticated security and infrastructure settings, consisting of virtual personal cloud (VPC) networking,
service role authorizations, and encryption settings. For a lot of use cases, the default settings will work well. However, for production implementations, you might wish to examine these settings to line up with your company's security and compliance requirements.
7. Choose Deploy to start utilizing the model.
When the deployment is complete, you can check DeepSeek-R1's capabilities straight in the Amazon Bedrock playground.
8. Choose Open in play area to access an interactive user interface where you can explore various triggers and adjust model parameters like temperature level and maximum length.
When utilizing R1 with Bedrock's InvokeModel and Playground Console, utilize DeepSeek's chat design template for ideal outcomes. For example, <_begin_of_sentence_><_User_>content for reasoning<_Assistant_>.
This is an outstanding way to check out the design's reasoning and text generation abilities before integrating it into your applications. The playground offers immediate feedback, helping you understand how the design reacts to numerous inputs and letting you fine-tune your triggers for optimal results.
You can rapidly evaluate the model in the playground through the UI. However, to conjure up the deployed design programmatically with any Amazon Bedrock APIs, you need to get the endpoint ARN.
Run reasoning utilizing guardrails with the
released DeepSeek-R1 endpoint
The following code example shows how to perform reasoning using a released DeepSeek-R1 model through Amazon Bedrock utilizing the invoke_model and ApplyGuardrail API. You can produce a guardrail utilizing the Amazon Bedrock console or the API. For the example code to produce the guardrail, see the GitHub repo. After you have actually produced the guardrail, utilize the following code to implement guardrails. The script initializes the bedrock_runtime customer, sets up reasoning criteria, and sends out a request to produce text based on a user timely.

Deploy DeepSeek-R1 with SageMaker JumpStart
SageMaker JumpStart is an artificial intelligence (ML) center with FMs, built-in algorithms, and prebuilt ML solutions that you can release with just a couple of clicks. With SageMaker JumpStart, you can
tailor pre-trained designs to your use case, with your information, and release them into production utilizing either the UI or SDK.
Deploying DeepSeek-R1 model through SageMaker JumpStart provides two convenient techniques: using the user-friendly SageMaker JumpStart UI or implementing programmatically through the SageMaker Python SDK. Let's explore both approaches to help you choose the approach that finest suits your requirements.
Deploy DeepSeek-R1 through SageMaker JumpStart UI
Complete the following actions to release DeepSeek-R1 using SageMaker JumpStart:
1. On the SageMaker console, choose Studio in the navigation pane.
2. First-time users will be prompted to produce a domain.
3. On the SageMaker Studio console, select JumpStart in the navigation pane.
The model web browser displays available designs, with details like the supplier name and model capabilities.
4. Look for DeepSeek-R1 to view the DeepSeek-R1 model card.
Each design card shows key details, including:
- Model name
- Provider name
- Task category (for instance, Text Generation).
Bedrock Ready badge (if appropriate), suggesting that this model can be signed up with Amazon Bedrock, permitting you to use
Amazon Bedrock APIs to
conjure up the model
5. Choose the
model card to view the design details page.
The model details page includes the following details:
- The model name and provider details.
Deploy button to deploy the model.
About and Notebooks tabs with detailed details
The About tab consists of important details, such as:
- Model description.
- License details.
- Technical requirements.
- Usage standards
Before you release the model, it's suggested to evaluate the design details and license terms to verify compatibility with your usage case.

6. Choose Deploy to proceed with deployment.
7. For Endpoint name, use the immediately generated name or create a custom-made one.
8. For Instance type ¸ pick a circumstances type (default: ml.p5e.48 xlarge).
9. For Initial instance count, go into the variety of circumstances (default: 1).
Selecting proper circumstances types and counts is crucial for cost and
performance optimization. Monitor your release to adjust these settings as needed.Under Inference type, Real-time inference is picked by default. This is optimized for sustained traffic and low latency.
10. Review all configurations for precision. For this design, we highly advise sticking to SageMaker JumpStart default settings and making certain that network seclusion remains in place.
11.
Choose Deploy to deploy the model.
The release procedure can take numerous minutes to finish.
When deployment is complete, your endpoint status will change to
InService. At this point, the model is all set to accept reasoning requests through the endpoint. You can monitor the deployment progress on the
SageMaker console Endpoints page, which will show pertinent metrics and status details. When the implementation is complete, you can invoke the design using a SageMaker runtime customer and incorporate it with your applications.
Deploy DeepSeek-R1 using the SageMaker Python SDK
To start with DeepSeek-R1 utilizing the SageMaker Python SDK, you will require to set up the SageMaker Python SDK and make certain you have the required AWS permissions and environment setup. The following is a detailed code example that shows how to release and use DeepSeek-R1 for
inference programmatically. The code for releasing the model is provided in the Github here. You can clone the note pad and run from SageMaker Studio.
You can run extra requests against the predictor:
Implement guardrails and run reasoning with your SageMaker JumpStart predictor
Similar to Amazon Bedrock, you can also utilize the ApplyGuardrail API with your SageMaker JumpStart predictor. You can create a guardrail utilizing the Amazon Bedrock console or the API, and execute it as displayed in the following code:
Tidy up
To avoid undesirable charges, finish the actions in this area to clean up your resources.
Delete the Amazon Bedrock Marketplace release
If you deployed the design utilizing Amazon Bedrock Marketplace, total the following steps:
1. On the Amazon Bedrock console, under Foundation designs in the navigation pane, choose Marketplace
deployments.
2. In the Managed implementations section, locate the endpoint you wish to erase.
3. Select the endpoint, and on the Actions menu, select Delete.
4. Verify the endpoint details to make certain you're deleting the right implementation: 1. Endpoint name.
2. Model name.
3. Endpoint status
Delete the
SageMaker JumpStart predictor
The
SageMaker JumpStart model you deployed will sustain expenses if you leave it running. Use the following code to delete the endpoint if you desire to stop sustaining charges. For more details, see Delete Endpoints and
Resources.
Conclusion
In this post, we checked out how you can access and release the DeepSeek-R1 design using Bedrock Marketplace and SageMaker JumpStart. Visit SageMaker JumpStart in SageMaker Studio or Amazon Bedrock Marketplace now to get going. For more details, describe Use Amazon Bedrock tooling with
Amazon SageMaker JumpStart models, SageMaker JumpStart pretrained designs, Amazon SageMaker JumpStart Foundation Models, Amazon Bedrock Marketplace, and Getting going with Amazon SageMaker JumpStart.
About the Authors
Vivek Gangasani is a Lead Specialist Solutions Architect for Inference at AWS. He assists emerging generative
AI business develop ingenious options using AWS services and accelerated calculate. Currently, he is focused on establishing strategies for fine-tuning and enhancing the inference performance of big language designs. In his downtime, Vivek delights in hiking, seeing motion pictures, and attempting various foods.
Niithiyn Vijeaswaran is a Generative
AI Specialist Solutions Architect with the Third-Party Model Science group at AWS. His location of focus is AWS
AI accelerators (AWS Neuron). He holds a Bachelor's degree in Computer Science and Bioinformatics.

Jonathan Evans is an Expert Solutions Architect working on generative
AI with the Third-Party Model Science group at AWS.
Banu Nagasundaram leads product, engineering, and tactical partnerships for Amazon SageMaker JumpStart, SageMaker's artificial intelligence and generative
AI center. She is enthusiastic about developing solutions that help consumers accelerate their
AI journey and unlock organization value.