weave

package
v1.9.0 Latest Latest
Warning

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

Go to latest
Published: Oct 27, 2026 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

Package weave adapts the Weave RAG engine to the cortex knowledge.Provider interface.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EngineOption

func EngineOption(c vessel.Vessel) engine.Option

EngineOption returns an engine.Option that auto-discovers a Weave engine from the DI container and configures the Cortex engine's knowledge provider. If no Weave engine is found, returns a no-op option (safe to always include).

Types

type Adapter

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

Adapter implements knowledge.Provider by delegating to a weave Engine.

func New

func New(eng *weaveengine.Engine) *Adapter

New creates a new Weave adapter from an engine instance.

func (*Adapter) ListCollections

func (a *Adapter) ListCollections(ctx context.Context) ([]knowledge.CollectionInfo, error)

ListCollections returns available knowledge collections with statistics.

func (*Adapter) Retrieve

func (a *Adapter) Retrieve(ctx context.Context, query string, params *knowledge.RetrieveParams) ([]knowledge.ScoredChunk, error)

Retrieve performs a semantic search and returns scored chunks.

Jump to

Keyboard shortcuts

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