memory

package
v0.13.0 Latest Latest
Warning

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

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

Documentation

Overview

Package memory provides a compiled skill for semantic memory operations.

Index

Constants

View Source
const (
	// SkillName is the name of the memory skill.
	SkillName = "memory"

	// DefaultScope is the default memory scope.
	DefaultScope = core.ScopeSession
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	// Client is an existing omnimemory client.
	// If nil, a new in-memory client will be created.
	Client *core.Client

	// TenantID is the default tenant for memory operations.
	TenantID string

	// AgentID is the agent identifier for memory attribution.
	AgentID string
}

Config configures the memory skill.

type Skill

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

Skill implements compiled.Skill for memory operations using omnimemory.

func NewSkill

func NewSkill(cfg Config) *Skill

NewSkill creates a new memory skill.

func (*Skill) Client added in v0.11.0

func (s *Skill) Client() *core.Client

Client returns the omnimemory client.

func (*Skill) Close

func (s *Skill) Close() error

Close implements compiled.Skill.

func (*Skill) Description

func (s *Skill) Description() string

Description implements compiled.Skill.

func (*Skill) Init

func (s *Skill) Init(ctx context.Context) error

Init implements compiled.Skill.

func (*Skill) Name

func (s *Skill) Name() string

Name implements compiled.Skill.

func (*Skill) SetMemory added in v0.11.0

func (s *Skill) SetMemory(client *core.Client)

SetMemory sets the omnimemory client. This is called when the skill is registered with an agent that has memory configured.

func (*Skill) Tools

func (s *Skill) Tools() []skill.Tool

Tools implements compiled.Skill.

Jump to

Keyboard shortcuts

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