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

Elliot Swader 2025-02-21 01:57:50 +00:00
commit ea97b56cb7
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 models](https://socialeconomy4ces-wiki.auth.gr) are available through Amazon Bedrock Marketplace and Amazon SageMaker JumpStart. With this launch, you can now deploy DeepSeek [AI](http://vts-maritime.com)'s first-generation frontier model, DeepSeek-R1, together with the distilled variations varying from 1.5 to 70 billion criteria to construct, experiment, and responsibly scale your [generative](http://39.105.129.2293000) [AI](https://www.ubom.com) ideas on AWS.<br>
<br>In this post, we show how to get started with DeepSeek-R1 on Amazon Bedrock Marketplace and SageMaker JumpStart. You can follow comparable actions to deploy the distilled versions of the models also.<br>
<br>Overview of DeepSeek-R1<br>
<br>DeepSeek-R1 is a big language design (LLM) established by DeepSeek [AI](https://yeetube.com) that utilizes reinforcement discovering to enhance thinking abilities through a [multi-stage training](http://117.72.39.1253000) process from a DeepSeek-V3-Base foundation. A key distinguishing feature is its support learning (RL) step, which was used to fine-tune the model's reactions beyond the standard pre-training and tweak process. By incorporating RL, DeepSeek-R1 can adjust better to user feedback and goals, ultimately improving both significance and clearness. In addition, DeepSeek-R1 employs a chain-of-thought (CoT) method, indicating it's geared up to break down complicated inquiries and reason through them in a detailed manner. This assisted thinking procedure allows the design to produce more precise, transparent, and detailed responses. This model combines RL-based fine-tuning with CoT capabilities, aiming to create structured reactions while focusing on interpretability and user interaction. With its comprehensive abilities DeepSeek-R1 has actually captured the industry's attention as a versatile [text-generation model](https://recrutevite.com) that can be integrated into numerous workflows such as agents, sensible thinking and data analysis tasks.<br>
<br>DeepSeek-R1 uses a Mix of Experts (MoE) architecture and is 671 billion parameters in size. The MoE architecture permits activation of 37 billion specifications, enabling efficient inference by routing questions to the most pertinent expert "clusters." This technique allows the design to specialize in various [issue domains](https://www.runsimon.com) while maintaining overall effectiveness. DeepSeek-R1 requires a minimum of 800 GB of in FP8 format for [hb9lc.org](https://www.hb9lc.org/wiki/index.php/User:KathieMate327) reasoning. In this post, we will utilize an ml.p5e.48 xlarge circumstances to release the design. ml.p5e.48 xlarge includes 8 Nvidia H200 [GPUs providing](http://csserver.tanyu.mobi19002) 1128 GB of GPU memory.<br>
<br>DeepSeek-R1 distilled designs bring the thinking abilities of the main R1 design to more efficient 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, more effective models to [imitate](https://tjoobloom.com) the behavior and reasoning patterns of the larger DeepSeek-R1 design, using it as a teacher model.<br>
<br>You can deploy 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 place. In this blog, we will utilize Amazon Bedrock Guardrails to present safeguards, avoid damaging content, and evaluate models against key security requirements. At the time of composing this blog site, for DeepSeek-R1 deployments on SageMaker JumpStart and Bedrock Marketplace, Bedrock Guardrails supports just the ApplyGuardrail API. You can [produce](https://tj.kbsu.ru) multiple guardrails tailored to various use cases and use them to the DeepSeek-R1 design, enhancing user experiences and standardizing security controls across your generative [AI](https://git.tissue.works) applications.<br>
<br>Prerequisites<br>
<br>To deploy the DeepSeek-R1 model, you require access to an ml.p5e circumstances. To check if you have quotas for P5e, open the Service Quotas console and under AWS Services, choose 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](https://kaymack.careers) in the AWS Region you are deploying. To ask for a limitation boost, produce a limit increase request 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) approvals to use Amazon Bedrock Guardrails. For instructions, see Establish approvals to use guardrails for content filtering.<br>
<br>Implementing guardrails with the ApplyGuardrail API<br>
<br>Amazon Bedrock Guardrails enables you to introduce safeguards, prevent harmful material, and evaluate designs against key safety criteria. You can implement precaution for the DeepSeek-R1 design using the Amazon Bedrock [ApplyGuardrail](https://gitlab.ui.ac.id) API. This enables you to apply guardrails to evaluate user inputs and model 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 create the guardrail, see the GitHub repo.<br>
<br>The general flow includes the following actions: First, the system gets an input for the design. 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 design's output, another guardrail check is used. If the output passes this final check, it's returned as the result. However, if either the input or output is intervened 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 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 to DeepSeek-R1 in Amazon Bedrock, complete the following steps:<br>
<br>1. On the Amazon Bedrock console, choose Model brochure under Foundation designs in the navigation pane.
At the time of writing this post, you can utilize the InvokeModel API to invoke the design. It doesn't support Converse APIs and other Amazon Bedrock tooling.
2. Filter for DeepSeek as a provider and select the DeepSeek-R1 model.<br>
<br>The design detail page provides vital details about the design's capabilities, prices structure, and application standards. You can find detailed use instructions, including sample API calls and code bits for combination. The model supports numerous text generation jobs, including material production, [disgaeawiki.info](https://disgaeawiki.info/index.php/User:EvangelineSingle) code generation, and concern answering, using its reinforcement finding out optimization and [CoT reasoning](https://gitlab-mirror.scale.sc) capabilities.
The page also consists of release alternatives and licensing details to help you get started with DeepSeek-R1 in your applications.
3. To begin utilizing 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 (in between 1-50 alphanumeric characters).
5. For Variety of circumstances, go into a number of circumstances (between 1-100).
6. For example type, select your circumstances type. For ideal [performance](https://aladin.tube) with DeepSeek-R1, a GPU-based circumstances type like ml.p5e.48 xlarge is suggested.
Optionally, you can configure innovative security and infrastructure settings, consisting of virtual private cloud (VPC) networking, service role consents, and file encryption [settings](https://cphallconstlts.com). For many use cases, the default settings will work well. However, for production releases, you may want to evaluate these settings to align with your company's security and compliance requirements.
7. Choose Deploy to start using the design.<br>
<br>When the implementation is total, you can check DeepSeek-R1's abilities straight in the Amazon Bedrock playground.
8. Choose Open in playground to access an interactive user interface where you can experiment with different prompts and adjust model specifications like temperature and maximum 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 exceptional way to check out the model's thinking and text generation abilities before integrating it into your applications. The playground offers immediate feedback, assisting you comprehend how the design reacts to various inputs and [letting](https://kronfeldgit.org) you tweak your triggers for optimum outcomes.<br>
<br>You can rapidly test the model in the play ground through the UI. However, to invoke the deployed design programmatically with any Amazon Bedrock APIs, you need to get the endpoint ARN.<br>
<br>Run inference using guardrails with the deployed DeepSeek-R1 endpoint<br>
<br>The following code example shows how to perform inference using a deployed DeepSeek-R1 model through Amazon Bedrock using the invoke_model and ApplyGuardrail API. 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. After you have created the guardrail, [setiathome.berkeley.edu](https://setiathome.berkeley.edu/view_profile.php?userid=11857434) utilize the following code to carry out [guardrails](https://careers.jabenefits.com). The script initializes the bedrock_[runtime](https://www.vadio.com) customer, sets up reasoning criteria, and sends a request to produce text based on a user timely.<br>
<br>Deploy DeepSeek-R1 with SageMaker JumpStart<br>
<br>SageMaker JumpStart is an artificial intelligence (ML) hub with FMs, integrated algorithms, and prebuilt ML services that you can release with simply a couple of clicks. With SageMaker JumpStart, you can tailor pre-trained designs to your usage case, with your information, and release them into production using either the UI or SDK.<br>
<br>Deploying DeepSeek-R1 design through SageMaker JumpStart offers two convenient techniques: utilizing the user-friendly SageMaker JumpStart UI or implementing programmatically through the SageMaker Python SDK. Let's check out both approaches to help you select the technique that finest matches your needs.<br>
<br>Deploy DeepSeek-R1 through [SageMaker JumpStart](https://site4people.com) UI<br>
<br>Complete the following steps to release DeepSeek-R1 utilizing SageMaker JumpStart:<br>
<br>1. On the SageMaker console, select Studio in the navigation pane.
2. First-time users will be prompted to develop a domain.
3. On the SageMaker Studio console, choose JumpStart in the navigation pane.<br>
<br>The design browser shows available designs, with details like the service provider name and design abilities.<br>
<br>4. Look for DeepSeek-R1 to view the DeepSeek-R1 design card.
Each model card reveals essential details, including:<br>
<br>- Model name
- Provider name
- Task classification (for example, Text Generation).
[Bedrock Ready](http://123.56.193.1823000) badge (if appropriate), indicating that this model can be signed up with Amazon Bedrock, allowing you to utilize Amazon Bedrock APIs to invoke the model<br>
<br>5. Choose the model card to see the design details page.<br>
<br>The design details page consists of the following details:<br>
<br>- The model name and [higgledy-piggledy.xyz](https://higgledy-piggledy.xyz/index.php/User:AlanaConnah86) provider details.
Deploy button to release the design.
About and Notebooks tabs with detailed details<br>
<br>The About tab includes important 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 confirm compatibility with your use case.<br>
<br>6. Choose Deploy to continue with implementation.<br>
<br>7. For Endpoint name, use the instantly produced name or create a customized one.
8. For example type ¸ choose a circumstances type (default: ml.p5e.48 xlarge).
9. For Initial circumstances count, get in the number of circumstances (default: 1).
Selecting suitable instance types and counts is important for expense and performance optimization. Monitor your implementation to adjust these settings as needed.Under Inference type, Real-time reasoning is picked by default. This is enhanced for sustained traffic and low [latency](https://fydate.com).
10. Review all setups for accuracy. For this design, we strongly advise adhering to [SageMaker](http://190.117.85.588095) JumpStart default settings and making certain that network seclusion remains in location.
11. Choose Deploy to release the design.<br>
<br>The implementation procedure can take a number of minutes to finish.<br>
<br>When release is complete, your endpoint status will change to InService. At this point, the model is all set to accept inference demands through the endpoint. You can keep an eye on the [implementation progress](http://git.edazone.cn) on the SageMaker console Endpoints page, which will display relevant metrics and [status details](https://awaz.cc). When the deployment is total, you can conjure up the model using a SageMaker runtime client and incorporate it with your applications.<br>
<br>Deploy DeepSeek-R1 utilizing the SageMaker Python SDK<br>
<br>To get started 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 consents and environment setup. The following is a detailed code example that shows how to deploy and use DeepSeek-R1 for inference programmatically. The code for [releasing](http://git.meloinfo.com) the model is supplied in the Github here. You can clone the note pad and range from SageMaker Studio.<br>
<br>You can run extra requests against the predictor:<br>
<br>Implement guardrails and run inference 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 develop a guardrail utilizing the Amazon Bedrock console or the API, and implement it as shown in the following code:<br>
<br>Tidy up<br>
<br>To avoid unwanted charges, complete the steps in this section to tidy up your resources.<br>
<br>Delete the Amazon Bedrock Marketplace deployment<br>
<br>If you deployed the design utilizing Amazon Bedrock Marketplace, complete the following steps:<br>
<br>1. On the Amazon Bedrock console, under Foundation designs in the navigation pane, select Marketplace implementations.
2. In the Managed deployments section, locate the endpoint you desire to delete.
3. Select the endpoint, and on the Actions menu, choose Delete.
4. Verify the endpoint details to make certain you're deleting the correct deployment: 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 erase 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 utilizing Bedrock Marketplace and SageMaker JumpStart. Visit SageMaker JumpStart in SageMaker Studio or Amazon [Bedrock Marketplace](http://oj.algorithmnote.cn3000) now to get going. For more details, refer to Use Amazon Bedrock tooling with Amazon SageMaker JumpStart models, SageMaker JumpStart pretrained models, Amazon SageMaker JumpStart Foundation Models, Amazon Bedrock Marketplace, and Beginning with Amazon SageMaker JumpStart.<br>
<br>About the Authors<br>
<br>Vivek Gangasani is a Lead Specialist Solutions Architect for Inference at AWS. He assists emerging generative [AI](https://agapeplus.sg) companies build innovative solutions utilizing AWS services and [accelerated](https://proputube.com) calculate. Currently, he is concentrated on developing methods for fine-tuning and optimizing the reasoning performance of big language models. In his complimentary time, Vivek enjoys treking, enjoying motion pictures, and trying various foods.<br>
<br>Niithiyn Vijeaswaran is a [Generative](https://avpro.cc) [AI](http://ecoreal.kr) Specialist Solutions Architect with the Third-Party Model Science group at AWS. His area of focus is AWS [AI](https://git.teygaming.com) accelerators (AWS Neuron). He holds a Bachelor's degree in Computer Science and Bioinformatics.<br>
<br>Jonathan Evans is a Specialist Solutions Architect dealing with generative [AI](https://gitlab.kitware.com) with the Third-Party Model [Science](https://knightcomputers.biz) group at AWS.<br>
<br>Banu Nagasundaram leads item, engineering, and strategic partnerships for Amazon SageMaker JumpStart, SageMaker's artificial intelligence and generative [AI](https://niaskywalk.com) hub. She is [passionate](https://syndromez.ai) about building options that assist customers accelerate their [AI](https://172.105.135.218) journey and unlock organization value.<br>