Working with Amazon CodeWhisperer by using AWS Cloud9

更新 發佈閱讀 5 分鐘


What is CodeWhisperer?

Amazon CodeWhisperer is a machine learning service that improves developer productivity by generating code suggestions based on their natural language comments and code in their IDE.

CodeWhisperer supports programming languages such as Java, JavaScript, Python, C#, and TypeScript, and also supports code generation for Ruby, Go, PHP, C++, C, Shell, Scala, Rust, Kotlin, and SQL. The service integrates with several integrated development environments (IDEs), including JetBrains (IntelliJ, PyCharm, WebStorm, and Rider), Visual Studio Code, AWS Cloud9, and AWS Lambda Console.


Setting up


AWS IAM CodeWhisperer permissions for AWS Cloud9

{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "CodeWhispererPermissions",
"Effect": "Allow",
"Action": ["codewhisperer:GenerateRecommendations"],
"Resource": "*"
}
]
}


Activating Amazon CodeWhisperer with AWS Cloud9

From inside your existing AWS Cloud9 environment, choose the AWS logo on the left edge of the window. A panel will expand rightward.

vocus|新世代的創作平台

In the lower part of the panel, under Developer tools, open the CodeWhisperer dropdown.

vocus|新世代的創作平台

Choose Enable CodeWhisperer.


Enter your description :# add two numbers in the python

vocus|新世代的創作平台

It will give you tips on what to do.

vocus|新世代的創作平台
vocus|新世代的創作平台

Bubble Sort

vocus|新世代的創作平台


All in all, CodeWhisperer is a powerful AI coding companion that helps developers build applications faster and more securely.


Security scans

CodeWhisperer offers a valuable Security Scan feature for your project files. It enhances application resilience by identifying security concerns like cross-site scripting vulnerabilities, log injections, weak file permissions, and hardcoded credentials. This security scan seamlessly integrates with CodeGuru, which applies multiple layers of filtering to prioritize critical issues. CodeGuru filters unsupported languages and conducts preliminary code testing, even for open source code, before initiating security scans.

vocus|新世代的創作平台


Next article Using Amazon CodeGuru Security to find out if code is vulnerable


Reference

https://aws.amazon.com/tw/codewhisperer/

https://docs.aws.amazon.com/codewhisperer/latest/userguide/cloud9-setup.html

留言
avatar-img
西尼亞ming的沙龍
16會員
80內容數
西尼亞ming的沙龍的其他內容
2024/11/05
在ops-agent當中可以安裝 JVM 來收集 Java 參數,該工具主要收集 memory 以及 garbage collection 的參數,其中監控的選項有包含以下: jvm.classes.loaded jvm.gc.collections.count jvm.gc.collec
2024/11/05
在ops-agent當中可以安裝 JVM 來收集 Java 參數,該工具主要收集 memory 以及 garbage collection 的參數,其中監控的選項有包含以下: jvm.classes.loaded jvm.gc.collections.count jvm.gc.collec
2024/11/05
**Google Cloud 操作與 Audit Logs 說明** Google Cloud 作為純雲端服務提供商,所有操作均透過 HTTPS 網頁或 API 呼叫完成,並無「登入專案」的行為紀錄。不過,若使用 Google Workspace 管理使用者身份,則可以透過 Google
2024/11/05
**Google Cloud 操作與 Audit Logs 說明** Google Cloud 作為純雲端服務提供商,所有操作均透過 HTTPS 網頁或 API 呼叫完成,並無「登入專案」的行為紀錄。不過,若使用 Google Workspace 管理使用者身份,則可以透過 Google
2024/11/05
使用 Storage Transfer 服務是否能降低成本? Storage Transfer 的計價方式針對從 Cloud Storage 轉移至 Cloud Storage,除了一般費用外,Storage 移轉服務會使用 Cloud Storage rewrite 作業在 Cloud
2024/11/05
使用 Storage Transfer 服務是否能降低成本? Storage Transfer 的計價方式針對從 Cloud Storage 轉移至 Cloud Storage,除了一般費用外,Storage 移轉服務會使用 Cloud Storage rewrite 作業在 Cloud
看更多
你可能也想看
Thumbnail
背景:從冷門配角到市場主線,算力與電力被重新定價   小P從2008進入股市,每一個時期的投資亮點都不同,記得2009蘋果手機剛上市,當時蘋果只要在媒體上提到哪一間供應鏈,隔天股價就有驚人的表現,當時光學鏡頭非常熱門,因為手機第一次搭上鏡頭可以拍照,也造就傳統相機廠的殞落,如今手機已經全面普及,題
Thumbnail
背景:從冷門配角到市場主線,算力與電力被重新定價   小P從2008進入股市,每一個時期的投資亮點都不同,記得2009蘋果手機剛上市,當時蘋果只要在媒體上提到哪一間供應鏈,隔天股價就有驚人的表現,當時光學鏡頭非常熱門,因為手機第一次搭上鏡頭可以拍照,也造就傳統相機廠的殞落,如今手機已經全面普及,題
Thumbnail
What is CodeWhisperer? Amazon CodeWhisperer is a machine learning service that improves developer productivity by generating code suggestions based
Thumbnail
What is CodeWhisperer? Amazon CodeWhisperer is a machine learning service that improves developer productivity by generating code suggestions based
Thumbnail
在開始前,請先至 GitHub 上 Clone 相關資源到環境裡。 $ git clone https://github.com/ml-explore/mlx-examples.git 完成後,進入資料夾 $ cd ./mlx-examples/whisper​ 裡面有以下資源: # wh
Thumbnail
在開始前,請先至 GitHub 上 Clone 相關資源到環境裡。 $ git clone https://github.com/ml-explore/mlx-examples.git 完成後,進入資料夾 $ cd ./mlx-examples/whisper​ 裡面有以下資源: # wh
Thumbnail
《轉轉生》(Re:INCARNATION)為奈及利亞編舞家庫德斯.奧尼奎庫與 Q 舞團創作的當代舞蹈作品,結合拉各斯街頭節奏、Afrobeat/Afrobeats、以及約魯巴宇宙觀的非線性時間,建構出關於輪迴的「誕生—死亡—重生」儀式結構。本文將從約魯巴哲學概念出發,解析其去殖民的身體政治。
Thumbnail
《轉轉生》(Re:INCARNATION)為奈及利亞編舞家庫德斯.奧尼奎庫與 Q 舞團創作的當代舞蹈作品,結合拉各斯街頭節奏、Afrobeat/Afrobeats、以及約魯巴宇宙觀的非線性時間,建構出關於輪迴的「誕生—死亡—重生」儀式結構。本文將從約魯巴哲學概念出發,解析其去殖民的身體政治。
Thumbnail
對 AWS Certified Cloud Practitioner 證照考試難度的看法、學習方法和考試內容的介紹。
Thumbnail
對 AWS Certified Cloud Practitioner 證照考試難度的看法、學習方法和考試內容的介紹。
Thumbnail
從 JavaScript 到 Python
Thumbnail
從 JavaScript 到 Python
Thumbnail
這是一場修復文化與重建精神的儀式,觀眾不需要完全看懂《遊林驚夢:巧遇Hagay》,但你能感受心與土地團聚的渴望,也不急著在此處釐清或定義什麼,但你的在場感受,就是一條線索,關於如何找著自己的路徑、自己的聲音。
Thumbnail
這是一場修復文化與重建精神的儀式,觀眾不需要完全看懂《遊林驚夢:巧遇Hagay》,但你能感受心與土地團聚的渴望,也不急著在此處釐清或定義什麼,但你的在場感受,就是一條線索,關於如何找著自己的路徑、自己的聲音。
Thumbnail
本文分析導演巴里・柯斯基(Barrie Kosky)如何運用極簡的舞臺配置,將布萊希特(Bertolt Brecht)的「疏離效果」轉化為視覺奇觀與黑色幽默,探討《三便士歌劇》在當代劇場中的新詮釋,並藉由舞臺、燈光、服裝、音樂等多方面,分析該作如何在保留批判核心的同時,觸及觀眾的觀看位置與人性幽微。
Thumbnail
本文分析導演巴里・柯斯基(Barrie Kosky)如何運用極簡的舞臺配置,將布萊希特(Bertolt Brecht)的「疏離效果」轉化為視覺奇觀與黑色幽默,探討《三便士歌劇》在當代劇場中的新詮釋,並藉由舞臺、燈光、服裝、音樂等多方面,分析該作如何在保留批判核心的同時,觸及觀眾的觀看位置與人性幽微。
Thumbnail
該服務透過記錄在AWS控制台上執行的操作並產生範例程式碼來實現 Infrastructure as Code (IaC) 目前僅在 us-east-1 的 EC2 控制台上可用 支援的格式: CDK(Java) CDK(Python) CDK(TypeScript) CloudFor
Thumbnail
該服務透過記錄在AWS控制台上執行的操作並產生範例程式碼來實現 Infrastructure as Code (IaC) 目前僅在 us-east-1 的 EC2 控制台上可用 支援的格式: CDK(Java) CDK(Python) CDK(TypeScript) CloudFor
Thumbnail
最近看到一些網路教學AWS S3可以部署靜態網頁,就想說那不如試試看將local swagger部署上去,之後還可以透過github action 自動部署swagger到s3上,於是花點時間看個影片並搭配chatgpt來實現
Thumbnail
最近看到一些網路教學AWS S3可以部署靜態網頁,就想說那不如試試看將local swagger部署上去,之後還可以透過github action 自動部署swagger到s3上,於是花點時間看個影片並搭配chatgpt來實現
Thumbnail
在沒有分環境之前,每一隻lambda只有一個code console給所有人一起編輯,開發好了就deploy,根據設定的trigger觸發執行。 現在我們希望能夠在code console開發,然後deploy到不同的stage,目標是不同stage的api gateway能夠調用該lambda的
Thumbnail
在沒有分環境之前,每一隻lambda只有一個code console給所有人一起編輯,開發好了就deploy,根據設定的trigger觸發執行。 現在我們希望能夠在code console開發,然後deploy到不同的stage,目標是不同stage的api gateway能夠調用該lambda的
Thumbnail
In the previous post, I tried it immediately from the Bedrock console. This time, I tried to use Bedrock from the programme, not from the console.
Thumbnail
In the previous post, I tried it immediately from the Bedrock console. This time, I tried to use Bedrock from the programme, not from the console.
追蹤感興趣的內容從 Google News 追蹤更多 vocus 的最新精選內容追蹤 Google News