Support explicit read-only RAG archives
This commit is contained in:
parent
b3191f4f2c
commit
bba41efbd6
6 changed files with 36 additions and 8 deletions
|
|
@ -26,8 +26,14 @@ export function createVoidbotMcpContext(): VoidbotMcpContext {
|
|||
process.chdir(workspaceRoot);
|
||||
|
||||
const config = loadConfig();
|
||||
const archiveRepository = new FileMessageArchiveRepository(config.ragArchivePath);
|
||||
const sourceArchiveRepository = new FileSourceDocumentArchiveRepository(config.ragSourceArchivePath);
|
||||
const archiveOptions = {
|
||||
readOnly: process.env.VOIDBOT_MCP_ARCHIVES_READ_ONLY === "true",
|
||||
};
|
||||
const archiveRepository = new FileMessageArchiveRepository(config.ragArchivePath, archiveOptions);
|
||||
const sourceArchiveRepository = new FileSourceDocumentArchiveRepository(
|
||||
config.ragSourceArchivePath,
|
||||
archiveOptions,
|
||||
);
|
||||
const embedder = createTextEmbedder({
|
||||
backend: config.ragEmbeddingBackend,
|
||||
hashDimensions: config.ragEmbeddingDimensions,
|
||||
|
|
|
|||
Loading…
Reference in a new issue