More flexible annotation setup #183
Labels
No labels
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
orinoco/dump-things-server#183
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
It is my understanding that, at present, the annotation tags for recording the submitter and the submission time stamp are hard-coded.
It would be good to have them be configurable, such that a user/admin can decide what vocabulary terms is appropriate in a given content.
Right now, the assumption dumpthings is making is that people run
things/v1, and that theannotation_valueis a string with no further constraints. It would be good to decoupledumpthingsfrom the specifics ofthings/v1in this regard.I only see the slot name
annotation_valuebeing used in the tests right now (cool!). A futurethingsrelease may get rid of this dedicated slot, and switch to the genericdescriptionslot instead. If the name of theannotation_valueequivalent slot is important, it should become a configurable parameter.Moreover, it would also be good to support simple templating of the annotation value.
Use case: Rather than having two annotations for submission time and submitter separately, one might want to have a single "dumpthings submission tag", and maybe have that formatted as a string following particular conventions. This could be achieved by allowing for a Python template string to be configurable, and provide a small catalog of values (timestamp in different formats, submitter ID, maybe incoming IP, maybe certain HTTP header values, ...) that could also be extended as needed in future releases.
Annotation tag classes were made configurable in PR #145. The admin can define the vocabulary terms in the configuration keys:
collections.<collection_name>.submission_tags.submitter_id_tag, andcollections.<collection_name>.submission_tags.submission_time_tagCurrently, both values are always added to an annotation.