def METHOD_NAME(settings: Dict[str, Any], supported_langs: List[str] = None):
    lang2elastic_stop = {
        "en": english.STOPWORDS,
        "es": "_spanish_",
        "fr": "_french_",
        "de": "_german_",
    }
    supported_langs = supported_langs or [lang for lang in lang2elastic_stop]
    def get_value_with_defaults(data: dict, key: str, default):
        prop = data.get(key)
        if prop is None:
            data[key] = default
        return data[key]
    analysis = get_value_with_defaults(settings, "analysis", {})
    filter = get_value_with_defaults(analysis, "filter", {})
    analyzer = get_value_with_defaults(analysis, "analyzer", {})
    filters = []
    for lang in supported_langs:
        stopwords = lang2elastic_stop.get(lang)
        if stopwords:
            filter[lang] = {
                "type": "stop",
                "stopwords": stopwords,
            }
            filters.append(lang)
    analyzer[MULTILINGUAL_STOP_ANALYZER_REF] = {
        "tokenizer": "lowercase",
        "filter": filters,
    }
    return settings