a
    ag	                     @   s   d dl mZmZ d dlmZmZmZmZ d dlm	Z	 dZ
e	e
ZdZedddefgZeeeefgd	Zd
Ze	eZdZedefdgZeeeefgd	ZdS )    )ConditionalPromptSelectoris_chat_model)AIMessagePromptTemplateChatPromptTemplateHumanMessagePromptTemplateSystemMessagePromptTemplate)PromptTemplatea}  The original question is as follows: {question}
We have provided an existing answer: {existing_answer}
We have the opportunity to refine the existing answer (only if needed) with some more context below.
------------
{context_str}
------------
Given the new context, refine the original answer to better answer the question. If the context isn't useful, return the original answer.a  We have the opportunity to refine the existing answer (only if needed) with some more context below.
------------
{context_str}
------------
Given the new context, refine the original answer to better answer the question. If the context isn't useful, return the original answer.)humanz
{question})Zaiz{existing_answer}r	   )Zdefault_promptZconditionalszContext information is below. 
------------
{context_str}
------------
Given the context information and not prior knowledge, answer the question: {question}
zContext information is below.
------------
{context_str}
------------
Given the context information and not prior knowledge, answer any questionssystemN)Z langchain.chains.prompt_selectorr   r   Zlangchain_core.prompts.chatr   r   r   r   Zlangchain_core.prompts.promptr   ZDEFAULT_REFINE_PROMPT_TMPLZfrom_templateZDEFAULT_REFINE_PROMPTZrefine_templateZfrom_messagesZCHAT_REFINE_PROMPTZREFINE_PROMPT_SELECTORZDEFAULT_TEXT_QA_PROMPT_TMPLZDEFAULT_TEXT_QA_PROMPTZchat_qa_prompt_templateZCHAT_QUESTION_PROMPTZQUESTION_PROMPT_SELECTOR r   r   /var/www/html/cobodadashboardai.evdpl.com/venv/lib/python3.9/site-packages/langchain/chains/question_answering/refine_prompts.py<module>   s>   


