Reshapes
← Relifold documentationDistribute
Route each row to one or more output Spaces.
Distribute sends every row to the output Spaces returned by a deterministic routing function.
Worked example
Distribute(
name="route-by-market",
input_spaces=("news",),
output_spaces=("us-news", "eu-news", "global-news"),
distribute_by=target_markets,
)| Parameter | Default | Meaning |
|---|---|---|
input_spaces | required | The Space or Spaces read by the reshape. |
name | required | A stable node name shown in the pipeline and session. |
output_spaces | required | Every allowed destination Space. |
distribute_by | required | A callable from one row to one or more declared destination names. |
Output
Each input row appears in every destination returned for it.
Design guidance
A row may be sent to several outputs, so Distribute is not necessarily a partition.