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

Sabine Pritt 2025-02-20 05:35:52 +08:00
commit 78f77d9d4b
1 changed files with 93 additions and 0 deletions

@ -0,0 +1,93 @@
<br>Today, we are excited to reveal 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](https://999vv.xyz)'s first-generation frontier design, DeepSeek-R1, along with the distilled variations ranging from 1.5 to 70 billion parameters to build, experiment, and properly scale your generative [AI](https://savico.com.br) 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 comparable 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 model (LLM) established by DeepSeek [AI](https://www.jobsalert.ai) that utilizes reinforcement finding out to enhance reasoning abilities through a multi-stage training procedure from a DeepSeek-V3-Base structure. An essential differentiating function is its [support knowing](https://oldgit.herzen.spb.ru) (RL) action, which was utilized to refine the design's responses beyond the standard pre-training and fine-tuning process. By [including](https://mp3talpykla.com) RL, DeepSeek-R1 can adjust better to user feedback and goals, ultimately improving both relevance and clearness. In addition, DeepSeek-R1 uses a chain-of-thought (CoT) approach, suggesting it's geared up to break down intricate inquiries and factor through them in a detailed way. This assisted reasoning process permits the model to produce more precise, transparent, and detailed answers. This design integrates RL-based fine-tuning with CoT abilities, aiming to generate structured actions while concentrating on interpretability and user interaction. With its wide-ranging abilities DeepSeek-R1 has caught the industry's attention as a versatile text-generation model that can be integrated into various workflows such as representatives, rational thinking and data analysis tasks.<br>
<br>DeepSeek-R1 [utilizes](http://8.211.134.2499000) a Mix of Experts (MoE) architecture and is 671 billion parameters in size. The MoE architecture allows activation of 37 billion parameters, enabling effective inference by routing inquiries to the most appropriate expert "clusters." This method permits the design to concentrate on various problem domains while [maintaining](http://101.34.211.1723000) general performance. DeepSeek-R1 needs a minimum of 800 GB of HBM memory in FP8 format for [hb9lc.org](https://www.hb9lc.org/wiki/index.php/User:DamionNobles) inference. In this post, we will use an ml.p5e.48 xlarge circumstances to deploy the model. ml.p5e.48 xlarge features 8 Nvidia H200 GPUs supplying 1128 GB of GPU memory.<br>
<br>DeepSeek-R1 distilled models bring the reasoning abilities of the main R1 design to more efficient architectures based upon 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 [efficient models](http://1.15.187.67) to imitate the habits and thinking patterns of the larger DeepSeek-R1 model, utilizing it as an instructor design.<br>
<br>You can deploy DeepSeek-R1 model either through SageMaker JumpStart or Bedrock Marketplace. Because DeepSeek-R1 is an emerging model, we suggest deploying this model with guardrails in location. In this blog site, we will use Amazon Bedrock Guardrails to present safeguards, avoid hazardous material, and [examine designs](https://git.bluestoneapps.com) against essential safety criteria. At the time of composing this blog, for DeepSeek-R1 releases on SageMaker JumpStart and Bedrock Marketplace, Bedrock Guardrails supports only the ApplyGuardrail API. You can develop several guardrails tailored to different use cases and use them to the DeepSeek-R1 model, improving user experiences and standardizing security controls throughout your generative [AI](https://edtech.wiki) 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, select Amazon SageMaker, and confirm 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 releasing. To request a limit boost, develop a limitation increase request and reach out to your account group.<br>
<br>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 use Amazon Bedrock Guardrails. For instructions, see Establish authorizations to utilize guardrails for content filtering.<br>
<br>Implementing guardrails with the ApplyGuardrail API<br>
<br>Amazon Bedrock Guardrails permits you to present safeguards, avoid [damaging](https://becalm.life) material, and evaluate models against key [safety criteria](https://weworkworldwide.com). You can execute security procedures for the DeepSeek-R1 [model utilizing](http://120.79.94.1223000) the Amazon Bedrock ApplyGuardrail API. This enables you to use guardrails to evaluate user inputs and design responses released on Amazon Bedrock Marketplace and SageMaker JumpStart. You can produce a guardrail using the Amazon Bedrock console or the API. For the example code to develop the guardrail, see the GitHub repo.<br>
<br>The basic flow involves the following steps: 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 to the design for reasoning. After receiving the design's output, another guardrail check is applied. If the output passes this last check, it's returned as the outcome. However, if either the input or [wiki.asexuality.org](https://wiki.asexuality.org/w/index.php?title=User_talk:AleishaWorkman7) output is intervened by the guardrail, a message is returned indicating the nature of the intervention and whether it took place 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 offers you access to over 100 popular, emerging, and specialized structure designs (FMs) through [Amazon Bedrock](https://gitea.easio-com.com). To gain access to DeepSeek-R1 in Amazon Bedrock, complete the following steps:<br>
<br>1. On the Amazon Bedrock console, select Model brochure under Foundation models in the navigation pane.
At the time of writing this post, you can utilize the InvokeModel API to invoke 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 model.<br>
<br>The design detail page provides important details about the model's abilities, pricing structure, and execution standards. You can discover detailed usage 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, utilizing its reinforcement discovering optimization and CoT thinking capabilities.
The page likewise consists of implementation choices and licensing details to help you start with DeepSeek-R1 in your applications.
3. To start utilizing DeepSeek-R1, choose Deploy.<br>
<br>You will be triggered to configure 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 Variety of instances, enter a number of circumstances (between 1-100).
6. For example type, [yewiki.org](https://www.yewiki.org/User:IMIKristin) pick your circumstances type. For optimum efficiency with DeepSeek-R1, a GPU-based circumstances type like ml.p5e.48 xlarge is recommended.
Optionally, you can set up sophisticated security and facilities settings, including virtual personal cloud (VPC) networking, service function authorizations, and file encryption settings. For most use cases, the default settings will work well. However, for [production](https://nextjobnepal.com) releases, you might desire to examine these settings to align with your organization's security and compliance [requirements](http://krzsyjtj.zlongame.co.kr9004).
7. Choose Deploy to start utilizing the model.<br>
<br>When the deployment is total, you can test DeepSeek-R1's abilities straight in the Amazon Bedrock playground.
8. Choose Open in play ground to access an interactive interface where you can try out different prompts and change design 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 to check out the design's reasoning and text generation abilities before incorporating it into your applications. The play area [supplies instant](http://121.40.234.1308899) feedback, helping you comprehend how the model reacts to various inputs and letting you tweak your triggers for ideal outcomes.<br>
<br>You can rapidly test the design in the playground 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 inference utilizing guardrails with the deployed DeepSeek-R1 endpoint<br>
<br>The following code example demonstrates how to carry out inference utilizing a released DeepSeek-R1 model through Amazon Bedrock using the invoke_model and ApplyGuardrail API. You can create a guardrail using the Amazon Bedrock [console](http://pplanb.co.kr) or the API. For the example code to create the guardrail, see the GitHub repo. After you have created the guardrail, use the following code to execute guardrails. The script initializes the bedrock_runtime customer, configures inference specifications, and sends a request to produce text based upon 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 [options](https://www.pkgovtjobz.site) that you can deploy with simply a few clicks. With SageMaker JumpStart, you can tailor pre-trained designs to your usage case, with your information, and deploy them into production utilizing either the UI or SDK.<br>
<br>Deploying DeepSeek-R1 design through SageMaker JumpStart provides two practical approaches: using the user-friendly SageMaker JumpStart UI or [executing programmatically](http://101.33.255.603000) through the SageMaker Python SDK. Let's check out both techniques to assist you pick the method that finest suits your requirements.<br>
<br>Deploy DeepSeek-R1 through SageMaker JumpStart UI<br>
<br>Complete the following steps to release DeepSeek-R1 utilizing 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 shows available designs, with details like the supplier name and design capabilities.<br>
<br>4. Search for DeepSeek-R1 to see the DeepSeek-R1 design card.
Each model card shows key details, consisting of:<br>
<br>- Model name
- Provider name
- Task category (for instance, [forum.altaycoins.com](http://forum.altaycoins.com/profile.php?id=1095873) Text Generation).
Bedrock Ready badge (if applicable), suggesting that this design can be signed up with Amazon Bedrock, allowing you to use Amazon Bedrock APIs to invoke the design<br>
<br>5. Choose the design card to see the model details page.<br>
<br>The model details page consists of the following details:<br>
<br>- The design name and provider details.
Deploy button to release the model.
About and Notebooks tabs with detailed details<br>
<br>The About tab consists of crucial details, such as:<br>
<br>- Model description.
- License details.
- Technical specifications.
- Usage standards<br>
<br>Before you [release](http://123.57.58.241) the design, it's suggested to [examine](http://modiyil.com) the model details and license terms to validate compatibility with your usage case.<br>
<br>6. Choose Deploy to proceed with release.<br>
<br>7. For Endpoint name, utilize the immediately generated name or develop a custom one.
8. For example type ¸ choose an instance type (default: ml.p5e.48 xlarge).
9. For Initial instance count, get in the number of instances (default: 1).
Selecting suitable instance types and counts is essential for expense and performance optimization. Monitor your deployment to adjust these settings as needed.Under Inference type, Real-time reasoning is selected by default. This is enhanced for sustained traffic and [low latency](https://men7ty.com).
10. Review all setups for accuracy. For this design, we highly recommend adhering to SageMaker JumpStart default settings and making certain that network seclusion remains in place.
11. Choose Deploy to deploy the design.<br>
<br>The implementation process can take several minutes to finish.<br>
<br>When release is total, your endpoint status will alter to InService. At this moment, the model is prepared to accept reasoning demands through the endpoint. You can keep an eye on the release progress on the SageMaker console Endpoints page, which will display relevant metrics and status details. When the release is total, you can invoke the design utilizing a SageMaker runtime customer and integrate it with your applications.<br>
<br>Deploy DeepSeek-R1 utilizing the SageMaker Python SDK<br>
<br>To begin with DeepSeek-R1 utilizing the SageMaker Python SDK, you will require 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 notebook and run from SageMaker Studio.<br>
<br>You can run additional demands against the predictor:<br>
<br>Implement guardrails and run inference with your SageMaker JumpStart predictor<br>
<br>Similar to Amazon Bedrock, you can also use the [ApplyGuardrail API](http://git.cxhy.cn) with your SageMaker JumpStart predictor. You can create a guardrail utilizing the Amazon Bedrock console or [wiki.snooze-hotelsoftware.de](https://wiki.snooze-hotelsoftware.de/index.php?title=Benutzer:DenishaHolyfield) the API, and implement it as shown in the following code:<br>
<br>Tidy up<br>
<br>To prevent unwanted charges, complete the steps in this section to clean up your resources.<br>
<br>Delete the Amazon Bedrock Marketplace release<br>
<br>If you released the model using Amazon Bedrock Marketplace, total the following actions:<br>
<br>1. On the Amazon Bedrock console, under Foundation designs in the navigation pane, select Marketplace implementations.
2. In the Managed releases area, find the endpoint you desire to delete.
3. Select the endpoint, and on the Actions menu, [choose Delete](https://githost.geometrx.com).
4. Verify the endpoint details to make certain you're erasing the proper release: 1. Endpoint name.
2. Model name.
3. Endpoint status<br>
<br>Delete the SageMaker JumpStart predictor<br>
<br>The SageMaker JumpStart model 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 design using Bedrock Marketplace and SageMaker JumpStart. Visit SageMaker JumpStart in SageMaker Studio or Amazon Bedrock Marketplace now to get going. For more details, refer to Use Amazon Bedrock tooling with Amazon SageMaker [JumpStart](https://www.sewosoft.de) models, SageMaker JumpStart pretrained designs, 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://video.chops.com) companies develop ingenious services utilizing AWS services and sped up compute. Currently, he is focused on establishing methods for fine-tuning and enhancing the inference performance of big language models. In his leisure time, Vivek takes pleasure in hiking, enjoying motion pictures, [it-viking.ch](http://it-viking.ch/index.php/User:EpifaniaHerron) and attempting various foods.<br>
<br>Niithiyn Vijeaswaran is a Generative [AI](https://git.bluestoneapps.com) Specialist Solutions Architect with the Third-Party Model Science team at AWS. His [location](https://supardating.com) of focus is AWS [AI](https://nemoserver.iict.bas.bg) accelerators (AWS Neuron). He holds a Bachelor's degree in Computer Science and Bioinformatics.<br>
<br>Jonathan Evans is an Expert Solutions Architect working on [generative](https://adventuredirty.com) [AI](https://callingirls.com) with the Third-Party Model Science team at AWS.<br>
<br>Banu Nagasundaram leads item, engineering, and strategic partnerships for [Amazon SageMaker](http://39.99.134.1658123) JumpStart, SageMaker's artificial intelligence and generative [AI](http://82.156.184.99:3000) hub. She is passionate about constructing solutions that assist consumers accelerate their [AI](https://grailinsurance.co.ke) journey and unlock company value.<br>