trace

package
v0.16.6 Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2026 License: MIT Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Hook

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

Hook logs LLM, tool, and memory call details via slog, and optionally exports OpenTelemetry traces when OTEL_EXPORTER_OTLP_ENDPOINT is set.

func (*Hook) Close

func (h *Hook) Close() error

Close flushes pending spans and shuts down the trace provider.

func (*Hook) Name

func (*Hook) Name() string

func (*Hook) OnPostAgentCall

func (h *Hook) OnPostAgentCall(_ context.Context, hctx *hooks.PostAgentCallContext)

func (*Hook) OnPostLLMCall

func (h *Hook) OnPostLLMCall(_ context.Context, hctx *hooks.PostLLMCallContext)

func (*Hook) OnPostMemoryCall

func (h *Hook) OnPostMemoryCall(_ context.Context, hctx *hooks.PostMemoryCallContext)

func (*Hook) OnPostToolCall

func (h *Hook) OnPostToolCall(_ context.Context, hctx *hooks.PostToolCallContext)

func (*Hook) OnPreAgentCall

func (h *Hook) OnPreAgentCall(_ context.Context, hctx *hooks.PreAgentCallContext)

func (*Hook) OnPreLLMCall

func (h *Hook) OnPreLLMCall(_ context.Context, hctx *hooks.PreLLMCallContext) (hooks.PreLLMCallResult, error)

func (*Hook) OnPreToolCall

func (h *Hook) OnPreToolCall(_ context.Context, hctx *hooks.PreToolCallContext) (hooks.PreToolCallResult, error)

func (*Hook) Priority

func (*Hook) Priority() int

Jump to

Keyboard shortcuts

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