Packages

Prompt Runner SDK - packet-first prompt execution for Elixir and CLI workflows with verifier-owned completion, retry, repair, and git-aware repository orchestration.

Current section

Files

Jump to
prompt_runner_sdk lib prompt_runner rendering sink.ex
Raw

lib/prompt_runner/rendering/sink.ex

defmodule PromptRunner.Rendering.Sink do
@moduledoc """
Behaviour for output destinations that receive rendered prompt-runner text and raw events.
"""
@type state :: term()
@type opts :: keyword()
@callback init(opts()) :: {:ok, state()} | {:error, term()}
@callback write(iodata(), state()) :: {:ok, state()} | {:error, term(), state()}
@callback write_event(event :: map(), iodata(), state()) ::
{:ok, state()} | {:error, term(), state()}
@callback flush(state()) :: {:ok, state()}
@callback close(state()) :: :ok
end