mirror of
https://github.com/QwenLM/qwen-code.git
synced 2025-12-19 09:33:53 +00:00
Basic code assist support (#910)
This commit is contained in:
committed by
GitHub
parent
4e84431df3
commit
d79dafc577
19
packages/core/src/code_assist/codeAssist.ts
Normal file
19
packages/core/src/code_assist/codeAssist.ts
Normal file
@@ -0,0 +1,19 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import { ContentGenerator } from '../core/contentGenerator.js';
|
||||
import { loginWithOauth } from './oauth2.js';
|
||||
import { setupUser } from './setup.js';
|
||||
import { CcpaServer } from './ccpaServer.js';
|
||||
|
||||
export async function createCodeAssistContentGenerator(): Promise<ContentGenerator> {
|
||||
const oauth2Client = await loginWithOauth();
|
||||
const projectId = await setupUser(
|
||||
oauth2Client,
|
||||
process.env.GOOGLE_CLOUD_PROJECT,
|
||||
);
|
||||
return new CcpaServer(oauth2Client, projectId);
|
||||
}
|
||||
Reference in New Issue
Block a user