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

Tags, annotations, and other blasphemy #102

Open
jonnybazookatone opened this issue Jul 6, 2016 · 1 comment
Open

Tags, annotations, and other blasphemy #102

jonnybazookatone opened this issue Jul 6, 2016 · 1 comment
Labels

Comments

@jonnybazookatone
Copy link
Contributor

We have had several debates, and discussions about tags, and annotations (any many other forms of the same thing). For the foreseeable year, I believe this argument holds true:

  • Not that many people used tags or annotations in ADS 2.0, and so they are low priority
  • We have made it possible for people to export their libraries to disk if they wish to retain tags, and import them into other tools such as Zotero, or Mendeley.
  • With the above, we have removed any rush or prerequisite to fulfil any requirement such as -- "ADS 2.0 had it, so we must implement it before we shut down".

So, I hesitantly write the following, and encourage that this feature only be considered if the developers and other team members think it is important.

Tags or Annotations: Backend

Given the way the system is currently architected, it is completely possible to include tags or annotations.

Bibcode level

Bibcode level refers to, annotating a single bibcode Bib1 with a tag, or an annotation, within a given library Lib1.

Each user's library contains the following:

class Library(db.Model):
    """
    Library table
    """
    ....
    bibcode = db.Column(MutableDict.as_mutable(JSON), default={})
    ....

The idea would be simple. You can add an annotation to the dictionary of the bibcode, so you'll essentially have a JSON blob as:

{
  "Bib1": {
    "annotations": ["page1": "Interesting!", "page20": "Discuss at work"],
    "tags": ["clusters", "to-read", "10/10"],
    },
}

Keep in mind, this would always have a Library scope. If you wanted to use the same tags and annotations for a user through all of our interface, I do not believe the library service is the way to do it, given the way the models are -- but worth thinking about.

Library level

Library level refers to the scope of the library itself, i.e., you want to tag or place notes on that library. Again this is easily feasible. One need just update the model of the library:

class Library(db.Model):
    """
    Library table
    """
    tags = db.Column(db.List(db.String(20)))
    annotations = db.Column(db.JSON)

Or whatever type of notes you wish to be added to the library at this level. You'd then simply update the REST end points, and migrate the database.

@aaccomazzi
Copy link
Member

While I don't have an objection to the implementation suggested here, we should definitely take into consideration the W3C annotation model even for these kinds of annotations (called "whole-record", meaning we are annotating the entire document with a tag or some free-text content). See https://www.w3.org/annotation/ and links therein.

I suspect we'll need to collect a lot more information about the annotation itself to be compliant with the model. Given the potential expansion to full-text annotation in ADS and other services, we need to be sure that we can provide an OA-compliant API some day.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants