Delete duplicate notes created during Zotfile annotation extraction?

Hello,
I have a strange use-case that I understand is not the way Zotero proper expects me to be dealing with annotation extractions:

I wanted to have my annotations separated into separate notes (each highlighted sentence creates its own child note). This was a feature of Zotfile but was deactivated once Zotero 6 came out with an integrated annotation extraction feature, which unfortunately does not support extracting annotations into multiple notes. So I made some changes on the most recent Zotfile source code and now I have the separate note functionality back and running with no issues.

However, I'm running into this situation: I have a PDF that I extracted the annotations from, and have, for example, 10 child notes. Then I happen to go back to the PDF again and add another highlight. When I ask Zotfile to extract annotations, it (understandably) extracts all of them again, meaning I now have 21 notes, the original ones having been duplicated. This all makes sense. I wonder if anyone has any method to automatically delete duplicate child notes so that only the new annotations are added once I re-extract the annotations. I know there's a built in Duplicate Items folder, but that only applies to actual citations, and not to child notes. Any ideas?
  • edited March 2, 2023
    We can't help with this, obviously, but see https://forums.zotero.org/discussion/comment/426530/#Comment_426530. If there's sufficient demand for creating separate notes from annotations for multiple items at once, we can consider adding back a way to do this.
  • For the general issue, which would apply to Zotero's functionality as well, see the discussion around (1) here: https://forums.zotero.org/discussion/88066/pdf-editor-beta-some-notes-on-notes
  • Thank you – maybe I'm misunderstanding what you mean by "creating separate notes from annotations for multiple items at once" but I'm not talking about extracting annotations from multiple different pdfs with one click. I mean extracting annotations from one single pdf, and creating a separate note for each individual annotation (i.e. each different highlighted sentence) as a child note under the item.
  • edited March 2, 2023
    Ah, OK. Out of curiosity, why do you want to do that?

    Here's what I've said on this elsewhere, for what it's worth:
    It's not expected that you would be creating individual notes for each quote as you read — that's the whole point of annotations. You highlight as you read, you add comments to the annotations, and then, later, you create a note from all the annotations and comments in a single step. And you can, if you prefer, first filter the annotations by color or tag in the annotations tab of the sidebar to create a note from a specific set of annotations.

    In an upcoming version, you'll be able to see annotations from the main library view (which might address whatever use case is causing you to think you need to create individual notes).
    If there's a particular output for your workflow that requires individual notes, that's something that would better be addressed by later processing the annotations in some way (e.g., an integration plugin for a given text editor could pull annotations directly — they don't need to be in notes).
  • I extract all the quotes into individual notes and then put those into Scrivener (in my case). Then I categorize them according to different topics, and distribute them to the relevant sections of my dissertation. But a Zotero-only use case would be something like: I extract two notes from a pdf, and one of them is about topic A and the other one about topic B. Those would get their relevant tags and when I get to writing the chapter about topic A, it would be easy to find the relevant quotes, rather than having to go through a long list of quotations every time and trying to figure out which ones are about what topic.
  • It used to be a feature on Zotfile, but was hidden when the Zotero built-in extractor was introduced. I really like the built in extractor, too (I make a report and print it out so that I have a physical copy of all my annotations/save it to a separate folder as a backup). But having separate notes for each annotation would in my opinion make Zotero a lot more streamlined with the writing process; identify the relevant quote easily in Zotero, each note has the extracted quotation already in quotation marks and followed by the footnote or inline citation; copy paste into your text editor and you're done.
  • edited March 2, 2023
    But a Zotero-only use case would be something like: I extract two notes from a pdf, and one of them is about topic A and the other one about topic B. Those would get their relevant tags and when I get to writing the chapter about topic A, it would be easy to find the relevant quotes
    No, that's my point, though — for something like that, you'd want to just insert the annotations directly into the word processor. They already exist in the database as distinct entries, can be tagged individually, filtered by tag, etc., and they'll show up in the items list in an upcoming version. The official word processor plugins don't yet support inserting annotations directly, but it's coming.

    Same would apply for something like Obsidian, where a plugin can pull the annotations directly, with no need for pointless intermediate notes.

    The plugin part doesn't apply if you're using a closed-source text editor with no plugin architecture that has been weirdly hostile over the years to repeated requests from users for any some sort of Zotero integration, but there's not much we can do about that… In any case, once annotations show up in the items list, you'll be able to filter by tag and use Quick Copy to copy them individually into Scrivener. (You can already do this from the PDF reader, where you can also filter by tag in the sidebar.)
  • I see, yes, I am indeed using Pages. If there will be a way to pull in the annotations directly in Word etc. then I see why notes would be redundant. Porting them into Scrivener one by one is a bit much at scale, but hopefully once they're available as items there could be a plugin to deal with that. Thanks again
  • I was referring to Scrivener, to be clear. Pages also doesn't have a plugin architecture, but that's less hostile, more Apple.
  • Oh did not know that, how unfortunate. I’ve only been using Scrivener (and Zotero’s features beyond the basic bibliography page generator) for a few days, trying to figure out a workflow to manage quotations and references.
  • @dr503, I can relate to the issue you describe. The best route I have found to achieve this is described here: https://daily.jstor.org/how-to-use-zotero-and-scrivener-for-research-driven-writing/

    The one update I would add to this, is that I don't need to generate a report from my annotations. I open the child note with all the annotations included, select all, and then paste into Word, before running the find and replace.

    Hope this helps. I would also value a way to get notes from Zotero into Scrivener as individual files, but I'm not sure I'd want my Zotero cluttered with hundreds of individual child notes along the way.
Sign In or Register to comment.