Documentation
¶
Overview ¶
Package ai contains bounded HTTP clients for optional model integrations.
Index ¶
- type AgentOptions
- type AgentResult
- type Call
- type Choice
- type Classification
- type ClassificationResult
- type Client
- func (c *Client) Classify(ctx context.Context, model string, items []raindrop.Raindrop, ...) (ClassificationResult, error)
- func (c *Client) Post(ctx context.Context, path string, body, out any) error
- func (c *Client) RunAgent(ctx context.Context, options AgentOptions, tools []Tool, execute Execute) (AgentResult, error)
- type CloudflareProvider
- type CommandProvider
- type Execute
- type Poster
- type Tool
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AgentOptions ¶
type AgentResult ¶
type Classification ¶
type ClassificationResult ¶
type ClassificationResult struct {
Model string `json:"model"`
Results []Classification `json:"results"`
}
type Client ¶
func (*Client) RunAgent ¶
func (c *Client) RunAgent(ctx context.Context, options AgentOptions, tools []Tool, execute Execute) (AgentResult, error)
RunAgent executes tools sequentially and feeds their results back until the model finishes or a hard limit/error stops the loop. It does not retry writes.
type CloudflareProvider ¶
type CloudflareProvider struct {
// contains filtered or unexported fields
}
CloudflareProvider adapts the Workers AI envelope to System One decisions.
func NewCloudflareProvider ¶
func NewCloudflareProvider(base, key, account, model string) (*CloudflareProvider, error)
type CommandProvider ¶
CommandProvider executes a user-configured executable directly. No shell is involved and model/tool inputs never choose an executable or its arguments.