webtools

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Oct 19, 2026 License: MIT Imports: 23 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewFetchTool added in v0.2.0

func NewFetchTool() tools.Executor

NewFetchTool is web_fetch: one public page as readable text.

func NewSearchTool added in v0.2.0

func NewSearchTool(config func() (SearchConfig, error)) tools.Executor

NewSearchTool is web_search over the provider config reads at each call; nil config searches DuckDuckGo.

Types

type SearchConfig added in v0.2.0

type SearchConfig struct {
	Provider  string
	TavilyKey string
	SerperKey string
	BaseURL   string
}

SearchConfig holds the active provider credentials for web search.

type WebFetchParams

type WebFetchParams struct {
	URL string `json:"url"`
}

type WebSearchParams

type WebSearchParams struct {
	Query string `json:"query"`
	Limit int    `json:"limit,omitempty"`
}

type WebSearchResponseMetadata

type WebSearchResponseMetadata struct {
	Query    string            `json:"query"`
	Provider string            `json:"provider"`
	Results  []WebSearchResult `json:"results"`
}

type WebSearchResult

type WebSearchResult struct {
	Position    int    `json:"position"`
	Title       string `json:"title"`
	URL         string `json:"url"`
	Description string `json:"description,omitempty"`
}

Jump to

Keyboard shortcuts

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