Tagging agent specification¶
Tagging service provides VOLTTRON users the ability to add semantic tags to different topics so that topic can be queried by tags instead of specific topic name or topic name pattern.
VOLLTTRON will use tags from Project Haystack. Tags defined in haystack will be imported into VOLTTRON and grouped by categories to tag topics and topic name prefix.
Once data in VOLTTRON has been tagged, users will be able to query topics based on tags and use the resultant topics to query the historian
- User should be able to tag individual components of a topic such as campus, building, device, point etc.
- Using the tagging service users should only be able to add tags already defined in the volttron tagging schema. New tags should be explicitly added to the tagging schema before it can be used to tag topics or topic prefix
- Users should be able batch process and tag multiple topic names or topic prefix using a template. At the end of this, users should be notified about the list of topics that did not confirm to the template. This will help users to individually add or edit tags for those specific topics
- When users query for topics based on a tag, the results would correspond to the current metadata values. It is up to the calling agent/application to periodically query for latest updates if needed.
- Users should be able query based on tags on a specific topic or its topic prefix/parents
- Allow for count and skip parameters in queries to restrict count and allow pagination
1. Get the list of tag categories available¶
rpc call to tagging service method ‘get_categories’ with optional parameters:
- include_description - set to True to return available description for each category. Default = False
- skip - number of categories to skip. this parameter along with count can be used for paginating results
- count - limit the total number of tag categories returned to given count
- order - ASCENDING or DESCENDING. By default, it will be sorted in ascending order
Use case examples¶
Possible future improvements¶
- Versioning - When a value of a tag is changed, users should be prompted to verify if this change denotes a new version or a value correction. If this value denotes a new version, then older value of the tag should preserved in a history/audit store
- Validation of tag values based on data type
- Support for units validation and conversions
- Processing and saving geologic coordinates that can enable users to do geo-spatial queries in databases that support it.