Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Recipe #309 annotation collections #521

Open
wants to merge 28 commits into
base: master
Choose a base branch
from

Conversation

robcast
Copy link
Contributor

@robcast robcast commented Jul 19, 2024

PR for #309

@robcast robcast linked an issue Jul 19, 2024 that may be closed by this pull request
@glenrobson
Copy link
Member

Add partOf in the manifest.
Link to the annotations rather than embed them on the page.
Remove Europeana provider
Move annotation collection example above the manifest as its so short

@glenrobson
Copy link
Member

Comments from cookbook editors:

  • use case: add comma after “algorithm”

implementation notes:

  • “The AnnotationCollection is a separate document that references a chain of one or more separate AnnotationPages containing the Annotations” - could potentially be ambiguos to a reader whether the annotationcollections or the annotionpages contain the annotation pages?
  • for consistency, should refer to as “Annotation Collections” (not “the” in front) or “an AnnotationCollection”, but not “AnnotationCollections” or “The AnnotationCollections”. Same with AnnotationPage
    should to SHOULD?
  • that Annotations that should be shown on a Canvas… > that Annotations intended to be shown on a Canvas …

Comments from Glen:

  • Could you have a look at the title as currently it is IIIF specific. Maybe something like "Grouping annotations into collections"
  • Could you move the links to the two annotation pages above the manifest JSON and below the AnnotationCollection.
  • Add JSON-LD link to the AnnotationCollection
  • Highlight the AnnotationCollection in the manifest
  • Can you include the label in the embedded annotation collection e.g:
"annotations": [
        {
          "id": "https://preview.iiif.io/cookbook/309-annotation-collections/recipe/0309-annotation-collection/anno_p2.json",
          "type": "AnnotationPage",
          "partOf": [
            {
              "id": "https://preview.iiif.io/cookbook/309-annotation-collections/recipe/0309-annotation-collection/anno_coll.json",
              "type": "AnnotationCollection",
              "label": {
                   "en": [ "Newspaper layout markup"   ]
              },
              "total": 8
            }
          ],
          "prev": "https://preview.iiif.io/cookbook/309-annotation-collections/recipe/0309-annotation-collection/anno_p1.json"
        }
      ]

As I think this will save a round trip for the client.

@@ -0,0 +1,59 @@
---
title: Using Annotation Collections
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The title seems more like a tutorial than a recipe. If I were looking for this, I would be searching for terms from the use case


## Use Case

You have a large number of Annotations covering multiple Canvases in a Manifest, for example crowd-sourced transcriptions or the output from a layout analysis algorithm and you want the Annotations to be displayed in a viewer as a recognizable group over the document with a label and a common color.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps lead with one of the examples as the case and then the technical terms followed by the analogous use case examples.


The AnnotationPages have an `items` property containing the list of Annotations, a `partOf` property that contains the URI of the parent AnnotationCollection, and `next` and `prev` properties that contain the URIs of the next and previous AnnotationPages in the sequence. AnnotationPages are often separate documents that are [referenced][0269] in the manifest using a reference object that can additionally provide some properties for access inside the manifest.

A IIIF viewer that displays Annotations on a Canvas follows the URIs in the `annotations` property of the Canvas and loads the Annotations in the referenced AnnotationPages. If the viewer wants to indicate that these Annotations belong to one or more AnnotationCollections it has to follow the URI in the `partOf` property of the AnnotationPages to identify the AnnotationCollection and display its label and choose a common color for the Annotations. The indirect connection from the Manifest to the AnnotationCollection means that a viewer would have to load all AnnotationPages from all Canvases if it wants to present a complete list of all AnnotationCollections in the Manifest to the user. This potentially slow process can be avoided if the `partOf`, `next`, and `prev` properties of the AnnotationPages are provided in the reference object inside the Manifest like in the example below.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a little odd where it is expressing guidance for viewer designers. The language of a recipe (I think) should be to the Manifest host, explaining how to express presentation preferences to the viewers. The advice is solid, however.


A IIIF viewer that displays Annotations on a Canvas follows the URIs in the `annotations` property of the Canvas and loads the Annotations in the referenced AnnotationPages. If the viewer wants to indicate that these Annotations belong to one or more AnnotationCollections it has to follow the URI in the `partOf` property of the AnnotationPages to identify the AnnotationCollection and display its label and choose a common color for the Annotations. The indirect connection from the Manifest to the AnnotationCollection means that a viewer would have to load all AnnotationPages from all Canvases if it wants to present a complete list of all AnnotationCollections in the Manifest to the user. This potentially slow process can be avoided if the `partOf`, `next`, and `prev` properties of the AnnotationPages are provided in the reference object inside the Manifest like in the example below.

## Example
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a lot to take in. I wouldn't delay posting it, but a diagram may be helpful here, in the flavor of those provided in the APIs.

@glenrobson
Copy link
Member

From the cookbook:

From navPlace x NavDate:
config='data-line="39-63,73-97,107-131,141-165,175-200"'

@glenrobson
Copy link
Member

Comments from Patrick and I:

  • Use case is clear

As there are lots of links between the Manifest, AnnotationPage and AnntationCollection it might be helpful to add a Diagram similar to the one on the PresentationAPI to show how the different files link together. Maybe a cut down version of: https://iiif.io/api/assets/images/data-model.png

Remove Annotation with a Non-Rectangular Polygon annotating an irregular shape on a Canvas as related.

Otherwise we were happy for it to go through to the TRC.

@robcast for info the other cookbook editors may comment on this pull request async as it proved difficult to find a time where we could all meet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
meta: ready-for-trc Issue is ready for TRC review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Annotation Collections
3 participants