events

package
v0.0.143 Latest Latest
Warning

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

Go to latest
Published: Aug 20, 2026 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateEvents

func GenerateEvents(seed int64, prompt string) []types.AgentEvent

Types

type EventStream added in v0.0.45

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

EventStream yields AgentEvents one at a time using the same logic and RNG sequence as GenerateEvents, without running the full probe loop upfront.

func NewEventStream added in v0.0.45

func NewEventStream(seed int64, prompt string) *EventStream

NewEventStream creates a lazy generator for the given seed and prompt.

func NewMockEventStream added in v0.0.45

func NewMockEventStream(seed int64, prompt string) *EventStream

NewMockEventStream creates a fast lazy generator for llm-mock: think on the first Next(), message on the second, with no synchronous probe execution.

func (*EventStream) IsMockFast added in v0.0.45

func (es *EventStream) IsMockFast() bool

IsMockFast reports whether this stream uses the llm-mock fast path (think then message).

func (*EventStream) Next added in v0.0.45

func (es *EventStream) Next() (types.AgentEvent, bool)

Next returns the next generated event, or false when the session is exhausted.

func (*EventStream) PeekNext added in v0.0.45

func (es *EventStream) PeekNext() (types.AgentEvent, bool)

PeekNext returns the next event without advancing stream state.

type Generator

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

func NewGenerator

func NewGenerator(seed int64) *Generator

Jump to

Keyboard shortcuts

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