JevMade Sign in
← Back to guides

JevMade field notes / Worked Spring AI retrieval tutorial

Search widely, then check the passages

Christian Tzolov combines broader document search with Jev checks that filter passages and rank the remaining answer evidence.

Original by Christian TzolovRetrieval

Listen to this guide

JevMade’s plain-English explanation

0:00 /

AI narration

Credits

“Spring AI Modular RAG and TypeSafe Jev: Retrieve More, Keep Only What Answers” by Christian Tzolov. Read the original source.

This expanded guide is an AI-narrated adaptation prepared by JevMade. It expands the source’s essential ideas, examples and caveats in JevMade’s own words and is not a word-for-word reading. The synthetic voice does not imitate the author or imply their endorsement.

Our summary

A document search can find text about the right subject without finding an answer. Christian Tzolov's Spring AI tutorial rewrites a reader's question and searches several versions of it. Jev then checks the retrieved passages before a text-generating model uses them to answer the reader.

Four yes-or-no questions check each passage for hostile instructions, contradiction, relevance and answer evidence. After screening hostile instructions, the filter keeps evidence that challenges what the question assumes. Another Jev check ranks the remaining passages. The author's Hurricane Milton example narrows six retrieved passages to two useful ones.

If Jev fails, passages may continue unchecked or unscored. The final passage limit still applies, so contradictory evidence can be lost later. Filtering and ranking add service requests. Two extra text-model calls rewrite the question and produce search variants before retrieval. The example is not a security guarantee.

Key takeaways

  1. Retrieve broadly, then distinguish text about a topic from text that actually answers the question.
  2. Check hostile instructions first. Evidence that passes that check should not be discarded just because it contradicts the question.
  3. Count filtering and ranking requests separately, and decide whether continuing without those checks is acceptable when the service fails.

The author's example was not independently reproduced. Filtering makes one Jev request per passage; ranking makes another for each passage that remains. Each batch allows four requests in progress at once by default. The six-to-two example implies eight Jev requests before retries. Both stages continue on service failure, but the final passage limit still applies.

Spring blog · Original published

Read the original guide Opens the author’s site in a new tab.

Keep this for later

Sign in to bookmark experiments, guides and videos, and keep notes only you can see.

Continue to sign in

We’ll bring you back to this listing.