Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
chyroc committed Mar 4, 2025
1 parent 2d8569c commit 01c9a75
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
6 changes: 4 additions & 2 deletions examples/benchmark_ark_text.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,9 +71,11 @@ async def main():
times = 100
text_latency = []
for i in range(times):
logid, text, latency = test_latency(ep, token, text)
logid, first_text, latency = test_latency(ep, token, text)
text_latency.append(latency)
print(f"[latency.ark.text] {i}, latency: {cal_latency(latency, text_latency)}, log: {logid}, text: {text}")
print(
f"[latency.ark.text] {i}, latency: {cal_latency(latency, text_latency)}, log: {logid}, text: {first_text}"
)


if __name__ == "__main__":
Expand Down
4 changes: 2 additions & 2 deletions examples/benchmark_text_chat.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,9 +115,9 @@ async def main():
times = 100
text_latency = []
for i in range(times):
logid, text, latency = await test_latency(coze, bot_id, text)
logid, first_text, latency = await test_latency(coze, bot_id, text)
text_latency.append(latency)
print(f"[latency.text] {i}, latency: {cal_latency(latency, text_latency)}, log: {logid}, text: {text}")
print(f"[latency.text] {i}, latency: {cal_latency(latency, text_latency)}, log: {logid}, text: {first_text}")


if __name__ == "__main__":
Expand Down

0 comments on commit 01c9a75

Please sign in to comment.