memory

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Feb 19, 2025 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Stream

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

The stream memory retains all of the agent's observations in the time ordered sequence.

func NewStream

func NewStream(stratum chatter.Stratum) *Stream

Creates new stream memory that retains all of the agent's observations.

func (*Stream) Commit

func (s *Stream) Commit(e *thinker.Observation)

Commit new observation into memory.

func (*Stream) Context

func (s *Stream) Context(prompt chatter.Prompt) []fmt.Stringer

Builds the context window for LLM using incoming prompt.

type Void

type Void struct{}

The void memory does not retain any observations.

func NewVoid

func NewVoid() *Void

Create the void memory that does not retain any observations.

func (*Void) Commit

func (s *Void) Commit(e *thinker.Observation)

Commit new observation into memory.

func (*Void) Context

func (s *Void) Context(prompt chatter.Prompt) []fmt.Stringer

Builds the context window for LLM using incoming prompt.

Jump to

Keyboard shortcuts

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