Foresight.Reflect.LoopOptions (Foresight v0.3.0)

Copy Markdown View Source

Guards the options reflect hands to LlmCore.Agent.Loop.

Reflect accumulates grounding (cited ids, tool calls, token usage) in the calling process's dictionary while the loop runs its iteration pipeline synchronously in that same process. An asynchronous pipeline would run the stages elsewhere and silently lose every grounding write, so that configuration is refused up front.

Summary

Functions

Raise unless the pipeline runs synchronously (the default).

Attach caller-supplied pipeline options to the loop options, refusing async ones.

Functions

assert_sync!(pipeline_opts)

@spec assert_sync!(keyword()) :: :ok

Raise unless the pipeline runs synchronously (the default).

with_pipeline_opts(loop_opts, pipeline_opts)

@spec with_pipeline_opts(
  keyword(),
  keyword() | nil
) :: keyword()

Attach caller-supplied pipeline options to the loop options, refusing async ones.