web_search

package
v0.1.1 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(cfg Config) (tools.Tool, error)

New creates a new web_search tool with the given configuration.

Types

type Config

type Config struct {
	Enabled bool `toml:"enabled"`
}

Config holds web_search configuration.

func DefaultConfig

func DefaultConfig() Config

DefaultConfig returns the default configuration.

type Tool

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

Tool implements the tools.Tool interface for web search via Brave API.

func (*Tool) Run

func (t *Tool) Run(ctx context.Context, input map[string]any) (tools.Result, error)

Run executes the web search operation.

func (*Tool) Spec

func (t *Tool) Spec() llm.ToolSpec

Spec returns the tool specification.

Jump to

Keyboard shortcuts

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