Skip to content

WebSearchToolConfig

Base classes

Name Children Inherits
_ToolConfigBase
codexed.models.tool_config
Base for individual tool configuration models.

⋔ Inheritance diagram

graph TD
  3271597023["tool_config.WebSearchToolConfig"]
  4259177097["tool_config._ToolConfigBase"]
  3879467795["main.BaseModel"]
  2751680898["builtins.object"]
  4259177097 --> 3271597023
  3879467795 --> 4259177097
  2751680898 --> 3879467795

🛈 DocStrings

Bases: _ToolConfigBase

Configuration for the web_search tool.

Source code in src/codexed/models/tool_config.py
class WebSearchToolConfig(_ToolConfigBase):
    """Configuration for the web_search tool."""

    type: Literal["web_search"] = "web_search"

    mode: WebSearchMode | None = None
    """Search mode."""

    context_size: WebSearchContextSize | None = None
    """Amount of context returned from search results."""

    allowed_domains: list[str] | None = None
    """Restrict search to these domains only."""

    location: WebSearchLocation | None = None
    """Approximate user location for localised results."""

allowed_domains class-attribute instance-attribute

allowed_domains: list[str] | None = None

Restrict search to these domains only.

context_size class-attribute instance-attribute

context_size: WebSearchContextSize | None = None

Amount of context returned from search results.

location class-attribute instance-attribute

location: WebSearchLocation | None = None

Approximate user location for localised results.

mode class-attribute instance-attribute

mode: WebSearchMode | None = None

Search mode.

:fa-brands-github: Show source on GitHub