scan_directory
Scans a directory to find files already linked to vault nodes and lists unregistered files with suggested types, subtypes, and titles for review.
Instructions
Scan a directory for files and identify which already have vault nodes.
For each file found, checks whether any vault node has a has_asset location with scheme: local pointing to that file (by resolved absolute path).
Returns: { directory: str, total_files: int, unregistered: [{path, filename, format, suggested_type, suggested_subtype, suggested_title}, ...], registered: [{path, filename, format, node_uid}, ...], }
suggested_type is asset (with suggested_subtype book) for ebook formats
and document otherwise; suggested_title is the humanized filename. Both
come from the filename alone — confirm with the user when they look wrong.
Args: path: Absolute path to the directory to scan. recursive: Scan subdirectories recursively (default false).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | ||
| recursive | No |