You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Now, granted, Scibot would ideally post annotations using the full complement of selectors. It doesn't operate in a DOM context, so would have a hard time figuring out RangeSelector. Scibot probably could and should at least figure out TextPositionSelector as well as TextQuoteSelector, which might be enough to differentiate. Still, one would expect that the anchoring system could handle annotations with TextQuoteSelectors that differ by suffix alone. Evidently we don't?
We only search for the suffix if the prefix isn't found. Which makes sense: always searching would be expensive. If we kept track of anchors where prefixes and exacts match, we could maybe search for the suffix in only those cases.
Fixed by hypothesis/client#2814. When there are multiple matches for a given TextQuoteSelector they are now ranked by a weighted score based on quote similarity, suffix similarity, prefix similarity and distance from expected text position.
When the Hypothesis client creates two annotations, as shown here, http://jonudell.net/h/same-prefix-diff-suffix.html, both anchor, because the client uses the full complement of selectors.
But when Scibot creates the same two annotations, the anchors pile up on one occurrence of the
exact
like so:Now, granted, Scibot would ideally post annotations using the full complement of selectors. It doesn't operate in a DOM context, so would have a hard time figuring out RangeSelector. Scibot probably could and should at least figure out TextPositionSelector as well as TextQuoteSelector, which might be enough to differentiate. Still, one would expect that the anchoring system could handle annotations with TextQuoteSelectors that differ by
suffix
alone. Evidently we don't?/cc @tgbugs, see https://www.ncbi.nlm.nih.gov/pmc/articles/PMC6522220/
The text was updated successfully, but these errors were encountered: