Inline tag sytem

I am trying to build a system that will automatically detect keywords in the content of an editor and “tag” that item with a box and add a disable/enable button onto it, like this:

Screen Shot 2020-02-17 at 2.05.45 PM

I am getting confused on which parts of the interface are Marks and Decorations, and if I would need a new plugin to enable this feature?

Has anyone done something similar?

I’ve looked at the Suggestions example (as well as all the others) but that doesn’t quite do what I’m looking to do.