o
    Zh                     @   s^   d Z ddlmZmZ ddlmZ ddlmZ ddlm	Z	 de
ddfd	d
ZG dd deZdS )zTool for asking human input.    )CallableOptional)CallbackManagerForToolRun)BaseTool)FieldtextreturnNc                 C   s   t d t |  d S )N
)print)r    r   [/var/www/html/lang_env/lib/python3.10/site-packages/langchain_community/tools/human/tool.py_print_func
   s   r   c                   @   s~   e Zd ZU dZdZeed< dZeed< edd dZ	e
egd	f ed
< edd dZe
ed< 		ddedee defddZd	S )HumanInputRunzTool that asks user for input.ZhumannamezYou can ask a human for guidance when you think you got stuck or you are not sure what to do next. The input should be a question for the human.descriptionc                   C      t S N)r   r   r   r   r   <lambda>       zHumanInputRun.<lambda>)default_factoryNprompt_funcc                   C   r   r   )inputr   r   r   r   r      r   
input_funcqueryrun_managerr   c                 C   s   |  | |  S )zUse the Human input tool.)r   r   )selfr   r   r   r   r   _run   s   
zHumanInputRun._runr   )__name__
__module____qualname____doc__r   str__annotations__r   r   r   r   r   r   r   r   r   r   r   r   r      s   
 
 r   )r    typingr   r   Zlangchain_core.callbacksr   Zlangchain_core.toolsr   Zpydanticr   r!   r   r   r   r   r   r   <module>   s    