In order to link to the source for every citation, I generally write citation in Markdown like:
For example, see [@anand2011](x-devonthink-item://5647F891-CDFF-4A32-939B-74038A8336F5?page=23&annotation=Highlight&x=146&y=357);
[@bachman1996](obsidian://open?vault=myvault&file=journals%2F2023-02-24); [@clark2000](logseq://graph/mygraph?block-id=6369da66-9dd2-42bb-a90a-13bac6bb2ub8)
Before converting the document format with Pandoc, I will remove all links, and it would be like:
For example, see [@anand2011];
[@bachman1996]; [@clark2000]
However, according Pandoc’s citation syntax, these four citations should be wrapped as:
For example, see [@anand2011
@bachman1996; @clark2000]
So how can I write a Lua filter to merge adjacent multiple citations into one using Lua filter? Any suggestions would be appreciated. Thanks in advance!