DOCUMENT SEARCH & ANSWERS
How documents become searchable
A file on a shared drive is a picture of pages. Before anyone can search it, something has to read it, cut it into passages and index what it says, by its words and by its meaning.
- ReadText is pulled out page by page, with its headings, author and language.49 pages · 8,303 words
- SplitThe text is cut into passages along its headings.49 passages
- UnderstandA summary, keywords and a category are written for it.category: hr
- IndexEvery passage is indexed by its words and by its meaning.words + meaning
- SearchA search returns the document, and the passage inside it.Employee Handbook · page 29
A file is not a searchable thing
Every company has a shared drive, and every shared drive has a search box that finds files by their names. That works for the file you named yourself last week. It does not work for the question people actually have, which is never "where is employee-handbook-2027.pdf" and always "how many days do I have to file an expense claim". The answer to that is a sentence on one page of one file, and a file name says nothing about sentences.
The reason is that a document, as stored, is built for reading and printing. A PDF describes where ink goes on a page. A Word file is text wrapped in formatting. A spreadsheet is cells, a presentation is slides, a scan is a photograph of paper. None of them is organized for the one thing a search needs: given some words, or an idea, find the place that matches. Making documents searchable means building that organization beside the files, once, and keeping it current.
Step one: read it
Before anything else, the text has to come out of the file. This is called extraction, and it is less trivial than it sounds, because each format hides its text differently. A good extractor returns the words in reading order, where each page begins and ends, which lines are headings, and the details the file carries about itself: title, author, language, page count. For the Employee Handbook 2027 used in the examples here, that is 49 pages and 8,303 words, written in English, with a heading on nearly every page.
Two honest limits belong at this step. A scanned page is a picture, and its words exist only after optical character recognition has read them, which a system either has switched on or has not. And some files cannot be read at all: a password-protected PDF, a damaged file, a format nobody recognizes. A trustworthy system says so, per file, instead of quietly indexing nothing and letting a search come back empty.
Step two: cut it into passages
A 49-page handbook is not about one thing. It is about joining, attendance, leave, travel, expenses and IT support, and a question is only ever about one of them. So the text is cut into passages: a few paragraphs under one heading, each remembering its heading and the page it came from. The handbook becomes 49 passages, and the search works on those. This is the step that lets a result say "page 29" rather than "somewhere in this file". What is a passage? covers how the cuts are made and why their size matters.
Step three: understand it
This step is optional, and it is where an AI model first earns its place. Given the text, a model can write what nobody has time to: a short summary of what the document covers, the keywords it is about, and a category from a list the organization defines, such as policy, contract or manual. The handbook lands in the category hr without anyone filling in a form.
None of this changes what the document says. It changes how quickly a person can recognize it. A result list that shows a two-sentence summary under each title is a list you can scan; a category and keywords are filters you can click. The work is done once, when the file arrives, not every time someone searches.
Step four: index it twice
Now the passages are indexed, and the modern answer is to index each one in two ways. The first is by its words: every term is recorded with the passages that contain it, which is what makes a search for "reimbursement" return in milliseconds and forgive a typo. This is the same structure that powers product search, described in Full-text search vs database LIKE.
The second is by its meaning. An AI model turns each passage into a long list of numbers that places it on a kind of map, where passages about similar things sit close together. A question is placed on the same map, and the nearest passages are the answer, even when they share no words with the question. "Getting paid back for a client trip" lands beside the expense policy. Keyword vs semantic vs hybrid search compares the two and explains why most searches should use both.
Two answers from one search
With documents and passages both indexed, one search can be read two ways. Search the demo library for "expense reimbursement" and the documents view returns 2 results: the handbook and the processes manual, the files that are about the subject, each with its summary and category. The passages view returns 26: the sections that say something about it, each with its heading and page.
- Employee Handbook 2027hr
- Company Processes Manual 2027manual
- Which files are about it
- Not yet where they say it
- Filing deadline and claim preparationp. 29
- Manager approval and Finance reviewp. 13
- Worked example for a taxi claimp. 34
- The section that says it, with its page
- Opens at that place in the document
The two views answer different questions. The first is "which files should I know about?" The second is "where does it say so?": the filing deadline on page 29 of the handbook, the approval steps on page 13 of the processes manual, a worked taxi example on page 34. Opening a passage lands on that place in the document, not on its cover.
Keeping it current
An index is a copy, and documents change. Three behaviours separate a system people keep trusting from one they abandon. A changed file is read and indexed again, replacing its old passages rather than adding to them. A removed file drops out of search, so nobody is sent to a policy that was withdrawn. And the same file added twice is recognized by its content and indexed once, however many names it travels under. Pointing the system at the folder where documents already live, and letting it check on a schedule, makes all three automatic.
Who can find what
Search across every document is only acceptable if "every" means "every one you are allowed to see". The usual arrangement groups documents into workspaces - HR, legal, finance, a project - and grants each person or group the workspaces they need. The restriction has to be applied inside the search itself, before results are ranked, not by hiding results afterwards. Access control: users, groups and scoped views describes the same model for dashboards.
Where it stops
Document search finds what documents say. It does not add up a column across a thousand invoices; that is a question about records, answered by an index of records and described in Three ways AI answers from your data. It inherits the quality of the documents: two versions of a policy will both be found, and it is the reader, or a citation, that shows which is which. And a table cut across two pages is still a table cut across two pages. What it reliably removes is the first and longest step of every document question: finding the page.