How to set up a text format that replaces the tokens?
Token Filter is a very simple module to make token values available as an input filter.

This doesn't mean that all tokens will work in every location. For example, if you use a [node:field_foo] token in the text of a block, the token system will not know which node you are referring to and will not replace the token.
It is up to you when you are implementing this module to be aware of the context for token usage and use them appropriately

https://www.drupal.org/project/token_filter