agentwiring

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Sep 12, 2026 License: AGPL-3.0 Imports: 19 Imported by: 0

Documentation

Overview

Package agentwiring builds the agent-execution stack — model, capability source, conversation/memory/gap-report stores, usage emitter — and adapts it to assistanta2a.AgentRunner. It exists so both cmd/assistant (the standalone A2A server, still used by datumctl/patchcli) and cmd/assistant-apiserver (the conversations/sendmessage subresource) build the exact same agent.Conversation from the exact same config.Config shape, instead of maintaining two independently-drifting constructors.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewRunner

func NewRunner(ctx context.Context, cfg *config.Config, log *slog.Logger, metrics *appmetrics.Metrics) (assistanta2a.AgentRunner, history.Store, func(), error)

NewRunner builds the assistanta2a.AgentRunner a chat surface drives: it resolves the model from config, wires the capability source, conversation store, and usage emitter, constructs the agent orchestrator, and adapts it to the A2A seam. metrics is shared with the caller's own HTTP telemetry so conversation/tool/model/compaction/gap-report telemetry lands on the same /metrics endpoint. The returned cleanup releases the conversation store's resources (call it on shutdown; it is never nil).

The conversation store is returned alongside the runner because callers need it directly for conversation-rename operations — naming a conversation is a row update with no agent in it, so routing it through the runner seam (the way compaction is) would be a category error.

Types

This section is empty.

Jump to

Keyboard shortcuts

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