403Webshell
Server IP : 54.37.205.81  /  Your IP : 216.73.216.76
Web Server : nginx/1.22.1
System : Linux vps-249481fa 6.1.0-50-cloud-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.176-1 (2026-07-02) x86_64
User : debian ( 1000)
PHP Version : 8.2.32
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : OFF
Directory :  /usr/lib/python3/dist-packages/nltk/chat/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /usr/lib/python3/dist-packages/nltk/chat/__pycache__/util.cpython-311.pyc
�

 T�c2���ddlZddlZidd�dd�dd�dd�d	d
�dd�d
d�dd�dd�dd�dd�dd�dd�dd�dd�dd�ZGd�d��ZdS)�Nzi amzyou arezi waszyou were�i�youzi'mzi'dz	you wouldzi'vezyou havezi'llzyou will�my�yourzI amzI waszyou'vezI havezyou'llzI will�yours�mine�mec�8�eZdZifd�Zd�Zd�Zd�Zd�Zd	d�ZdS)
�Chatc�h�d�|D��|_||_|���|_dS)a�
        Initialize the chatbot.  Pairs is a list of patterns and responses.  Each
        pattern is a regular expression matching the user's statement or question,
        e.g. r'I like (.*)'.  For each such pattern a list of possible responses
        is given, e.g. ['Why do you like %1', 'Did you ever dislike %1'].  Material
        which is matched by parenthesized sections of the patterns (e.g. .*) is mapped to
        the numbered positions in the responses, e.g. %1.

        :type pairs: list of tuple
        :param pairs: The patterns and responses
        :type reflections: dict
        :param reflections: A mapping between first and second person expressions
        :rtype: None
        c�V�g|]&\}}tj|tj��|f��'S�)�re�compile�
IGNORECASE)�.0�x�ys   �0/usr/lib/python3/dist-packages/nltk/chat/util.py�
<listcomp>z!Chat.__init__.<locals>.<listcomp>3s/��M�M�M�V�a���
�1�b�m�4�4�a�8�M�M�M�N)�_pairs�_reflections�_compile_reflections�_regex)�self�pairs�reflectionss   r�__init__z
Chat.__init__#s9�� N�M�u�M�M�M���'����/�/�1�1����rc
���t|jtd���}tjd�d�ttj|������tj	��S)NT)�key�reversez\b({})\b�|)
�sortedr�lenrr�format�join�map�escaper)r�sorted_refls  rrzChat._compile_reflections7sZ���T�.�C��F�F�F���z����s�x�x��B�I�{�(C�(C�D�D�E�E�r�}�
�
�	
rc�d���j��fd�|�����S)z�
        Substitute words in the string, according to the specified reflections,
        e.g. "I'm" -> "you are"

        :type str: str
        :param str: The string to be mapped
        :rtype: str
        c����j|j|���|����S)N)r�string�start�end)�mors �r�<lambda>z"Chat._substitute.<locals>.<lambda>Hs+���t�(���2�8�8�:�:������3H�)I�J�r)r�sub�lower)r�strs` r�_substitutezChat._substitute=s3����{���J�J�J�J�C�I�I�K�K�
�
�	
rc�.�|�d��}|dkryt||dz|dz���}|d|�|�|�|����z||dzd�z}|�d��}|dk�y|S)N�%r��)�find�intr5�group)r�response�match�pos�nums     r�
_wildcardszChat._wildcardsKs����m�m�C� � ���Q�h�h��h�s�Q�w��q��0�1�2�2�C���#����"�"�5�;�;�s�#3�#3�4�4�5��3��7�9�9�%�&�
�
�-�-��$�$�C��Q�h�h��rc��|jD]�\}}|�|��}|rdtj|��}|�||��}|dd�dkr
|dd�dz}|dd�dkr
|dd�dz}|cS��dS)z�
        Generate a response to the user input.

        :type str: str
        :param str: The string to be mapped
        :rtype: str
        ���Nz?.�.z??�?)rr>�random�choicerA)rr4�patternr=r>�resps      r�respondzChat.respondWs���$(�;�
	�
	��W�h��M�M�#�&�&�E��	
��}�X�.�.�����t�U�3�3������9��$�$�����9�s�?�D�����9��$�$�����9�s�?�D�����	
�	
	�
	r�quitc��d}||kr||}	td��}n#t$rt|��YnwxYw|r@|ddvr|dd�}|ddv�t|�|����||k�zdSdS)N��>���z!.)�input�EOFError�printrJ)rrK�
user_inputs   r�conversez
Chat.converseqs����
��D� � ��J�
"�"�3�Z�Z�
�
���
"�
"�
"��j�!�!�!�!�!�
"�����
0� ��n��,�,�!+�C�R�C��J�!��n��,�,��d�l�l�:�.�.�/�/�/��D� � � � � � s��8�8N)rK)	�__name__�
__module__�__qualname__rrr5rArJrTrrrrr"s{������*,�2�2�2�2�(
�
�
�
�
�
�
�
�
����40�0�0�0�0�0rr)rFrrrrrr�<module>rXs���
�
�
�	�	�	�	��
�I���Z�����
�9�	�

�;���J�
��J��	�&���v�����
�h��
�h���D���V��
�4�� 	�%�!��(Z0�Z0�Z0�Z0�Z0�Z0�Z0�Z0�Z0�Z0r

Youez - 2016 - github.com/yon3zu
LinuXploit