Prompt Fetching#4
Merged
Andrew Kent (realark) merged 3 commits intoOct 23, 2025
Merged
Conversation
f07856f to
7fc149d
Compare
de33568 to
5a7dc09
Compare
eca8268 to
da5a759
Compare
d4ad8d3 to
c61b40b
Compare
22e1e26 to
7eab143
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Braintrustutility as a convenient main entry point to the SDKExample:
{ // simple example var prompt = braintrust.promptLoader().load("kind-greeter-69d2"); var response = openAIClient .chat() .completions() .create( buildChatCompletionsPrompt( prompt, Map.of("name", "Sam Malone"))); System.out.println("got response: %s".formatted(response.choices().get(0).message())); } { // more complex prompt options var prompt = braintrust .promptLoader() .load( PromptLoadRequest.builder() .projectName("andrew-misc") .promptSlug("unkind-greeter-fd4c") .version("cbbc711da9f7d445") .defaults("model", "gpt-3.5-turbo") .build()); var response = openAIClient .chat() .completions() .create( buildChatCompletionsPrompt( prompt, Map.of("name", "Frasier Crane"))); System.out.println("got response: %s".formatted(response)); }