feat(AIC-3449): Support pulling in configs for evals from code - #108
Merged
Merged
Conversation
donei003
approved these changes
Sep 24, 2026
donei003
left a comment
Contributor
There was a problem hiding this comment.
Approved. But had some feedback which we can incorporate
| ) | ||
| provider: Any = None | ||
| model_config_key = latest.get("modelConfigKey") | ||
| if isinstance(model_config_key, str) and model_config_key: |
Contributor
There was a problem hiding this comment.
What would happen if this wasn't true?
Contributor
Author
There was a problem hiding this comment.
this check represents validation to make sure that if a model config is set, it's set correctly. I'm restructuring it to be clearer and adding an exception to fail loudly
aknight-ld
force-pushed
the
AIC-3449-support-config-calls
branch
from
September 24, 2026 19:59
c49366c to
39a7e2e
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 39a7e2e. Configure here.
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.

Current build of evaluations from the SDK requires the user to define a generation dict by hand. Callers who want to evaluate a variation that already exists have to copy its model, prompt, and tools by hand. This PR provides functionality to let them name
ai_config+variation, fetch that variation's definition, and treat any explicit argument as an override.Note
Overview
Evaluations
run()can seed settings from an existing AI Config variation instead of requiring a fully hand-builtgenerationdict. Callers passai_configandvariation; the SDK fetches the latest variation (and linked model config) via the management API, builds defaults for model/provider/parameters, prompt, tools, and judges, then applies optionalgeneration,tools, andcriteriaas overrides.generationis now optional when both config keys are provided._merge_generationlayers overrides field-by-field (parameters merge by key; supplyinginstructionsormessagesreplaces both fetched prompt slots). Validation is split into config-source checks (before any I/O) and post-merge generation checks. Variation-attached tools require implementations or the run fails early; attached judges become default criteria whencriteriais omitted. Warnings are logged when a variation pins an older tool version than the API’s latest.Adds
AIConfigVariationparsing and runner helpers_fetch_config_variation/_fetch_model_config, plus broad tests for seeding, overrides, validation, and edge cases.Reviewed by Cursor Bugbot for commit 510d21d. Bugbot is set up for automated code reviews on this repo. Configure here.