rewrite

package
v1.1.1 Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package rewrite provides query rewriting steps for RAG retrieval pipelines.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Rewrite

func Rewrite(
	llm core.Client,
	logger logging.Logger,
	metrics core.Metrics,
) pipeline.Step[*core.RetrievalContext]

Rewrite creates a new query rewriting step with logger and metrics.

Parameters:

  • llm: LLM client for query rewriting
  • logger: structured logger (auto-defaults to NoopLogger if nil)
  • metrics: metrics collector (optional, can be nil)

Example:

p.AddStep(rewrite.Rewrite(llm, logger, metrics))

Types

This section is empty.

Jump to

Keyboard shortcuts

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