Mapping text to large taxonomies of 100,000+ labels, whether that's biomedical entity linking, vendor normalization, or company deduplication, is a common production problem where regex, trained classifiers, and direct LLM calls all struggle on cost, maintenance, and context limits.

Our solution pairs vector search with the Databricks AI Classify function: retrieve a shortlist of candidate labels per document, then let the AI Classify function pick from that shortlist instead of the full taxonomy.

Across three benchmarks spanning these use cases, SQL-native vector search plus AI Classify beat the best cost-efficient frontier model by five points of accuracy at roughly a hundredth of the token cost.

Across Databricks, thousands of customers build production workloads that map freeform text to normalized taxonomies of 100k+ labels. A few common use cases include:

Biomedical entity linking. Clinical notes and research papers mention diseases, drugs, and procedures that must be matched to a concept in the Unified Medical Language System, a vocabulary with thousands of biomedical concept identifiers.

Vendor normalization. To analyze spending patterns, financial companies normalize raw transaction strings like "SBUX #4471 SEATTLE WA" against a set of 100,000+ merchants.

Company normalization. Enterprises deduplicate customer records across different internal systems by matching company descriptions against a set of 100,000+ companies.

Each of these use cases defines a large set of labels, also called a taxonomy, and every input must be mapped to one or more of its labels. Customers typically evaluate their production solution based on these criteria:

Quality: Produce classifications that are accurate enough to drive downstream decisions.

Throughput: Process large workflows, often on the order of hundreds of thousands of documents, within a reasonable timeframe.

Meeting all three requirements makes production large taxonomy classification difficult, and we prioritize researching and building solutions to them at Databricks.

Historically, organizations approached large taxonomy classification by relying on custom regex rules, keyword matching, and supervised machine learning classifiers. However, these approaches fall short on a few dimensions: