session

package
v0.6.3 Latest Latest
Warning

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

Go to latest
Published: May 3, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Delete

func Delete(sessionsDir string, id string) error

func Save

func Save(sessionsDir string, id string, state agent.State) error

Save writes the session to disk. It is a no-op if there are no messages, so brand-new (empty) sessions don't leave orphan files. Returns nil in that case.

Types

type Session

type Session struct {
	ID        string      `json:"id"`
	Title     string      `json:"title,omitempty"`
	CreatedAt time.Time   `json:"created_at"`
	UpdatedAt time.Time   `json:"updated_at"`
	State     agent.State `json:"state"`
}

Session represents a saved conversation session.

func List

func List(sessionsDir string) ([]Session, error)

func Load

func Load(sessionsDir string, id string) (Session, error)

Jump to

Keyboard shortcuts

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