[annotator-dev] Annotator and yuma-js media annotation toolkit?

Nick Stenning nick at whiteink.com
Thu Jan 19 11:51:49 UTC 2012

> Exactly. What I wonder is whether we can converge on the exchange
> format (obviously for text we have these 'start/end location' and we
> just extend to say an annotation must have:
> EITHER: start/end offsets as xpath
> OR: some description of the bounding box

To pick up on this point. I did consider the latter, briefly, when
writing the early versions of Annotator. But unless someone can
convince me otherwise, I think it's a non-starter, for the following

- Web pages are not a bitmapped medium. Pixel locations of elements
are not consistent between browsers, or even between different
instances of the same page in the same browser.

- More generally, it's far more sensible to annotate the *generating*
source of the page, than the *generated* rendering. In this case, the
generating source is the DOM tree.

If you're annotating HTML documents, then let the browser do the
normalisation for you (into a DOM tree), and then an annotation points
to a node or set of nodes within that tree. This is what XPath +
offset gives you.

If you want to consider possible extensions to the model, it might be
worth looking at XPointer -- built upon XPath -- which includes the
URI in the XPointer and provides a few features that XPath lacks. It
has the unfortunate disadvantage that it is not widely implemented by
browser vendors, unlike XPath.

Annotator's current serialisation strategy can be considered a
pragmatic, ad-hoc implementation of XPointer's aims.

Just my $0.02,

More information about the annotator-dev mailing list