Update synonym in real time

Hi,

Good questions, in general, if you use synonyms in your analysis chain at index time this means Elasticsearch is writing whatever tokens the synonym filter adds/changes to the index, so in order to change that you will need to reindex. However, most of the use cases don't require index time synonym expansion, but most of the time its enough to apply synonyms in your query. This does not require re-indexation (because no document is changed).
In order to change the synonyms you still need to change the files containing the dictionary on all nodes though (loading from external sources or changing from UI is currently not possible but surely on the roadmap). Since version 7.3 there is an API to reload search analyzers which you can use to reload the synonyms after changing them on disk. Before version 7.3 reloading the analyzer required to close and reopen the index.
Yet another alternative would be to use query expansion on the client side, so your client logic would intercept the user query before sending it to elasticsearch and add alternative search terms as e.g. OR clauses.
Hope this helps.