Skip to main content

JSON pipelines

Use --output json whenever another program will consume the results.

Keep stdout machine-readable

Search, fetch, and ranking progress is written to stderr, so redirecting stdout does not mix diagnostics into the JSON document. To suppress progress messages as well:

Select fields with jq

Reduce downstream context

Limit both the result count and extracted text when sending results to a model:

Handle empty results

An empty successful search emits an empty JSON array and exits successfully:
A failure of every requested search exits with status 1 and writes the error to stderr. Partial successes in fanout mode are retained. See the output schema for field definitions.