亚洲乱码中文字幕综合,中国熟女仑乱hd,亚洲精品乱拍国产一区二区三区,一本大道卡一卡二卡三乱码全集资源,又粗又黄又硬又爽的免费视频

PyCharm 接入 DeepSeek最新完整教程

 更新時間:2025年02月15日 12:18:20   作者:大模型應(yīng)用  
文章介紹了DeepSeek-V3模型的性能提升以及如何在PyCharm中接入和使用DeepSeek進行代碼開發(fā),本文通過圖文并茂的形式給大家介紹的非常詳細,感興趣的朋友一起看看吧

DeepSeek-V3

DeepSeek-V3是一個擁有671B參數(shù)的MoE模型,吞吐量每秒達60 token,比上一代V2提升3倍;在數(shù)學(xué)代碼性能上,堪比國外大模型Claude 3.5 Sonnet。

接下來,我們把DeepSeek接入到PyCharm中,并利用其能力輔助我們進行代碼開發(fā)。

效果演示

首先來看一下效果。

我們可以直接選中代碼,并對代碼段進行解釋。

我們也可以通過選中代碼,對代碼進行修改。

創(chuàng)建API Key

首先進入DeepSeek官網(wǎng),官網(wǎng)鏈接如下

https://www.deepseek.com/

點擊API開放平臺:

點擊左側(cè)“API Keys”,點擊創(chuàng)建 API key,輸出名稱為“AI 代碼提示”,也可以使用其它自定義的名稱。

點擊“創(chuàng)建",一定要記錄此處的 API key,可以先將 API key 復(fù)制在其它地方。

在PyCharm中下載Continue插件

打開PyCharm,打開文件->設(shè)置->插件,搜索“Continue”,點擊安裝。

等待插件安裝完畢后,點擊“應(yīng)用”,插件安裝成功。

配置Continue

插件安裝成功后,在右側(cè)的標簽欄中,會顯示一個Continue的標簽,我們點擊即可進入,隨后點擊設(shè)置按鍵,如下圖。

點擊后,文本編輯區(qū)將會彈出配置文件。

我們對配置文件進行修改,將內(nèi)容替換為下面的內(nèi)容:

{`  `"completionOptions": {`    `"BaseCompletionOptions": {`        `"temperature": 0.0,`        `"maxTokens": 256`    `}`  `},`  `"models": [`    `{`      `"title": "DeepSeek",`      `"model": "deepseek-chat",`      `"contextLength": 128000,`      `"apiKey": "REDACTED",`      `"provider": "deepseek",`      `"apiBase": "https://api.deepseek.com/beta"`    `}`  `],`  `"tabAutocompleteModel": {`    `"title": "DeepSeek Coder",`    `"model": "deepseek-coder",`    `"apiKey": "REDACTED",`    `"provider": "deepseek",`    `"apiBase": "https://api.deepseek.com/beta"`  `},`  `"customCommands": [`    `{`      `"name": "test",`      `"prompt": "{`    `{`    `{ input }}}\n\nWrite a comprehensive set of unit tests for the selected code. It should setup, run tests that check for correctness including important edge cases, and teardown. Ensure that the tests are complete and sophisticated. Give the tests just as chat output, don't edit any file.",`      `"description": "Write unit tests for highlighted code"`    `}`  `],`  `"contextProviders": [`    `{`      `"name": "diff",`      `"params": {}`    `},`    `{`      `"name": "folder",`      `"params": {}`    `},`    `{`      `"name": "codebase",`      `"params": {}`    `}`  `],`  `"slashCommands": [`    `{`      `"name": "share",`      `"description": "Export the current chat session to markdown"`    `},`    `{`      `"name": "commit",`      `"description": "Generate a git commit message"`    `}`  `]``}

修改時將會彈出提示,點擊確定。

隨后,我們將兩處apiKey替換為先前保存的API key。

保存文件后,即可開始使用。

到此這篇關(guān)于PyCharm 接入 DeepSeek的文章就介紹到這了,更多相關(guān)PyCharm 接入 DeepSeek內(nèi)容請搜索腳本之家以前的文章或繼續(xù)瀏覽下面的相關(guān)文章希望大家以后多多支持腳本之家!

相關(guān)文章

最新評論