export_code
Export any saved estimator or pipeline as executable Python code. Provide a handle ID and optional variable name to generate runnable code with fit example.
Instructions
Export an estimator or pipeline as executable Python code
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": {
"handle": "<handle>"
},
"name": "export_code"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| handle | Yes | Handle ID of the estimator/pipeline to export | |
| dataset | No | Optional dataset name for the fit example (e.g. 'airline', 'sunspots'). Defaults to 'airline' if omitted. | |
| var_name | No | Variable name to use in generated code (default: 'model') | model |
| include_fit_example | No | Whether to include a fit/predict example (default: false) |