sul-dlss-deprecated / triannon

Rails engine for working with storage of OpenAnnotations stored in Fedora4
Other
13 stars 1 forks source link

integration tests for Mirador annos #140

Open ndushay opened 9 years ago

ndushay commented 9 years ago

From: Drew Winget awinget@stanford.edu Date: March 12, 2015 at 4:06:14 PM PDT Subject: Re: on tagging in SW: javascript code info To: Robert Sanderson azaroth42@gmail.com Cc: Naomi Dushay ndushay@stanford.edu ...

As far as annotations go, here are some examples of the only two variations that Mirador currently sends to catch (given below in OA format, which is how they're stored in Mirador. Simple comment annotation ``` { "@context":"http://iiif.io/api/presentation/2/context.json", "@type":"oa:Annotation", "motivation":[ "oa:commenting" ], "resource":[ { "@type":"dctypes:Text", "format":"text/html", "chars":"Yet another line of unreadable text." } ], "on":{ "@type":"oa:SpecificResource", "source":"http://manifests.ydc2.yale.edu/canvas/3a38190c-49a2-4e24-8ac8-b886087e63da", "selector":{ "@type":"oa:FragmentSelector", "value":"xywh=2244,2086,1176,188" }, "scope":{ "@context":"http://www.harvard.edu/catch/oa.json", "@type":"catch:Viewport", "value":"xywh=-872,0,5406,4489" } } } ``` Simple comment annotation with tags ``` { "@context":"http://iiif.io/api/presentation/2/context.json", "@type":"oa:Annotation", "motivation":[ "oa:tagging", "oa:commenting" ], "resource":[ { "@type":"oa:Tag", "chars":"brown," }, { "@type":"oa:Tag", "chars":"scribbly," }, { "@type":"oa:Tag", "chars":"unreadable" }, { "@type":"dctypes:Text", "format":"text/html", "chars":"This one has some tags associated with it." } ], "on":{ "@type":"oa:SpecificResource", "source":"http://manifests.ydc2.yale.edu/canvas/a66c3752-b152-44c2-ae14-c46529258d0b", "selector":{ "@type":"oa:FragmentSelector", "value":"xywh=2018,1269,772,166" }, "scope":{ "@context":"http://www.harvard.edu/catch/oa.json", "@type":"catch:Viewport", "value":"xywh=-923,0,5517,4581" } } } ```
ndushay commented 9 years ago

ensure:

ndushay commented 9 years ago

@azaroth42 Note:

  1. annos are in IIIF context
  2. examples have
"scope":{  
         "@context":"http://www.harvard.edu/catch/oa.json",
         "@type":"catch:Viewport",
         "value":"xywh=-872,0,5406,4489"
      }

but the context url doesn't resolve, and this one https://github.com/danielcebrian/catch/blob/master/data/fixtures/annotations.json doesn't have viewport.

azaroth42 commented 9 years ago

@aeschylus I thought we agreed that the annotations would be transferred in the OA context, not the IIIF context? e.g. as per http://www.openannotation.org/spec/core/publishing.html#Serialization

(for exactly this reason)

aeschylus commented 9 years ago

Hm. I have clearly not understood the implications/details of this. The spec says they may be transferred in any context capable of expressing the graph, but I'm happy to transform it. The scope is another matter. Is the problem that the @context doesn't resolve to something that can help transform the @type? If I remember the archaeology of the catch:Viewport, this was a way for us to get the target region into catch with a custom field, though it seems cloogey now, and is obviously incorrect.

aeschylus commented 9 years ago

The "scope" field was a custom invention for representing what was being called "bounds" at the time. This was a description of the appropriate zoom framing rectangle from which to view the target annotation region. Should we represent this a different way?