refactor: simplify cli conversions

This commit is contained in:
Peter Steinberger
2026-04-11 01:27:39 +01:00
parent 5c0d1c6a40
commit 1fb2e18f47
21 changed files with 24 additions and 25 deletions

View File

@@ -372,8 +372,9 @@ export function resolveMemoryBackendConfig(params: {
const mergedExtraCollections = [
...(params.cfg.agents?.defaults?.memorySearch?.qmd?.extraCollections ?? []),
...(agentEntry?.memorySearch?.qmd?.extraCollections ?? []),
].filter((value): value is MemoryQmdIndexPath =>
Boolean(value && typeof value === "object" && typeof value.path === "string"),
].filter(
(value): value is MemoryQmdIndexPath =>
value !== null && typeof value === "object" && typeof value.path === "string",
);
// Combine QMD-specific paths with extraPaths and per-agent cross-agent collections.