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

Felipa Lamington 2025-02-07 06:48:22 +08:00
commit e75cd93aa6
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](https://supremecarelink.com) Marketplace and Amazon SageMaker JumpStart. With this launch, you can now release DeepSeek [AI](http://files.mfactory.org)'s first-generation frontier design, DeepSeek-R1, along with the distilled [versions](https://vidhiveapp.com) [varying](https://asixmusik.com) from 1.5 to 70 billion parameters to construct, experiment, and responsibly scale your generative [AI](http://42.194.159.64:9981) ideas on AWS.<br>
<br>In this post, we show how to get going with DeepSeek-R1 on Amazon Bedrock Marketplace and SageMaker JumpStart. You can follow similar steps to release the distilled variations of the [designs](https://recruitment.transportknockout.com) also.<br>
<br>Overview of DeepSeek-R1<br>
<br>DeepSeek-R1 is a big language design (LLM) established by DeepSeek [AI](http://www.kotlinx.com:3000) that uses support learning to improve reasoning capabilities through a multi-stage training process from a DeepSeek-V3-Base foundation. A key identifying feature is its reinforcement learning (RL) step, which was used to fine-tune the model's responses beyond the standard pre-training and fine-tuning process. By including RL, DeepSeek-R1 can adapt better to user feedback and objectives, eventually boosting both relevance and clarity. In addition, DeepSeek-R1 utilizes a chain-of-thought (CoT) approach, [wiki.dulovic.tech](https://wiki.dulovic.tech/index.php/User:GLXKatrice) meaning it's equipped to break down complex queries and factor through them in a detailed way. This assisted thinking process permits the design to produce more accurate, transparent, and [hb9lc.org](https://www.hb9lc.org/wiki/index.php/User:KeithSpina077) detailed responses. This model integrates RL-based fine-tuning with CoT capabilities, aiming to [produce structured](https://git.esc-plus.com) actions while concentrating on interpretability and user interaction. With its comprehensive abilities DeepSeek-R1 has actually recorded the market's attention as a flexible text-generation design that can be incorporated into various workflows such as representatives, sensible thinking and information analysis jobs.<br>
<br>DeepSeek-R1 uses a Mixture of Experts (MoE) [architecture](http://social.redemaxxi.com.br) and is 671 billion criteria in size. The MoE architecture allows activation of 37 billion parameters, making it possible for effective inference by routing inquiries to the most [pertinent professional](http://copyvance.com) "clusters." This method enables the design to specialize in various issue domains while maintaining general [performance](https://media.motorsync.co.uk). 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 circumstances to release 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 thinking abilities of the main R1 model to more efficient architectures based upon popular open designs like Qwen (1.5 B, 7B, 14B, and 32B) and Llama (8B and 70B). Distillation describes a procedure of training smaller, more efficient designs to simulate the behavior and reasoning patterns of the bigger DeepSeek-R1 model, utilizing it as an instructor design.<br>
<br>You can release DeepSeek-R1 model either through SageMaker JumpStart or Bedrock Marketplace. Because DeepSeek-R1 is an emerging design, we advise deploying this design with guardrails in location. In this blog, we will utilize Amazon Bedrock Guardrails to introduce safeguards, prevent harmful material, and assess designs against essential security criteria. At the time of writing this blog, for DeepSeek-R1 deployments on SageMaker JumpStart and Bedrock Marketplace, Bedrock Guardrails supports only the ApplyGuardrail API. You can develop multiple 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](http://www.brightching.cn) applications.<br>
<br>Prerequisites<br>
<br>To deploy the DeepSeek-R1 design, you need 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 validate you're using 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 request a limitation increase, create a limit boost request and reach out to your account team.<br>
<br>Because you will be deploying this design with Amazon Bedrock Guardrails, make certain you have the correct [AWS Identity](https://gitea.bone6.com) and Gain Access To Management (IAM) permissions to use Amazon Bedrock Guardrails. For guidelines, see Establish permissions to utilize guardrails for material filtering.<br>
<br>Implementing guardrails with the ApplyGuardrail API<br>
<br>Amazon Bedrock Guardrails enables you to introduce safeguards, avoid damaging material, and evaluate models against crucial safety criteria. You can carry out precaution for the DeepSeek-R1 design using the Amazon Bedrock ApplyGuardrail API. This enables you to apply guardrails to assess user inputs and model reactions released on Amazon Bedrock Marketplace and SageMaker JumpStart. You can produce a guardrail utilizing the Amazon [Bedrock console](https://git.ombreport.info) or the API. For the example code to produce the guardrail, see the [GitHub repo](https://www.jjldaxuezhang.com).<br>
<br>The basic circulation includes the following steps: First, the system [receives](https://git.lewis.id) an input for the model. This input is then processed through the . If the input passes the guardrail check, it's sent to the model for [inference](https://git.brodin.rocks). 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](http://47.120.16.1378889) at the input or [pipewiki.org](https://pipewiki.org/wiki/index.php/User:IvyCano5125640) output stage. The examples showcased in the following areas demonstrate 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, [links.gtanet.com.br](https://links.gtanet.com.br/vernon471078) emerging, and specialized foundation 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, pick Model catalog under Foundation models in the navigation pane.
At the time of composing this post, you can use the [InvokeModel API](http://193.200.130.1863000) to invoke the design. It doesn't support Converse APIs and other Amazon Bedrock tooling.
2. Filter for DeepSeek as a [company](http://116.63.157.38418) and choose the DeepSeek-R1 design.<br>
<br>The model detail page supplies important details about the design's abilities, pricing structure, [genbecle.com](https://www.genbecle.com/index.php?title=Utilisateur:JulieBrower730) and implementation guidelines. You can discover [detailed usage](https://flixtube.info) guidelines, consisting of sample API calls and code bits for integration. The design supports different text generation tasks, consisting of material creation, code generation, and question answering, utilizing its reinforcement learning optimization and CoT thinking abilities.
The page likewise consists of implementation options and licensing details to assist you get going with DeepSeek-R1 in your applications.
3. To begin utilizing DeepSeek-R1, select Deploy.<br>
<br>You will be [prompted](https://consultoresdeproductividad.com) to configure the release details for DeepSeek-R1. The model ID will be pre-populated.
4. For Endpoint name, go into an endpoint name (in between 1-50 alphanumeric characters).
5. For Number of instances, enter a number of instances (between 1-100).
6. For Instance type, pick your instance type. For ideal efficiency with DeepSeek-R1, a [GPU-based instance](https://talentup.asia) type like ml.p5e.48 xlarge is suggested.
Optionally, you can configure innovative [security](https://git.penwing.org) and facilities settings, consisting of virtual personal cloud (VPC) networking, service role consents, and file encryption settings. For the majority of utilize cases, the default settings will work well. However, for production releases, you may desire to review these settings to align with your organization's security and compliance requirements.
7. Choose Deploy to start using the model.<br>
<br>When the implementation is total, you can evaluate DeepSeek-R1's capabilities straight in the Amazon Bedrock playground.
8. Choose Open in play area to access an interactive interface where you can explore different prompts and adjust design specifications like temperature and optimum length.
When utilizing R1 with Bedrock's InvokeModel and Playground Console, utilize DeepSeek's chat design template for optimal results. For instance, content for inference.<br>
<br>This is an excellent way to explore the design's reasoning and text generation capabilities before integrating it into your applications. The play ground provides instant feedback, helping you comprehend how the [design reacts](http://metis.lti.cs.cmu.edu8023) to various inputs and letting you tweak your triggers for ideal results.<br>
<br>You can rapidly test the design in the play ground through the UI. However, to invoke the released model programmatically with any Amazon Bedrock APIs, you require to get the endpoint ARN.<br>
<br>Run reasoning utilizing guardrails with the [released](http://plethe.com) DeepSeek-R1 endpoint<br>
<br>The following code example demonstrates how to carry out reasoning utilizing a deployed DeepSeek-R1 design through Amazon Bedrock utilizing the invoke_model and ApplyGuardrail API. You can produce a guardrail using the Amazon Bedrock console or the API. For the example code to produce the guardrail, see the GitHub repo. After you have produced the guardrail, utilize the following code to [implement guardrails](https://online-learning-initiative.org). The script initializes the bedrock_runtime client, configures reasoning specifications, and sends a request to [produce text](https://vmi528339.contaboserver.net) based upon a user timely.<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 services that you can [release](https://video.chops.com) with simply a couple of clicks. With SageMaker JumpStart, you can tailor pre-trained models to your use case, with your data, and release them into production utilizing either the UI or SDK.<br>
<br>Deploying DeepSeek-R1 model through SageMaker JumpStart uses 2 practical approaches: utilizing the user-friendly SageMaker JumpStart UI or carrying out programmatically through the SageMaker Python SDK. Let's explore both approaches to assist you pick the method that finest fits 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, 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 model web browser displays available models, with details like the provider name and model capabilities.<br>
<br>4. Look for DeepSeek-R1 to view the DeepSeek-R1 design card.
Each design card reveals crucial details, including:<br>
<br>- Model name
- Provider name
- Task category (for example, Text Generation).
Bedrock Ready badge (if suitable), indicating that this model can be signed up with Amazon Bedrock, permitting you to utilize Amazon Bedrock APIs to conjure up the model<br>
<br>5. Choose the design card to view the model details page.<br>
<br>The model details page [consists](http://www.jimtangyh.xyz7002) of the following details:<br>
<br>- The model name and service provider details.
Deploy button to release 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.
- Technical specifications.
- Usage standards<br>
<br>Before you release the design, it's recommended to evaluate the [model details](https://chosenflex.com) and license terms to validate compatibility with your use case.<br>
<br>6. Choose Deploy to proceed with deployment.<br>
<br>7. For Endpoint name, use the immediately produced name or develop a customized one.
8. For example type ¸ choose a circumstances type (default: ml.p5e.48 xlarge).
9. For Initial circumstances count, go into the variety of instances (default: 1).
Selecting suitable [circumstances](https://blessednewstv.com) types and counts is vital for expense and [efficiency optimization](https://cozwo.com). Monitor your [implementation](https://usa.life) to change these settings as needed.Under Inference type, Real-time inference is chosen by default. This is enhanced for sustained traffic and low latency.
10. Review all configurations for accuracy. For this model, we strongly recommend adhering to SageMaker JumpStart default settings and making certain that network isolation remains in location.
11. Choose Deploy to release the model.<br>
<br>The implementation process can take several minutes to finish.<br>
<br>When deployment is complete, your endpoint status will alter to InService. At this point, the design is prepared to accept inference [demands](https://gogs.k4be.pl) through the endpoint. You can keep track of the implementation development on the SageMaker [console Endpoints](https://gitea.fcliu.net) page, which will show relevant metrics and status details. When the deployment is complete, you can invoke the design using a SageMaker runtime client and incorporate it with your applications.<br>
<br>Deploy DeepSeek-R1 utilizing the SageMaker Python SDK<br>
<br>To begin with DeepSeek-R1 using the SageMaker Python SDK, you will require to install the SageMaker Python SDK and make certain you have the essential 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 the design is provided in the Github here. You can clone the note pad and range 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](http://git.dashitech.com). You can develop a guardrail utilizing the Amazon Bedrock console or the API, and implement it as displayed in the following code:<br>
<br>Tidy up<br>
<br>To avoid unwanted charges, complete the actions in this area to tidy up your resources.<br>
<br>Delete the Amazon Bedrock Marketplace release<br>
<br>If you released the design utilizing Amazon Bedrock Marketplace, total the following actions:<br>
<br>1. On the Amazon Bedrock console, under Foundation designs in the navigation pane, choose Marketplace releases.
2. In the Managed deployments area, locate the [endpoint](https://forsetelomr.online) you wish 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 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 released will sustain expenses if you leave it running. Use the following code to erase the endpoint if you want to stop sustaining charges. For more details, see Delete [Endpoints](https://git.profect.de) and Resources.<br>
<br>Conclusion<br>
<br>In this post, we checked out how you can access and release the DeepSeek-R1 design utilizing Bedrock Marketplace and SageMaker JumpStart. Visit SageMaker JumpStart in SageMaker Studio or Amazon Bedrock Marketplace now to start. For more details, refer to Use Amazon Bedrock tooling with Amazon SageMaker JumpStart models, [SageMaker JumpStart](https://saksa.co.za) 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://csmsound.exagopartners.com) [companies develop](http://120.196.85.1743000) innovative options utilizing AWS services and accelerated calculate. Currently, he is concentrated on developing methods for fine-tuning and optimizing the reasoning performance of big language designs. In his spare time, Vivek takes pleasure in hiking, watching movies, and attempting various foods.<br>
<br>Niithiyn Vijeaswaran is a Generative [AI](http://40.73.118.158) Specialist Solutions Architect with the Third-Party Model [Science](http://125.ps-lessons.ru) group at AWS. His area of focus is AWS [AI](http://git.hsgames.top:3000) accelerators (AWS Neuron). He holds a Bachelor's degree in Computer technology and Bioinformatics.<br>
<br>Jonathan Evans is a Professional Solutions Architect dealing with generative [AI](http://112.112.149.146:13000) with the Third-Party Model Science team at AWS.<br>
<br>Banu Nagasundaram leads product, engineering, and strategic partnerships for Amazon SageMaker JumpStart, SageMaker's artificial intelligence and generative [AI](https://voggisper.com) hub. She is passionate about developing solutions that help customers accelerate their [AI](https://195.216.35.156) journey and unlock service value.<br>