
- Amazon Q Business - Workflow
- Amazon Q Business - Key Concepts
- Amazon Q Business - Subscription Tiers & Index Types
- Amazon Q Business - Service Quotas
- Amazon Q Business - Document Attributes
- Amazon Q Business - Setup
- Amazon Q Business - Identity Center Directory
- Amazon Q Business - Identity Center Integrated Application
- Amazon Q Business - Identity Federation Application
- Amazon Q Business - Data Sources Connectors
- Amazon Q Business - Enhance Application
- Amazon Q Business - Features
- Amazon Q Business - Security
- Amazon Q Business - Monitoring
- Amazon Q Business API Reference
- Amazon Q Business - API Overview
- Amazon Q Business - API References
- Amazon Q Business - Supported Actions
- Amazon Q Business - Supported Data Types
- Amazon Q Business - Common Parameters
- Amazon Q Business - Common Errors
- Amazon Q Developer User Guide
- Amazon Q Developer - Introduction
- Amazon Q Developer - Getting Started
- Amazon Q Developer - On AWS
- Amazon Q Developer - In IDE
- Amazon Q Developer - Command Line
- Amazon Q Developer - Customization
- Amazon Q Developer - Security
- Amazon Q Developer - Monitoring
- Amazon Q Developer - Supported Region & Service Rename
- Amazon Q Developer - Document History
Amazon Q Developer - Customization
An Amazon Q customization is a set of elements that allows Amazon Q to provide suggestions based on your company's codebase. You connect a data source with your codebase, and Amazon Q uses this content to offer assistance tailored to your organization's development style.
Prerequisites
To use Amazon Q customizations, follow the Amazon Q Developer Pro setup process, including adding users to your profile who need access to customizations.
Authorizing Your Administrator
To use Amazon Q Customizations, your Amazon Q administrator needs access to your codebase, stored on Amazon S3 or through AWS CodeConnections. However, during the standard Amazon Q Developer Pro setup process, your AWS Organizations administrator does not grant access to these services.
Therefore, before you use Amazon Q Customizations, you must add the following permissions to your Amazon Q administrator's role:
{ "Version": "2012-10-17", "Statement": [{ "Effect": "Allow", "Action": [ "sso-directory:DescribeUsers" ], "Resource": [ "*" ] }, { "Effect": "Allow", "Action": [ "codewhisperer:CreateCustomization", "codewhisperer:DeleteCustomization", "codewhisperer:ListCustomizations", "codewhisperer:UpdateCustomization", "codewhisperer:GetCustomization", "codewhisperer:ListCustomizationPermissions", "codewhisperer:AssociateCustomizationPermission", "codewhisperer:DisassociateCustomizationPermission" ], "Resource": [ "*" ] }, { "Effect": "Allow", "Action": [ "codeconnections:ListConnections", "codeconnections:ListOwners", "codeconnections:ListRepositories", "codeconnections:GetConnection" ], "Resource": [ "*" ] }, { "Effect": "Allow", "Action": "codeconnections:UseConnection", "Resource": "*", "Condition": { "ForAnyValue:StringEquals": { "codeconnections:ProviderAction": [ "GitPull", "ListRepositories", "ListOwners" ] } } }, { "Effect": "Allow", "Action": [ "s3:GetObject*", "s3:GetBucket*", "s3:ListBucket*" ], "Resource": [ "*" ] } ] }
Preparing Your Data
The following is the key concepts to keep in mind when preparing your data source for Amazon Q Customizations:
- Add code with patterns encouraged by your team.
- Avoid code with bugs, security vulnerabilities, performance issues, and more.
- Ensure the data source contains at least 2 MB and at most 20 GB of source code files.
- Files larger than 10 MB will be ignored.
- Include at least 10 files for each language you want your customization to support.
- Place source code within a directory, not at the root level, in your Amazon S3 data source.
Amazon Q Customizations supports the following languages and file extensions:
- Java (.java)
- JavaScript (.js, .jsx)
- Python (.py)
- TypeScript (.ts, .tsx)
Enabling Customization In Chat
To enable customization in chat, use the following procedure.
- Go to the Amazon Q Developer console.
- From the navigation panel, choose settings
- Choose View settings.
- Under Details, choose Edit.
- Under Advanced settings, select the check box next to Enable chat customization feature.
- Choose Save changes.
Creating Your Customization
To create your customization, follow this procedure:
- To set up Amazon Q Developer Pro, enable IAM Identity Center, authorize an administrator to Amazon Q Developer, and activate the Amazon Q Developer console.
- Open the Amazon Q Developer console.
- From the navigation pane on the left, choose Customizations.
- The customizations page will appear.
- Choose Create customization.
- Enter a customization name and (optional) description.
Connecting To Your Data Source
To connect to your data source through CodeConnections, follow this procedure:
- Under Connection to source provider, select CodeConnections.
- If you are using an existing connection, choose Select existing connection. Then, under Select a connection, select your connection from the dropdown. Otherwise, choose Create a new connection.
- In the pop-up window that opens, navigate to your data source and follow the instructions in the console.
- After you create your data source, return to the Create customization page.
- Under Select a connection, select your connection from the dropdown.
To connect to your data source through Amazon S3, follow this procedure:
- Under Connection to source provider, select Amazon S3.
- Choose Browse Amazon S3.
- Navigate to the bucket or folder containing your codebase and make a note of the URI.
- Paste the URL into the field labeled Enter Amazon S3 URI.
Customizing Creation Issues
You can troubleshoot the following errors in the ways mentioned below:
- You may receive the error: 'Total size of the provided repositories exceeds the maximum allowed size of number for a customization'. In that case, remove a repository from your data source and try again.
- You may receive the error: 'Insufficient data to create a customization. Add more files from supported languages and retry'. If you receive this error, add more files containing the programming language that is the focus of your customization, and try again.
Deleting Your Customization
To delete your customization, follow this procedure:
- Open the Amazon Q Developer console.
- From the navigation pane on the left, choose Customizations.
- The customizations page will appear.
- If the customization that you want to delete is still active, choose Deactivate.
- Choose Delete.
Evaluating Your Customization
To evaluate your customizations follow the steps mentioned below:
- In the Amazon Q Developer console, from the navigation panel, choose Customizations.
- Choose the name of the customization to examine.
- The evaluation score on the right side of the window shows how effective your customization may be, as evaluated by Amazon Q.
Optimizing Your Customization
To optimize your customizations follow the steps mentioned below:
- Consider expanding your data source to include more code repositories.
- Consider expanding to more programming languages if you primarily included data from limited languages.
- Remove auto-generated files and repositories, or those generated from templates, as they add noise and are not valuable for training a customization.
- If your codebase rarely uses internal libraries, the core Amazon Q model may already be performing optimally.
Logging And Troubleshooting
Amazon Q can provide you with log files that will help you understand and troubleshoot issues with your customization.
Setting Up Log Delivery
To set up log delivery, select the Log deliveries tab on the console page for your customization. Follow the instructions in the interface to configure your log deliveries. Then choose Create log deliveries.
The prefix of logs delivered to an Amazon S3 bucket will be:
AWSLogs/account_id/codeWhispererCustomizationLogs/region/customization_id/year/month/day/hour/
The files will be zipped, with the naming format:
account_id_codeWhispererCustomizationLogs_customization_id_date_file_id.log.gz
Interpreting Customization Logs
The following table lists log messages that may help you understand issues with your customization.
Log message | Log level |
---|---|
Starting to ingest number repos from source source | Info |
Downloading data from repo: repo name | Info |
Received amount MB of supported data. amount MB required. Add more data and retry. | Error |
The provided CodeStar Connection ARN: Arn is invalid. | Error |
Access denied when attempting to reach the provided CodeStar Connection: Arn | Error |
Failed to download with AWS CodeStar Connection: Arn probably deleted by customer | Error |
ProviderThrottlingException from CodeStar Connection: Arn while cloning repository: repository | Error |
Processing data from S3: S3 URI | Info |
Invalid S3 path specified: S3 Directory | Error |
Unable to access the provided S3 bucket: bucket name | Error |
The provided S3 bucket: bucket name does not exist. | Error |
The provided S3 key S3 URI does not exist. | Error |
Customization Error Messages
The following table will help you understand customization-related messages in the Amazon Q console.
Error message | Suggested action |
---|---|
You have activated the maximum number of customizations. | Deactivate an active customization and try again. |
You have exceeded the maximum number of group permissions limit of limit. | Remove a group and retry. |
You have exceeded the maximum number of user permissions limit of limit. | Remove a user and retry. |
Maximum active jobs reached. | Wait until an in-progress job in the same account has finished. Retry the operation. |
Encountered an unexpected error when processing the request. | Retry the operation. If it continues to fail, contact customer support. |
Failed to download with AWS CodeStar Connection: Arn probably deleted by customer | Access denied when attempting to reach the provided AWS CodeConnections connection. |
Access denied when attempting to reach the provided AWS CodeConnections connection | Validate permissions on your connection and on your third-party provider. Then retry the operation. |
One or more repositories not found while accessing the provided AWS CodeConnections connection. | Validate permissions and list of repos from the third-party provider. Then retry the operation. |
The provided AWS CodeConnections connection ARN is invalid. | Update the customization with a corrected Connection ARN. |
The Host associated with the provided AWS CodeConnections connection is unavailable. | Try again in 5 minutes. |
Invalid Amazon S3 path specified. | Update the customization with a valid Amazon S3 URI. |
Unable to access the provided Amazon S3 bucket. | Validate permissions for the admin's role. Retry after fixing any permission issues. |
Activating Your Customizations
To activate a version of your customization, follow this procedure:
- Open the Amazon Q Developer console.
- From the navigation pane on the left, choose Customizations.
- Choose the customization you want to activate a version for.
- Choose the version you want to activate from the Versions table.
- Choose Activate.
Updating Your Customizations
To create a new version of your customization, follow this procedure:
- Open the Amazon Q Developer console.
- From the navigation pane on the left, choose Customizations.
- Choose the customization for which you want to create a new version.
- Select Create new version from the Actions dropdown.
- If applicable, change the data source.
- Choose Create.
Adding Users And Groups
To add users and groups to your Amazon Q customizations, follow the steps mentioned below:
- In the Amazon Q Developer console, from the navigation panel, choose Customizations.
- Choose the name of the customization to which you want to add users or groups.
- In the bottom half of the window, if necessary, select the Users and groups tab. and then the Users or Groups sub-tab.
- Select the users or groups that require access to your customization.
- Choose Add users or Add groups.
Using Amazon Q Customizations
To use customizations with VS Code, follow the steps mentioned below:
- Authenticate to Amazon Q Developer Pro with IAM Identity Center using the steps under Installing the Amazon Q Developer extension or plugin in your IDE.
- In the Developer Tools pane, under Amazon Q, choose Select Customization.
- At the top of the window, from the dropdown menu, select the appropriate customization.
To use customizations with JetBrains, follow the steps mentioned below:
- Authenticate to Amazon Q Developer Pro with IAM Identity Center using the steps under Installing the Amazon Q Developer extension or plugin in your IDE.
- In the Developer Tools pane, under Amazon Q, choose Select Customization.
- In the pop-up window, select the appropriate customization.
- Choose Connect.