Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(llm): support record QPS by decorator #76

Merged
merged 7 commits into from
Sep 1, 2024

Conversation

ChenZiHong-Gavin
Copy link
Contributor

No description provided.

@github-actions github-actions bot added the llm label Aug 31, 2024
@ChenZiHong-Gavin ChenZiHong-Gavin marked this pull request as ready for review September 1, 2024 01:04
@dosubot dosubot bot added size:M This PR changes 30-99 lines, ignoring generated files. enhancement New feature or request labels Sep 1, 2024
result = func(*args, **kwargs)
call_count = result.get("call_count", 0)
qps = call_count / (time.perf_counter() - start)
log.debug("%s LLM QPS: %.2f", args[0].__class__.__name__, qps)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ignore time gap < 0.10

@imbajin imbajin merged commit c399b3b into apache:main Sep 1, 2024
11 checks passed
@imbajin imbajin changed the title feat(llm): add llm qps feat(llm): support record QPS by decorator Sep 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request llm size:M This PR changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants