Blog
Start here
Read these in order. Each part builds on the one before.
- Part 1 of 7Can you send the whole document?
Building an app that answers questions from documents? Learn when to send the whole file, what counts toward the input limit, and when to select passages.
- Part 2 of 7What changes when the documents no longer fit?
When documents no longer fit in one request, your app must choose passages. Check which passages each request contains and whether they are current.
- Part 3 of 7How should you divide documents into passages?
Learn how to divide documents into passages, choose size and overlap, preserve tables and source details, and test the results against your questions.
- Part 4 of 7Which matching passages should reach the model?
Learn how search scores, top-k and reranking decide which passages go into the model's request, and how to check that the passage a question needs got in.
- Part 5 of 7How should an answer cite your documents?
Learn what citation features return, the two ways a citation fails, and a first setup that checks each cited passage against its statement.
- Part 6 of 7When should an answer say "I don't know"?
Learn when an answer should say "I don't know", how to tell missing evidence from a passage that never arrived, and a first check.
- Part 7 of 7How do you test the answers your application gives?
Compare your document app's answers before and after a change. Save requests, check evidence and citations, and compare automatic scores with human review.
Problem-solving guides
Ingestion
- How do you fix PDF tables and broken reading order?
Find where PDF extraction merges table rows, shifts columns or breaks reading order, then change that stage and test the answers that depend on tables.
Retrieval
- How to fix stale answers after a document update
Trace why your application keeps answering from old documents. Check updates, deletions, synchronization, cleanup and version filters.
Agent runs
- How to resume agent runs without duplicate actions
When a crashed agent run sends an email twice, check saved progress, isolate side effects, reuse idempotency keys and test recovery with a controlled crash.
Go deeper
Preparing documents
- How do you extract reliable text from PDFs and scans?
Choose how to extract text from PDFs and scans, preserve tables and page locations, and check for missing pages, scrambled wording and added text.
- How do you prepare documents so search finds the right version?
Attach source, version and effective-date metadata to documents, filter search by it, and check that updates and deletions reach search.
Search and retrieval
- Should you search documents by words, meaning or both?
Compare keyword, embedding and hybrid search for document questions. Learn how results are combined and test whether the deciding passage reaches the model.
- How do you measure whether search finds the right passages?
Measure whether document search finds the passages needed to answer a question. Compare recall, precision and ranking, and keep your evidence labels valid.
Agents and graphs
- When does a knowledge graph help document search?
Decide when a knowledge graph helps document search: which questions need one, what it costs to build and keep current, and a first check.
- When does agentic RAG help document search?
Agentic RAG lets a model search your documents in several steps. See which questions it helps, what it costs, how to limit a run and how to test it.