claude

package
v0.13.0 Latest Latest
Warning

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

Go to latest
Published: Jun 28, 2026 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

Package claude implements llm.Runner by invoking the Claude CLI.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewRunner

func NewRunner(model string) llm.Runner

NewRunner returns an llm.Runner backed by the claude CLI.

Types

type Runner

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

Runner invokes the claude CLI with --output-format json and parses the response into agent-neutral LLMMetadata.

func (*Runner) Run

func (r *Runner) Run(ctx context.Context, req llm.Request) (*llm.RunResult, error)

Run executes claude -p --output-format json and parses the JSON response. The claude CLI accepts a single stdin payload, so SystemPrompt and UserPrompt are concatenated — prompt caching is not available through this transport.

Jump to

Keyboard shortcuts

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