Skip to content

BIREME Bulletin n. 114

Search in your own words: natural language in the VHL Regional Portal (Part 2 of 2)

In the first part of this article, we saw that natural language search can bring users’ questions closer to the documents available in the VHL Regional Portal without replacing the precision of Boolean search. We also saw that, in a multilingual collection, embedding models need to be evaluated in the context of scientific production and the linguistic diversity of Latin America and the Caribbean. But making this search work as a service requires addressing decisions that remain invisible to anyone who simply types a question.

The hidden cost of an instant

For users, the operation should take only an instant. For the infrastructure, that instant contains an entire sequence of work: receiving the query, processing the text, generating its vector, searching for the nearest neighbors in the index, and returning the results along with filters and metadata.

Document vectors can be produced in batches, outside peak usage hours. The query vector cannot. It has to be generated in real time. This requires keeping the model available in memory and sizing the service for simultaneous queries. A prototype may work very well for one person and still fail as a service when fifty people ask questions at the same time. In this case, speed is not a finishing touch. It is part of the functionality.

There is also the weight of the index itself. To get a sense of scale: one million vectors with 4,096 32-bit values would occupy about 16 gigabytes just for the raw numbers. The structure used to locate neighbors, identifiers, metadata, backups, and the margin required for operation would still need to be added. We can reduce dimensions, compress values, or adopt other techniques, but every saving needs to be tested against a possible loss of quality.

There is also a less obvious consequence: vectors produced by different models do not necessarily share the same map. Changing the model may require recalculating the entire collection. In a continuously updated portal, this turns the choice of model into a commitment involving architecture, versioning, and maintenance. It is not something that can simply be swapped out.

As I have written before in this column, all computing comes at a cost. Vector search confirms the rule. It costs memory, processing, storage, energy, and engineering time. The challenge is to ensure that this cost is proportional to the benefit delivered.

What, exactly, is a document?

Before transforming a document into a vector, we need to answer an apparently elementary question: which part of it best represents its meaning?

The title is concise, but it may be insufficient. The abstract contains the problem, methods, and results, but not every record has an abstract. The full text is rich, but long and noisy. DeCS descriptors carry decades of specialized knowledge organization, but they do not capture every nuance of a question. Author, country, language, study type, and year are essential for filtering results, although they should not necessarily carry the same weight in semantic similarity.

Combining everything indiscriminately can dilute what matters. Dividing a text into small fragments can improve the ability to locate a passage, but it can also separate a statement from the context that gives it meaning. Representing only the abstract may exclude precisely the regional or technical literature that does not have one.

This may be one of the decisions most characteristic of BIREME. We do not start from an anonymous pile of texts. We start from records enriched by networks of libraries, cooperating centers, indexers, and controlled vocabularies. The new architecture should not erase this heritage in order to start from scratch. It should learn to use it better.

Proximity is not relevance

There is another essential caution. A semantically close document is not automatically the document a person needs.

A search on treatment may retrieve a study on a biological mechanism. A question about older adults may be close to an article that merely mentions aging. A query about a health policy may retrieve a conceptually similar text from another health system with no regional applicability. The model calculates proximity; relevance also depends on the population, study design, date, context, and the searcher’s intent.

That is why filters and metadata remain necessary. In some scenarios, the most robust solution may be hybrid: combining the strength of lexical matching with semantic approximation and then reranking the results. Broad information retrieval evaluations show precisely that lexical methods remain robust benchmarks, while neural models and reranking stages can improve results at higher computational costs.[1] There is no universal winner.

Vector search does not know how to say “I found nothing”

Boolean search returns zero results, and zero is valuable information: your strategy is too narrow, or what you are looking for does not exist in the collection.

Vector search, by design, never returns an empty result set. It always has a nearest neighbor to offer, even if that neighbor is very far away. Without a cutoff criterion, the system delivers the least irrelevant result and calls it a result. Caution is needed.

An interface is also a method

When natural language search reaches the interface, it will need to explain itself.

Users should know which mode they are searching in, what the system will do with their question, and what type of result they will receive. Advanced search cannot disappear behind a simplified experience. Filters need to remain available. Examples should teach without making users feel constrained. And the visual language should not suggest that the new option answers clinical questions, when what it actually does is retrieve and rank scientific and technical information. Importantly: Finding is not answering.

In the first article in this series, I recalled that the value of the CD-ROM for BIREME never lay only in possessing the technology. It lay in what our Region was able to read within it. The same standard applies now. The goal is not to put AI in the search box. It is to reduce the distance between a human question and the evidence that can help address it, without taking away from skilled searchers the rigor, control, and memory of the path they followed.

Perhaps a librarian will continue to prefer a carefully constructed Boolean strategy. Perhaps a health professional will begin with a natural language question. Perhaps the same person will alternate between the two approaches as the investigation develops.
Making access easier is an obligation of a public good. But it cannot come at the cost of being able to retrace the path. That is why we are not building a new search to replace the old one. We are building a second door and making sure it leads to the same library.

Until next month.

By Francisco Barbosa Junior, Digital Solutions and Emerging Technologies at BIREME.

 

Reference

[1] Thakur N, Reimers N, Rücklé A, Srivastava A, Gurevych I. BEIR: A Heterogeneous Benchmark for Zero-shot Evaluation of Information Retrieval Models. 2021.

Related articles

View all