Retrieval
Hybrid search over all indexed documents, with citations and line anchors.
Orcha indexes all content in a workspace for retrieval: files, database records, and documents from connected sources. search_context does hybrid retrieval over all of this content. It uses PostgreSQL full-text search and pgvector semantic search. It then combines the two result lists with weighted reciprocal-rank fusion.
Queries
The query supports websearch syntax: "quoted phrases" and -excluded terms. strategy can be keyword, semantic, or hybrid (the default).
For difficult questions, give 1 to 8 typed sub-queries in searches. They increase recall, but they do not replace the original question. The original question always has double weight. The sub-query types are:
lex: exact keywords for full-text searchvec: the question in different natural-language words, for vector searchhyde: a hypothetical answer passage of 30 to 80 words. Orcha embeds this passage in place of the question (Hypothetical Document Embeddings)
minScore removes weak results. tokenBudget sets a maximum size for the returned content. explain adds a score trace to each result. The effective search guide shows examples of these parameters.
Freshness modes
Orcha does not index all content in a connected source. Orcha catalogs discover-only objects as metadata and does not store their bodies. The mode parameter controls how Orcha gets this content:
| Mode | Behavior |
|---|---|
fast | Search only retained content. Orcha does not contact a provider |
balanced (default) | Also search the connected-source catalog. When an entry matches the question clearly, get a small number of bodies live from the provider. Orcha chunks these bodies in memory and cites them with syncMode: "live" |
fresh | Also send the query to providers that answer queries live, such as issue trackers |
Orcha counts live calls against the daily provider budget of the connection. Orcha caches live bodies for each revision but does not store them permanently. sourceIds limits a search to specific connected sources.
A response has two parts. results contains the cited evidence. coverage shows the routing. It shows the items that Orcha got live and the catalog items that Orcha did not get. It also shows where a budget limit or an availability limit stopped the search. Coverage notes are not evidence. Do not quote them as content.
Querying one source
If the question is clearly about one provider, query that provider directly. Do not search the full workspace. query_source queries one connected source. It searches retained content first. Then it uses the live-search path or the catalog of the provider, under the same daily budget. fetch_source_document returns the full body of one source document by its external ID. If the document is retained, the body comes from the index. If not, the body comes live from the provider. Both tools are available over REST and MCP. Neither tool operates with a folder-scoped token.
Results and citations
Each result includes content, score, a citation, the folder or source context, and the document updatedAt. It also includes a location with startLine/endLine anchors and the Markdown headingPath. After a search, agents must use a ranged get_file (fromLine, maxLines). Agents must not get full files.
Native records cite /databases/:databaseId?record=:recordId. Synced documents cite their upstream source, at the exact version that Orcha indexed.
Memories and workspace discovery
For known workflows that need a complete, curated set of sources, use memories, not search. A memory groups files, full folders, connected-source documents, and database views. When the memory loads, each member gives its current contents. Coverage notes show members that Orcha excluded, truncated, or could not get. An agent that does not know a workspace must start with get_workspace_overview. This tool gives a summary of files, folders, index state, recent changes, connected sources, and available memories. list_memories returns the useWhen guidance of each memory. get_memory gets the complete current contents of a memory by slug.
Use memories when the task matches a curated set. Use search_context for open questions that need only the most relevant excerpts.