@@ -20,7 +20,7 @@ import {
2020 updateConfigurationRequestType ,
2121 WorkspaceFolder ,
2222} from '@aws/language-server-runtimes/protocol'
23- import { AuthUtil , getSelectedCustomization } from 'aws-core-vscode/codewhisperer'
23+ import { AuthUtil , CodeWhispererSettings , getSelectedCustomization } from 'aws-core-vscode/codewhisperer'
2424import {
2525 Settings ,
2626 oidcClientName ,
@@ -92,20 +92,19 @@ export async function startLanguageServer(
9292 customization,
9393 optOutTelemetry : getOptOutPreference ( ) === 'OPTOUT' ,
9494 projectContext : {
95- enableLocalIndexing : true ,
95+ enableLocalIndexing : CodeWhispererSettings . instance . isLocalIndexEnabled ( ) ,
96+ enableGpuAcceleration : CodeWhispererSettings . instance . isLocalIndexGPUEnabled ( ) ,
97+ indexWorkerThreads : CodeWhispererSettings . instance . getIndexWorkerThreads ( ) ,
9698 } ,
9799 } ,
98100 ]
99101 }
100102 if ( params . items [ 0 ] . section === 'aws.codeWhisperer' ) {
101103 return [
102104 {
103- includeSuggestionsWithCodeReferences : vscode . workspace
104- . getConfiguration ( )
105- . get ( 'amazonQ.showCodeWithReferences' ) ,
106- shareCodeWhispererContentWithAWS : vscode . workspace
107- . getConfiguration ( )
108- . get ( 'amazonQ.shareContentWithAWS' ) ,
105+ includeSuggestionsWithCodeReferences :
106+ CodeWhispererSettings . instance . isSuggestionsWithCodeReferencesEnabled ( ) ,
107+ shareCodeWhispererContentWithAWS : ! CodeWhispererSettings . instance . isOptoutEnabled ( ) ,
109108 } ,
110109 ]
111110 }
0 commit comments