Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Invocation ¶
type Invocation struct {
// contains filtered or unexported fields
}
Invocation records one externally observable model or tool call. It is safe to finish from a deferred cleanup path and guarantees exactly one end event.
func Begin ¶
func Begin(ctx context.Context, kind, name, id string, fields ...any) *Invocation
Begin writes the start event. A caller-provided ID is useful for preserving a model tool_call_id; an empty ID receives a process-unique value.
func (*Invocation) End ¶
func (i *Invocation) End(err error, fields ...any)
End writes exactly one completion or failure event for the invocation.
Click to show internal directories.
Click to hide internal directories.