Local PDF annotations have urn:x-pdf:<fingerprint> as their URI, which says nothing about the filename or where it's stored. Would be nice to have the filename to link to the file in local knowledge base systems.
Solution
Have a PDF folder set in the config, keep a mapping of all PDF fingerprints for this folder (using this post as reference), and map all PDF annotations to their respective files using this mapping.
Alternatives
Ideally should have a reverse mapping function so that you don't need a PDF folder, but I doubt this is possible.
Additional context
Needs a file-watcher aspect to check if PDF files in the folder have been added / updated. The first version could just loop through the PDF folder on every sync.
Problem
Local PDF annotations have
urn:x-pdf:<fingerprint>
as their URI, which says nothing about the filename or where it's stored. Would be nice to have the filename to link to the file in local knowledge base systems.Solution
Have a PDF folder set in the config, keep a mapping of all PDF fingerprints for this folder (using this post as reference), and map all PDF annotations to their respective files using this mapping.
Alternatives
Ideally should have a reverse mapping function so that you don't need a PDF folder, but I doubt this is possible.
Additional context
Needs a file-watcher aspect to check if PDF files in the folder have been added / updated. The first version could just loop through the PDF folder on every sync.