Visualizing text

Hi everyone,
my goal is to visualize text using Streamlit (to be more specific I want to visualize the output of a sequence tagging task). I have two main questions:

  1. Is it possible to change the opacity of \colorbox elements in katex? The documentation only refers to six-digit HEX codes?
  2. Can I add textboxes/Tooltip to display the feature values when hovering over a token in the sentence? Which one of the text options would be the best to use?

Thank you for your help in advance,