Web search and page reading

DataMind Oda reaches the web with two tools: web_search finds pages for a question, and web_fetch reads a single page. This page is the reference for both calls: what each one accepts, the limits it works under, and the messages it can return. How Oda works with the web in a task is on How Oda uses the web.

The two web tools

Searching the web

Reading a page

How web results are labelled

Limits and defaults

The table lists the defaults; every value is set for your deployment.

LimitDefault
Queries in one searchUp to 4
Sources kept from a searchUp to 8
Time budget per web call30 seconds
Text kept from a page readUp to 200,000 characters

Messages a web call can return

A call built with a missing or wrong argument is refused before anything runs, and the refusal stays with the step:

MessageWhat it means
Error: queries must contain at least one queryThe call carried no queries.
Error: queries must contain at most <count> queriesThe call carried more queries than the bound allows.
Error: each query must be a non-empty stringOne of the call's queries was blank.
Error: url must be a non-empty stringThe read carried no address.

When one of these is returned, nothing was searched or read.

Questions, answered

How many queries can one search carry?

Between one and four; four is the default bound and your deployment can set a different one. When the same query is written twice, only the first copy is searched.

What happens when one of several queries fails?

The other searches are stopped and the first failure is reported; nothing partial comes back. Ask again for a fresh search.

Why does a search list end with (Showing the first <count> sources. Refine the query for more.)?

The search found more sources than the bound keeps (eight by default), so the list was cut to the bound. Refine the query for more, as the note says.

How long may a web call run?

Each call has a time budget, 30 seconds by default. A call that runs past its budget is stopped and reported as timed out.

Where does the rest of a large read go?

When even the capped result would fill the chat, the full text is kept in a file on this computer and the result shows a preview with Full formatted result stored at: plus a hint for reading it back. Where large results go covers those files.

What does [HTML content omitted: unable to convert safely.] mean?

The page's markup could not be converted safely, so its text was left out of the result. The page itself is unchanged; open its address to read it.

Why do web results carry a note about untrusted content?

The note marks what came from the web as information to weigh, never as instructions to follow. It stays with the result so anyone reading the step sees it.

Can I set a timeout or a size on a web call?

No. A call carries only the queries or the address, and the limits in the table above are set for your deployment, not per call.

What address can Oda read?

One full web address at a time, an http:// or https:// one. A search finds addresses for a question; a read takes one of them.

What do the Error: ... lines in a web step mean?

They are the call's own refusals, kept with the step: the call carried no queries, more queries than the bound allows, a blank query, or no address. Nothing was searched or read.