Web search (multi-engine, no API key)
searchRun a multi-engine web search to discover relevant URLs, returning a ranked, deduplicated link list to fetch and read next.
Instructions
Run a multi-engine web search and return a ranked, deduplicated link list.
Best for:
- Discovery queries ("what is X", "find me X", "who is X").
- Getting a list of URLs you can hand to `fetch` / `fetch_batch` next.
- Topics likely to be after your knowledge cutoff (use `freshness="week"`).
- Filtering to specific domains (`include_domains=["python.org"]`) or
a kind of source (`category="paper"` / `"finance"`, or a sub-group like
`category="paper.biomed"` / `"finance.filings"`; see `engines()` for the
full tree).
- Looking a fact up at its registry, with no category needed: a current
version or support end date ("latest fastapi version"), a CVE
("CVE-2024-3094": NVD record, OSV advisories, CISA exploited status),
a forecast ("上海明天天气"), an exchange rate ("100 usd to cny": ECB, and
the PBOC parity for 人民币), a coin price, a country indicator ("china
gdp", "japan population"), public holidays ("2026年放假安排"), the current
time in a city, a domain's expiry, a company's legal entity, an iOS
app's version, Wikidata facts ("Shanghai population"). The source that
fits the words joins the search and its record arrives as the first
result with the publisher's date in `dated …`, so it can be cited
without a fetch. Name the thing plainly. `category=` ("software",
"security", "weather", "finance.fx", "stats", "calendar", "reference",
"docs", "gov") asks the same sources explicitly.
Not recommended for:
- You already know the URL -> use `fetch` instead.
- You want both links AND their full text in one call -> use `research`.
- You want to query pages already in the local cache -> use `cache_search`.
- Reading PDFs/DOCX from a known URL -> use `read_doc`.
- Following one paper's references or citations -> use `paper_graph`.
Returns:
- markdown (default): numbered list of `n. title`, `<url>`, snippet. About 40%
fewer tokens than json.
- json: dict with `results` (list of {title,url,snippet,engines,score}),
`engines`, `cached`, optional `errors` map, optional `hint` string.
`engines` is what was actually ASKED for this answer; each result's own
`engines` is what found it. A default engine that failed recently is not
asked and appears under `benched_engines` instead; a rescue pass that
substituted a source appears as `rescued_via`.
Common mistakes:
- Answering from snippets. A snippet is an engine's summary of a page as it
looked when crawled: it drops qualifiers and is often years old. Use
`search` to find the URL, then read the page (`fetch`, `research`) for
any date, amount, rule, deadline or number you will state.
- Treating a result as recent because `freshness=` was set. The filter keeps
undated results; the header says how many could be dated (`dated: 3/10`)
and each result is marked `dated …`, `… (from snippet text)` or `undated`.
- Passing a URL as `query`: that is `fetch`'s job.
- Cranking `max_results` up hoping for better recall; engines cap around
10-20 each, anything beyond is duplicate noise (and 50 is the ceiling).
- Naming engines by default. The default pool is already the set that works
keylessly over plain HTTP, it benches an engine that starts failing and
seats a reserve when it gets thin, and naming engines switches all of
that, and `category=` routing, off. Name engines when you want a
specific index: `engines=["so360","baidu"]` for Chinese-language sites,
`engines=["brave"]` or `["startpage"]` (both need the browser) for a
second opinion.
- Using `category="news"` for breaking news without also setting
`freshness="day"`: the index lags by days.
Args:
query: Natural-language query (the same string a human would type).
engines: Subset of `engines()`. None (recommended) = the health-aware
default pool: duckduckgo, bing, anysearch and mojeek, plus
googlenews when `freshness` is "day"/"week" and a Chinese index for
a Chinese query.
max_results: Merged result count after dedup, clamped to 1-50. It is
also the PER-ENGINE budget, so it multiplies across the fan-out;
5-20 is the useful range and anything past that is duplicate noise
bought with real latency. Omit it for the configured default.
use_cache: Reuse the last result for this exact (query, engines,
max_results, AND all active filters: freshness, include/exclude
domains, category, include/exclude text) within the cache TTL.
Changing any filter is a different cache entry. False forces a
re-fetch.
max_age_hours: Treat cached results older than this as a read miss; a
fresh result is ALWAYS written back to the cache regardless of this
value, so caching is never disabled. Use 0 to force-refresh while
keeping cache writes; None = use server default TTL (7 days).
freshness: "day"|"week"|"month"|"year". Restricts to recent results.
Best-effort: applied as an engine time-window param AND a client-side
date check, but most HTML-engine results carry no parseable date, so
undated results are kept rather than dropped (unknown != old). Treat
it as a strong hint, not a hard filter; googlenews dates are exact.
include_domains: List of domains to restrict to (e.g. ["python.org"]).
exclude_domains: List of domains to exclude.
category: Which KIND of source to search. The enum lists every value.
A bare group widens: "paper" adds one specialist per sub-group to the
default web pool. A dotted sub-group narrows to just the sources that
index it ("paper.biomed" => the biomedical indexes only). It also
RERANKS: engines that natively index the category count double in
the fusion, so the filing outranks the commentary about it, and a
record looked up by the query (a PyPI release, a CVE, an ECB rate,
a forecast) counts five times, so it leads the list. Call
`engines()` for the group -> sub-group -> engine tree with a line on
each source. Two behaviours worth knowing: "image"/"dataset" REPLACE
the web pool rather than augment it (a web engine cannot return an
image file), and "news"/"paper"/"forum"/"github"/"blog" also filter
general-web hits by hostname, so a strict category can thin those
engines out. The specialists it routes to are exempt.
include_text: Substring required in title or snippet (case-insensitive).
exclude_text: Substring forbidden in title or snippet.
format: "markdown" (default) or "json".
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | ||
| format | No | markdown | |
| engines | No | ||
| category | No | ||
| freshness | No | ||
| use_cache | No | ||
| max_results | No | ||
| exclude_text | No | ||
| include_text | No | ||
| max_age_hours | No | ||
| exclude_domains | No | ||
| include_domains | No |