Ivan, thank you for the suggestion, but I ended up implimenting the following change to your code and I think this is good enough for now:
your code (does not filter by Tags, it just takes all available tags):
my code (filters by the user input FromTags):
I applied the same to the Categories and it is working now.
thanks for all the help.