UpdateExperimentPlan
Updates an experiment plan.
Operation description
Updates a specified experiment plan. Unspecified fields remain unchanged. Only plans created by the current account can be updated.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
agentloop:UpdateExperimentPlan |
update |
*Workspace
|
None | None |
Request syntax
PUT /api/v1/experiments/{agentSpace}/plans/{planId} HTTP/1.1
Path Parameters
|
Parameter |
Type |
Required |
Description |
Example |
| agentSpace |
string |
No |
The name of the AgentSpace. |
al-playground-cn-hongkong |
| planId |
string |
No |
The ID of the experiment plan. |
exp-plan-e95bff54685a4ae29ff3a834c1008a71 |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| body |
object |
No |
The request body. Unspecified fields remain unchanged. |
{"planName": "rca_benchmark_eval_experiment", "description": "", "datasetId": "rca_benckmark_eval", "selectedItemIds": [], "querySql": "", "evaluators": [{"variableMapping": {"output": "experiment_output", "input": "experiment_input", "expected_output": "dataset.ground_truth_json"}, "evaluatorRef": "Builtin.agent_correctness", "name": "Builtin.agent_correctness", "filters": {"query": "", "sample": "100"}, "type": "AGENT", "config": {"variables": [], "prompt": ""}, "resultType": "score", "resultName": "Builtin.agent_correctness"}, {"variableMapping": {"output": "experiment_output", "input": "experiment_input", "question": "dataset.question", "expected_output": "dataset.ground_truth_json", "payload_json": "dataset.payload_json"}, "evaluatorRef": "rca-toxicity-safety-accuracy", "name": "rca-toxicity-safety-accuracy", "filters": {"query": "", "sample": "100"}, "type": "AGENT", "config": {"variables": [], "prompt": ""}, "resultType": "score", "resultName": "rca-toxicity-safety-accuracy"}]} |
| planName |
string |
No |
The name of the experiment plan. |
rca_benchmark_eval_experiment |
| experimentType |
string |
No |
The type of the experiment. Valid values:
|
OFFLINE |
| description |
string |
No |
The description. |
rca_benchmark_eval_experiment offline experiment |
| datasetId |
string |
No |
The ID of the associated dataset. |
rca_benckmark_eval |
| datasetProject |
string |
No |
Optional. |
agentspace-project |
| experiments |
array |
No |
The list of experiment configurations. When passed, the entire list is replaced. The number of items must be between 1 and 5. |
[{"label": "A", "name": "baseline", "modelName": "qwen-max"}] |
| ExperimentConfig |
No |
The configuration of a single experiment group. |
{"label":"A","name":"baseline","modelName":"qwen-max"} |
|
| evaluators |
array |
No |
The list of evaluators. If omitted, the list is not modified. If an empty array is passed, the list is cleared. |
[{"evaluatorRef": "Builtin.agent_task_completion"}] |
| Evaluator |
No |
A single evaluator configuration object. |
{"evaluatorRef":"Builtin.agent_task_completion"} |
|
| selectedItemIds |
array |
No |
The list of selected data item IDs in partial dataset mode. If an empty array is passed, the list is cleared. |
[] |
|
string |
No |
The ID of a single data item in the dataset. |
a1b2c3d4-e5f6-7890-abcd-ef1234567890 |
|
| querySql |
string |
No |
The custom query SQL clause in partial dataset mode. |
level > 2 |
| pipelineName |
string |
No |
The name of the associated data processing pipeline. This parameter is optional. If this parameter is not specified, the pipeline is not updated. If an empty character string is specified, the association is dissociated. After the association, when an experiment under this plan executes and completes writing experiment results to the Logstore, the system filters by the traceId of the current experiment trace and invokes PreviewPipeline to write the results processed by the pipeline. |
my-pipeline |
| input |
object |
No |
Optional. |
{"question": "How do I request a refund?"} |
Request example (update the dataset and evaluators of an offline plan)
{
"planName": "rca_benchmark_eval_experiment",
"description": "",
"datasetId": "rca_benckmark_eval",
"selectedItemIds": [],
"querySql": "",
"evaluators": [
{
"variableMapping": {
"output": "experiment_output",
"input": "experiment_input",
"expected_output": "dataset.ground_truth_json"
},
"evaluatorRef": "Builtin.agent_correctness",
"name": "Builtin.agent_correctness",
"filters": {
"query": "",
"sample": "100"
},
"type": "AGENT",
"config": {
"variables": [],
"prompt": ""
},
"resultType": "score",
"resultName": "Builtin.agent_correctness"
},
{
"variableMapping": {
"output": "experiment_output",
"input": "experiment_input",
"question": "dataset.question",
"expected_output": "dataset.ground_truth_json",
"payload_json": "dataset.payload_json"
},
"evaluatorRef": "rca-toxicity-safety-accuracy",
"name": "rca-toxicity-safety-accuracy",
"filters": {
"query": "",
"sample": "100"
},
"type": "AGENT",
"config": {
"variables": [],
"prompt": ""
},
"resultType": "score",
"resultName": "rca-toxicity-safety-accuracy"
}
]
}
Response elements
|
Element |
Type |
Description |
Example |
|
object |
The update experiment plan response. |
{"requestId":"3FE4CD1E-FF41-56BE-B590-7A021D9C1524","planId":"exp-plan-e95bff54685a4ae29ff3a834c1008a71","status":"updated","message":"Experiment plan updated successfully"} |
|
| requestId |
string |
The request ID. |
3FE4CD1E-FF41-56BE-B590-7A021D9C1524 |
| planId |
string |
The ID of the experiment plan. |
exp-plan-e95bff54685a4ae29ff3a834c1008a71 |
| status |
string |
The update result. A value of updated indicates success. |
updated |
| message |
string |
The message. |
Experiment plan updated successfully |
To view the complete updated configuration, call GetExperimentPlan.
{
"planId": "exp-plan-e95bff54685a4ae29ff3a834c1008a71",
"status": "updated"
}
Examples
Success response
JSON format
{
"requestId": "3FE4CD1E-FF41-56BE-B590-7A021D9C1524",
"planId": "exp-plan-e95bff54685a4ae29ff3a834c1008a71",
"status": "updated",
"message": "Experiment plan updated successfully"
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.