Documentation
¶
Index ¶
- func NewRetriever(vectorStore core.VectorStore, graphStore store.GraphStore, ...) core.Retriever
- type CypherStep
- type Option
- func WithCustomStep(step pipeline.Step[*core.RetrievalContext]) Option
- func WithDepth(d int) Option
- func WithDocStore(s store.DocStore) Option
- func WithLimit(l int) Option
- func WithLogger(l logging.Logger) Option
- func WithPromptTemplate(t string) Option
- func WithTopK(k int) Option
- func WithTracer(t observability.Tracer) Option
- type Options
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewRetriever ¶
func NewRetriever( vectorStore core.VectorStore, graphStore store.GraphStore, embedder embedding.Provider, llm chat.Client, opts ...Option, ) core.Retriever
NewRetriever creates a new GraphRAG retriever.
Types ¶
type CypherStep ¶
type CypherStep struct {
// contains filtered or unexported fields
}
CypherStep allows using Cypher templates for deep relationship retrieval. It is specifically designed for GraphStores that support Cypher (like Neo4j).
func NewCypherStep ¶
func NewCypherStep(store store.GraphStore, template string, logger logging.Logger) *CypherStep
NewCypherStep creates a new step for Cypher-based graph retrieval.
func (*CypherStep) Execute ¶
func (s *CypherStep) Execute(ctx context.Context, retrievalCtx *core.RetrievalContext) error
func (*CypherStep) Name ¶
func (s *CypherStep) Name() string
type Option ¶
type Option func(*Options)
func WithCustomStep ¶
func WithCustomStep(step pipeline.Step[*core.RetrievalContext]) Option
func WithDocStore ¶
func WithLogger ¶
func WithPromptTemplate ¶
func WithTracer ¶
func WithTracer(t observability.Tracer) Option
Click to show internal directories.
Click to hide internal directories.