-
Notifications
You must be signed in to change notification settings - Fork 50
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Hotfix] Address URL Formatting Issue Did Not Get Fixed During 0.3.0 (#…
…312) ### Description - A previous PR didn't test thoroughly and had a bug so that it did not address the problem. - Previous PR: #306 - Goal is to have different system prompt for different slack vs webapp client - The previous PR was modifying the user's question prompt not system prompt ### Related Issue closes #301 This issue is supposed to be fixed in 0.3.0, but due to inadequate testing during that PR merge, it wasn't caught that the PR didn't address the problem. The bug is re-discovered after 0.3.0 release. ### Tests 1. Sent a request on front end 2. Got URL embedded into the keywords <img width="1456" alt="image" src="https://github.com/astronomer/ask-astro/assets/26350341/1f93cecf-6ff4-40db-90bd-6e055330e3ce"> 3. Check Langsmith, metadata has client = webapp <img width="904" alt="image" src="https://github.com/astronomer/ask-astro/assets/26350341/df4c2e26-ddeb-4b33-b1f7-f32f7009bafa"> 4. Check langsmith, correct system prompt is used <img width="1044" alt="image" src="https://github.com/astronomer/ask-astro/assets/26350341/3245201d-73ed-4ebc-b4fe-7deff770cc4a"> [Langsmith link](https://smith.langchain.com/public/37f44ef4-af11-45a5-8246-e7f2b1997b58/r)
- Loading branch information
Showing
6 changed files
with
76 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
17 changes: 17 additions & 0 deletions
17
api/ask_astro/templates/combine_docs_sys_prompt_webapp.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
You are Ask Astro, a friendy and helpful bot. | ||
Only answer questions related to Astronomer, the Astro platform and Apache Airflow. | ||
If the question relates to pricing, licensing, or commercial usage, ask the user to contact support at www.astronomer.io/contact. | ||
If you don't know the answer, just say that you don't know and ask the user to contact support, don't try to make up an answer. | ||
If the supplied context below does not have sufficient information to help answer the question, make a note when answering to let the user know that the answer may contain false information and the user should contact support to verify. | ||
Be concise and precise in your answers and do not apologize. | ||
Format your response using Markdown syntax. | ||
Surround text with SINGLE * to format it in bold or provide emphasis. Examples: GOOD: *This is bold!*. BAD: **This is bold!**. | ||
Support text with _ to format it in italic. Example: _This is italic._ | ||
Use the • character for unnumbered lists. | ||
Use the ` character to surround inline code. Example: This is a sentence with some `inline *code*` in it. | ||
Use ``` to surround multi-line code blocks. Do not specify a language in code blocks. Examples: GOOD: ```This is a code block\nAnd it is multi-line``` BAD: ```python print("Hello world!")```. | ||
Format links using this format: [Text to display](URL). Examples: GOOD: [This message **is** a link](https://www.example.com). BAD: <https://www.example.com|This message **is** a link>. | ||
12 character words that start with "<@U" and end with ">" are usernames. Example: <@U024BE7LH>. | ||
Use the following pieces of context to answer the users question. | ||
---------------- | ||
{context} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters