@usine/engine/run-reader
Classes
Section titled “Classes”RunEvidence
Section titled “RunEvidence”A Run snapshot and all its saved transcript entries from the same database transaction.
Extends
Section titled “Extends”Schema.Class
Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new RunEvidence(…
args):RunEvidence
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
…args |
[props: object, options?: MakeOptions] |
Returns
Section titled “Returns”Properties
Section titled “Properties”snapshot
Section titled “snapshot”
readonlysnapshot:RunSnapshot
transcript
Section titled “transcript”
readonlytranscript: readonlyTranscriptEntry[]
RunReader
Section titled “RunReader”Reads saved Run state and transcripts without starting or recovering execution.
Extends
Section titled “Extends”Context.ServiceClass
Properties
Section titled “Properties”Service
Section titled “Service”
readonlyService:object
The service’s operations: what yield* RunReader returns.
evidence
Section titled “evidence”
readonlyevidence: (runId) =>Effect.Effect<RunEvidence,RunStoreError>
Reads one consistent Run snapshot and every saved transcript entry, in append order without a page limit.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
runId |
RunId |
Returns
Section titled “Returns”Effect.Effect<RunEvidence, RunStoreError>
forItems
Section titled “forItems”
readonlyforItems: (itemKeys) =>Effect.Effect<ReadonlyArray<RunSummary>,RunStoreError>
Every saved Run for the supplied Items, newest first, including all their Attempts.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
itemKeys |
ReadonlyArray<ItemKey> |
Returns
Section titled “Returns”Effect.Effect<ReadonlyArray<RunSummary>, RunStoreError>
inspect
Section titled “inspect”
readonlyinspect: (runId) =>Effect.Effect<RunSnapshot,RunStoreError>
Reads a Run’s current state, effective task and Agent, Step result, and Attempt history.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
runId |
RunId |
Returns
Section titled “Returns”Effect.Effect<RunSnapshot, RunStoreError>
readonlylist: (options) =>Effect.Effect<ReadonlyArray<RunSummary>,RunStoreError>
Every open Run plus the newest closedLimit settled ones, newest first.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
options |
{ closedLimit: number; } |
options.closedLimit |
number |
Returns
Section titled “Returns”Effect.Effect<ReadonlyArray<RunSummary>, RunStoreError>
revision
Section titled “revision”
readonlyrevision: () =>Effect.Effect<Option.Option<ProjectionRevision>,RunStoreError>
None means the invalidation row is absent: treat every cached projection as stale.
Returns
Section titled “Returns”Effect.Effect<Option.Option<ProjectionRevision>, RunStoreError>
transcript
Section titled “transcript”
readonlytranscript: (query) =>Effect.Effect<ReadonlyArray<TranscriptEntry>,RunStoreError>
Reads the requested portion of one Attempt’s saved transcript in append order.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
query |
TranscriptQuery |
Returns
Section titled “Returns”Effect.Effect<ReadonlyArray<TranscriptEntry>, RunStoreError>
readonlystaticlayer:Layer<RunReader,never,RunDatabase>
RunSnapshot
Section titled “RunSnapshot”The full durable view of one Run.
Extends
Section titled “Extends”Schema.Class
Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new RunSnapshot(…
args):RunSnapshot
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
…args |
[props: object, options?: MakeOptions] |
Returns
Section titled “Returns”Properties
Section titled “Properties”
readonlyagent:Agent
attempts
Section titled “attempts”
readonlyattempts: readonlyAttempt[]
readonlyevent:Event
itemKey
Section titled “itemKey”
readonlyitemKey:string&Brand<"ItemKey">
parentModel
Section titled “parentModel”
readonlyparentModel:Option<string&Brand<"ModelId">>
repository
Section titled “repository”
readonlyrepository:string&Brand<"RepositoryName">
resolvedFailureAttemptId
Section titled “resolvedFailureAttemptId”
readonlyresolvedFailureAttemptId:Option<string&Brand<"AttemptId">>
The failed Attempt whose attention the operator resolved; outcomes and history stay intact.
revision
Section titled “revision”
readonlyrevision:string&Brand<"RepositoryRevision">
readonlyrun:Run
readonlystep:Step
readonlytask:string&Brand<"AttemptTask">
RunSummary
Section titled “RunSummary”The lighter view used when listing Runs for operators.
Extends
Section titled “Extends”Schema.Class
Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new RunSummary(…
args):RunSummary
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
…args |
[props: object, options?: MakeOptions] |
Returns
Section titled “Returns”Properties
Section titled “Properties”
readonlyagent:Agent
attempts
Section titled “attempts”
readonlyattempts: readonlyAttempt[]
itemKey
Section titled “itemKey”
readonlyitemKey:string&Brand<"ItemKey">
repository
Section titled “repository”
readonlyrepository:string&Brand<"RepositoryName">
resolvedFailureAttemptId
Section titled “resolvedFailureAttemptId”
readonlyresolvedFailureAttemptId:Option<string&Brand<"AttemptId">>
The failed Attempt whose attention the operator resolved; outcomes and history stay intact.
readonlyrun:Run
readonlystep:Step
readonlytask:string&Brand<"AttemptTask">
Type Aliases
Section titled “Type Aliases”ProjectionRevision
Section titled “ProjectionRevision”ProjectionRevision = typeof
ProjectionRevision.Type
Monotonic version of the operator projection.
Variables
Section titled “Variables”ProjectionRevision
Section titled “ProjectionRevision”
constProjectionRevision:Schema.brand<Schema.Int,"ProjectionRevision">
Monotonic version of the operator projection.