This commit is contained in:
Manuel Soria
2023-11-12 18:27:46 -03:00
parent e65b73157e
commit 362e1c5233
2 changed files with 3 additions and 2 deletions

View File

@@ -13,7 +13,7 @@ from prompt_templates import postgresql_template, final_template
"""
# TODO explain how to setup
IMPORTANT: For using this template, you will need to follow the setup steps in the readme file
"""
if os.environ.get("OPENAI_API_KEY", None) is None:
@@ -49,6 +49,7 @@ def get_query(query):
sql_query = re.sub(r"\[([\w\s,]+)\]", replace_brackets, query)
return sql_query
# -----------------------
# Now we create the chain
# -----------------------

View File

@@ -6,7 +6,7 @@ Pay attention to use only the column names you can see in the tables below. Be c
Pay attention to use date('now') function to get the current date, if the question involves "today".
You can use an extra extension which allows you to run semantic similarity using <-> operator on tables containing columns named "embeddings".
<-> operator can ONLY be used on embeddings columns.
<-> operator can ONLY be used on embeddings vector columns.
The embeddings value for a given row typically represents the semantic meaning of that row.
The vector represents an embedding representation of the question, given below.
Do NOT fill in the vector values directly, but rather specify a `[search_word]` placeholder, which should contain the word that would be embedded for filtering.