Expected numeric type on field [Flag], but got [keyword]

Graylog is using the dynamic mapping feature of Elasticsearch, once a field is generated the type of that ingested content is used.

To avoid that you have multiple field types in different indices having a custom mapping is one solution. Check the content of the fields in a processing pipeline would be another solution.