Documentation
¶
Index ¶
- type ExtractedTopic
- type FactVectorItem
- type RetrievalDebugInfo
- type RetrievalOptions
- type SearchResult
- type Service
- func (s *Service) FindSimilarFacts(ctx context.Context, userID int64, embedding []float32, threshold float32) ([]storage.Fact, error)
- func (s *Service) ForceProcessUser(ctx context.Context, userID int64) (int, error)
- func (s *Service) ReloadVectors() error
- func (s *Service) Retrieve(ctx context.Context, userID int64, query string, opts *RetrievalOptions) ([]TopicSearchResult, *RetrievalDebugInfo, error)
- func (s *Service) RetrieveFacts(ctx context.Context, userID int64, query string) ([]storage.Fact, error)
- func (s *Service) Start(ctx context.Context) error
- func (s *Service) Stop()
- func (s *Service) TriggerConsolidation()
- type TopicSearchResult
- type TopicVectorItem
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ExtractedTopic ¶
type FactVectorItem ¶
type RetrievalDebugInfo ¶
type RetrievalDebugInfo struct {
OriginalQuery string
EnrichedQuery string
EnrichmentPrompt string
EnrichmentTokens int
Results []TopicSearchResult
}
RetrievalDebugInfo contains trace data for RAG debugging
type RetrievalOptions ¶
type SearchResult ¶
SearchResult kept for backward compatibility if needed, but we are moving to TopicSearchResult. We remove it to force type errors in other files to fix them.
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func NewService ¶
func NewService(logger *slog.Logger, cfg *config.Config, topicRepo storage.TopicRepository, factRepo storage.FactRepository, factHistoryRepo storage.FactHistoryRepository, msgRepo storage.MessageRepository, logRepo storage.LogRepository, client openrouter.Client, memoryService *memory.Service, translator *i18n.Translator) *Service
func (*Service) FindSimilarFacts ¶
func (*Service) ForceProcessUser ¶
func (*Service) ReloadVectors ¶
func (*Service) Retrieve ¶
func (s *Service) Retrieve(ctx context.Context, userID int64, query string, opts *RetrievalOptions) ([]TopicSearchResult, *RetrievalDebugInfo, error)
func (*Service) RetrieveFacts ¶
func (*Service) TriggerConsolidation ¶
func (s *Service) TriggerConsolidation()
type TopicSearchResult ¶
TopicSearchResult represents a matched topic with its messages
type TopicVectorItem ¶
Click to show internal directories.
Click to hide internal directories.