Table of Contents
Fetching ...

Capturing P: On the Expressive Power and Efficient Evaluation of Boolean Retrieval

Amir Aavani

TL;DR

This work reframes information retrieval as a computational operation over the index by introducing a DAG-based Retrieval Language $\mathcal{L}_R$ that precisely captures the complexity class $\mathbf{P}$. It proves both lower and upper bounds for $\mathcal{L}_R$ and presents ComputePN, a polynomial-time evaluator using a Positive-Negative (PN) representation to avoid the classic Tree-Expansion and Universal Scan penalties. The authors demonstrate that the index can function as a general-purpose computational engine, enabling neuro-symbolic reasoning directly within the retrieval process and integrating with ranking via a Dual-Payload protocol. They validate the approach theoretically and with empirical stress testing (e.g., MS MARCO), and propose a practical architecture where LLMs translate natural language into precise $\mathcal{L}_R$ DAGs, enabling context-aware, high-throughput, and interpretable retrieval for agentic search tasks.

Abstract

Modern information retrieval is transitioning from simple document filtering to complex, neuro-symbolic reasoning workflows. However, current retrieval architectures face a fundamental efficiency dilemma when handling the rigorous logical and arithmetic constraints required by this new paradigm. Standard iterator-based engines (Document-at-a-Time) do not natively support complex, nested logic graphs; forcing them to execute such queries typically results in intractable runtime performance. Conversely, naive recursive approaches (Term-at-a-Time), while capable of supporting these structures, suffer from prohibitive memory consumption when enforcing broad logical exclusions. In this paper, we propose that a retrieval engine must be capable of ``Capturing $\mathbf{P}$'' -- evaluating any polynomial-time property directly over its index in a computationally efficient manner. We define a formal Retrieval Language ($\mathcal{L}_R$) based on Directed Acyclic Graphs (DAGs) and prove it precisely captures the complexity class $\mathbf{P}$. We introduce \texttt{ComputePN}, a novel evaluation algorithm that makes $\mathcal{L}_R$ tractable. By combining native DAG traversal with a memory-efficient ``Positive-Negative'' response mechanism, \texttt{ComputePN} ensures the efficient evaluation of any query in $\mathcal{L}_R$. This work establishes the theoretical foundation for turning the search index into a general-purpose computational engine.

Capturing P: On the Expressive Power and Efficient Evaluation of Boolean Retrieval

TL;DR

This work reframes information retrieval as a computational operation over the index by introducing a DAG-based Retrieval Language that precisely captures the complexity class . It proves both lower and upper bounds for and presents ComputePN, a polynomial-time evaluator using a Positive-Negative (PN) representation to avoid the classic Tree-Expansion and Universal Scan penalties. The authors demonstrate that the index can function as a general-purpose computational engine, enabling neuro-symbolic reasoning directly within the retrieval process and integrating with ranking via a Dual-Payload protocol. They validate the approach theoretically and with empirical stress testing (e.g., MS MARCO), and propose a practical architecture where LLMs translate natural language into precise DAGs, enabling context-aware, high-throughput, and interpretable retrieval for agentic search tasks.

Abstract

Modern information retrieval is transitioning from simple document filtering to complex, neuro-symbolic reasoning workflows. However, current retrieval architectures face a fundamental efficiency dilemma when handling the rigorous logical and arithmetic constraints required by this new paradigm. Standard iterator-based engines (Document-at-a-Time) do not natively support complex, nested logic graphs; forcing them to execute such queries typically results in intractable runtime performance. Conversely, naive recursive approaches (Term-at-a-Time), while capable of supporting these structures, suffer from prohibitive memory consumption when enforcing broad logical exclusions. In this paper, we propose that a retrieval engine must be capable of ``Capturing '' -- evaluating any polynomial-time property directly over its index in a computationally efficient manner. We define a formal Retrieval Language () based on Directed Acyclic Graphs (DAGs) and prove it precisely captures the complexity class . We introduce \texttt{ComputePN}, a novel evaluation algorithm that makes tractable. By combining native DAG traversal with a memory-efficient ``Positive-Negative'' response mechanism, \texttt{ComputePN} ensures the efficient evaluation of any query in . This work establishes the theoretical foundation for turning the search index into a general-purpose computational engine.
Paper Structure (34 sections, 2 theorems, 5 equations, 2 figures, 1 table)

This paper contains 34 sections, 2 theorems, 5 equations, 2 figures, 1 table.

Key Result

Theorem 1

The Retrieve Problem is P-Hard.

Figures (2)

  • Figure 1: Query DAG (Ours)
  • Figure 2: Unrolled Tree (Iterator)

Theorems & Definitions (6)

  • Definition 3.1: Query DAG
  • Theorem 1: P-Hardness
  • proof
  • Definition 4.1: PN-Response
  • Theorem 2: Complexity
  • proof