janhq/jan · error · Error
Vector DB extension does not support project-level ingestion
Error message
Vector DB extension does not support project-level ingestion
What it means
ingestAttachmentsForProject() looks up the registered VectorDB extension and requires it to expose ingestFileForProject. The built-in vector-db extension does not implement project-level ingestion, so this guard throws to signal the operation is unsupported by the current VectorDB provider.
Solutions
- Ingest files individually via vec.ingestFile per attachment instead of project-level ingestion
- Install/upgrade a VectorDB extension that implements ingestFileForProject
- Check capability first (typeof vec?.ingestFileForProject === 'function') and fall back to per-file ingestion
- Ensure the VectorDB extension is registered in window.core.extensionManager before ingest
Example fix
// before
await rag.ingestAttachmentsForProject(projectId, files) // throws with default vector DB
// after
if (typeof vec?.ingestFileForProject === 'function') {
await rag.ingestAttachmentsForProject(projectId, files)
} else {
for (const f of files) await vec.ingestFile(f)
} Defensive patterns
Strategy: type-guard
Validate before calling
const vec = window.core?.extensionManager?.get(ExtensionTypeEnum.VectorDB) as VectorDBExtension | undefined
if (typeof vec?.ingestFileForProject !== 'function') {
throw new Error('Project-level ingestion unavailable; fall back to per-file ingestFile')
} Type guard
const supportsProjectIngestion = (v: unknown): v is VectorDBExtension & { ingestFileForProject: Function } =>
!!v && typeof (v as any).ingestFileForProject === 'function' Try / catch
try {
await rag.ingestAttachmentsForProject(projectId, files)
} catch (e) {
if (String(e).includes('does not support project-level ingestion')) {
for (const f of files) await vec.ingestFile(f)
} else throw e
} Prevention
- Feature-detect ingestFileForProject before calling project-level ingestion
- Keep the VectorDB extension upgraded to a version that supports project ingestion
- Design callers with a per-file ingestion fallback path
- Verify the VectorDB extension is registered and enabled at startup
When it happens
Trigger: Calling RAG extension's ingestAttachmentsForProject() when no VectorDB extension is registered, the cast to VectorDBExtension failed, or the installed VectorDB implementation lacks ingestFileForProject.
Common situations: Project-level RAG ingestion attempted with the default vector-db extension that only supports per-file ingestion; vector-db extension not installed/enabled; version mismatch where the extension predates the ingestFileForProject API.
Related errors
- Catalog not supported for
- Failed to parse document
- Failed to resolve ingested attachment id
- File ' ' exceeds size limit ( bytes > MB).
- IO error
AI-assisted analysis of janhq/jan@7205d770c1 (2026-09-17).
Data as JSON: /api/errors/63255176f5dc5dd7.
Report an issue: GitHub.
Appendix: source
Thrown at extensions/rag-extension/src/index.ts:387
): Promise<{
filesProcessed: number
chunksInserted: number
files: AttachmentFileInfo[]
}> {
if (!projectId || !Array.isArray(files) || files.length === 0) {
return { filesProcessed: 0, chunksInserted: 0, files: [] }
}
// Respect feature flag: do nothing when disabled
if (this.config.enabled === false) {
return { filesProcessed: 0, chunksInserted: 0, files: [] }
}
const vec = window.core?.extensionManager.get(
ExtensionTypeEnum.VectorDB
) as unknown as VectorDBExtension
if (!vec?.ingestFileForProject) {
throw new Error('Vector DB extension does not support project-level ingestion')
}
// Load settings
const s = this.config
const maxSize = (s?.enabled === false ? 0 : s?.maxFileSizeMB) || undefined
const chunkSize = s?.chunkSizeChars as number | undefined
const chunkOverlap = s?.overlapChars as number | undefined
let totalChunks = 0
const processedFiles: AttachmentFileInfo[] = []
for (const f of files) {
if (!f?.path) continue
if (maxSize && f.size && f.size > maxSize * 1024 * 1024) {
throw new Error(
`File '${f.name}' exceeds size limit (${f.size} bytes > ${maxSize} MB).`
)
}View on GitHub (pinned to 7205d770c1)