Sweep one parameter and compare real results
optimizeSlices the same model once per value of one config key, then returns measured print time and filament usage sorted by print time so you can compare parameter costs.
Instructions
Build and actually slice the same model once per value of a single config key, then return a table of measured print time and filament usage sorted fastest first. This answers questions like 'how much time does support_threshold_angle cost me?' with sliced numbers instead of guesses.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"input": "<input>",
"sweep_param": "<sweep_param>",
"values": "<values>"
},
"name": "optimize"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| input | Yes | Path to .stl or .3mf | |
| values | Yes | Values to try | |
| machine | No | ||
| process | No | ||
| filament | No | ||
| output_dir | No | Where to save sliced output. Default: <input dir>/bambu_sweep, keeping only the best run. When set explicitly, every successful run is kept. | |
| sweep_param | Yes | Config key to vary, e.g. support_threshold_angle, layer_height | |
| base_overrides | No | Overrides applied to every run | |
| timeout_seconds | No |