Documentation
¶
Overview ¶
Package digest generates periodic summaries of recent Eidetic memories and delivers them to channel bots. It follows the Second Brain pattern: Capture -> Sort -> Store -> Digest.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Chatter ¶
type Chatter interface {
Chat(ctx context.Context, sessionKey, message string) (agentapi.Response, error)
}
Chatter is the minimal agent interface needed for LLM summarization.
type Config ¶
type Config struct {
Enabled bool `json:"enabled"`
Schedule string `json:"schedule"` // "daily", "weekly", or cron expression (only daily/weekly supported now)
Hour int `json:"hour"` // hour of day to run (0-23), default 8
Timezone string `json:"timezone"` // IANA timezone, default "America/New_York"
Target string `json:"target"` // delivery target: "last" (all paired), "none"
LookbackH int `json:"lookbackHours"` // hours to look back, default 24 for daily
MaxEntries int `json:"maxEntries"` // max entries to summarize, default 50
}
Config controls digest generation behavior.
type Deliverer ¶
type Deliverer interface {
SendToAllPaired(text string)
}
Deliverer can broadcast a message to all paired users on a channel.
type Runner ¶
type Runner struct {
// contains filtered or unexported fields
}
Runner generates periodic memory digests using an LLM.
func NewRunner ¶
func NewRunner(cfg Config, ec eidetic.Client, chatter Chatter, deliverers []Deliverer, logger *zap.SugaredLogger, stateFile string) *Runner
NewRunner creates a digest runner. stateFile is the path to persist scheduling state across restarts (e.g. ~/.roger/state/digest-state.json). Pass "" to disable persistence (in-memory only).
func (*Runner) GenerateDigest ¶
GenerateDigest fetches recent memories, sends them to the LLM with a digest prompt, and returns the summary text.