<commit_before>"""
Stores HTTPRequestContext
"""
from asphalt.core import Context
from typeguard import check_argument_types

import kyokai


class HTTPRequestContext(Context):
    """
    Sub-class of context used for HTTP requests.
    """

    cfg = {}

    def __init__(self, request, parent: Context):
        assert check_argument_types()
        super().__init__(parent=parent)
        self._request = request

    @property
    def request(self) -> 'kyokai.Request':
        return self._request<commit_msg>Add setter for Request in context.<commit_after>"""
Stores HTTPRequestContext
"""
from asphalt.core import Context
from typeguard import check_argument_types

import kyokai


class HTTPRequestContext(Context):
    """
    Sub-class of context used for HTTP requests.
    """

    cfg = {}

    def __init__(self, request, parent: Context):
        assert check_argument_types()
        super().__init__(parent=parent)
        self._request = request

    @property
    def request(self) -> 'kyokai.Request':
        return self._request

    @request.setter
    def request(self, req: 'kyokai.Request'):
        self._request = req
{'fraction_non_alphanumeric': 0.09860383944153578, 'fraction_numerical': 0.0, 'mean_word_length': 3.2014652014652016, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, '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': '4964744', 'n_tokens_mistral': 330, 'n_tokens_neox': 314, 'n_words': 89}