Skip to content

LearnRetrieve

Step-back prompting

Step-back query

Asking a model for a more general version of a specific question, then searching with both the original and the general query.

In DocSlurpGlossary entry

On this page

Step-back prompting asks a language model to generalize a question before searching. “Can my assistant book the Learjet for a $55k London trip on Friday?” steps back to “private jet booking and approval policy”. The specific question searches for a passage that mentions the Learjet, $55k and Friday together, which may not exist. The general question finds the policy page that states the rule, and the answer follows from the rule.

The technique comes from a 2023 paper on reasoning, where models answered better after first recalling the principle behind a question. For retrieval, systems usually search with both versions and fuse the lists, so the specific query still finds an exact match if one exists.

The gotcha: too far back

A model asked to generalize may climb too high: “how does business travel work?” returns introductory material instead of your $40k threshold. And step-back adds a model call to each search. It pays off for specific questions over documents organized around general rules: policies, standards, textbooks, contracts. For lookups of a single fact that the documents state directly, it mostly adds latency.

In DocSlurp, stepback: true generates one generalized query, runs it alongside the original in parallel and fuses the two result lists with reciprocal rank fusion.

In DocSlurp

In DocSlurp

Off by default; stepback: true asks a model for one generalized query, runs the original and generalized searches in parallel and fuses them with RRF (core/server/src/search/stepback.ts, core/server/src/search/session-planner.ts).

Sources

Jump to