Help us shape the future of Go! Take the 2026 Go Developer Survey

sessindex

package
v0.4.45 Latest Latest
Warning

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

Go to latest
Published: Nov 3, 2026 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewSQLiteIndex

func NewSQLiteIndex(cfg SQLiteIndexConfig, deps SQLiteIndexDeps) (capsessionindex.Service, error)

NewSQLiteIndex registers session/sqlite-index: FTS index over session/store JSONL files.

Types

type IndexableMessage added in v0.4.24

type IndexableMessage struct {
	Seq  int64
	Role string
	Text string
}

IndexableMessage is one searchable row from a session log.

func ExtractIndexableMessages

func ExtractIndexableMessages(events []agentkit.SessionEvent) []IndexableMessage

ExtractIndexableMessages returns user/assistant text from session events.

type SQLiteIndex

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

SQLiteIndex persists FTS5 over session JSONL transcripts per tenant workspace.

func (*SQLiteIndex) ListSessions

func (s *SQLiteIndex) ListSessions(ctx context.Context, limit int) ([]capsessionindex.SessionSummary, error)

func (*SQLiteIndex) ScrollMessages

func (s *SQLiteIndex) ScrollMessages(ctx context.Context, sessionID string, anchorSeq int64, before, after int) ([]capsessionindex.MessageRow, error)

func (*SQLiteIndex) Search

func (s *SQLiteIndex) Search(ctx context.Context, query string, limit int) ([]capsessionindex.Hit, error)

func (*SQLiteIndex) SyncSessions

func (s *SQLiteIndex) SyncSessions(ctx context.Context) error

type SQLiteIndexConfig

type SQLiteIndexConfig struct {
	// IndexRel is the workspace-relative SQLite file path.
	IndexRel string `json:"indexRel"`
	// SessionsRel is the workspace-relative sessions directory to ingest.
	SessionsRel string `json:"sessionsRel"`
}

func (*SQLiteIndexConfig) SetDefaults added in v0.3.48

func (c *SQLiteIndexConfig) SetDefaults()

SetDefaults implements pluginkit.Defaulter.

type SQLiteIndexDeps

type SQLiteIndexDeps struct {
	Workspace workspace.Service `json:"workspace"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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