firehose> #llmops

Search-Then-Get

A deliberate two-tool split for how an agent pulls memory into context: a search tool returns lean results — file path, line numbers, a relevance score, a short preview (OpenClaw caps at ~700 chars), and citation info — and a separate get tool fetches an exact line range from a chosen file. Search returns just enough to decide what's relevant; get pulls only the specific content actually needed. The point is to keep the context window lean: never load whole files when a preview plus a targeted fetch will do. The chunk-level line-range metadata (stored at index time) is what makes get precise and lets the agent cite exactly where a memory came from.

This is the attention-budget discipline expressed as a tool contract: the shape of the two tools forces progressive disclosure instead of dumping candidate documents into context. It's the same cheap-recall-then-expensive-precision staging as Reranking, but the scarce resource being protected is the context window, not compute. OpenClaw makes the first step a "mandatory recall step" — its prompt tells the agent to search memory before answering about prior work, decisions, dates, people, preferences, or to-dos — so recall happens reliably rather than being skipped. Pairs naturally with Evergreen vs Volatile Context (what's allowed in) and Context Routing (where to look): search-then-get governs how much of a found memory reaches the window.

Claims


Linked from