<commit_before>"""
The idea of MultilingualManager is taken from
django-linguo by <NAME>

https://github.com/zmathew/django-linguo
"""
from django.db import models
from django.db.models.fields.related import RelatedField
from django.utils.translation import get_language
from django.utils.tree import Node

from modeltranslation.utils import build_localized_fieldname
from modeltranslation import settings


_registry = {}
<commit_msg>Used get_language from modeltranslation.utils. Otherwise the returned language isn't guaranteed to be in the LANGUAGES setting and the manager might rewrite the field name to something like foo_en_us.<commit_after>"""
The idea of MultilingualManager is taken from
django-linguo by <NAME>

https://github.com/zmathew/django-linguo
"""
from django.db import models
from django.db.models.fields.related import RelatedField
from django.utils.tree import Node

from modeltranslation.utils import build_localized_fieldname, get_language
from modeltranslation import settings


_registry = {}

{'fraction_non_alphanumeric': 0.06562193927522038, 'fraction_numerical': 0.0, 'mean_word_length': 5.905405405405405, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5187799', 'n_tokens_mistral': 272, 'n_tokens_neox': 264, 'n_words': 98}