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

Add prefix prompt generation to GenAI-Perf #208

Merged
merged 3 commits into from
Dec 10, 2024
Merged

Conversation

dyastremsky
Copy link
Contributor

@dyastremsky dyastremsky commented Dec 6, 2024

Users can now have GenAI-Perf synthetically generate a system prompt pool by setting --num-system-prompts > 0 and setting a --system-prompt-length (default: 100 tokens). This is useful for benchmarking in caching situations (e.g. with prefix caching)

Screenshot:
image

Notice that the token count can be off by one, due to concatenating the system prompt and user prompt, creating a final prompt that can have a slight difference in the number of tokens from the two fragments.

debermudez
debermudez previously approved these changes Dec 6, 2024
@dyastremsky
Copy link
Contributor Author

@nv-hwoo Thank you for providing such fast, high-quality reviews. I really appreciate it! I tried to walk through my logic for each of these (one of them is pending expert input). Happy to talk through any of these points on a call too.

I'll update the unit tests.

Clarify unit test

Remove mentions of system prompt
Copy link
Contributor

@nv-hwoo nv-hwoo left a comment

Choose a reason for hiding this comment

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

LGTM 🚀

@dyastremsky dyastremsky merged commit b13e65c into main Dec 10, 2024
6 checks passed
@dyastremsky dyastremsky deleted the dyas-system-prompts branch December 10, 2024 19:36
@dyastremsky dyastremsky changed the title Add system prompt generation option Add prefix prompt generation to GenAI-Perf Dec 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants