/** * vendo()'s tool-search strategy — the loadout cap and the `find_tools` hand. * * Brain strategy, not runtime machinery: `claudeCode()` reads a large catalog * natively and opted out of curation entirely; this file is how OUR brain copes * with a 600-tool host (dub ≈ 617, papermark ≈ 388). It lives in the vendo * folder because it is vendo()'s coping strategy and nobody else's — the * runtime's ctx safety projection (what may be offered AT ALL) is unrelated * machinery and stays in `turn-tools.ts`. * * No session object, no ToolSet attach, no adapter dance: `vendo()` mounts * `find_tools` as one of its own hands, scores over the turn's own listings * (or a composed registry search), and remembers what it loaded in * `turn.state` — the brain's own memory slot. */ import type { ToolListing } from "@vendoai/core"; export declare const FIND_TOOLS_TOOL_NAME = "find_tools"; /** Bound on the uncurated initial loadout: past it, the rest of the catalog is * reachable through {@link FIND_TOOLS_TOOL_NAME} instead of flooding context. * * 24, not 128 (2026-08-11): selection accuracy degrades past 30-50 offered * tools (Anthropic's tool-search numbers: deferring the catalog behind search * raised Opus 4.5 tool-selection from 79.5% to 88.1%; OpenAI's guidance says * under ~20 upfront). The always-active set rides on top, so the belt lands * right at the edge of the safe band — and the belt is a convenience, never * the contract: everything past it is one search away. */ export declare const DEFAULT_MAX_INITIAL_TOOLS = 24; /** * What composition (or a host) hands `vendo()` at construction. All optional — * `search` unset falls back to {@link searchListings} over the turn's own * listings, so a bare config still gets a working `find_tools`. */ export interface VendoToolSearchConfig { /** Registry-backed search (the umbrella wires `ActionsRegistry.search`, which * may lazily expand a connector toolkit — the expanded tools then join the * projected listing, which vendo() re-reads after every call). */ search?: (query: string, options?: { limit?: number; }) => Promise; /** Uncurated loadout cap; defaults to {@link DEFAULT_MAX_INITIAL_TOOLS}. */ maxInitialTools?: number; /** Explicit curated starting set. When set, exactly these (that exist) start * active and the cap is not applied. */ loadout?: string[]; /** Names never hidden behind the cap. The COMPOSITION declares the tools its * prompt teaches by name (uiaudit 2026-08-06 — a host past the cap lost * `request_connection` while the prompt kept teaching it); the harness * itself exempts only its own capability-miss hand. */ alwaysActive?: readonly string[]; } /** The harness's ONE native exemption: its own capability-miss listing. Every * product name is the composition's to declare through * {@link VendoToolSearchConfig.alwaysActive} — this file knows no product * tools. */ export declare const alwaysActivePredicate: (config?: VendoToolSearchConfig) => ((name: string) => boolean); /** * The starting toolbelt: an explicit `loadout` wins; a surface under the cap * rides whole; a large one is cut safest-first (read < write < destructive), * then A-Z — deterministic, never an alphabetical accident. */ export declare function computeInitialLoadout(listings: readonly ToolListing[], config: VendoToolSearchConfig): Set; export declare function searchListings(listings: readonly ToolListing[], query: string, limit?: number): { name: string; description: string; score: number; }[]; export declare const FIND_TOOLS_DESCRIPTION: string; //# sourceMappingURL=tool-search.d.ts.map