-
Notifications
You must be signed in to change notification settings - Fork 4
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
Add mapping content identifier to annotations #173
Comments
I would compare annotations to comments and edit suggestions in collaborative software such as Google Docs. If other people comment my text, I can close the comment and the comment disappears when I delete the commented section of text. Trying to prevent "abuse" should not be a technical goal anyway. On the other hand Additional thought: Annotating a mapping might imply same judgement of other "duplicate" mappings with same |
The thing is: I would add the |
|
Yeah, it would require changes in Cocoda, changes in jskos-server, breaks backwards compatibility, and does not make sense in my opinion. I mentioned |
Reading the Web Annotation Data Model I found how this feature (making sure the identity of annotated target has not been changed) is intended to be solved: change {
"target": "https://coli-conc.gbv.de/api/mappings/f8eff4e2-a6df-4d2c-8382-523072c59af7",
} to {
"target": {
"id": "https://coli-conc.gbv.de/api/mappings/981a003d-ae64-46b9-9571-04cbbe78c7fd",
"state": {
"id": "urn:jskos:mapping:content:3df6513d6c645eefafc93e62f6e2f221c6624e1b"
}
}
} but as you said, the change might not be worth the trouble, we could just do {
"target": "https://coli-conc.gbv.de/api/mappings/981a003d-ae64-46b9-9571-04cbbe78c7fd",
"_state": "urn:jskos:mapping:content:3df6513d6c645eefafc93e62f6e2f221c6624e1b"
} |
Oh, I missed this! Well, I wouldn't mind either option, but actually doing it how the spec is intended sounds right to me. Changing the format of One more question: Should Cocoda be responsible for adding that information or should jskos-server do it? I'm actually not sure about this, but so far, jskos-server doesn't actually mess at all with the annotations besides adding a URI in field Edit: It would probably make sense for jskos-server to add that information if the target is part of the same instance. Since it is only additional information, I think it would be fine to add it if it's not already included in the payload. |
- Adds new index. - Adds mapping content identifier if possible.
Suggested implementation in branch annotation-state. |
I found out (unfortunately after almost having finished the implementation) that jskos-server needs to have a consistent format for the
@nichtich what do you think? My guess would be that you'd vote for option 2, but maybe I'm wrong about that. 😅 Edit: Note that both options work fine from a validation standpoint which is nice. |
Change annotation format and add mapping state if possible (#173)
This is now part of v1.4.5 and can be taken into account when implementing gbv/cocoda#605 and gbv/cocoda#667. |
Let's assume annotations are only used to annotate mappings that live inside the same jskos-server instance.
If the target mapping of an annotation changes in certain ways, i.e. its members or its type is changed, an annotation with motivation
assessing
(withbodyValue
either+1
or-1
) should be marked as invalidated or potentially even deleted because it's not relevant anymore.I personally would not delete an annotation automatically since it belongs to a different user and also the creator of the mapping could simply change a mapping, then change it back, abusing the system. I think the best way would be to simply save a mapping's
urn:jskos:mapping:content:
and/orurn:jskos:mapping:members:
identifiers which can then be compared to the current mapping's identifier to see whether the annotation refers to an old version of that mapping. If we do it this way, then jskos-server doesn't even need to be aware of this mechanism at all. (Except when we implement gbv/cocoda#605 which consists of calculating the total "rating" of a mapping.)The Web Annotation Data Model is pretty flexible, so I think it would be possible to add additional data to an annotation. Also we could via
npm run upgrade
add the information to all existing annotations (assuming that the associated mappings have not changed since the annotation was created).What do you think, @nichtich?
(This came up in gbv/cocoda#667.)
The text was updated successfully, but these errors were encountered: