Update functions.py
Browse files- functions.py +0 -5
functions.py
CHANGED
@@ -51,7 +51,6 @@ from langchain import VectorDBQA
|
|
51 |
from langchain.chains.question_answering import load_qa_chain
|
52 |
|
53 |
from langchain.prompts import PromptTemplate
|
54 |
-
from langchain.prompts.base import RegexParser
|
55 |
|
56 |
nltk.download('punkt')
|
57 |
|
@@ -64,10 +63,6 @@ HTML_WRAPPER = """<div style="overflow-x: auto; border: 1px solid #e6e9ef; borde
|
|
64 |
margin-bottom: 2.5rem">{}</div> """
|
65 |
|
66 |
#Stuff Chain Type Prompt template
|
67 |
-
output_parser = RegexParser(
|
68 |
-
regex=r"(.*?)\nScore: (.*)",
|
69 |
-
output_keys=["answer", "score"],
|
70 |
-
)
|
71 |
|
72 |
system_template="""Use only the following pieces of finance context to answer the users question thoroughly.
|
73 |
Do not use any information not provided in the context and remember you are a finance expert.
|
|
|
51 |
from langchain.chains.question_answering import load_qa_chain
|
52 |
|
53 |
from langchain.prompts import PromptTemplate
|
|
|
54 |
|
55 |
nltk.download('punkt')
|
56 |
|
|
|
63 |
margin-bottom: 2.5rem">{}</div> """
|
64 |
|
65 |
#Stuff Chain Type Prompt template
|
|
|
|
|
|
|
|
|
66 |
|
67 |
system_template="""Use only the following pieces of finance context to answer the users question thoroughly.
|
68 |
Do not use any information not provided in the context and remember you are a finance expert.
|