Integrate an entire folder of notes and documents at once. Groups files thematically, presents proposals per group, and processes after user confirmation. Uses entity cache across files for token efficiency.
Integrate multiple notes and documents from a folder in one workflow. Token-efficient: shares entity lookups across files (search once, link many).
FEATURE-2005, EPIC-020.
Ask: "How would you like to handle this batch?"
Wait for the user's answer.
Use list_files on the target folder. For each file:
read_fileReport to the user:
Found {N} files in {folder}:
- {X} markdown notes ({Y} with complete frontmatter, {Z} need integration)
- {A} PDFs
- {B} Office documents
- {C} already integrated (skipping)
- {D} potential duplicates (will flag)
Estimated cost: ~${N * 0.10}-${N * 0.15} (entity cache reduces redundant searches)
For each file that needs integration:
read_file, documents: read_document)semantic_search, check the cache:
semantic_search, store result in cachePresent groups to the user (in group-review mode):
Group 1: "AI Ethics" (5 files)
- ethics-of-ai.md -> Themen: [[KI]], [[Ethik]]
- responsible-ai.pdf -> New source note, Themen: [[KI]]
- fairness-metrics.md -> Konzepte: [[Fairness]]
...
Group 2: "Project Management" (3 files)
- sprint-retro-march.md -> Themen: [[Projektmanagement]]
...
Shall I proceed with Group 1?
For each confirmed group:
ingest_document (attaches full text automatically)update_frontmatter for properties, write_file only if body needs wikilinksAfter the group is done:
Group 1 complete: 5 files integrated, 2 stub notes created.
Proceed to Group 2, or undo Group 1?
After all groups are processed:
Batch ingest complete:
- {N} files integrated
- {M} stub notes created
- {K} entities reused from cache (saved ~{K * 0.02} tokens)
- {G} groups, each with a checkpoint for undo
Next: Run vault health check to verify graph integrity?