Add DeepSeek-R1 Model now Available in Amazon Bedrock Marketplace And Amazon SageMaker JumpStart

Madelaine Valliere 2025-03-11 22:04:24 +03:00
commit e1fa69caab
1 changed files with 93 additions and 0 deletions

@ -0,0 +1,93 @@
<br>Today, we are excited to announce that DeepSeek R1 distilled Llama and Qwen designs are available through Amazon Bedrock Marketplace and Amazon SageMaker JumpStart. With this launch, you can now deploy DeepSeek [AI](https://x-like.ir)'s first-generation frontier model, DeepSeek-R1, along with the distilled versions ranging from 1.5 to 70 billion specifications to develop, experiment, and responsibly scale your generative [AI](https://20.112.29.181) concepts on AWS.<br>
<br>In this post, we demonstrate how to get going with DeepSeek-R1 on Amazon Bedrock Marketplace and [SageMaker JumpStart](https://git.mintmuse.com). You can follow similar actions to deploy the distilled variations of the designs also.<br>
<br>Overview of DeepSeek-R1<br>
<br>DeepSeek-R1 is a large language design (LLM) established by DeepSeek [AI](http://git.sdkj001.cn) that utilizes support learning to improve thinking abilities through a multi-stage training procedure from a DeepSeek-V3-Base structure. A key distinguishing function is its reinforcement learning (RL) step, which was utilized to improve the model's reactions beyond the standard pre-training and fine-tuning procedure. By incorporating RL, DeepSeek-R1 can adapt more successfully to user feedback and goals, eventually enhancing both significance and clearness. In addition, DeepSeek-R1 uses a chain-of-thought (CoT) method, implying it's geared up to break down [complicated questions](https://gitea.gai-co.com) and factor through them in a detailed way. This directed thinking [procedure](https://code.linkown.com) allows the model to produce more precise, transparent, and [detailed responses](https://abileneguntrader.com). This design integrates RL-based fine-tuning with CoT abilities, aiming to create structured actions while focusing on interpretability and user interaction. With its comprehensive abilities DeepSeek-R1 has actually recorded the market's attention as a versatile text-generation design that can be integrated into various workflows such as representatives, logical reasoning and data interpretation jobs.<br>
<br>DeepSeek-R1 uses a Mixture of Experts (MoE) architecture and is 671 billion criteria in size. The MoE architecture enables activation of 37 billion specifications, enabling efficient reasoning by routing questions to the most pertinent expert "clusters." This method enables the model to concentrate on various issue domains while maintaining overall efficiency. DeepSeek-R1 requires a minimum of 800 GB of HBM memory in FP8 format for reasoning. In this post, we will use an ml.p5e.48 xlarge instance to release the design. ml.p5e.48 xlarge features 8 Nvidia H200 GPUs offering 1128 GB of GPU memory.<br>
<br>DeepSeek-R1 distilled designs bring the thinking abilities of the main R1 design to more effective architectures based upon popular open [designs](https://thegoldenalbatross.com) like Qwen (1.5 B, 7B, 14B, and 32B) and Llama (8B and 70B). Distillation describes a process of training smaller sized, more efficient models to imitate the behavior and thinking patterns of the bigger DeepSeek-R1 model, utilizing it as an instructor model.<br>
<br>You can release DeepSeek-R1 model either through SageMaker JumpStart or Bedrock Marketplace. Because DeepSeek-R1 is an emerging design, we advise releasing this model with guardrails in location. In this blog, we will utilize Amazon Bedrock Guardrails to introduce safeguards, avoid harmful content, and examine designs against essential safety requirements. At the time of composing this blog site, for DeepSeek-R1 implementations on SageMaker JumpStart and Bedrock Marketplace, Bedrock Guardrails supports just the ApplyGuardrail API. You can produce several guardrails tailored to different use cases and use them to the DeepSeek-R1 design, improving user experiences and controls across your generative [AI](https://git.thatsverys.us) applications.<br>
<br>Prerequisites<br>
<br>To deploy the DeepSeek-R1 model, you need access to an ml.p5e instance. To check if you have quotas for P5e, open the Service Quotas console and under AWS Services, choose Amazon SageMaker, and confirm you're utilizing ml.p5e.48 xlarge for endpoint use. Make certain that you have at least one ml.P5e.48 xlarge circumstances in the AWS Region you are releasing. To ask for a limit boost, create a limitation boost demand and reach out to your account group.<br>
<br>Because you will be releasing this model with Amazon Bedrock Guardrails, make certain you have the appropriate AWS Identity and Gain Access To Management (IAM) consents to utilize Amazon Bedrock Guardrails. For instructions, see Set up consents to utilize guardrails for content filtering.<br>
<br>Implementing guardrails with the ApplyGuardrail API<br>
<br>Amazon Bedrock Guardrails allows you to introduce safeguards, prevent harmful content, and examine models against crucial security requirements. You can execute precaution for the DeepSeek-R1 design utilizing the Amazon Bedrock ApplyGuardrail API. This enables you to use guardrails to examine user inputs and design reactions deployed on Amazon Bedrock Marketplace and SageMaker JumpStart. You can create a guardrail using the Amazon Bedrock [console](http://git.gupaoedu.cn) or the API. For the example code to create the guardrail, see the GitHub repo.<br>
<br>The general circulation involves the following actions: First, the system gets an input for the model. This input is then processed through the ApplyGuardrail API. If the input passes the guardrail check, it's sent out to the model for inference. After getting the model's output, another guardrail check is applied. If the output passes this final check, it's returned as the final result. However, if either the input or output is stepped in by the guardrail, a message is returned indicating the nature of the intervention and whether it occurred at the input or output phase. The examples showcased in the following sections demonstrate inference utilizing this API.<br>
<br>Deploy DeepSeek-R1 in Amazon Bedrock Marketplace<br>
<br>Amazon Bedrock Marketplace offers you access to over 100 popular, emerging, and specialized foundation designs (FMs) through Amazon Bedrock. To [gain access](http://xn--jj-xu1im7bd43bzvos7a5l04n158a8xe.com) to DeepSeek-R1 in Amazon Bedrock, total the following actions:<br>
<br>1. On the Amazon Bedrock console, select Model brochure under Foundation designs in the navigation pane.
At the time of composing this post, you can [utilize](https://www.wakewiki.de) 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 [service provider](https://www.jobseeker.my) and select the DeepSeek-R1 model.<br>
<br>The design detail page offers important details about the model's abilities, prices structure, and execution guidelines. You can discover detailed use directions, including sample API calls and code snippets for integration. The design supports numerous text generation tasks, consisting of content production, code generation, and concern answering, utilizing its support discovering optimization and CoT reasoning abilities.
The page likewise includes implementation choices and licensing details to help you get going with DeepSeek-R1 in your applications.
3. To begin using DeepSeek-R1, choose Deploy.<br>
<br>You will be prompted to configure the deployment details for DeepSeek-R1. The model ID will be pre-populated.
4. For Endpoint name, enter an endpoint name (between 1-50 alphanumeric characters).
5. For Variety of circumstances, go into a variety of circumstances (between 1-100).
6. For Instance type, select your instance type. For ideal performance with DeepSeek-R1, a GPU-based circumstances type like ml.p5e.48 xlarge is suggested.
Optionally, you can configure sophisticated security and facilities settings, including virtual personal cloud (VPC) networking, service function approvals, and [pipewiki.org](https://pipewiki.org/wiki/index.php/User:DiegoAtkin) file encryption settings. For the majority of use cases, the default settings will work well. However, for production deployments, you may want to review these settings to line up with your company's security and compliance requirements.
7. Choose Deploy to start utilizing the design.<br>
<br>When the implementation is complete, you can test DeepSeek-R1's capabilities straight in the Amazon Bedrock playground.
8. Choose Open in playground to access an interactive user interface where you can experiment with different triggers and adjust design parameters like temperature and maximum length.
When using R1 with Bedrock's InvokeModel and Playground Console, use DeepSeek's chat design template for optimal results. For instance, material for inference.<br>
<br>This is an outstanding way to check out the design's reasoning and text generation abilities before integrating it into your applications. The play area provides instant feedback, helping you understand how the model reacts to different inputs and letting you tweak your prompts for optimal results.<br>
<br>You can [rapidly test](https://gitlab.reemii.cn) the model in the play area through the UI. However, to conjure up the released design programmatically with any Amazon Bedrock APIs, you require to get the endpoint ARN.<br>
<br>Run inference utilizing guardrails with the deployed DeepSeek-R1 endpoint<br>
<br>The following code example [demonstrates](http://kiwoori.com) how to carry out inference using a deployed DeepSeek-R1 design through Amazon Bedrock utilizing the invoke_model and ApplyGuardrail API. You can develop a guardrail utilizing the Amazon Bedrock console or the API. For the example code to develop the guardrail, see the GitHub repo. After you have [developed](https://dating.checkrain.co.in) the guardrail, use the following code to implement guardrails. The script initializes the bedrock_runtime customer, configures inference specifications, and sends out a demand to generate text based on a user timely.<br>
<br>Deploy DeepSeek-R1 with [SageMaker](https://gitea.lihaink.cn) JumpStart<br>
<br>SageMaker JumpStart is an artificial intelligence (ML) center with FMs, built-in algorithms, and prebuilt ML solutions that you can deploy with simply a few clicks. With SageMaker JumpStart, you can tailor pre-trained models to your usage case, with your information, and release them into production utilizing either the UI or SDK.<br>
<br>Deploying DeepSeek-R1 design through SageMaker JumpStart uses two practical techniques: using the instinctive SageMaker JumpStart UI or carrying out programmatically through the SageMaker Python SDK. Let's check out both techniques to help you choose the method that finest fits your requirements.<br>
<br>Deploy DeepSeek-R1 through SageMaker JumpStart UI<br>
<br>Complete the following steps to deploy DeepSeek-R1 using SageMaker JumpStart:<br>
<br>1. On the SageMaker console, pick Studio in the navigation pane.
2. First-time users will be prompted to develop a domain.
3. On the SageMaker Studio console, select JumpStart in the navigation pane.<br>
<br>The design browser displays available designs, with details like the service provider name and model abilities.<br>
<br>4. Search for DeepSeek-R1 to view the DeepSeek-R1 model card.
Each model card shows key details, including:<br>
<br>- Model name
- Provider name
- Task [classification](http://8.141.83.2233000) (for example, Text Generation).
Bedrock Ready badge (if applicable), showing that this design can be signed up with Amazon Bedrock, enabling you to utilize Amazon Bedrock APIs to conjure up the design<br>
<br>5. Choose the model card to view the model details page.<br>
<br>The model details page consists of the following details:<br>
<br>- The model name and service provider details.
Deploy button to deploy the model.
About and Notebooks tabs with detailed details<br>
<br>The About tab includes important details, such as:<br>
<br>- Model description.
- License [details](https://gogs.2dz.fi).
- Technical specifications.
- Usage standards<br>
<br>Before you deploy the model, it's suggested to evaluate the model details and license terms to confirm compatibility with your usage case.<br>
<br>6. Choose Deploy to proceed with release.<br>
<br>7. For Endpoint name, use the immediately created name or create a custom one.
8. For Instance type ¸ pick a circumstances type (default: ml.p5e.48 xlarge).
9. For Initial circumstances count, get in the variety of circumstances (default: 1).
Selecting suitable instance types and counts is important for expense and efficiency optimization. Monitor your deployment to adjust these settings as needed.Under [Inference](http://www.tuzh.top3000) type, Real-time inference is chosen by default. This is optimized for sustained traffic and low latency.
10. Review all configurations for accuracy. For this design, we highly advise sticking to SageMaker JumpStart default settings and making certain that network seclusion remains in [location](http://deve.work3000).
11. [Choose Deploy](https://topdubaijobs.ae) to deploy the model.<br>
<br>The deployment procedure can take numerous minutes to finish.<br>
<br>When implementation is complete, your endpoint status will alter to InService. At this moment, the design is ready to accept reasoning requests through the endpoint. You can keep an eye on the release development on the [SageMaker](https://gitlab.amepos.in) console Endpoints page, which will display relevant metrics and status details. When the deployment is total, you can invoke the model using a SageMaker runtime customer and incorporate it with your applications.<br>
<br>Deploy DeepSeek-R1 using the SageMaker Python SDK<br>
<br>To get going with DeepSeek-R1 using the SageMaker Python SDK, you will require to set up the SageMaker Python SDK and make certain you have the required AWS consents and environment setup. The following is a detailed code example that demonstrates how to deploy and use DeepSeek-R1 for reasoning programmatically. The code for releasing the design is provided in the Github here. You can clone the notebook and run from SageMaker Studio.<br>
<br>You can run additional requests against the predictor:<br>
<br>Implement guardrails and run inference with your SageMaker JumpStart predictor<br>
<br>Similar to Amazon Bedrock, you can also utilize the ApplyGuardrail API with your SageMaker JumpStart predictor. You can produce a guardrail using the Amazon Bedrock console or the API, and execute it as revealed in the following code:<br>
<br>Tidy up<br>
<br>To avoid undesirable charges, complete the steps in this area to tidy up your resources.<br>
<br>Delete the Amazon Bedrock Marketplace release<br>
<br>If you deployed the design using Amazon Bedrock Marketplace, total the following actions:<br>
<br>1. On the Amazon Bedrock console, under Foundation models in the navigation pane, pick Marketplace deployments.
2. In the Managed releases section, locate the endpoint you want to delete.
3. Select the endpoint, and on the Actions menu, select Delete.
4. Verify the endpoint details to make certain you're deleting the right deployment: 1. Endpoint name.
2. Model name.
3. Endpoint status<br>
<br>Delete the SageMaker JumpStart predictor<br>
<br>The [SageMaker JumpStart](https://topdubaijobs.ae) design you deployed will sustain costs if you leave it running. Use the following code to delete the endpoint if you wish to stop sustaining charges. For more details, see Delete Endpoints and Resources.<br>
<br>Conclusion<br>
<br>In this post, we checked out how you can access and release the DeepSeek-R1 model using Bedrock Marketplace and SageMaker JumpStart. Visit SageMaker JumpStart in SageMaker Studio or Amazon Bedrock [Marketplace](http://1138845-ck16698.tw1.ru) now to begin. For more details, refer to Use Amazon Bedrock tooling with Amazon SageMaker JumpStart models, [SageMaker JumpStart](https://gogs.dev.dazesoft.cn) pretrained designs, Amazon SageMaker JumpStart Foundation Models, Amazon Bedrock Marketplace, and Starting with Amazon SageMaker JumpStart.<br>
<br>About the Authors<br>
<br>Vivek Gangasani is a Lead Specialist Solutions [Architect](https://firemuzik.com) for Inference at AWS. He assists emerging generative [AI](https://www.tobeop.com) companies develop innovative solutions utilizing AWS services and accelerated calculate. Currently, he is focused on developing techniques for fine-tuning and optimizing the inference performance of big [language](https://webshow.kr) [designs](https://gitlab.ngser.com). In his leisure time, Vivek delights in hiking, enjoying movies, and trying different foods.<br>
<br>Niithiyn Vijeaswaran is a Generative [AI](https://git.iidx.ca) Specialist Solutions Architect with the [Third-Party Model](http://27.154.233.18610080) [Science team](https://furrytube.furryarabic.com) at AWS. His area of focus is AWS [AI](https://miderde.de) accelerators (AWS Neuron). He holds a Bachelor's degree in Computer technology and Bioinformatics.<br>
<br>Jonathan Evans is a Professional Solutions Architect working on generative [AI](http://116.198.225.84:3000) with the Third-Party Model Science team at AWS.<br>
<br>Banu Nagasundaram leads item, engineering, and strategic partnerships for Amazon SageMaker JumpStart, SageMaker's artificial intelligence and generative [AI](https://dainiknews.com) center. She is passionate about developing solutions that help clients accelerate their [AI](https://www.joboptimizers.com) journey and unlock service value.<br>