Skip to content

Commit 8eb19b3

Browse files
fix: Inject dynamic client name into Azure OpenAI host instructions (#482)
* Fix: Updated function_app.py for Azure Function * Remove unused dotenv import
1 parent 262ec7f commit 8eb19b3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/AzureFunction/function_app.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -339,7 +339,7 @@ async def stream_openai_text(req: Request) -> StreamingResponse:
339339
"If the user references a name that clearly differs from '{SelectedClientName}', respond only with: 'Please only ask questions about the selected client or select another client.' Otherwise, provide thorough answers for every question using only data from SQL or call transcripts."
340340
"If no data is found, respond with 'No data found for that client.' Remove any client identifiers from the final response."
341341
)
342-
342+
HOST_INSTRUCTIONS = HOST_INSTRUCTIONS.replace("{SelectedClientName}", selected_client_name)
343343
#Create the agent using the Semantic Kernel Assistant Agent
344344
kernel = Kernel()
345345
kernel.add_plugin(ChatWithDataPlugin(), plugin_name="ChatWithData")

0 commit comments

Comments
 (0)