mention

package
v1.0.2 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InsertIntoInput

func InsertIntoInput(input string, token Token, path string) string

Types

type AgentEntry added in v0.1.8

type AgentEntry struct {
	Name        string
	Description string
	Scope       string
}

type AgentSource added in v0.1.8

type AgentSource interface {
	ListAgents() []AgentEntry
}

type Candidate

type Candidate struct {
	Path        string
	BaseName    string
	TypeTag     string
	Kind        string  // "file", "dir", or "agent"
	Description string  // agent description, empty for files
	Score       float64 // normalized relevance score (0 = best)
}

type IndexStats

type IndexStats struct {
	Count     int
	MaxFiles  int
	Truncated bool
	Ready     bool
	Building  bool
	Partial   bool
}

type Token

type Token struct {
	Query string
	Start int
	End   int
}

func FindActiveToken

func FindActiveToken(input string) (Token, bool)

type WorkspaceFileIndex

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

func NewStaticWorkspaceFileIndex

func NewStaticWorkspaceFileIndex(candidates []Candidate, maxFiles int, truncated bool) *WorkspaceFileIndex

func NewWorkspaceFileIndex

func NewWorkspaceFileIndex(workspace string) *WorkspaceFileIndex

func (*WorkspaceFileIndex) Prewarm

func (idx *WorkspaceFileIndex) Prewarm()

func (*WorkspaceFileIndex) Search

func (idx *WorkspaceFileIndex) Search(query string, limit int) []Candidate

func (*WorkspaceFileIndex) SearchWithRecency

func (idx *WorkspaceFileIndex) SearchWithRecency(query string, limit int, recency map[string]int) []Candidate

func (*WorkspaceFileIndex) Stats

func (idx *WorkspaceFileIndex) Stats() IndexStats

Jump to

Keyboard shortcuts

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