mirror of
https://github.com/vxcontrol/langchaingo.git
synced 2026-07-21 17:05:31 -04:00
36f399f058
* Added initial HandelStreamFunc callback handler * added callback handler to conversational agent * Added Agent final stdout callback * Added callback handler to mrkl agent * Added egress buffer for final agent streaming * Added proper egress channel handling * Added comments * Added better context handling * Fixing lint
26 lines
1.1 KiB
Go
26 lines
1.1 KiB
Go
//nolint:forbidigo
|
|
package callbacks
|
|
|
|
import (
|
|
"context"
|
|
|
|
"github.com/tmc/langchaingo/llms"
|
|
"github.com/tmc/langchaingo/schema"
|
|
)
|
|
|
|
type SimpleHandler struct{}
|
|
|
|
var _ Handler = SimpleHandler{}
|
|
|
|
func (SimpleHandler) HandleText(context.Context, string) {}
|
|
func (SimpleHandler) HandleLLMStart(context.Context, []string) {}
|
|
func (SimpleHandler) HandleLLMEnd(context.Context, llms.LLMResult) {}
|
|
func (SimpleHandler) HandleChainStart(context.Context, map[string]any) {}
|
|
func (SimpleHandler) HandleChainEnd(context.Context, map[string]any) {}
|
|
func (SimpleHandler) HandleToolStart(context.Context, string) {}
|
|
func (SimpleHandler) HandleToolEnd(context.Context, string) {}
|
|
func (SimpleHandler) HandleAgentAction(context.Context, schema.AgentAction) {}
|
|
func (SimpleHandler) HandleRetrieverStart(context.Context, string) {}
|
|
func (SimpleHandler) HandleRetrieverEnd(context.Context, string, []schema.Document) {}
|
|
func (SimpleHandler) HandleStreamingFunc(context.Context, []byte) {}
|