<commit_before># Third-Party
from django_filters.rest_framework import (
    FilterSet,
    OrderingFilter,
)

# Local
from .models import (
    Award,
    Chart,
    Contestant,
    Convention,
    Entry,
    Group,
    Member,
    Office,
    Officer,
    Organization,
    Panelist,
    Participant,
    Person,
    Round,
    Score,
    Session,
    Venue,
)


class AwardFilter(FilterSet):
    class Meta:
        model = Award
        fields = {
            'nomen': [
                'icontains',
            ],
            'kind': [
                'exact',
            ],
            'season': [
                'exact',
            ],
            'status': [
                'exact',
            ],
            'organization': [
                'exact',
            ],
            'organization__parent': [
                'exact',
            ],
            'organization__name': [
                'exact',
            ],
            'organization__kind': [
                'exact',
            ],
            'organization__officers__office__short_name': [
                'exact',
            ],
            'organization__officers__person__user': [
                'exact',
            ],
            'organization__officers__office__is_award_manager': [
                'exact',
            ],
            'organization__officers__status': [
                'exact',
                'gt',
            ],
        }


class ChartFilter(FilterSet):
    class Meta:
        model = Chart
        fields = {
            'nomen': [
                'icontains',
            ],
            'status': [
                'exact',
                'gte',
            ],
        }


class ContestantFilter(FilterSet):
    class Meta:
        model = Contestant
        fields = {
            'nomen': [
                'icontains',
            ],
        }


class ConventionFilter(FilterSet):
    class Meta:
        model = Convention
        fields = {
            'status': [
                'exact',
                'lt',
            ],
            'year': [
                'exact',
            ],
            'assignments__person__user': [
                'exact',
            ],
            'organization__officers__person__user': [
                'exact',
            ],
            'assignments__kind': [
                'exact',
            ],
        }


class EntryFilter(FilterSet):
    class Meta:<commit_msg>Assignment DRCJ support<commit_after># Third-Party
from django_filters.rest_framework import (
    FilterSet,
    OrderingFilter,
)

# Local
from .models import (
    Award,
    Chart,
    Contestant,
    Convention,
    Entry,
    Group,
    Member,
    Office,
    Officer,
    Organization,
    Panelist,
    Participant,
    Person,
    Round,
    Score,
    Session,
    Venue,
)


class AwardFilter(FilterSet):
    class Meta:
        model = Award
        fields = {
            'nomen': [
                'icontains',
            ],
            'kind': [
                'exact',
            ],
            'season': [
                'exact',
            ],
            'status': [
                'exact',
            ],
            'organization': [
                'exact',
            ],
            'organization__parent': [
                'exact',
            ],
            'organization__name': [
                'exact',
            ],
            'organization__kind': [
                'exact',
            ],
            'organization__officers__office__short_name': [
                'exact',
            ],
            'organization__officers__person__user': [
                'exact',
            ],
            'organization__officers__office__is_award_manager': [
                'exact',
            ],
            'organization__officers__status': [
                'exact',
                'gt',
            ],
        }


class ChartFilter(FilterSet):
    class Meta:
        model = Chart
        fields = {
            'nomen': [
                'icontains',
            ],
            'status': [
                'exact',
                'gte',
            ],
        }


class ContestantFilter(FilterSet):
    class Meta:
        model = Contestant
        fields = {
            'nomen': [
                'icontains',
            ],
        }


class ConventionFilter(FilterSet):
    class Meta:
        model = Convention
        fields = {
            'status': [
                'exact',
                'lt',
            ],
            'year': [
                'exact',
            ],
            'assignments__person__user': [
                'exact',
            ],
            'organization__officers__person__user': [
                'exact',
            ],
            'assignments__kind': [
                'exact',
            ],
            'assignments__category': [
                'exact',
            ],
        }


class EntryFilter(FilterSet):
    class Meta:
{'fraction_non_alphanumeric': 0.10544424205626392, 'fraction_numerical': 0.0, 'mean_word_length': 0.9919387343812979, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, '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': '200095', 'n_tokens_mistral': 1360, 'n_tokens_neox': 1246, 'n_words': 209}