Skip to content

pipeline

pipeline<Out>(s1): Stage<PlanningInput, PipelineOutput<Out>>

Defined in: packages/engine/src/lib/planner/pipeline.ts:37

Composes stages into a Planner, feeding each stage’s output to the next. The first stage takes PlanningInput, the last produces a PlannerCandidate, and every adjacent pair must agree on the type in between; a mismatch is a compile error at the offending argument. A last stage that produces a wider PlannerOutput makes the result as wide, as PipelineOutput describes: for example a ClarifyingPlanner when it may ask for clarification.

Every stage receives the same StageContext, and runs wrapped by its StageContext.instrument: once per request, just before it runs, under the name given with named or stage-<index>. The first Err (a Deferred or an EngineError) stops the pipeline and is returned unchanged. If the request’s signal aborts while a stage is running, the next stage does not start and the pipeline returns a CancellationError.

Accepts one to nine stages.

Out extends PlannerOutput

Stage<PlanningInput, Out>

Stage<PlanningInput, PipelineOutput<Out>>

const planner = pipeline(selectVessels, arrangeLayout);

pipeline<A, Out>(s1, s2): Stage<PlanningInput, PipelineOutput<Out>>

Defined in: packages/engine/src/lib/planner/pipeline.ts:40

Composes stages into a Planner, feeding each stage’s output to the next. The first stage takes PlanningInput, the last produces a PlannerCandidate, and every adjacent pair must agree on the type in between; a mismatch is a compile error at the offending argument. A last stage that produces a wider PlannerOutput makes the result as wide, as PipelineOutput describes: for example a ClarifyingPlanner when it may ask for clarification.

Every stage receives the same StageContext, and runs wrapped by its StageContext.instrument: once per request, just before it runs, under the name given with named or stage-<index>. The first Err (a Deferred or an EngineError) stops the pipeline and is returned unchanged. If the request’s signal aborts while a stage is running, the next stage does not start and the pipeline returns a CancellationError.

Accepts one to nine stages.

A

Out extends PlannerOutput

Stage<PlanningInput, A>

Stage<A, Out>

Stage<PlanningInput, PipelineOutput<Out>>

const planner = pipeline(selectVessels, arrangeLayout);

pipeline<A, B, Out>(s1, s2, s3): Stage<PlanningInput, PipelineOutput<Out>>

Defined in: packages/engine/src/lib/planner/pipeline.ts:44

Composes stages into a Planner, feeding each stage’s output to the next. The first stage takes PlanningInput, the last produces a PlannerCandidate, and every adjacent pair must agree on the type in between; a mismatch is a compile error at the offending argument. A last stage that produces a wider PlannerOutput makes the result as wide, as PipelineOutput describes: for example a ClarifyingPlanner when it may ask for clarification.

Every stage receives the same StageContext, and runs wrapped by its StageContext.instrument: once per request, just before it runs, under the name given with named or stage-<index>. The first Err (a Deferred or an EngineError) stops the pipeline and is returned unchanged. If the request’s signal aborts while a stage is running, the next stage does not start and the pipeline returns a CancellationError.

Accepts one to nine stages.

A

B

Out extends PlannerOutput

Stage<PlanningInput, A>

Stage<A, B>

Stage<B, Out>

Stage<PlanningInput, PipelineOutput<Out>>

const planner = pipeline(selectVessels, arrangeLayout);

pipeline<A, B, C, Out>(s1, s2, s3, s4): Stage<PlanningInput, PipelineOutput<Out>>

Defined in: packages/engine/src/lib/planner/pipeline.ts:49

Composes stages into a Planner, feeding each stage’s output to the next. The first stage takes PlanningInput, the last produces a PlannerCandidate, and every adjacent pair must agree on the type in between; a mismatch is a compile error at the offending argument. A last stage that produces a wider PlannerOutput makes the result as wide, as PipelineOutput describes: for example a ClarifyingPlanner when it may ask for clarification.

Every stage receives the same StageContext, and runs wrapped by its StageContext.instrument: once per request, just before it runs, under the name given with named or stage-<index>. The first Err (a Deferred or an EngineError) stops the pipeline and is returned unchanged. If the request’s signal aborts while a stage is running, the next stage does not start and the pipeline returns a CancellationError.

Accepts one to nine stages.

A

B

C

Out extends PlannerOutput

Stage<PlanningInput, A>

Stage<A, B>

Stage<B, C>

Stage<C, Out>

Stage<PlanningInput, PipelineOutput<Out>>

const planner = pipeline(selectVessels, arrangeLayout);

pipeline<A, B, C, D, Out>(s1, s2, s3, s4, s5): Stage<PlanningInput, PipelineOutput<Out>>

Defined in: packages/engine/src/lib/planner/pipeline.ts:55

Composes stages into a Planner, feeding each stage’s output to the next. The first stage takes PlanningInput, the last produces a PlannerCandidate, and every adjacent pair must agree on the type in between; a mismatch is a compile error at the offending argument. A last stage that produces a wider PlannerOutput makes the result as wide, as PipelineOutput describes: for example a ClarifyingPlanner when it may ask for clarification.

Every stage receives the same StageContext, and runs wrapped by its StageContext.instrument: once per request, just before it runs, under the name given with named or stage-<index>. The first Err (a Deferred or an EngineError) stops the pipeline and is returned unchanged. If the request’s signal aborts while a stage is running, the next stage does not start and the pipeline returns a CancellationError.

Accepts one to nine stages.

A

B

C

D

Out extends PlannerOutput

Stage<PlanningInput, A>

Stage<A, B>

Stage<B, C>

Stage<C, D>

Stage<D, Out>

Stage<PlanningInput, PipelineOutput<Out>>

const planner = pipeline(selectVessels, arrangeLayout);

pipeline<A, B, C, D, E, Out>(s1, s2, s3, s4, s5, s6): Stage<PlanningInput, PipelineOutput<Out>>

Defined in: packages/engine/src/lib/planner/pipeline.ts:62

Composes stages into a Planner, feeding each stage’s output to the next. The first stage takes PlanningInput, the last produces a PlannerCandidate, and every adjacent pair must agree on the type in between; a mismatch is a compile error at the offending argument. A last stage that produces a wider PlannerOutput makes the result as wide, as PipelineOutput describes: for example a ClarifyingPlanner when it may ask for clarification.

Every stage receives the same StageContext, and runs wrapped by its StageContext.instrument: once per request, just before it runs, under the name given with named or stage-<index>. The first Err (a Deferred or an EngineError) stops the pipeline and is returned unchanged. If the request’s signal aborts while a stage is running, the next stage does not start and the pipeline returns a CancellationError.

Accepts one to nine stages.

A

B

C

D

E

Out extends PlannerOutput

Stage<PlanningInput, A>

Stage<A, B>

Stage<B, C>

Stage<C, D>

Stage<D, E>

Stage<E, Out>

Stage<PlanningInput, PipelineOutput<Out>>

const planner = pipeline(selectVessels, arrangeLayout);

pipeline<A, B, C, D, E, F, Out>(s1, s2, s3, s4, s5, s6, s7): Stage<PlanningInput, PipelineOutput<Out>>

Defined in: packages/engine/src/lib/planner/pipeline.ts:70

Composes stages into a Planner, feeding each stage’s output to the next. The first stage takes PlanningInput, the last produces a PlannerCandidate, and every adjacent pair must agree on the type in between; a mismatch is a compile error at the offending argument. A last stage that produces a wider PlannerOutput makes the result as wide, as PipelineOutput describes: for example a ClarifyingPlanner when it may ask for clarification.

Every stage receives the same StageContext, and runs wrapped by its StageContext.instrument: once per request, just before it runs, under the name given with named or stage-<index>. The first Err (a Deferred or an EngineError) stops the pipeline and is returned unchanged. If the request’s signal aborts while a stage is running, the next stage does not start and the pipeline returns a CancellationError.

Accepts one to nine stages.

A

B

C

D

E

F

Out extends PlannerOutput

Stage<PlanningInput, A>

Stage<A, B>

Stage<B, C>

Stage<C, D>

Stage<D, E>

Stage<E, F>

Stage<F, Out>

Stage<PlanningInput, PipelineOutput<Out>>

const planner = pipeline(selectVessels, arrangeLayout);

pipeline<A, B, C, D, E, F, G, Out>(s1, s2, s3, s4, s5, s6, s7, s8): Stage<PlanningInput, PipelineOutput<Out>>

Defined in: packages/engine/src/lib/planner/pipeline.ts:79

Composes stages into a Planner, feeding each stage’s output to the next. The first stage takes PlanningInput, the last produces a PlannerCandidate, and every adjacent pair must agree on the type in between; a mismatch is a compile error at the offending argument. A last stage that produces a wider PlannerOutput makes the result as wide, as PipelineOutput describes: for example a ClarifyingPlanner when it may ask for clarification.

Every stage receives the same StageContext, and runs wrapped by its StageContext.instrument: once per request, just before it runs, under the name given with named or stage-<index>. The first Err (a Deferred or an EngineError) stops the pipeline and is returned unchanged. If the request’s signal aborts while a stage is running, the next stage does not start and the pipeline returns a CancellationError.

Accepts one to nine stages.

A

B

C

D

E

F

G

Out extends PlannerOutput

Stage<PlanningInput, A>

Stage<A, B>

Stage<B, C>

Stage<C, D>

Stage<D, E>

Stage<E, F>

Stage<F, G>

Stage<G, Out>

Stage<PlanningInput, PipelineOutput<Out>>

const planner = pipeline(selectVessels, arrangeLayout);

pipeline<A, B, C, D, E, F, G, H, Out>(s1, s2, s3, s4, s5, s6, s7, s8, s9): Stage<PlanningInput, PipelineOutput<Out>>

Defined in: packages/engine/src/lib/planner/pipeline.ts:89

Composes stages into a Planner, feeding each stage’s output to the next. The first stage takes PlanningInput, the last produces a PlannerCandidate, and every adjacent pair must agree on the type in between; a mismatch is a compile error at the offending argument. A last stage that produces a wider PlannerOutput makes the result as wide, as PipelineOutput describes: for example a ClarifyingPlanner when it may ask for clarification.

Every stage receives the same StageContext, and runs wrapped by its StageContext.instrument: once per request, just before it runs, under the name given with named or stage-<index>. The first Err (a Deferred or an EngineError) stops the pipeline and is returned unchanged. If the request’s signal aborts while a stage is running, the next stage does not start and the pipeline returns a CancellationError.

Accepts one to nine stages.

A

B

C

D

E

F

G

H

Out extends PlannerOutput

Stage<PlanningInput, A>

Stage<A, B>

Stage<B, C>

Stage<C, D>

Stage<D, E>

Stage<E, F>

Stage<F, G>

Stage<G, H>

Stage<H, Out>

Stage<PlanningInput, PipelineOutput<Out>>

const planner = pipeline(selectVessels, arrangeLayout);