Pixir.Provider.Connection (pixir v0.1.0)

Copy Markdown View Source

Per-key WebSocket connection process for the Responses Provider.

The process owns connection-local optimization state: socket, latest previous_response_id, prompt input prefix, keepalive timers, and temporary degraded/backoff state. It does not own Session History. If continuation state is missing or invalid, the caller can still replay from Pixir's Log over HTTP/SSE or a fresh WebSocket. The default idle window is deliberately agent-scale so ordinary pauses between Turns do not erase same-socket continuation evidence.

Summary

Functions

Returns a specification to start this module under a supervisor.

Functions

child_spec(init_arg)

Returns a specification to start this module under a supervisor.

See Supervisor.

start_link(opts)

stream(key, http_request, acc, fun, opts \\ [])

@spec stream(term(), map(), acc, (term(), acc -> acc), keyword()) ::
  {:ok, acc} | {:error, map(), acc}
when acc: term()

via(key)