llmtext

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: May 16, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package llmtext provides a processor that converts LLMTextFrame to AggregatedTextFrame using a configurable text aggregator (e.g. sentence-based).

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Processor

type Processor struct {
	*processors.BaseProcessor
	Aggregator textaggregator.Aggregator
}

Processor converts LLMTextFrame into AggregatedTextFrame via a text aggregator.

func New

func New(name string, agg textaggregator.Aggregator) *Processor

New returns an LLM text processor. If agg is nil, a default sentence aggregator is used.

func (*Processor) ProcessFrame

func (p *Processor) ProcessFrame(ctx context.Context, f frames.Frame, dir processors.Direction) error

ProcessFrame feeds LLM text into the aggregator and emits AggregatedTextFrame; flushes on end/interruption.

Jump to

Keyboard shortcuts

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