Skip to content

EngineConfig

Defined in: packages/engine/src/lib/config.ts:10

Dependencies and optional policies used to construct an Engine.

readonly optional history?: HistoryConfig<unknown>

Defined in: packages/engine/src/lib/config.ts:27

Optional history configuration. When omitted, chart_request turns still process normally but nothing is recorded, and assistant_message messages produce a validationError (‘history not configured’) since they have nowhere to be injected.


readonly optional instrument?: Instrument

Defined in: packages/engine/src/lib/config.ts:34

Optional telemetry seam (defaults to noopInstrument). Stages receive it as StageContext.instrument; pipeline wraps every stage with instrument.stage per request, and stages report model calls and other events through instrument.event.


readonly optional logger?: Logger

Defined in: packages/engine/src/lib/config.ts:20

Optional logger (defaults to consoleLogger). Stages receive it as StageContext.logger.


readonly planner: Planner

Defined in: packages/engine/src/lib/config.ts:18

Produces the candidate response for every chart_request. Use a planner implementation as is, or compose stages with pipeline and withFallback. The Engine heals and validates whatever the planner returns against the request the client sent.


readonly optional retry?: false | WithRetryOptions

Defined in: packages/engine/src/lib/config.ts:44

Retry policy the Engine wraps around EngineConfig.planner with withRetry. { max } re-runs the planner up to max times while healing recommends a retry (max is a non-negative integer). false (or { max: 0 }) runs the planner once; the Engine still heals and validates the candidate. Use false for planners that retry their own steps. Default { max: 1 }. See the README’s Retry section for the full policy.