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

Terrie Bechtel 2025-02-15 16:38:57 +08:00
commit ae2607d227

@ -0,0 +1,93 @@
<br>Today, we are delighted 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 release DeepSeek [AI](http://www.isexsex.com)'s first-generation frontier design, DeepSeek-R1, together with the distilled versions ranging from 1.5 to 70 billion specifications to develop, experiment, and properly scale your generative [AI](https://www.cbtfmytube.com) concepts on AWS.<br>
<br>In this post, we show how to start with DeepSeek-R1 on Amazon Bedrock Marketplace and SageMaker JumpStart. You can follow similar actions to deploy the distilled variations of the models too.<br>
<br>Overview of DeepSeek-R1<br>
<br>DeepSeek-R1 is a big language design (LLM) developed by DeepSeek [AI](http://111.229.9.19:3000) that uses reinforcement discovering to improve reasoning capabilities through a multi-stage training process from a DeepSeek-V3-Base foundation. A key differentiating function is its support knowing (RL) action, which was utilized to refine the model's responses beyond the standard pre-training and fine-tuning procedure. By including RL, DeepSeek-R1 can adjust better to user feedback and objectives, eventually boosting both relevance and clarity. In addition, DeepSeek-R1 uses a chain-of-thought (CoT) method, implying it's equipped to break down complex questions and factor through them in a detailed manner. This guided thinking process allows the design to produce more accurate, transparent, and [detailed answers](https://git.sofit-technologies.com). This design combines RL-based fine-tuning with CoT capabilities, aiming to generate structured actions while concentrating on interpretability and user interaction. With its comprehensive capabilities DeepSeek-R1 has actually caught the market's attention as a versatile text-generation design that can be incorporated into various workflows such as representatives, logical thinking and information interpretation tasks.<br>
<br>DeepSeek-R1 uses a [Mixture](https://www.kritterklub.com) of Experts (MoE) architecture and is 671 billion parameters in size. The MoE architecture enables activation of 37 billion parameters, allowing effective reasoning by routing questions to the most relevant specialist "clusters." This [method permits](https://git.nosharpdistinction.com) the model to specialize in different problem domains while maintaining overall efficiency. DeepSeek-R1 needs at least 800 GB of HBM memory in FP8 format for reasoning. In this post, we will use an ml.p5e.48 xlarge instance to deploy the model. ml.p5e.48 xlarge includes 8 Nvidia H200 [GPUs offering](https://axionrecruiting.com) 1128 GB of GPU memory.<br>
<br>DeepSeek-R1 distilled models bring the reasoning abilities of the main R1 design to more effective architectures based on popular open models like Qwen (1.5 B, 7B, 14B, and 32B) and Llama (8B and 70B). Distillation describes a procedure of training smaller sized, more effective models to imitate the habits and thinking patterns of the larger DeepSeek-R1 design, using it as an [instructor design](https://jobs.salaseloffshore.com).<br>
<br>You can deploy DeepSeek-R1 model 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, we will [utilize Amazon](https://employme.app) Bedrock Guardrails to introduce safeguards, prevent hazardous material, and examine designs against key safety criteria. At the time of composing this blog, for DeepSeek-R1 releases 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, enhancing user experiences and standardizing security controls throughout your generative [AI](https://uconnect.ae) applications.<br>
<br>Prerequisites<br>
<br>To release the DeepSeek-R1 design, you need access to an ml.p5e instance. To inspect if you have quotas for P5e, open the Service Quotas console and under AWS Services, pick Amazon SageMaker, and validate you're using ml.p5e.48 xlarge for endpoint usage. Make certain that you have at least one ml.P5e.48 xlarge instance in the AWS Region you are [deploying](http://www.isexsex.com). To ask for a limitation increase, develop a limitation increase request and connect to your account group.<br>
<br>Because you will be deploying this design with Amazon Bedrock Guardrails, make certain you have the [correct](https://clousound.com) AWS Identity and Gain Access To Management (IAM) permissions to utilize Amazon Bedrock Guardrails. For instructions, see Establish consents to utilize guardrails for material filtering.<br>
<br>Implementing guardrails with the ApplyGuardrail API<br>
<br>Amazon Bedrock Guardrails allows you to introduce safeguards, prevent hazardous content, and examine models against key safety requirements. You can carry out precaution for the DeepSeek-R1 design utilizing the Amazon Bedrock ApplyGuardrail API. This permits you to apply guardrails to assess user inputs and design responses deployed 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 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](https://trademarketclassifieds.com) check, it's sent to the model for reasoning. After receiving the model's output, another guardrail check is used. If the output passes this last 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 areas demonstrate inference utilizing this API.<br>
<br>Deploy DeepSeek-R1 in Amazon Bedrock Marketplace<br>
<br>Amazon Bedrock [Marketplace](https://git.xhkjedu.com) provides you access to over 100 popular, emerging, and [specialized structure](https://www.genbecle.com) models (FMs) through Amazon Bedrock. To gain access to DeepSeek-R1 in Amazon Bedrock, total the following actions:<br>
<br>1. On the Amazon Bedrock console, select Model catalog under Foundation designs in the navigation pane.
At the time of composing this post, you can utilize the [InvokeModel API](https://voyostars.com) to invoke the design. It does not support Converse APIs and other Amazon Bedrock [tooling](https://git.antonshubin.com).
2. Filter for DeepSeek as a supplier and choose the DeepSeek-R1 model.<br>
<br>The model detail page offers essential details about the design's abilities, pricing structure, and application guidelines. You can discover detailed use instructions, [consisting](http://128.199.175.1529000) of [sample API](http://www.hanmacsamsung.com) calls and code snippets for combination. The design supports different text generation tasks, including content creation, code generation, and [wiki.dulovic.tech](https://wiki.dulovic.tech/index.php/User:EdithJoseph92) concern answering, utilizing its support discovering optimization and CoT thinking capabilities.
The page likewise includes deployment options and licensing details to assist you get started with DeepSeek-R1 in your applications.
3. To start using DeepSeek-R1, select Deploy.<br>
<br>You will be prompted to set up the release details for DeepSeek-R1. The design ID will be pre-populated.
4. For Endpoint name, go into an endpoint name (between 1-50 alphanumeric characters).
5. For Number of instances, enter a number of instances (between 1-100).
6. For [Instance](http://180.76.133.25316300) type, pick your instance type. For optimal efficiency with DeepSeek-R1, a GPU-based circumstances type like ml.p5e.48 xlarge is advised.
Optionally, you can configure advanced security and facilities settings, including virtual private cloud (VPC) networking, consents, and file encryption settings. For a lot of use cases, the default settings will work well. However, for production deployments, [systemcheck-wiki.de](https://systemcheck-wiki.de/index.php?title=Benutzer:ETJXiomara) you may desire to [examine](http://www.sa1235.com) these settings to line up with your organization's security and compliance requirements.
7. Choose Deploy to begin using the model.<br>
<br>When the deployment is complete, you can check DeepSeek-R1's capabilities straight in the Amazon Bedrock playground.
8. Choose Open in play ground to access an interactive user interface where you can explore different prompts and adjust design parameters like temperature level and optimum length.
When using R1 with Bedrock's InvokeModel and Playground Console, use DeepSeek's chat design template for optimum results. For example, content for inference.<br>
<br>This is an excellent method to explore the design's thinking and text generation capabilities before integrating it into your applications. The play area supplies instant feedback, assisting you comprehend how the [design reacts](https://findspkjob.com) to various inputs and letting you tweak your prompts for optimum results.<br>
<br>You can rapidly test the model in the play ground through the UI. However, to invoke the released design programmatically with any Amazon Bedrock APIs, you require to get the endpoint ARN.<br>
<br>Run reasoning utilizing guardrails with the deployed DeepSeek-R1 endpoint<br>
<br>The following code example demonstrates how to perform inference using a released DeepSeek-R1 design through Amazon Bedrock utilizing the invoke_model and ApplyGuardrail API. You can develop a [guardrail](http://45.45.238.983000) using the [Amazon Bedrock](http://182.92.163.1983000) console or the API. For the example code to produce the guardrail, see the GitHub repo. After you have actually developed the guardrail, utilize the following code to [execute guardrails](http://121.40.234.1308899). The script initializes the bedrock_runtime client, configures reasoning criteria, and sends out a demand to generate text based on a user prompt.<br>
<br>Deploy DeepSeek-R1 with SageMaker 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 just a few clicks. With SageMaker JumpStart, you can tailor pre-trained models to your usage 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 two practical methods: using the intuitive SageMaker JumpStart UI or carrying out programmatically through the SageMaker Python SDK. Let's explore both approaches to assist you pick the technique that finest matches your requirements.<br>
<br>Deploy DeepSeek-R1 through SageMaker JumpStart UI<br>
<br>Complete the following actions to release DeepSeek-R1 using SageMaker JumpStart:<br>
<br>1. On the SageMaker console, choose Studio in the navigation pane.
2. First-time users will be prompted to create a domain.
3. On the SageMaker Studio console, pick JumpStart in the [navigation pane](http://112.74.93.6622234).<br>
<br>The model internet browser shows available models, with details like the company name and model abilities.<br>
<br>4. Look for DeepSeek-R1 to see the DeepSeek-R1 model card.
Each design card reveals key details, consisting of:<br>
<br>- Model name
- Provider name
- Task category (for instance, Text Generation).
Bedrock Ready badge (if appropriate), suggesting that this design can be registered with Amazon Bedrock, [it-viking.ch](http://it-viking.ch/index.php/User:Carmel1395) permitting you to use Amazon Bedrock APIs to conjure up the design<br>
<br>5. Choose the model card to view the design details page.<br>
<br>The design details page includes the following details:<br>
<br>- The model name and service provider details.
Deploy button to deploy the design.
About and Notebooks tabs with detailed details<br>
<br>The About tab includes essential details, such as:<br>
<br>- Model description.
- License details.
- Technical specifications.
- Usage standards<br>
<br>Before you deploy the model, it's suggested to review the model details and license terms to confirm compatibility with your use case.<br>
<br>6. Choose Deploy to proceed with implementation.<br>
<br>7. For Endpoint name, utilize the automatically produced name or develop a custom-made one.
8. For example type ¸ pick an instance type (default: ml.p5e.48 xlarge).
9. For Initial circumstances count, go into the number of circumstances (default: 1).
Selecting appropriate circumstances types and counts is crucial for cost and efficiency optimization. Monitor your implementation 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 remains in location.
11. Choose Deploy to release the design.<br>
<br>The release procedure can take numerous minutes to complete.<br>
<br>When release is complete, your endpoint status will alter to InService. At this point, the model is all set to accept reasoning demands through the endpoint. You can keep track of the release development on the SageMaker console Endpoints page, which will display relevant metrics and status details. When the release is total, you can conjure up the design utilizing a SageMaker runtime customer and incorporate it with your applications.<br>
<br>Deploy DeepSeek-R1 utilizing the SageMaker Python SDK<br>
<br>To get going with DeepSeek-R1 using the SageMaker Python SDK, you will need to install the SageMaker Python SDK and make certain you have the necessary AWS authorizations and environment setup. The following is a detailed code example that shows how to release and utilize DeepSeek-R1 for reasoning programmatically. The code for deploying the model is supplied in the Github here. You can clone the note pad and range from SageMaker Studio.<br>
<br>You can run additional demands against the predictor:<br>
<br>Implement guardrails and run reasoning with your SageMaker JumpStart predictor<br>
<br>Similar to Amazon Bedrock, you can likewise utilize the ApplyGuardrail API with your SageMaker JumpStart predictor. You can produce a guardrail utilizing the Amazon Bedrock console or the API, and [execute](http://git.morpheu5.net) it as displayed in the following code:<br>
<br>Clean up<br>
<br>To avoid undesirable charges, finish the actions in this section to tidy up your resources.<br>
<br>Delete the Amazon Bedrock Marketplace deployment<br>
<br>If you deployed the model using Amazon Bedrock Marketplace, complete the following steps:<br>
<br>1. On the Amazon Bedrock console, under Foundation designs in the navigation pane, pick Marketplace releases.
2. In the Managed releases section, find the endpoint you want to delete.
3. Select the endpoint, and on the Actions menu, pick Delete.
4. Verify the endpoint details to make certain you're deleting the proper implementation: 1. Endpoint name.
2. Model name.
3. Endpoint status<br>
<br>Delete the SageMaker JumpStart predictor<br>
<br>The SageMaker JumpStart design you released 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.<br>
<br>Conclusion<br>
<br>In this post, we checked out how you can access and deploy the DeepSeek-R1 design utilizing Bedrock Marketplace and SageMaker JumpStart. Visit SageMaker JumpStart in SageMaker Studio or Amazon Bedrock Marketplace now to begin. 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.<br>
<br>About the Authors<br>
<br>Vivek Gangasani is a Lead Specialist Solutions Architect for Inference at AWS. He helps emerging generative [AI](https://snapfyn.com) business develop ingenious solutions using AWS services and sped up compute. Currently, he is concentrated on establishing strategies for fine-tuning and optimizing the reasoning performance of big [language models](http://116.198.224.1521227). In his spare time, Vivek delights in hiking, watching films, and attempting different cuisines.<br>
<br>[Niithiyn Vijeaswaran](https://freelancejobsbd.com) is a Generative [AI](https://git.kansk-tc.ru) [Specialist Solutions](http://mohankrishnareddy.com) Architect with the Third-Party Model Science group at AWS. His area of focus is AWS [AI](https://coopervigrj.com.br) [accelerators](http://121.40.81.1163000) (AWS Neuron). He holds a Bachelor's degree in Computer technology and Bioinformatics.<br>
<br>Jonathan Evans is a Specialist Solutions Architect dealing with generative [AI](https://earlyyearsjob.com) with the Third-Party Model Science group at AWS.<br>
<br>[Banu Nagasundaram](https://saga.iao.ru3043) leads product, engineering, and strategic partnerships for Amazon SageMaker JumpStart, SageMaker's artificial intelligence and [generative](https://git.tedxiong.com) [AI](https://gitea.lolumi.com) hub. She is enthusiastic about building options that help consumers [accelerate](https://video.propounded.com) their [AI](https://www.greenpage.kr) journey and unlock organization value.<br>