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

Betsey Phillip 2025-04-07 04:04:11 +08:00
commit 4698b01f5b
1 changed files with 93 additions and 0 deletions

@ -0,0 +1,93 @@
<br>Today, we are thrilled 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 deploy DeepSeek [AI](https://www.racingfans.com.au)'s first-generation frontier design, DeepSeek-R1, along with the distilled variations varying from 1.5 to 70 billion parameters to develop, experiment, and responsibly scale your generative [AI](https://git.iws.uni-stuttgart.de) concepts on AWS.<br>
<br>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 deploy the distilled variations of the designs as well.<br>
<br>Overview of DeepSeek-R1<br>
<br>DeepSeek-R1 is a big language design (LLM) developed by DeepSeek [AI](https://givebackabroad.org) that utilizes support discovering to [enhance thinking](https://git.xhkjedu.com) capabilities through a multi-stage training process from a DeepSeek-V3-Base foundation. A crucial identifying feature is its support knowing (RL) action, which was used to fine-tune the design's actions beyond the standard pre-training and tweak process. By incorporating RL, DeepSeek-R1 can adapt better to user feedback and objectives, ultimately improving both significance and clearness. In addition, DeepSeek-R1 utilizes a chain-of-thought (CoT) technique, suggesting it's equipped to break down complicated queries and factor through them in a detailed manner. This directed thinking process allows the model to produce more accurate, transparent, and detailed answers. This design integrates RL-based fine-tuning with CoT abilities, aiming to produce structured actions while [concentrating](https://letustalk.co.in) on [interpretability](http://www.xn--2i4bi0gw9ai2d65w.com) 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 various workflows such as representatives, logical thinking and information analysis tasks.<br>
<br>DeepSeek-R1 utilizes a Mixture of Experts (MoE) architecture and is 671 billion specifications in size. The MoE architecture enables activation of 37 billion criteria, enabling efficient inference by routing inquiries to the most relevant expert "clusters." This approach enables the design to specialize in different issue domains while maintaining general effectiveness. DeepSeek-R1 requires a minimum of 800 GB of HBM memory in FP8 format for reasoning. In this post, we will utilize an ml.p5e.48 xlarge circumstances to release the model. ml.p5e.48 xlarge features 8 Nvidia H200 [GPUs providing](http://8.137.58.203000) 1128 GB of GPU memory.<br>
<br>DeepSeek-R1 distilled models bring the thinking capabilities of the main R1 design to more efficient architectures based on popular open designs like Qwen (1.5 B, 7B, 14B, and 32B) and Llama (8B and 70B). Distillation describes a procedure of training smaller sized, more efficient designs to imitate the habits and reasoning patterns of the larger DeepSeek-R1 model, utilizing it as a teacher model.<br>
<br>You can deploy DeepSeek-R1 design either through SageMaker JumpStart or Bedrock Marketplace. Because DeepSeek-R1 is an emerging model, we suggest releasing this model with guardrails in location. In this blog, we will use Amazon Bedrock [Guardrails](https://www.tobeop.com) to present safeguards, avoid harmful material, and examine designs against essential security criteria. At the time of writing this blog, for DeepSeek-R1 releases on SageMaker JumpStart and [Bedrock](http://123.207.52.1033000) Marketplace, Bedrock Guardrails supports just the ApplyGuardrail API. You can develop several guardrails tailored to various usage cases and use them to the DeepSeek-R1 design, improving user experiences and standardizing security controls across your generative [AI](http://59.110.162.91:8081) applications.<br>
<br>Prerequisites<br>
<br>To [release](https://gitea.evo-labs.org) the DeepSeek-R1 design, you need access to an ml.p5e instance. To examine if you have quotas for P5e, open the Service Quotas console and under AWS Services, select Amazon SageMaker, and verify you're utilizing ml.p5e.48 xlarge for endpoint usage. Make certain that you have at least one ml.P5e.48 xlarge circumstances in the AWS Region you are releasing. To request a [limitation](https://www.meditationgoodtip.com) increase, create a limitation boost demand and reach out to your account group.<br>
<br>Because you will be releasing this design with Amazon Bedrock Guardrails, make certain you have the appropriate AWS Identity and Gain Access To Management (IAM) approvals to use Amazon Bedrock Guardrails. For guidelines, see Establish consents to use guardrails for material filtering.<br>
<br>Implementing guardrails with the ApplyGuardrail API<br>
<br>Amazon Bedrock Guardrails allows you to present safeguards, avoid harmful material, and assess designs against essential security criteria. You can carry out safety steps for the DeepSeek-R1 model utilizing the Amazon Bedrock ApplyGuardrail API. This allows you to use guardrails to assess user inputs and design responses [released](https://gitlab.surrey.ac.uk) on Amazon Bedrock Marketplace and SageMaker JumpStart. You can develop a guardrail using the Amazon Bedrock console or the API. For the example code to produce the guardrail, see the GitHub repo.<br>
<br>The general [circulation involves](https://wiki.vst.hs-furtwangen.de) the following actions: First, the system gets an input for the model. This input is then [processed](https://www.hrdemployment.com) through the ApplyGuardrail API. If the input passes the guardrail check, it's sent to the design for inference. After getting the design's output, another guardrail check is used. If the output passes this last check, it's returned as the result. However, if either the input or output is intervened by the guardrail, a message is returned indicating the nature of the intervention and whether it occurred at the input or output stage. The examples showcased in the following sections show reasoning using this API.<br>
<br>Deploy DeepSeek-R1 in Amazon Bedrock Marketplace<br>
<br>Amazon Bedrock Marketplace provides you access to over 100 popular, emerging, and specialized structure designs (FMs) through Amazon Bedrock. To gain access to DeepSeek-R1 in Amazon Bedrock, total the following steps:<br>
<br>1. On the Amazon Bedrock console, choose Model catalog under Foundation models in the navigation pane.
At the time of composing this post, you can utilize the InvokeModel API to conjure up the design. It doesn't support Converse APIs and other Amazon Bedrock tooling.
2. Filter for DeepSeek as a supplier and select the DeepSeek-R1 design.<br>
<br>The design detail page supplies essential details about the design's abilities, pricing structure, and application guidelines. You can find detailed use directions, consisting of sample API calls and code bits for combination. The model supports various text generation tasks, consisting of content production, code generation, and [higgledy-piggledy.xyz](https://higgledy-piggledy.xyz/index.php/User:MiquelAer064) concern answering, utilizing its [support learning](https://www.meetgr.com) optimization and CoT reasoning [abilities](http://207.148.91.1453000).
The page also includes [release alternatives](https://cvwala.com) and [licensing details](https://kennetjobs.com) to help you get started with DeepSeek-R1 in your applications.
3. To begin using DeepSeek-R1, choose Deploy.<br>
<br>You will be prompted to configure the release details for DeepSeek-R1. The design ID will be pre-populated.
4. For Endpoint name, get in an endpoint name (between 1-50 alphanumeric characters).
5. For [Variety](http://8.211.134.2499000) of instances, enter a number of circumstances (between 1-100).
6. For example type, select your circumstances type. For optimum performance with DeepSeek-R1, a GPU-based instance type like ml.p5e.48 xlarge is advised.
Optionally, you can set up sophisticated security and infrastructure settings, consisting of virtual private cloud (VPC) networking, service role approvals, and encryption settings. For many use cases, the default settings will work well. However, for production deployments, you may wish to examine these settings to align with your company's security and compliance [requirements](http://geoje-badapension.com).
7. [Choose Deploy](http://ccrr.ru) to start utilizing the model.<br>
<br>When the implementation is complete, you can test DeepSeek-R1's abilities straight in the Amazon Bedrock play area.
8. Choose Open in play ground to access an interactive interface where you can experiment with different prompts and adjust model specifications like temperature level and maximum length.
When utilizing R1 with Bedrock's InvokeModel and Playground Console, utilize DeepSeek's chat design template for optimal outcomes. For instance, material for inference.<br>
<br>This is an excellent method to check out the model's reasoning and text generation capabilities before incorporating it into your applications. The play area supplies instant feedback, helping you comprehend how the design reacts to different inputs and letting you tweak your prompts for ideal results.<br>
<br>You can rapidly check the model in the play area through the UI. However, to conjure up the deployed design programmatically with any Amazon Bedrock APIs, you need to get the endpoint ARN.<br>
<br>Run reasoning using guardrails with the deployed DeepSeek-R1 endpoint<br>
<br>The following code example shows how to perform inference utilizing a released DeepSeek-R1 design through Amazon Bedrock utilizing the invoke_model and ApplyGuardrail API. You can produce a guardrail using the Amazon Bedrock [console](https://vagas.grupooportunityrh.com.br) or the API. For the example code to develop the guardrail, see the GitHub repo. After you have actually developed the guardrail, utilize the following code to implement guardrails. The script [initializes](http://tv.houseslands.com) the bedrock_runtime client, [configures reasoning](https://hiremegulf.com) parameters, and sends out a request to generate text based on a user prompt.<br>
<br>Deploy DeepSeek-R1 with SageMaker JumpStart<br>
<br>[SageMaker JumpStart](https://nepaxxtube.com) is an [artificial intelligence](https://silverray.worshipwithme.co.ke) (ML) hub with FMs, integrated algorithms, and prebuilt ML services that you can release with just a couple of clicks. With SageMaker JumpStart, you can tailor pre-trained models to your use case, with your data, and deploy them into production using either the UI or SDK.<br>
<br>Deploying DeepSeek-R1 model through SageMaker JumpStart provides 2 convenient approaches: utilizing the intuitive SageMaker JumpStart UI or implementing programmatically through the SageMaker Python SDK. Let's explore both approaches to help you select the method that best fits your requirements.<br>
<br>Deploy DeepSeek-R1 through SageMaker JumpStart UI<br>
<br>Complete the following [actions](http://gitlab.mints-id.com) to deploy DeepSeek-R1 using SageMaker JumpStart:<br>
<br>1. On the SageMaker console, choose Studio in the navigation pane.
2. First-time users will be triggered to create a domain.
3. On the SageMaker Studio console, choose JumpStart in the navigation pane.<br>
<br>The design web browser displays available models, with details like the provider name and [model abilities](https://wathelp.com).<br>
<br>4. Search for DeepSeek-R1 to see the DeepSeek-R1 model card.
Each design card shows essential details, consisting of:<br>
<br>- Model name
- Provider name
- Task category (for instance, Text Generation).
Bedrock Ready badge (if relevant), 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 design card to see the model details page.<br>
<br>The page includes the following details:<br>
<br>- The design name and service provider details.
Deploy button to release the model.
About and Notebooks tabs with [detailed](https://www.infiniteebusiness.com) details<br>
<br>The About tab includes crucial details, such as:<br>
<br>- Model description.
- License details.
- Technical specifications.
- Usage standards<br>
<br>Before you deploy the model, it's advised to evaluate the model details and license terms to validate compatibility with your use case.<br>
<br>6. Choose Deploy to continue with deployment.<br>
<br>7. For Endpoint name, utilize the instantly created name or create a custom one.
8. For Instance type ¸ pick an instance type (default: ml.p5e.48 xlarge).
9. For Initial instance count, get in the variety of circumstances (default: 1).
Selecting suitable instance types and counts is essential for expense and [efficiency optimization](https://work-ofie.com). Monitor your deployment to change these settings as needed.Under Inference type, Real-time reasoning is picked by default. This is optimized for sustained traffic and low latency.
10. Review all setups for accuracy. For this model, we highly suggest sticking to SageMaker JumpStart default settings and making certain that [network isolation](https://bnsgh.com) remains in location.
11. Choose Deploy to release the design.<br>
<br>The implementation process can take a number of minutes to complete.<br>
<br>When deployment is complete, your endpoint status will alter to InService. At this moment, the design is prepared to accept inference demands through the endpoint. You can keep an eye on the implementation progress on the SageMaker console Endpoints page, which will display appropriate metrics and status details. When the implementation is total, you can invoke the model utilizing a SageMaker runtime customer and incorporate it with your applications.<br>
<br>Deploy DeepSeek-R1 using the SageMaker Python SDK<br>
<br>To get started with DeepSeek-R1 utilizing the SageMaker Python SDK, you will [require](https://redebrasil.app) to install the SageMaker Python SDK and make certain you have the necessary AWS consents and environment setup. The following is a detailed code example that [demonstrates](https://encone.com) how to release and use DeepSeek-R1 for inference programmatically. The code for deploying the design is provided in the Github here. You can clone the note pad and run from SageMaker Studio.<br>
<br>You can run extra requests against the predictor:<br>
<br>Implement guardrails and run reasoning with your SageMaker JumpStart predictor<br>
<br>Similar to Amazon Bedrock, you can also use the ApplyGuardrail API with your SageMaker JumpStart predictor. You can produce a guardrail using the Amazon Bedrock console or the API, and [execute](https://www.ahrs.al) it as revealed in the following code:<br>
<br>Tidy up<br>
<br>To avoid unwanted charges, complete the steps in this area to tidy up your resources.<br>
<br>Delete the Amazon Bedrock Marketplace deployment<br>
<br>If you deployed the design utilizing Amazon Bedrock Marketplace, total the following actions:<br>
<br>1. On the Amazon Bedrock console, under Foundation models in the navigation pane, pick Marketplace implementations.
2. In the Managed deployments section, find the endpoint you wish to erase.
3. Select the endpoint, and on the Actions menu, pick Delete.
4. Verify the endpoint details to make certain you're erasing the right release: 1. Endpoint name.
2. Model name.
3. Endpoint status<br>
<br>Delete the SageMaker JumpStart predictor<br>
<br>The SageMaker JumpStart model you released 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 explored 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 now to start. For more details, describe Use Amazon Bedrock tooling with Amazon SageMaker JumpStart designs, SageMaker JumpStart pretrained models, 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://dubaijobzone.com) for Inference at AWS. He assists emerging generative [AI](http://gitlab.mints-id.com) business construct ingenious solutions using AWS services and sped up compute. Currently, he is focused on establishing methods for fine-tuning and optimizing the inference performance of large language designs. In his complimentary time, Vivek takes pleasure in treking, enjoying films, and [attempting](https://www.bongmedia.tv) different foods.<br>
<br>Niithiyn Vijeaswaran is a Generative [AI](https://baescout.com) Specialist Solutions [Architect](https://gitea.elkerton.ca) with the [Third-Party Model](https://git.becks-web.de) Science team at AWS. His area of focus is AWS [AI](https://studentvolunteers.us) accelerators (AWS Neuron). He holds a Bachelor's degree in Computer technology and Bioinformatics.<br>
<br>Jonathan Evans is a Specialist Solutions Architect working on generative [AI](http://fggn.kr) with the Third-Party Model Science team at AWS.<br>
<br>Banu Nagasundaram leads item, engineering, and tactical partnerships for Amazon SageMaker JumpStart, SageMaker's artificial [intelligence](https://www.suntool.top) and generative [AI](https://www.bjs-personal.hu) center. She is passionate about constructing services that help clients accelerate their [AI](https://postyourworld.com) journey and unlock service value.<br>