class LLM::ACPClient

Overview

ACP-backed client wrapper for communicating with local AI agents.

Defined in:

llm/acp/client.cr

Constant Summary

CLAUDE_ARGS = ["@zed-industries/claude-agent-acp"]
CODEX_ARGS = ["@zed-industries/codex-acp"]
GEMINI_ARGS = ["--experimental-acp"]

Constructors

Class Method Summary

Instance Method Summary

Constructor Detail

def self.new(provider : String, model : String, event_sink : Proc(String, Nil) | Nil = nil) #

[View source]

Class Method Detail

def self.acp_provider?(provider : String) : Bool #

[View source]
def self.default_model(provider : String, model : String) : String #

[View source]
def self.extract_target(provider : String) : String #

[View source]
def self.mute_acp_logs : Nil #

[View source]
def self.resolve_command(provider : String) : Tuple(String, Array(String)) #

Resolve provider aliases to actual executable command + args.


[View source]

Instance Method Detail

def args : Array(String) #

[View source]
def close : Nil #

[View source]
def command : String #

[View source]
def model : String #

[View source]
def provider : String #

[View source]
def request(prompt : String, format : String = "json") : String #

[View source]
def request_messages(messages : Array(Hash(String, String)), format : String = "json") : String #

[View source]