Skip to content

Commit

Permalink
fix print log (#84)
Browse files Browse the repository at this point in the history
  • Loading branch information
RexWzh authored Jun 23, 2024
1 parent 3b25b79 commit 950937d
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 1 deletion.
1 change: 1 addition & 0 deletions chattool/chattype.py
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,7 @@ def display_role_content(dic:dict, sep:Union[str, None]=None):
return f"{sep}{role}{sep}calling tool:\n{pformat(tools)}"
if 'function_call' in dic:
return f"{sep}{role}{sep}calling function:\n{pformat(dic['function_call'])}"
return f"{sep}{role}{sep}{content}"
else:
raise Exception(f"Unknown role {role}")

Expand Down
1 change: 0 additions & 1 deletion tests/test_chattool.py
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,6 @@ def test_error_message():
assert resp.error_code == "invalid_api_key"
assert resp.is_valid() == False


def test_usage():
resp = Resp(response=response)
assert resp.total_tokens == 18
Expand Down

0 comments on commit 950937d

Please sign in to comment.