Skip to content

feat: attach saved parameters to experiments#1550

Merged
Joshua Wootonn (joshuawootonn) merged 6 commits intomainfrom
feat/experiment-parameters-backlinks-sdk
Mar 13, 2026
Merged

feat: attach saved parameters to experiments#1550
Joshua Wootonn (joshuawootonn) merged 6 commits intomainfrom
feat/experiment-parameters-backlinks-sdk

Conversation

@joshuawootonn
Copy link
Contributor

@joshuawootonn Joshua Wootonn (joshuawootonn) commented Mar 12, 2026

Summary

This updates the JavaScript SDK to save parameters information so that I can display in the UI what Parameters were associated with each experiment.

Demo

CleanShot.2026-03-12.at.14.01.13.mp4

Related PRs

) {
const { data, baseExperiment: defaultBaseExperiment } = evaluatorData;
const parameters = await getExperimentParametersRef(evaluator.parameters);
// NOTE: This code is duplicated with initExperiment in js/src/framework.ts.
Copy link
Contributor Author

Choose a reason for hiding this comment

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

You will notice that getExperimentParametersRef is duplicated, and this comment is the reason why I'm just following the pattern of existing code.

@joshuawootonn Joshua Wootonn (joshuawootonn) force-pushed the feat/experiment-parameters-backlinks-sdk branch from a1383fc to c5d91a1 Compare March 12, 2026 19:34
@joshuawootonn
Copy link
Contributor Author

The API surface is technically expanding here. I added a new optional key parameter?: ParametersRef | RemoteEvalParameters<boolean, boolean> to InitOptions. This allows someone calling initExperiment to pass in the parameters associate with this experiment. This was causing a api-compatability CI fail, but I don't think it should since we are expanding InitOptions with a new key that is optional. So I updated the compatibility check in my last commit to not mark this as a breaking change.

@joshuawootonn Joshua Wootonn (joshuawootonn) merged commit 48d8ff8 into main Mar 13, 2026
42 checks passed
@joshuawootonn Joshua Wootonn (joshuawootonn) deleted the feat/experiment-parameters-backlinks-sdk branch March 13, 2026 19:04
@AbhiPrasad
Copy link
Member

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