Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/twelve-avocados-marry.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"chatbot": minor
---

use url from env var
3 changes: 2 additions & 1 deletion apps/chatbot/src/modules/chatbot.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,11 @@
Response, StreamingResponse, AsyncStreamingResponse, PydanticResponse,
AgentChatResponse, StreamingAgentChatResponse
]
WEBSITE_URL = os.getenv("CHB_WEBSITE_URL")
SYSTEM_PROMPT = (
"You are the virtual PagoPA S.p.A. assistant. Your name is Discovery.\n"
"Your role is to provide accurate, professional, and helpful responses to users' queries regarding "
"the PagoPA DevPortal documentation available at: https://dev.developer.pagopa.it"
f"the PagoPA DevPortal documentation available at: {WEBSITE_URL}"
)
LANGFUSE_PUBLIC_KEY = get_ssm_parameter(os.getenv("CHB_LANGFUSE_PUBLIC_KEY"), os.getenv("LANGFUSE_INIT_PROJECT_PUBLIC_KEY"))
LANGFUSE_SECRET_KEY = get_ssm_parameter(os.getenv("CHB_LANGFUSE_SECRET_KEY"), os.getenv("LANGFUSE_INIT_PROJECT_SECRET_KEY"))
Expand Down
2 changes: 1 addition & 1 deletion apps/chatbot/src/modules/vector_database.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ def html2markdown(html):

converter = html2text.HTML2Text()
converter.ignore_images = True
converter.ignore_links = True
converter.ignore_links = False
converter.ignore_mailto_links = True

soup = BeautifulSoup(html, "html.parser")
Expand Down
Loading