sessionlifecycle

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 28, 2026 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PhaseIdle = string(phaseIdle)
	PhaseTurn = string(phaseTurn)
)

Variables

This section is empty.

Functions

func IsRunningStatus

func IsRunningStatus(rawStatus, rawPhase string) bool

func MarkerForEngineStatus

func MarkerForEngineStatus(status engine.Status) sessiontree.TurnMarkerStatus

func ValidateProjection added in v0.29.0

func ValidateProjection(rawStatus, rawPhase, latestTurnID, waitingPrompt string, recoverable, canAppendMessage bool) error

ValidateProjection validates the public lifecycle facts emitted from Derive without reconstructing journal state or retry eligibility.

Types

type Lifecycle

type Lifecycle struct {
	// contains filtered or unexported fields
}

func Derive

func Derive(path []sessiontree.Entry, rawPhase string) Lifecycle

IMPORTANT: SessionLifecycle is the only host/UI boundary for session status, recoverability, and appendability. Do not derive these decisions directly from engine status, thread phase, sessiontree markers, or inspector transitions.

func Running

func Running(latestTurnID string) Lifecycle

func (Lifecycle) CanAppendMessage

func (l Lifecycle) CanAppendMessage() bool

func (Lifecycle) IsRunning

func (l Lifecycle) IsRunning() bool

func (Lifecycle) LatestTurnID

func (l Lifecycle) LatestTurnID() string

func (Lifecycle) Phase

func (l Lifecycle) Phase() string

func (Lifecycle) Recoverable

func (l Lifecycle) Recoverable() bool

func (Lifecycle) Status

func (l Lifecycle) Status() string

func (Lifecycle) WaitingPrompt

func (l Lifecycle) WaitingPrompt() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL