Node.JS/Browser Web Annotation Framework
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
anno-auth-server
anno-cli
anno-errors
anno-fixtures
anno-plugins
anno-queries
anno-schema
anno-server
anno-store-file
anno-store-http
anno-store-memory
anno-store-mongodb
anno-store-mongolike
anno-store-sql
anno-store
anno-test
anno-util-loaders
anno-util
anno-webpack
doc
envyconf @ 21fff99
scripts
.babelrc
.dockerignore
.gitignore
.gitlab-ci.yml
.gitmodules
.travis.yml
Dockerfile
Makefile
README.md
TODO
lerna.json
mkdocs.yml
package-lock.json
package.json

README.md

anno

Build Status Known Vulnerabilities

Look here for the documentation

This monorepo contains packages that provide the building blocks for annotation software implementing the Web Annotation Data Model and Web Annotation Protocol.

Each repository is designed to provide a single feature to allow for broad reuse of components.

Concepts

Store

A store provides persistent storage of annotations. A store exposes methods that reflect the Web Annotation Protocol and the extensions implemented of this framework.

The store module is a proxy to the actual implementation. It handles method dispatch and middleware and allows instantiation from the environemnt. Actual stores must implement its interface.

The store-mongolike module implements most of the store interface for document databases, such as mongodb or NeDB.

Authentication

Authentication is based on JSON Web Tokens.

To inspect your tokens, try jwtinspector browser extension which will detect JWT in HTTP traffic and localStorage.

Revisions

An oa:Annotation has 1..n annox:hasVersion annox:AnnotationRevision.

annox:hasVersion is an ordered List.

The top-level oa:Annotation has the data from the latest revision as

  • body
  • target
  • creator

The modified of the top-level oa:Annotation is the created of the latest revision.

hasVersion is part of the getMetadata store call/HEAD HTTP call.

Comments / Replies / Nesting

URL schema

ID is a nice slugid, based on uuid v4 without leading dash

<BASE_URL>/<ID>[.<REPLY_ID>]*[~<REVISION_ID>]

E.g.

  • http://localhost:3000/ewnfkjewnfew~2 Second revision
  • http://localhost:3000/ewnfkjewnfew.2.1~5 Fifth revision of first answer to second answer

Replies reply to the generic not versioned annotation (for sanity)

Extensions to Web Annotation Data Model

Namespace for extensions is https://kba.github.io/anno/#, short annox.

Context is at https://anno.github.io/anno/context.jsonld

Hacking

Modules are managed by lerna

npm install -g lerna
lerna bootstrap