import { Column } from "./column.js"; import { ColumnRecipe } from "./column_recipes/index.js"; import { AxisId } from "@milaboratories/pl-model-common"; export interface SplitAxis { /** Index of the axis in the column's axesSpec to split by. */ readonly idx: number; } export interface SplitByAxesOpts { /** * Resolve axis values to human-readable labels. * * Defaults to {@link deriveAxisValuesLabels} over the ambient render ctx * (current block outputs + result pool), resolved lazily on the first * lookup. Pass an explicit callback to narrow the label source, or * `() => undefined` to keep raw axis values. */ axisValuesLabels?: (axisId: AxisId) => undefined | Record; } /** * Split each input column along the requested axes into one * {@link ColumnRecipe} per Cartesian combination of the axes' distinct values. * * The split axes must be partition-key axes of the input's data — the distinct * values are read off the partition keys. * * Each split is produced as `ColumnOverriddenRecipe.wrap(ColumnFilteredRecipe.wrap(inner, axisFilters), { domain, annotations })`: * - `ColumnFilteredRecipe` pins all split axes at once (one wrap call with * every `[idx, value]` pair) and removes them from `axesSpec`. The * engine performs the data slicing via the `sliceAxes` query node. * - `ColumnOverriddenRecipe` overlays a `domain[axisName] = String(value)` * entry per split axis and appends a `split:` trace * entry per split axis to the existing `pl7.app/trace` annotation. * * The recipe id is a canonical * `ColumnOverriddenId(source: ColumnFilteredId(source: inner.id, axisFilters), specOverrides)` * — distinct per split combination, parseable by `extractPObjectId`, and * traversable by recipe walkers. * * Returns `undefined` when any input's `getData()` is not a * {@link TreeNodeAccessor} — partition inspection is not yet possible. */ export declare function splitByAxes(inputs: Column[], splitAxes: SplitAxis[], opts?: SplitByAxesOpts): ColumnRecipe[] | undefined; //# sourceMappingURL=split_by_axes.d.ts.map