feat: support generated-output flow in run_experiment (no prompt_temp…#486
Open
BipinShetty wants to merge 3 commits intomainfrom
Open
feat: support generated-output flow in run_experiment (no prompt_temp…#486BipinShetty wants to merge 3 commits intomainfrom
BipinShetty wants to merge 3 commits intomainfrom
Conversation
…late) - Remove hard ValueError for prompt_template=None in run_experiment(). The API is the authority on flow determination: if the dataset has a generated_output column, the API accepts prompt_template_version_id=None and runs metrics without LLM generation. If not, the API returns 3512. - Experiments.run(): only set default prompt_settings when a template is provided; pass prompt_template_id=None for generated-output flow. - Jobs.create(): make prompt_template_id and prompt_settings Optional; only include them in CreateJobRequest when non-None so the API contract is respected for both flows. - Add 3 tests: generated-output flow, prompt-takes-precedence, and no-prompt-no-dataset raises ValueError. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…dataset_raises Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #486 +/- ##
==========================================
+ Coverage 81.85% 81.87% +0.02%
==========================================
Files 96 96
Lines 9164 9166 +2
==========================================
+ Hits 7501 7505 +4
+ Misses 1663 1661 -2 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
dmcwhorter
approved these changes
Feb 25, 2026
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.
User description
…late)
Shortcut:
Description:
Tests:
Generated description
Below is a concise technical summary of the changes proposed in this PR:
Enables the generated-output flow in experiment runs by allowing
prompt_templateto be optional, shifting flow determination to the API based on dataset content. Updates the experiment and job creation logic to conditionally include prompt-related parameters only when a template is provided.Modified files (1)
Latest Contributors(2)
run_experiment,Experiments.run, andJobs.createto support optional prompt templates and settings, ensuring the API receivesNonevalues for generated-output flows.Modified files (2)
Latest Contributors(2)