acp

package
v0.1.4 Latest Latest
Warning

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

Go to latest
Published: Mar 10, 2026 License: MIT Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ServeStdio

func ServeStdio(ctx context.Context, opts api.Options, in io.Reader, out io.Writer) error

ServeStdio serves ACP over stdio using the provided runtime options.

Types

type Adapter

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

Adapter wires agentsdk-go runtime into ACP request/response methods.

func NewAdapter

func NewAdapter(opts api.Options) *Adapter

NewAdapter creates an ACP adapter backed by api.Runtime sessions.

func (*Adapter) Authenticate

Authenticate is a no-op success path.

func (*Adapter) Cancel

func (a *Adapter) Cancel(_ context.Context, params acpproto.CancelNotification) error

Cancel aborts the active turn for the target session when one exists.

func (*Adapter) Initialize

Initialize negotiates ACP protocol/capabilities/auth methods.

func (*Adapter) LoadSession

LoadSession restores a persisted session and replays prior conversation updates.

func (*Adapter) NewSession

NewSession creates a runtime session for the provided absolute working directory.

func (*Adapter) Prompt

Prompt streams runtime text deltas as ACP agent_message_chunk updates.

func (*Adapter) SetConnection

func (a *Adapter) SetConnection(conn *acpproto.AgentSideConnection)

SetConnection injects the live ACP connection so Prompt/updates can call back into the client.

func (*Adapter) SetSessionConfigOption

SetSessionConfigOption validates and updates config value, returns full config snapshot.

func (*Adapter) SetSessionMode

SetSessionMode validates and updates current mode, then emits sync updates for both legacy modes and configOptions(category=mode).

Jump to

Keyboard shortcuts

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