IBM · Filed Apr 10, 2025 · Published Oct 15, 2026

Red Hat Files Patent to Help AI Chatbots Pick the Right Source Document

Chatbots that search your documents can be fooled by a single good paragraph. Red Hat's filing makes them also check each document's summary, keywords and author before choosing what to read.

A setup that breaks documents into pieces and searches them to help an AI answer a person's question. Drawing from patent filing US 2026/0320133 A1.
A setup that breaks documents into pieces and searches them to help an AI answer a person's question.
See all 4 drawings from this filing ↓
Publication number US 2026/0320133 A1 US20260320133A1
Applicant Red Hat, Inc.
Filing date Apr 10, 2025
Publication date Oct 15, 2026
Inventors Farah Juma, Stefano Maestri
US classification 707/759
Examiner SYED, FARHAN M (Art Unit 2161)
Status when we published Approved; patent expected soon (Sep 28, 2026)
Document 20 claims

What Red Hat's document-ranking patent does

Today, many AI chatbots find answers by chopping documents into small passages and grabbing the document whose single passage best matches your question. One good paragraph can drag in a whole document that is otherwise off-topic, and the AI then answers from the wrong material. Red Hat's filing tries to fix that by checking more than the passage.

Alongside each passage, the system stores a numeric fingerprint of facts about the whole document, such as a short summary, a keyword list or the author's name. When you ask a question, it compares your question to the passage and to those extras, then blends the scores into one ranking.

The best-scoring documents are pulled up and handed to the AI along with your question, so its answer rests on a source that fits as a whole.

From the filing · CLAIM 1
generating a first similarity score for the respective chunk embedding by comparing the query embedding to the respective chunk embedding; generating a second similarity score for the respective chunk embedding by comparing the query embedding to a contextual data embedding …

Translation: The system compares the user's search to both the main text chunk and its surrounding background information.

How Red Hat blends passage and metadata scores

The patent covers an upgrade to retrieval augmented generation, or RAG (a method where an AI language model is handed relevant documents to read before it answers). In a standard setup, each document is split into chunks. Each chunk becomes an embedding (a list of numbers that captures its meaning) and is stored in a vector database (a store built for finding similar embeddings).

Here, each chunk's entry also links to contextual data embeddings, which are embeddings of facts about the whole document. The filing names a summary, keywords and author, and also lists the title, tags, source, document type, dates and sentiment. To save memory, document-level embeddings can be stored once and referenced by pointers.

When a question arrives, the system turns it into a query embedding and scores each chunk in several ways:

  • A first score compares the question to the chunk itself.
  • More scores compare the question to each linked contextual embedding.
  • A weighted sum combines them, and the weights can differ. The example formula is Z = aC + bS + cK + dA.

The top-scoring chunks (a preset number, called top-X) point to full documents in a separate document database. Those documents are bundled with the question into one prompt, and the language model writes its answer from that.

From the filing · THE ABSTRACT
A retrieval augmented generation (RAG) process for a large language model (LLM) can be enhanced using contextual data. For example, a system can transform a query into a query embedding and generate weighted similarity scores for chunk embeddings stored in a database.

Translation: Adding extra context helps AI search tools find more accurate documents to answer your questions.

Why better sourcing matters for AI answers

If you've ever asked a chatbot about a pile of documents and gotten an answer that wandered off-topic, the cause can sit in the lookup step, before the AI writes a word. This filing targets that step. Documents get judged on their summary, keywords and author as well as on one matching passage, which the filing says gives the AI better input and therefore better answers.

The patent office has approved the application and Red Hat has paid the fee to have it issued, so it should become a granted patent soon. The filing names no product, and the idea applies to any collection of text, from emails and news articles to academic papers.

IBM's 62nd filing we've tracked since May in the AI guardrails race builds on one that retracts outdated answers and custom tool per request.

Editorial take

If this works as described, you would notice it as fewer confident answers that come from the wrong source. The failure it prevents is a familiar one: you ask about one thing, and the chatbot answers from a document that only mentioned it in passing.

The filing gives no test results, so how much better the answers get stays unknown. The idea itself is easy to trust, because a document's summary and author tell you something about what it is really about.

You would never see any of this happening. It would show up only as an answer that happens to be right more often, which is exactly where a fix like this belongs.

Get our take in your Top Stories

Liked this breakdown? Add Patentlyze as a preferred source on Google, and our plain-English take shows up more often in your Top Stories the next time IBM patent news breaks.

There are more where this came from

We read every patent application Big Tech publishes and send you the ones worth knowing. Plain English, free, every week.

The drawings

4 drawing sheets from US 2026/0320133 A1 · click any drawing to enlarge

Document search for AI answers, drawing sheet 1 from US 2026/0320133 A1
Sheet 1 Document search for AI answers
Computer hardware and database records, drawing sheet 2 from US 2026/0320133 A1
Sheet 2 Computer hardware and database records
Steps for training and answering, drawing sheet 3 from US 2026/0320133 A1
Sheet 3 Steps for training and answering
Steps for answering user questions, drawing sheet 4 from US 2026/0320133 A1
Sheet 4 Steps for answering user questions
Browse all the drawings 4 drawing sheets
Patent filing page

Source. Full patent text and figures from the official USPTO publication PDF.
Reader comments

Be the first to weigh in

Start the discussion

Real name or a handle, either is fine. Comments are read by a person before they appear, so allow a little time. Keep it about the filing.