Skip to content

Commit

Permalink
update websearch run
Browse files Browse the repository at this point in the history
  • Loading branch information
ashpreetbedi committed May 3, 2024
1 parent 41c5380 commit 9e8aa34
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions phi/assistant/assistant.py
Original file line number Diff line number Diff line change
Expand Up @@ -1068,13 +1068,19 @@ async def _arun(
llm_response_type = "json"
elif self.markdown:
llm_response_type = "markdown"
functions = {}
if self.llm:
for _func in self.llm.functions:
if isinstance(_func, Function):
functions[_func.name] = _func.to_dict()
event_data = {
"run_type": "assistant",
"user_message": message,
"response": llm_response,
"response_format": llm_response_type,
"messages": llm_messages,
"metrics": self.llm.metrics if self.llm else None,
"functions": functions,
# To be removed
"llm_response": llm_response,
"llm_response_type": llm_response_type,
Expand Down

0 comments on commit 9e8aa34

Please sign in to comment.