-
Notifications
You must be signed in to change notification settings - Fork 22
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 option to pass 'api_key' to gen_answers, judge_answers #128
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1 to moving to judge and generate in mt_bench. Needs to be an option where ever server_url is passed.
9261d6c
to
a4f3f7b
Compare
a4f3f7b
to
3737621
Compare
@sallyom thanks for the contribution! some CI failures here - you can run the checks locally with |
6b6af51
to
2a0ba52
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good except my question around whether the test changes are helpful and the commits need to be squashed and/or made more descriptive.
4d0d0a3
to
1f049cc
Compare
`api_key` is optional and this PR remains backwards compatible. This allows for externally served models that require authentication. A helper function is added in mt_bench_common for creating the openai_client necessary for model requests. Signed-off-by: sallyom <somalley@redhat.com>
1f049cc
to
3445ce0
Compare
thanks for your review @danmcp, I really appreciate your help. |
Thanks for the commit and working through the minutia! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Appreciate the contribution @sallyom!
I notice the api_key is hard-coded which is preventing from using an external judge server. This adds an optional
api_key
to provide an openai_client in gen_answers and judge_answers. Note, candidate-server & judge-server may have unique tokens so the env var OPENAI_API_KEY should not be used.