Merge branch 'main' into preview
This commit is contained in:
commit
d9b46aca28
19 changed files with 346 additions and 149 deletions
19
.vscode/launch.json
vendored
19
.vscode/launch.json
vendored
|
|
@ -139,5 +139,24 @@
|
|||
"NODE_OPTIONS": "--experimental-vm-modules"
|
||||
}
|
||||
}
|
||||
// {
|
||||
// "name": "[openai-adapters] Jest Test Debugger, Current Open File",
|
||||
// "type": "node",
|
||||
// "request": "launch",
|
||||
// "runtimeArgs": [
|
||||
// "--inspect-brk",
|
||||
// "${workspaceRoot}/packages/openai-adapters/node_modules/jest/bin/jest.js",
|
||||
// "--runInBand",
|
||||
// "--config",
|
||||
// "${workspaceRoot}/packages/openai-adapters/jest.config.mjs",
|
||||
// "${relativeFile}"
|
||||
// ],
|
||||
// "cwd": "${workspaceRoot}/packages/openai-adapters",
|
||||
// "console": "integratedTerminal",
|
||||
// "internalConsoleOptions": "neverOpen",
|
||||
// "env": {
|
||||
// "NODE_OPTIONS": "--experimental-vm-modules"
|
||||
// }
|
||||
// }
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -36,6 +36,7 @@ import CustomLLMClass from "../llm/llms/CustomLLM.js";
|
|||
import FreeTrial from "../llm/llms/FreeTrial.js";
|
||||
import { llmFromDescription } from "../llm/llms/index.js";
|
||||
|
||||
import { execSync } from "child_process";
|
||||
import CodebaseContextProvider from "../context/providers/CodebaseContextProvider.js";
|
||||
import ContinueProxyContextProvider from "../context/providers/ContinueProxyContextProvider.js";
|
||||
import { fetchwithRequestOptions } from "../util/fetchWithOptions.js";
|
||||
|
|
@ -61,7 +62,7 @@ import {
|
|||
getPromptFiles,
|
||||
slashCommandFromPromptFile,
|
||||
} from "./promptFile.js";
|
||||
import { execSync } from "child_process";
|
||||
|
||||
function resolveSerializedConfig(filepath: string): SerializedContinueConfig {
|
||||
let content = fs.readFileSync(filepath, "utf8");
|
||||
const config = JSONC.parse(content) as unknown as SerializedContinueConfig;
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
import { BaseContextProvider } from "../";
|
||||
import {
|
||||
Chunk,
|
||||
ContextItem,
|
||||
|
|
@ -9,7 +10,6 @@ import {
|
|||
import DocsService from "../../indexing/docs/DocsService";
|
||||
import preIndexedDocs from "../../indexing/docs/preIndexedDocs";
|
||||
import { Telemetry } from "../../util/posthog";
|
||||
import { BaseContextProvider } from "../";
|
||||
|
||||
class DocsContextProvider extends BaseContextProvider {
|
||||
static nRetrieve = 30;
|
||||
|
|
@ -108,9 +108,8 @@ class DocsContextProvider extends BaseContextProvider {
|
|||
});
|
||||
}
|
||||
|
||||
const embeddingsProvider = await docsService.getEmbeddingsProvider(
|
||||
!!preIndexedDoc,
|
||||
);
|
||||
const embeddingsProvider =
|
||||
await docsService.getEmbeddingsProvider(!!preIndexedDoc);
|
||||
|
||||
const [vector] = await embeddingsProvider.embed([extras.fullInput]);
|
||||
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ import { ContinueServerClient } from "./continueServer/stubs/client";
|
|||
import { getAuthUrlForTokenPage } from "./control-plane/auth/index";
|
||||
import { ControlPlaneClient } from "./control-plane/client";
|
||||
import { CodebaseIndexer, PauseToken } from "./indexing/CodebaseIndexer";
|
||||
import DocsService, { docsServiceSingleton } from "./indexing/docs/DocsService";
|
||||
import DocsService from "./indexing/docs/DocsService";
|
||||
import Ollama from "./llm/llms/Ollama";
|
||||
import type { FromCoreProtocol, ToCoreProtocol } from "./protocol";
|
||||
import { GlobalContext } from "./util/GlobalContext";
|
||||
|
|
|
|||
6
core/index.d.ts
vendored
6
core/index.d.ts
vendored
|
|
@ -347,9 +347,9 @@ export interface LLMOptions {
|
|||
// WatsonX options
|
||||
watsonxUrl?: string;
|
||||
watsonxApiKey?: string;
|
||||
watsonxZenApiKeyBase64?:string// Required if using watsonx software with ZenApiKey auth
|
||||
watsonxUsername?:string;
|
||||
watsonxPassword?:string;
|
||||
watsonxZenApiKeyBase64?: string; // Required if using watsonx software with ZenApiKey auth
|
||||
watsonxUsername?: string;
|
||||
watsonxPassword?: string;
|
||||
watsonxProjectId?: string;
|
||||
}
|
||||
type RequireAtLeastOne<T, Keys extends keyof T = keyof T> = Pick<
|
||||
|
|
|
|||
|
|
@ -1,3 +1,8 @@
|
|||
import { open, type Database } from "sqlite";
|
||||
import sqlite3 from "sqlite3";
|
||||
import lancedb, { Connection } from "vectordb";
|
||||
import { ConfigHandler } from "../../config/ConfigHandler.js";
|
||||
import DocsContextProvider from "../../context/providers/DocsContextProvider.js";
|
||||
import {
|
||||
Chunk,
|
||||
ContinueConfig,
|
||||
|
|
@ -6,13 +11,19 @@ import {
|
|||
IndexingProgressUpdate,
|
||||
SiteIndexingConfig,
|
||||
} from "../../index.js";
|
||||
import { FromCoreProtocol, ToCoreProtocol } from "../../protocol/index.js";
|
||||
import { GlobalContext } from "../../util/GlobalContext.js";
|
||||
import { IMessenger } from "../../util/messenger.js";
|
||||
import {
|
||||
editConfigJson,
|
||||
getDocsSqlitePath,
|
||||
getLanceDbPath,
|
||||
} from "../../util/paths.js";
|
||||
import { Telemetry } from "../../util/posthog.js";
|
||||
import TransformersJsEmbeddingsProvider from "../embeddings/TransformersJsEmbeddingsProvider.js";
|
||||
import { Article, chunkArticle, pageToArticle } from "./article.js";
|
||||
import { crawlPage } from "./crawl.js";
|
||||
import { runLanceMigrations, runSqliteMigrations } from "./migrations.js";
|
||||
import {
|
||||
downloadFromS3,
|
||||
getS3Filename,
|
||||
|
|
@ -20,17 +31,6 @@ import {
|
|||
SiteIndexingResults,
|
||||
} from "./preIndexed.js";
|
||||
import preIndexedDocs from "./preIndexedDocs.js";
|
||||
import TransformersJsEmbeddingsProvider from "../embeddings/TransformersJsEmbeddingsProvider.js";
|
||||
import { ConfigHandler } from "../../config/ConfigHandler.js";
|
||||
import lancedb, { Connection } from "vectordb";
|
||||
import { GlobalContext } from "../../util/GlobalContext.js";
|
||||
import DocsContextProvider from "../../context/providers/DocsContextProvider.js";
|
||||
import { open, type Database } from "sqlite";
|
||||
import sqlite3 from "sqlite3";
|
||||
import { Telemetry } from "../../util/posthog.js";
|
||||
import { runSqliteMigrations, runLanceMigrations } from "./migrations.js";
|
||||
import { IMessenger } from "../../util/messenger.js";
|
||||
import { ToCoreProtocol, FromCoreProtocol } from "../../protocol/index.js";
|
||||
|
||||
// Purposefully lowercase because lancedb converts
|
||||
export interface LanceDbDocsRow {
|
||||
|
|
@ -521,9 +521,8 @@ export default class DocsService {
|
|||
private async getLanceTableNameFromEmbeddingsProvider(
|
||||
isPreIndexedDoc: boolean,
|
||||
) {
|
||||
const embeddingsProvider = await this.getEmbeddingsProvider(
|
||||
isPreIndexedDoc,
|
||||
);
|
||||
const embeddingsProvider =
|
||||
await this.getEmbeddingsProvider(isPreIndexedDoc);
|
||||
const embeddingsProviderId = this.removeInvalidLanceTableNameChars(
|
||||
embeddingsProvider.id,
|
||||
);
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import ignore, { Ignore } from "ignore";
|
||||
import path from "node:path";
|
||||
import { FileType, IDE } from "../index.d.js";
|
||||
import ignore, { Ignore } from "ignore";
|
||||
import {
|
||||
DEFAULT_IGNORE_DIRS,
|
||||
DEFAULT_IGNORE_FILETYPES,
|
||||
|
|
@ -104,17 +104,18 @@ class DFSWalker {
|
|||
if (ignoreFilesInDir.length === 0) {
|
||||
return parentIgnore;
|
||||
}
|
||||
const patterns = ignoreFilesInDir.map(c => {
|
||||
return c.split(/\r?\n/)
|
||||
.map((l) => l.trim())
|
||||
.filter((l) => !/^#|^$/.test(l));
|
||||
}).flat();
|
||||
const patterns = ignoreFilesInDir
|
||||
.map((c) => {
|
||||
return c
|
||||
.split(/\r?\n/)
|
||||
.map((l) => l.trim())
|
||||
.filter((l) => !/^#|^$/.test(l));
|
||||
})
|
||||
.flat();
|
||||
return ignore().add(parentIgnore).add(patterns);
|
||||
}
|
||||
|
||||
private async loadIgnoreFiles(
|
||||
entries: WalkableEntry[],
|
||||
): Promise<string[]> {
|
||||
private async loadIgnoreFiles(entries: WalkableEntry[]): Promise<string[]> {
|
||||
const ignoreEntries = entries.filter((w) => this.isIgnoreFile(w.entry));
|
||||
const promises = ignoreEntries.map(async (w) => {
|
||||
return await this.ide.readFile(w.absPath);
|
||||
|
|
@ -127,10 +128,7 @@ class DFSWalker {
|
|||
return this.ignoreFileNames.has(p);
|
||||
}
|
||||
|
||||
private shouldInclude(
|
||||
walkableEntry: WalkableEntry,
|
||||
ignore: Ignore,
|
||||
) {
|
||||
private shouldInclude(walkableEntry: WalkableEntry, ignore: Ignore) {
|
||||
if (this.entryIsSymlink(walkableEntry.entry)) {
|
||||
// If called from the root, a symlink either links to a real file in this repository,
|
||||
// and therefore will be walked OR it linksto something outside of the repository and
|
||||
|
|
|
|||
|
|
@ -1,99 +1,106 @@
|
|||
import {
|
||||
BedrockRuntimeClient,
|
||||
ConverseStreamCommand,
|
||||
} from "@aws-sdk/client-bedrock-runtime";
|
||||
import { fromIni } from "@aws-sdk/credential-providers";
|
||||
import {
|
||||
ChatMessage,
|
||||
CompletionOptions,
|
||||
LLMOptions,
|
||||
MessageContent,
|
||||
ModelProvider,
|
||||
} from "../../index.js";
|
||||
import { stripImages } from "../images.js";
|
||||
import { BaseLLM } from "../index.js";
|
||||
|
||||
class Bedrock extends BaseLLM {
|
||||
private static PROFILE_NAME: string = "bedrock";
|
||||
static providerName: ModelProvider = "bedrock";
|
||||
static defaultOptions: Partial<LLMOptions> = {
|
||||
region: "us-east-1",
|
||||
model: "anthropic.claude-3-sonnet-20240229-v1:0",
|
||||
contextLength: 200_000,
|
||||
};
|
||||
|
||||
constructor(options: LLMOptions) {
|
||||
super(options);
|
||||
if (!options.apiBase) {
|
||||
this.apiBase = `https://bedrock-runtime.${options.region}.amazonaws.com`;
|
||||
}
|
||||
BedrockRuntimeClient,
|
||||
ConverseStreamCommand,
|
||||
} from "@aws-sdk/client-bedrock-runtime";
|
||||
import { fromIni } from "@aws-sdk/credential-providers";
|
||||
import {
|
||||
ChatMessage,
|
||||
CompletionOptions,
|
||||
LLMOptions,
|
||||
MessageContent,
|
||||
ModelProvider,
|
||||
} from "../../index.js";
|
||||
import { stripImages } from "../images.js";
|
||||
import { BaseLLM } from "../index.js";
|
||||
|
||||
class Bedrock extends BaseLLM {
|
||||
private static PROFILE_NAME: string = "bedrock";
|
||||
static providerName: ModelProvider = "bedrock";
|
||||
static defaultOptions: Partial<LLMOptions> = {
|
||||
region: "us-east-1",
|
||||
model: "anthropic.claude-3-sonnet-20240229-v1:0",
|
||||
contextLength: 200_000,
|
||||
};
|
||||
|
||||
constructor(options: LLMOptions) {
|
||||
super(options);
|
||||
if (!options.apiBase) {
|
||||
this.apiBase = `https://bedrock-runtime.${options.region}.amazonaws.com`;
|
||||
}
|
||||
|
||||
protected async *_streamComplete(
|
||||
prompt: string,
|
||||
options: CompletionOptions,
|
||||
): AsyncGenerator<string> {
|
||||
const messages = [{ role: "user" as const, content: prompt }];
|
||||
for await (const update of this._streamChat(messages, options)) {
|
||||
yield stripImages(update.content);
|
||||
}
|
||||
}
|
||||
|
||||
protected async *_streamComplete(
|
||||
prompt: string,
|
||||
options: CompletionOptions,
|
||||
): AsyncGenerator<string> {
|
||||
const messages = [{ role: "user" as const, content: prompt }];
|
||||
for await (const update of this._streamChat(messages, options)) {
|
||||
yield stripImages(update.content);
|
||||
}
|
||||
|
||||
protected async *_streamChat(
|
||||
messages: ChatMessage[],
|
||||
options: CompletionOptions,
|
||||
): AsyncGenerator<ChatMessage> {
|
||||
const credentials = await this._getCredentials();
|
||||
const client = new BedrockRuntimeClient({
|
||||
region: this.region,
|
||||
credentials: {
|
||||
accessKeyId: credentials.accessKeyId,
|
||||
secretAccessKey: credentials.secretAccessKey,
|
||||
sessionToken: credentials.sessionToken || "",
|
||||
},
|
||||
});
|
||||
|
||||
const input = this._generateConverseInput(messages, options);
|
||||
const command = new ConverseStreamCommand(input);
|
||||
const response = await client.send(command);
|
||||
|
||||
if (response.stream) {
|
||||
for await (const chunk of response.stream) {
|
||||
if (chunk.contentBlockDelta?.delta?.text) {
|
||||
yield { role: "assistant", content: chunk.contentBlockDelta.delta.text };
|
||||
}
|
||||
}
|
||||
|
||||
protected async *_streamChat(
|
||||
messages: ChatMessage[],
|
||||
options: CompletionOptions,
|
||||
): AsyncGenerator<ChatMessage> {
|
||||
const credentials = await this._getCredentials();
|
||||
const client = new BedrockRuntimeClient({
|
||||
region: this.region,
|
||||
credentials: {
|
||||
accessKeyId: credentials.accessKeyId,
|
||||
secretAccessKey: credentials.secretAccessKey,
|
||||
sessionToken: credentials.sessionToken || "",
|
||||
},
|
||||
});
|
||||
|
||||
const input = this._generateConverseInput(messages, options);
|
||||
const command = new ConverseStreamCommand(input);
|
||||
const response = await client.send(command);
|
||||
|
||||
if (response.stream) {
|
||||
for await (const chunk of response.stream) {
|
||||
if (chunk.contentBlockDelta?.delta?.text) {
|
||||
yield {
|
||||
role: "assistant",
|
||||
content: chunk.contentBlockDelta.delta.text,
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private _generateConverseInput(messages: ChatMessage[], options: CompletionOptions): any {
|
||||
const convertedMessages = this._convertMessages(messages);
|
||||
|
||||
return {
|
||||
modelId: options.model,
|
||||
messages: convertedMessages,
|
||||
system: this.systemMessage ? [{ text: this.systemMessage }] : undefined,
|
||||
inferenceConfig: {
|
||||
maxTokens: options.maxTokens,
|
||||
temperature: options.temperature,
|
||||
topP: options.topP,
|
||||
stopSequences: options.stop?.filter((stop) => stop.trim() !== ""),
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
private _generateConverseInput(
|
||||
messages: ChatMessage[],
|
||||
options: CompletionOptions,
|
||||
): any {
|
||||
const convertedMessages = this._convertMessages(messages);
|
||||
|
||||
return {
|
||||
modelId: options.model,
|
||||
messages: convertedMessages,
|
||||
system: this.systemMessage ? [{ text: this.systemMessage }] : undefined,
|
||||
inferenceConfig: {
|
||||
maxTokens: options.maxTokens,
|
||||
temperature: options.temperature,
|
||||
topP: options.topP,
|
||||
stopSequences: options.stop?.filter((stop) => stop.trim() !== ""),
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
private _convertMessages(messages: ChatMessage[]): any[] {
|
||||
return messages.map((message) => ({
|
||||
role: message.role,
|
||||
content: this._convertMessageContent(message.content),
|
||||
}));
|
||||
}
|
||||
|
||||
private _convertMessageContent(messageContent: MessageContent): any[] {
|
||||
if (typeof messageContent === "string") {
|
||||
return [{ text: messageContent }];
|
||||
}
|
||||
|
||||
private _convertMessages(messages: ChatMessage[]): any[] {
|
||||
return messages.map((message) => ({
|
||||
role: message.role,
|
||||
content: this._convertMessageContent(message.content),
|
||||
}));
|
||||
}
|
||||
|
||||
private _convertMessageContent(messageContent: MessageContent): any[] {
|
||||
if (typeof messageContent === "string") {
|
||||
return [{ text: messageContent }];
|
||||
}
|
||||
return messageContent.map((part) => {
|
||||
return messageContent
|
||||
.map((part) => {
|
||||
if (part.type === "text") {
|
||||
return { text: part.text };
|
||||
}
|
||||
|
|
@ -108,21 +115,22 @@ import {
|
|||
};
|
||||
}
|
||||
return null;
|
||||
}).filter(Boolean);
|
||||
}
|
||||
|
||||
private async _getCredentials() {
|
||||
try {
|
||||
return await fromIni({
|
||||
profile: Bedrock.PROFILE_NAME,
|
||||
})();
|
||||
} catch (e) {
|
||||
console.warn(
|
||||
`AWS profile with name ${Bedrock.PROFILE_NAME} not found in ~/.aws/credentials, using default profile`,
|
||||
);
|
||||
return await fromIni()();
|
||||
}
|
||||
})
|
||||
.filter(Boolean);
|
||||
}
|
||||
|
||||
private async _getCredentials() {
|
||||
try {
|
||||
return await fromIni({
|
||||
profile: Bedrock.PROFILE_NAME,
|
||||
})();
|
||||
} catch (e) {
|
||||
console.warn(
|
||||
`AWS profile with name ${Bedrock.PROFILE_NAME} not found in ~/.aws/credentials, using default profile`,
|
||||
);
|
||||
return await fromIni()();
|
||||
}
|
||||
}
|
||||
|
||||
export default Bedrock;
|
||||
}
|
||||
|
||||
export default Bedrock;
|
||||
|
|
|
|||
|
|
@ -10,6 +10,7 @@ import {
|
|||
import { DEFAULT_MAX_TOKENS } from "../constants.js";
|
||||
import { BaseLLM } from "../index.js";
|
||||
import Anthropic from "./Anthropic.js";
|
||||
import Azure from "./Azure.js";
|
||||
import Bedrock from "./Bedrock.js";
|
||||
import Cloudflare from "./Cloudflare.js";
|
||||
import Cohere from "./Cohere.js";
|
||||
|
|
@ -27,14 +28,13 @@ import LlamaCpp from "./LlamaCpp.js";
|
|||
import Llamafile from "./Llamafile.js";
|
||||
import Mistral from "./Mistral.js";
|
||||
import Msty from "./Msty.js";
|
||||
import Azure from "./Azure.js";
|
||||
import Ollama from "./Ollama.js";
|
||||
import OpenAI from "./OpenAI.js";
|
||||
import Replicate from "./Replicate.js";
|
||||
import TextGenWebUI from "./TextGenWebUI.js";
|
||||
import Together from "./Together.js";
|
||||
import ContinueProxy from "./stubs/ContinueProxy.js";
|
||||
import WatsonX from "./WatsonX.js";
|
||||
import ContinueProxy from "./stubs/ContinueProxy.js";
|
||||
|
||||
function convertToLetter(num: number): string {
|
||||
let result = "";
|
||||
|
|
@ -127,7 +127,7 @@ const LLMs = [
|
|||
Deepseek,
|
||||
Msty,
|
||||
Azure,
|
||||
WatsonX
|
||||
WatsonX,
|
||||
];
|
||||
|
||||
export async function llmFromDescription(
|
||||
|
|
|
|||
|
|
@ -49,7 +49,7 @@ _You can also use other commercial chat models by adding them to your `config.js
|
|||
|
||||
## Autocomplete
|
||||
|
||||
You likely want to use a model that is 1-15B parameters for autocomplete.
|
||||
You likely want to use a model that is 1-15B parameters for autocomplete. You can read more about it [here](../features/tab-autocomplete.md#tab-autocomplete-beta)
|
||||
|
||||
### Commercial LLMs
|
||||
|
||||
|
|
|
|||
40
docs/static/schemas/config.json
vendored
40
docs/static/schemas/config.json
vendored
|
|
@ -1471,6 +1471,46 @@
|
|||
}
|
||||
},
|
||||
"allOf": [
|
||||
{
|
||||
"if": {
|
||||
"properties": {
|
||||
"name": {
|
||||
"enum": ["docs"]
|
||||
}
|
||||
}
|
||||
},
|
||||
"then": {
|
||||
"properties": {
|
||||
"params": {
|
||||
"properties": {
|
||||
"sites": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"title": {
|
||||
"type": "string"
|
||||
},
|
||||
"startUrl": {
|
||||
"type": "string"
|
||||
},
|
||||
"rootUrl": {
|
||||
"type": "string"
|
||||
},
|
||||
"maxDepth": {
|
||||
"type": "integer"
|
||||
}
|
||||
},
|
||||
"required": ["title", "startUrl"]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": ["sites"]
|
||||
}
|
||||
},
|
||||
"required": ["params"]
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": {
|
||||
"properties": {
|
||||
|
|
|
|||
|
|
@ -1471,6 +1471,46 @@
|
|||
}
|
||||
},
|
||||
"allOf": [
|
||||
{
|
||||
"if": {
|
||||
"properties": {
|
||||
"name": {
|
||||
"enum": ["docs"]
|
||||
}
|
||||
}
|
||||
},
|
||||
"then": {
|
||||
"properties": {
|
||||
"params": {
|
||||
"properties": {
|
||||
"sites": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"title": {
|
||||
"type": "string"
|
||||
},
|
||||
"startUrl": {
|
||||
"type": "string"
|
||||
},
|
||||
"rootUrl": {
|
||||
"type": "string"
|
||||
},
|
||||
"maxDepth": {
|
||||
"type": "integer"
|
||||
}
|
||||
},
|
||||
"required": ["title", "startUrl"]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": ["sites"]
|
||||
}
|
||||
},
|
||||
"required": ["params"]
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": {
|
||||
"properties": {
|
||||
|
|
|
|||
|
|
@ -1471,6 +1471,46 @@
|
|||
}
|
||||
},
|
||||
"allOf": [
|
||||
{
|
||||
"if": {
|
||||
"properties": {
|
||||
"name": {
|
||||
"enum": ["docs"]
|
||||
}
|
||||
}
|
||||
},
|
||||
"then": {
|
||||
"properties": {
|
||||
"params": {
|
||||
"properties": {
|
||||
"sites": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"title": {
|
||||
"type": "string"
|
||||
},
|
||||
"startUrl": {
|
||||
"type": "string"
|
||||
},
|
||||
"rootUrl": {
|
||||
"type": "string"
|
||||
},
|
||||
"maxDepth": {
|
||||
"type": "integer"
|
||||
}
|
||||
},
|
||||
"required": ["title", "startUrl"]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": ["sites"]
|
||||
}
|
||||
},
|
||||
"required": ["params"]
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": {
|
||||
"properties": {
|
||||
|
|
|
|||
|
|
@ -1624,6 +1624,55 @@
|
|||
}
|
||||
},
|
||||
"allOf": [
|
||||
{
|
||||
"if": {
|
||||
"properties": {
|
||||
"name": {
|
||||
"enum": [
|
||||
"docs"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"then": {
|
||||
"properties": {
|
||||
"params": {
|
||||
"properties": {
|
||||
"sites": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"title": {
|
||||
"type": "string"
|
||||
},
|
||||
"startUrl": {
|
||||
"type": "string"
|
||||
},
|
||||
"rootUrl": {
|
||||
"type": "string"
|
||||
},
|
||||
"maxDepth": {
|
||||
"type": "integer"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"title",
|
||||
"startUrl"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"sites"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"params"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": {
|
||||
"properties": {
|
||||
|
|
|
|||
|
|
@ -259,6 +259,9 @@ export class VsCodeExtension {
|
|||
const indexer = await this.core.codebaseIndexerPromise;
|
||||
indexer.refreshFile(filepath);
|
||||
}
|
||||
|
||||
// Reindex the workspaces
|
||||
this.core.invoke("index/forceReIndex", undefined);
|
||||
});
|
||||
|
||||
// When GitHub sign-in status changes, reload config
|
||||
|
|
|
|||
|
|
@ -1,12 +1,12 @@
|
|||
import { ContinueConfig, QuickActionConfig } from "core";
|
||||
import { Telemetry } from "core/util/posthog";
|
||||
import * as vscode from "vscode";
|
||||
import { QuickEditShowParams } from "../../../quickEdit/QuickEditQuickPick";
|
||||
import {
|
||||
CONTINUE_WORKSPACE_KEY,
|
||||
getContinueWorkspaceConfig,
|
||||
} from "../../../util/workspaceConfig";
|
||||
import { isTutorialFile } from "./TutorialCodeLensProvider";
|
||||
import { Telemetry } from "core/util/posthog";
|
||||
import { QuickEditShowParams } from "../../../quickEdit/QuickEditQuickPick";
|
||||
|
||||
export const ENABLE_QUICK_ACTIONS_KEY = "enableQuickActions";
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import { ContinueConfig, IDE } from "core";
|
||||
import { QuickPickItem, window } from "vscode";
|
||||
import { fetchwithRequestOptions } from "core/util/fetchWithOptions";
|
||||
import { QuickPickItem, window } from "vscode";
|
||||
|
||||
export async function getContextProviderItems({
|
||||
contextProviders,
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
import { ChevronDownIcon, ChevronUpIcon } from "@heroicons/react/24/outline";
|
||||
import { SiteIndexingConfig } from "core";
|
||||
import { usePostHog } from "posthog-js/react";
|
||||
import { useContext, useLayoutEffect, useRef, useState } from "react";
|
||||
|
|
|
|||
|
|
@ -1,10 +1,10 @@
|
|||
import {
|
||||
ArrowUturnLeftIcon,
|
||||
BarsArrowDownIcon,
|
||||
CubeIcon,
|
||||
HandThumbDownIcon,
|
||||
HandThumbUpIcon,
|
||||
TrashIcon,
|
||||
CubeIcon,
|
||||
} from "@heroicons/react/24/outline";
|
||||
import { ChatHistoryItem } from "core";
|
||||
import { stripImages } from "core/llm/images";
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue